make-rules/attpackagemake.mk
changeset 4091 fca9099ab398
parent 3864 77a09e73626b
child 4252 891a844655c4
--- a/make-rules/attpackagemake.mk	Tue Apr 07 05:51:44 2015 -0700
+++ b/make-rules/attpackagemake.mk	Thu Apr 09 18:28:09 2015 -0700
@@ -60,9 +60,11 @@
 
 # The install and test process needs the same environment as the build
 COMPONENT_INSTALL_ENV = $(COMPONENT_BUILD_ENV)
+COMPONENT_INSTALL_ARGS = HOSTTYPE="$(HOSTTYPE$(BITS))"
 COMPONENT_TEST_ENV = $(COMPONENT_BUILD_ENV)
-COMPONENT_INSTALL_ARGS = HOSTTYPE="$(HOSTTYPE$(BITS))"
 COMPONENT_TEST_ARGS = HOSTTYPE="$(HOSTTYPE$(BITS))"
+COMPONENT_SYSTEM_TEST_ENV = $(COMPONENT_BUILD_ENV)
+COMPONENT_SYSTEM_TEST_ARGS = HOSTTYPE="$(HOSTTYPE$(BITS))"
 
 # build the configured source
 $(BUILD_DIR)/%/.built:	$(SOURCE_DIR)/.prep
@@ -115,6 +117,33 @@
 	$(COMPONENT_TEST_CLEANUP)
 	$(TOUCH) [email protected]
 
+# test the installed packages
+$(BUILD_DIR)/%/.system-tested-and-compared:    $(SOURCE_DIR)/.prep
+	$(RM) -rf $(COMPONENT_TEST_BUILD_DIR)
+	$(MKDIR) $(COMPONENT_TEST_BUILD_DIR)
+	$(COMPONENT_PRE_SYSTEM_TEST_ACTION)
+	-(cd $(COMPONENT_SYSTEM_TEST_DIR) ; \
+		$(COMPONENT_SYSTEM_TEST_ENV_CMD) $(COMPONENT_SYSTEM_TEST_ENV) \
+		bin/package test $(COMPONENT_SYSTEM_TEST_TARGETS) \
+		$(COMPONENT_SYSTEM_TEST_ARGS) \
+		&> $(COMPONENT_TEST_OUTPUT)
+	$(COMPONENT_POST_SYSTEM_TEST_ACTION)
+	$(COMPONENT_TEST_CREATE_TRANSFORMS)
+	$(COMPONENT_TEST_PERFORM_TRANSFORM)
+	$(COMPONENT_TEST_COMPARE)
+	$(COMPONENT_SYSTEM_TEST_CLEANUP)
+	$(TOUCH) [email protected]
+
+$(BUILD_DIR)/%/.system-tested:    $(SOURCE_DIR)/.prep
+	$(COMPONENT_PRE_SYSTEM_TEST_ACTION)
+	cd $(COMPONENT_SYSTEM_TEST_DIR) ; \
+		$(COMPONENT_SYSTEM_TEST_ENV_CMD) $(COMPONENT_SYSTEM_TEST_ENV) \
+		bin/package test $(COMPONENT_SYSTEM_TEST_TARGETS) \
+		$(COMPONENT_SYSTEM_TEST_ARGS)
+	$(COMPONENT_POST_SYSTEM_TEST_ACTION)
+	$(COMPONENT_SYSTEM_TEST_CLEANUP)
+	$(TOUCH) [email protected]
+
 ifeq   ($(strip $(PARFAIT_BUILD)),yes)
 parfait: build
 else