Files
gnatdashboard/sonar-ada/Makefile
Nicolas Setton cb3b97f6a6 SB30-014 Prepare grounds for using maven in offline mode
Add support for extra environment variables that will be
passed by anod to toggle online/offline mode.

Change-Id: I253ce195e987ab6f4afbd701a1934df96c6e2d9d
2019-12-04 22:07:29 +00:00

27 lines
749 B
Makefile

BUILD_DIR := target
RESULTS_DIR := $(BUILD_DIR)
MVN := BUILD_DIR=$(BUILD_DIR) mvn -PalternateBuildDir
MVN_OPTS := -Xmx512m $(MAVEN_OPTS)
MVN_BUILD_OPTS := -Dmaven.test.skip=true
MVN_TEST_OPTS :=
.PHONY: build
build:
MAVEN_OPTS="$(MVN_OPTS)" $(MVN) $(MVN_BUILD_OPTS) $(MAVEN_ANOD_OPTS) package
set-version:
MAVEN_OPTS="$(MVN_OPTS)" $(MVN) $(MAVEN_ANOD_OPTS) versions:set "-DnewVersion=$(SONAR_ADA_PLUGIN_VERSION)"
test:
# The maven command can fail because of the tests, but we want the report to
# be generated afterward.
-MAVEN_OPTS="$(MVN_OPTS)" $(MVN) $(MVN_TEST_OPTS) $(MAVEN_ANOD_OPTS) package
python surefire-to-gnatpython-report.py \
-i $(BUILD_DIR)/surefire-reports \
-o $(RESULTS_DIR)
clean:
$(MVN) clean