From d4f45f51c9e376648f27ab9aaf28b5f020b5cb36 Mon Sep 17 00:00:00 2001 From: Magnus Ihse Bursie Date: Tue, 19 May 2015 10:05:02 +0200 Subject: [PATCH] 8080630: Stop doing sed manipulation of manifest files in SetupJavaCompilation Reviewed-by: erikj --- jdk/make/CompileDemos.gmk | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/jdk/make/CompileDemos.gmk b/jdk/make/CompileDemos.gmk index 5e03eb1aa46..7719a8663f5 100644 --- a/jdk/make/CompileDemos.gmk +++ b/jdk/make/CompileDemos.gmk @@ -30,6 +30,7 @@ include MakeBase.gmk include JavaCompilation.gmk include NativeCompilation.gmk include SetupJavaCompilers.gmk +include TextFileProcessing.gmk # Prepare the find cache. $(eval $(call FillCacheFind, $(JDK_TOPDIR)/src)) @@ -49,6 +50,15 @@ GLOBAL_VERSION_INFO_RESOURCE := $(JDK_TOPDIR)/src/java.base/windows/native/commo ################################################################################################## +# This rule will be depended on due to the MANIFEST line +$(eval $(call SetupTextFileProcessing, BUILD_JAVA_MANIFEST, \ + SOURCE_FILES := $(JDK_TOPDIR)/make/data/mainmanifest/manifest.mf, \ + OUTPUT_FILE := $(SUPPORT_OUTPUTDIR)/demo/java-main-manifest.mf, \ + REPLACEMENTS := \ + @@RELEASE@@ => $(RELEASE) ; \ + @@COMPANY_NAME@@ => $(COMPANY_NAME) , \ +)) + define SetupAppletDemo $$(eval $$(call SetupJavaCompilation,BUILD_DEMO_APPLET_$1, \ SETUP := GENERATE_USINGJDKBYTECODE, \ @@ -122,7 +132,7 @@ define SetupDemo COPY := $(PATTERNS_TO_COPY) $(10), \ JAR := $(SUPPORT_OUTPUTDIR)/demo/image/$2/$1/$$($1_JARFILE), \ JARMAIN := $4, \ - MANIFEST := $(JDK_TOPDIR)/make/data/mainmanifest/manifest.mf, \ + MANIFEST := $(SUPPORT_OUTPUTDIR)/demo/java-main-manifest.mf, \ EXTRA_MANIFEST_ATTR := $(11), \ SRCZIP := $(SUPPORT_OUTPUTDIR)/demo/image/$2/$1/src.zip, \ EXCLUDE_FILES := $9, \ @@ -290,7 +300,7 @@ define SetupJVMTIDemo COPY := $(PATTERNS_TO_COPY), \ JAR := $(SUPPORT_OUTPUTDIR)/demo/image/jvmti/$1/$1.jar, \ EXTRA_MANIFEST_ATTR := Main-Class: \n, \ - MANIFEST := $(JDK_TOPDIR)/make/data/mainmanifest/manifest.mf)) + MANIFEST := $(SUPPORT_OUTPUTDIR)/demo/java-main-manifest.mf)) BUILD_DEMOS += $(SUPPORT_OUTPUTDIR)/demo/image/jvmti/$1/$1.jar endif @@ -382,7 +392,7 @@ ifeq ($(OPENJDK_TARGET_OS), solaris) BIN := $(SUPPORT_OUTPUTDIR)/demo/classes/jni/Poller, \ HEADERS := $(SUPPORT_OUTPUTDIR)/demo/classes/jni/Poller, \ JAR := $(SUPPORT_OUTPUTDIR)/demo/image/jni/Poller/Poller.jar, \ - MANIFEST := $(JDK_TOPDIR)/make/data/mainmanifest/manifest.mf, \ + MANIFEST := $(SUPPORT_OUTPUTDIR)/demo/java-main-manifest.mf, \ SRCZIP := $(SUPPORT_OUTPUTDIR)/demo/image/jni/Poller/src.zip, \ COPY := README.txt Poller.c, \ JARMAIN := Client))