[COMMON] Align Makefile with last changes 87/109887/1
authorSylvain Desbureaux <sylvain.desbureaux@orange.com>
Tue, 7 Jul 2020 08:26:46 +0000 (10:26 +0200)
committerSylvain Desbureaux <sylvain.desbureaux@orange.com>
Tue, 7 Jul 2020 08:26:46 +0000 (10:26 +0200)
Previous changes on Makefile prevents it to work.

Issue-ID: OOM-2412
Signed-off-by: Sylvain Desbureaux <sylvain.desbureaux@orange.com>
Change-Id: Idee3ccff03d1b216eb52ef17d2397873d5d5d0dc

kubernetes/Makefile

index 38fbf4f..ee9e8d9 100644 (file)
@@ -32,7 +32,7 @@ HELM_CHARTS := $(filter-out $(EXCLUDES), $(sort $(patsubst %/.,%,$(wildcard */.)
 
 .PHONY: $(EXCLUDES) $(HELM_CHARTS)
 
-all: $(COMMON_CHARTS_DIR) $(HELM_CHARTS) plugins
+all: $(COMMON_CHARTS_DIR) $(SUBMODS) $(HELM_CHARTS) plugins
 
 $(COMMON_CHARTS):
        @echo "\n[$@]"
@@ -42,6 +42,18 @@ $(HELM_CHARTS):
        @echo "\n[$@]"
        @make package-$@
 
+$(SUBMODS):
+       @echo "\n[$@]"
+       @make submod-$@
+       @make package-$@
+
+submod-%:
+       @make $*/requirements.yaml
+
+%/requirements.yaml:
+       $(error Submodule $* needs to be retrieved from gerrit.  See https://wiki.onap.org/display/DW/OOM+-+Development+workflow+after+code+transfer+to+tech+teams ); fi
+
+
 make-%:
        @if [ -f $*/Makefile ]; then make -C $*; fi
 
@@ -49,7 +61,7 @@ dep-%: make-%
        @if [ -f $*/requirements.yaml ]; then helm dep up $*; fi
 
 lint-%: dep-%
-       @if [ -f $*/Chart.yaml ]; then helm lint $*; fi
+       @if [ -f $*/Chart.yaml ]; then $(HELM_LINT_CMD) $*; fi
 
 package-%: lint-%
        @mkdir -p $(PACKAGE_DIR)