sbsv2/raptor/lib/flm/build.flm
branchwip
changeset 11 ea23b18a2ff6
parent 7 f9fd2a994239
child 12 2cfea3290625
--- a/sbsv2/raptor/lib/flm/build.flm	Wed Nov 18 21:50:36 2009 +0000
+++ b/sbsv2/raptor/lib/flm/build.flm	Thu Nov 19 18:52:19 2009 +0000
@@ -34,7 +34,7 @@
 define doexports
 PP_EXPORTS::
 	$(call startrule,makefile_generation_exports) \
-	$(SBS) --pp=slave --toolcheck=off --export-only $(component_list) $(config_list) -f- -m $(MAKEFILE_PATH).exports $(CLI_OPTIONS)  \
+	$(SBS) --toolcheck=off --export-only $(component_list) $(config_list) -f- -m $(MAKEFILE_PATH).exports $(CLI_OPTIONS)  \
 	$(call endrule,makefile_generation_exports)
 
 CLEANTARGETS:=$$(CLEANTARGETS) $(MAKEFILE_PATH).exports 
@@ -46,9 +46,9 @@
 
 ALL:: $(MAKEFILE_PATH)
 
-$(MAKEFILE_PATH): $(COMPONENT_PATHS) | PP_EXPORTS 
+$(MAKEFILE_PATH): $(COMPONENT_PATHS) $(if $(DOEXPORT),| PP_EXPORTS )
 	$(call startrule,makefile_generation) \
-	$(SBS) --pp=slave --toolcheck=off -n $(CLI_OPTIONS) $(component_list) $(config_list) -m $$@ -f- \
+	$(SBS) --noexport --toolcheck=off -n $(CLI_OPTIONS) $(component_list) $(config_list) -m $$@ -f- \
 	$(call endrule,makefile_generation)
 
 CLEANTARGETS:=$$(CLEANTARGETS) $(MAKEFILE_PATH) 
@@ -58,9 +58,13 @@
 # Create config list for commands
 config_list:=$(addprefix -c ,$(CONFIGS))
 component_list:=$(addprefix -b ,$(COMPONENT_PATHS))
-$(info <debug>build.flm: configlist: $(config_list)</debug>)
+
+$(if $(FLMDEBUG),$(info <debug>build.flm: configlist: $(config_list)</debug>))
 
-$(eval $(doexports))
+# Do exports only if asked. This doesn't work brilliantly in emake
+# since exports are often duplicated in some components - leads to conflicts 
+# and rebuilds.  Better to export before trying to do parallel parsing at all.
+$(if $(DOEXPORT),$(eval $(doexports)),$(if $(FLMDEBUG),$(info <debug>build.flm: Exports off </debug>)))
 
 # Create the Makefiles
 $(eval $(call generate_makefiles))