aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2015-08-18 11:15:16 +0200
committerNatanael Copa <ncopa@alpinelinux.org>2015-08-18 11:16:36 +0200
commitef4f1e78f322e3f0b2a5b4816d43bc4196ac3bd5 (patch)
tree1ad97bab187691bd12cbfe12202cd2b7f92e0271
parent166ad0377b8e939f7777c85b4a791ae53969a42b (diff)
downloadaports-ef4f1e78f322e3f0b2a5b4816d43bc4196ac3bd5.tar.bz2
aports-ef4f1e78f322e3f0b2a5b4816d43bc4196ac3bd5.tar.xz
main/openjdk8: respect our CFLAGS and LDFLAGS and build on x86 too
-rw-r--r--testing/openjdk8/APKBUILD16
-rw-r--r--testing/openjdk8/build-demo-ldflags.patch21
2 files changed, 33 insertions, 4 deletions
diff --git a/testing/openjdk8/APKBUILD b/testing/openjdk8/APKBUILD
index ab61684b54..f6a1b11b2d 100644
--- a/testing/openjdk8/APKBUILD
+++ b/testing/openjdk8/APKBUILD
@@ -8,7 +8,7 @@ pkgver=$_java_ver.$_jdk_update.$_jdk_build
pkgrel=0
pkgdesc="Sun OpenJDK 8"
url="http://openjdk.java.net"
-arch="x86_64"
+arch="x86_64 x86"
license="custom"
depends="$pkgname-jre"
options="sover-namecheck"
@@ -59,6 +59,7 @@ source="saveas-$_dropsurl/archive/${_dropsver}.tar.bz2/jdk8u-$_dropsver.tar.bz2
icedtea-jdk-musl.patch
icedtea-jdk-includes.patch
fix-libjvm-load.patch
+ build-demo-ldflags.patch
"
_builddir="$srcdir/jdk8u-$_dropsver"
@@ -100,6 +101,10 @@ build() {
--with-user-release-suffix="alpine-r${pkgrel}" \
--enable-unlimited-crypto \
--with-zlib=system \
+ --with-giflib=system \
+ --with-extra-cflags="$CFLAGS" \
+ --with-extra-cxxflags="$CXXFLAGS" \
+ --with-extra-ldflags="$LDFLAGS" \
--disable-freetype-bundling \
--with-boot-jdk="$BOOTSTRAP_JAVA_HOME" \
|| return 1
@@ -214,7 +219,8 @@ bdea7060a067faf1c2de5f4eb6e8525d icedtea-jdk-execinfo.patch
250b0807b59762670954b132e8f8dfba icedtea-jdk-fix-ipv6-init.patch
fc1dc983dc562eda399c9d7eabd3b299 icedtea-jdk-musl.patch
fc7d3cc1f5a5615574fd1e416144a042 icedtea-jdk-includes.patch
-9b95183ae088ac2520ac66ae587619e4 fix-libjvm-load.patch"
+9b95183ae088ac2520ac66ae587619e4 fix-libjvm-load.patch
+ea23c28032d50816a243d15afb2d8fb6 build-demo-ldflags.patch"
sha256sums="f4dbc2d8f184d60b2caee56c86e29a3fae6025ee6606079e9e8a607402b631f9 jdk8u-jdk8u66-b02.tar.bz2
7cd14a32a00f9051a7c37d2c263626b97463ef7874df34175a8807bc15d2ac60 corba-jdk8u66-b02.tar.bz2
c9b1c7f21d5bc335b4bedb327267b68ea5b90bef2ed3938c9de08d5f5ca3de43 jaxp-jdk8u66-b02.tar.bz2
@@ -230,7 +236,8 @@ a35d40f24098747cdb73d9c3742cfb4aecafa0f72c9dfdfe2cb460f9706ff665 icedtea-jdk-ex
632683ec88a6fb250ef043aae9cace605d0c669b7058f8c47b62b09b03ecc6c5 icedtea-jdk-fix-ipv6-init.patch
d3fcf4779a23181178e722a93290921f5c61ed7220d3a431953a53c24f89e562 icedtea-jdk-musl.patch
38590e411b7bf9b99f5168709b975e1c432ef600915800c709a6617504e2c13a icedtea-jdk-includes.patch
-47028d87c9a65df8d0103b39bf54b2b22de7db7c52a5de1058f88f4c5ea24f0d fix-libjvm-load.patch"
+47028d87c9a65df8d0103b39bf54b2b22de7db7c52a5de1058f88f4c5ea24f0d fix-libjvm-load.patch
+eebfb2613ae342587e8477a1022703ac986ed59e941ec1e96b2a3264c67c587b build-demo-ldflags.patch"
sha512sums="ddbae784fbae51b49f3308eeb3995458fb43d563a8699ef8cb3d7d3775ed58a60c1cf11339ab520bdb6300709236f28444059b2f3f5bf551faac6748a02e6779 jdk8u-jdk8u66-b02.tar.bz2
fbaa4207a24e90f55aa3e0584598b7f4cf3baa7d565fb04699abb47fc8ff720c1c6a956b1e0296076f988517e13f3ca446aca8c60e0351a4ea25f108f954aaa1 corba-jdk8u66-b02.tar.bz2
b258f72216202844ac25415bb5c14caf34efb110e7684d7d392b30fca1df19d064e91c3bef35e16acd1d0be6ed1dc36158cb7922cad191408883f9e241b075a5 jaxp-jdk8u66-b02.tar.bz2
@@ -246,4 +253,5 @@ f6365cfafafa008bd6c1bf0ccec01a63f8a39bd1a8bc87baa492a27234d47793ba02d455e5667a87
48533f87fc2cf29d26b259be0df51087d2fe5b252e72d00c6ea2f4add7b0fb113141718c116279c5905e03f64a1118082e719393786811367cf4d472b5d36774 icedtea-jdk-fix-ipv6-init.patch
2fd75bb52e7c9e3b56a383b72ee519d395413b000aef94ad00b106a692a199de34967bac1120164cebce5f71d302413742922a55cc6479b2d33258aaf7d03c1b icedtea-jdk-musl.patch
7df0db85039da8cbde49093ec3299f6804370f4134554a9c26c130a4e9e0b35409a3be833f3e90764ed16718683daffb6447261db8e5988f2e0519f649aedbc6 icedtea-jdk-includes.patch
-978539ba0b1f1694cda6a3a1542a4373861cbfb4dc414a3b796cd8841ecf6e12248c746b5efe2c031c85a3b0684101b29e8a5f4ff70e77c1a3f3cd7f5cb148ce fix-libjvm-load.patch"
+978539ba0b1f1694cda6a3a1542a4373861cbfb4dc414a3b796cd8841ecf6e12248c746b5efe2c031c85a3b0684101b29e8a5f4ff70e77c1a3f3cd7f5cb148ce fix-libjvm-load.patch
+bcf9af85907b4f49f1aa470d21917280fcf9fc8892f089fe8c284ec3f2eccd57f799c7f06ce2ce641421d50396fa192cb71ccbb7a077958aacf57b8dadc80bc1 build-demo-ldflags.patch"
diff --git a/testing/openjdk8/build-demo-ldflags.patch b/testing/openjdk8/build-demo-ldflags.patch
new file mode 100644
index 0000000000..ded0f11c8b
--- /dev/null
+++ b/testing/openjdk8/build-demo-ldflags.patch
@@ -0,0 +1,21 @@
+our LDFLAGS has -Wl,-z,relro but the commas are expanded too early in makefile.
+
+--- ./jdk/make/CompileDemos.gmk.orig
++++ ./jdk/make/CompileDemos.gmk
+@@ -245,13 +245,15 @@
+ BUILD_DEMO_JVMTI_$1_CFLAGS := $(CFLAGS_JDKLIB) $(CFLAGS_DEBUG_SYMBOLS) \
+ -I$(JDK_TOPDIR)/src/share/demo/jvmti/$1 $$(BUILD_DEMO_JVMTI_$1_EXTRA_INC) $3
+
++ BUILD_DEMO_JVMTI_$1_LDFLAGS := $(filter-out -incremental:no -opt:ref,$(LDFLAGS_JDKLIB))
++
+ # Remove the -incremental:no setting to get .ilk-files like in the old build.
+ $$(eval $$(call SetupNativeCompilation,BUILD_DEMO_JVMTI_$1, \
+ SRC := $(JDK_TOPDIR)/src/share/demo/jvmti/$1 $$(BUILD_DEMO_JVMTI_$1_EXTRA_SRC), \
+ LANG := $$(BUILD_DEMO_JVMTI_$1_LANG), \
+ OPTIMIZATION := LOW, \
+ CXXFLAGS := $$($1_CXXFLAGS), \
+- LDFLAGS := $(filter-out -incremental:no -opt:ref, $(LDFLAGS_JDKLIB)), \
++ LDFLAGS := $$(BUILD_DEMO_JVMTI_$1_LDFLAGS), \
+ LDFLAGS_macosx := $(call SET_EXECUTABLE_ORIGIN), \
+ LDFLAGS_SUFFIX := $$($1_EXTRA_CXX), \
+ LDFLAGS_SUFFIX_posix := $5, \