From 29a673abff645c7079c3358c1b88c223f878eb2b Mon Sep 17 00:00:00 2001 From: erikj Date: Fri, 4 Jan 2013 17:08:33 +0100 Subject: [PATCH] 8005654: build-infra: Create sec-bin.zip Reviewed-by: tbell --- common/bin/compare.sh | 15 +++++++++++++++ common/makefiles/JavaCompilation.gmk | 8 +++++++- 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/common/bin/compare.sh b/common/bin/compare.sh index e2684db956..aab24421ca 100644 --- a/common/bin/compare.sh +++ b/common/bin/compare.sh @@ -1166,6 +1166,15 @@ if [ -z "$OTHER_DOCS" ]; then echo "WARNING! Other build doesn't contain docs, skipping doc compare." fi +if [ -f "$OTHER/tmp/sec-bin.zip" ]; then + OTHER_SEC_BIN="$OTHER/tmp/sec-bin.zip" +elif [ -f "$OTHER/images/sec-bin.zip" ]; then + OTHER_SEC_BIN="$OTHER/tmp/sec-bin.zip" +else + echo "WARNING! No sec-bin.zip found in other." +fi +THIS_SEC_BIN="$THIS/images/sec-bin.zip" + ########################################################################################## # Do the work @@ -1282,6 +1291,12 @@ if [ "$CMP_ZIPS" = "true" ]; then if [ -n "$THIS_J2SDK" ] && [ -n "$OTHER_J2SDK" ]; then compare_all_zip_files $THIS_J2SDK $OTHER_J2SDK $COMPARE_ROOT/j2sdk fi + if [ -n "$THIS_SEC_BIN" ] && [ -n "$OTHER_SEC_BIN" ]; then + if [ -n "$(echo $THIS_SEC_BIN | $FILTER)" ]; then + echo "sec-bin.zip..." + compare_zip_file $(dirname $THIS_SEC_BIN) $(dirname $OTHER_SEC_BIN) $COMPARE_ROOT/sec-bin sec-bin.zip + fi + fi fi if [ "$CMP_JARS" = "true" ]; then diff --git a/common/makefiles/JavaCompilation.gmk b/common/makefiles/JavaCompilation.gmk index 54ce927dd7..59adc33977 100644 --- a/common/makefiles/JavaCompilation.gmk +++ b/common/makefiles/JavaCompilation.gmk @@ -250,7 +250,7 @@ endef define SetupZipArchive # param 1 is for example ZIP_MYSOURCE # param 2,3,4,5,6,7,8,9 are named args. - # SRC,ZIP,INCLUDES,EXCLUDES,EXCLUDE_FILES,SUFFIXES,EXTRA_DEPS + # SRC,ZIP,INCLUDES,INCLUDE_FILES,EXCLUDES,EXCLUDE_FILES,SUFFIXES,EXTRA_DEPS $(foreach i,2 3 4 5 6 7 8 9 10 11 12 13 14 15, $(if $($i),$1_$(strip $($i)))$(NEWLINE)) $(call LogSetupMacroEntry,SetupZipArchive($1),$2,$3,$4,$5,$6,$7,$8,$9,$(10),$(11),$(12),$(13),$(14),$(15)) $(if $(16),$(error Internal makefile error: Too many arguments to SetupZipArchive, please update JavaCompilation.gmk)) @@ -267,6 +267,12 @@ define SetupZipArchive else $1_ZIP_INCLUDES := $$(addprefix -i$(SPACE)$(DQUOTE),$$(addsuffix /*$(DQUOTE),$$($1_INCLUDES))) endif + endif + ifneq ($$($1_INCLUDE_FILES),) + $1_SRC_INCLUDES += $$(foreach i,$$($1_SRC),$$(addprefix $$i/,$$($1_INCLUDE_FILES))) + $1_ZIP_INCLUDES += $$(addprefix -i$(SPACE),$$($1_INCLUDE_FILES)) + endif + ifneq ($$($1_SRC_INCLUDES),) $1_ALL_SRCS := $$(filter $$($1_SRC_INCLUDES),$$($1_ALL_SRCS)) endif ifneq ($$($1_EXCLUDES),) -- GitLab