diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2019-02-26 08:13:03 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2019-02-26 08:28:06 +0000 |
commit | 4143ac1472217f787f21dd52dfdecfe09d74edd2 (patch) | |
tree | df8782681d3897781383fb65ba42d41446d70c8a /testing/openjdk9 | |
parent | 356b47d2f4120c743b616c561c93eb8d264dd4b5 (diff) | |
download | aports-4143ac1472217f787f21dd52dfdecfe09d74edd2.tar.bz2 aports-4143ac1472217f787f21dd52dfdecfe09d74edd2.tar.xz |
testing/openjdk9: reorder subpkg split and add -src
Diffstat (limited to 'testing/openjdk9')
-rw-r--r-- | testing/openjdk9/APKBUILD | 79 |
1 files changed, 43 insertions, 36 deletions
diff --git a/testing/openjdk9/APKBUILD b/testing/openjdk9/APKBUILD index a44299a4c9..ccfb40370a 100644 --- a/testing/openjdk9/APKBUILD +++ b/testing/openjdk9/APKBUILD @@ -1,8 +1,8 @@ # Contributor: Simon Frankenberger <simon-alpine@fraho.eu> # Maintainer: Simon Frankenberger <simon-alpine@fraho.eu> pkgname=openjdk9 -_pkgver=9.0.4+12 -pkgver=${_pkgver/+/.} +pkgver=9.0.4_p12 +_pkgver=${pkgver/_p/+} pkgrel=0 pkgdesc="Oracle OpenJDK 9" url="https://hg.openjdk.java.net/jdk-updates/jdk9u" @@ -37,8 +37,9 @@ subpackages="$pkgname-jmods:_jmods:noarch $pkgname-demos:_demos:noarch $pkgname-doc:_doc:noarch $pkgname-dbg:_dbg -$pkgname-jre-headless:_jre_headless $pkgname-jre:_jre +$pkgname-src:_src +$pkgname-jre-headless:_jre_headless $pkgname-jdk:_jdk " source="jdk-$_pkgver-root.tar.bz2::http://hg.openjdk.java.net/jdk-updates/jdk9u/archive/jdk-$_pkgver.tar.bz2 @@ -90,8 +91,8 @@ unpack() { done } -build() { - cd "$builddir" +prepare() { + default_prepare # update the config.sub file to detect alpine cp $srcdir/2019-01-05_config.sub common/autoconf/build-aux/autoconf-config.sub @@ -101,6 +102,10 @@ build() { # # haven't found any way to disable this module so just remove it. rm -r hotspot/src/jdk.hotspot.agent +} + +build() { + cd "$builddir" if [ $_run_jtreg -ne 0 ]; then _with_jtreg="--with-jtreg=/usr/share/java/jtreg" @@ -108,6 +113,12 @@ build() { _with_jtreg="--with-jtreg=no" fi + # CFLAGS, CXXFLAGS and LDFLAGS are ignored as shown by a warning + # in the output of ./configure unless used like such: + # --with-extra-cflags="${CFLAGS}" + # --with-extra-cxxflags="${CXXFLAGS}" + # --with-extra-ldflags="${LDFLAGS}" + # See also paragraph "Configure Control Variables from "jdk9-${_hg_tag}/common/doc/building.md CFLAGS= CXXFLAGS= LDFLAGS= \ bash ./configure \ --openjdk-target=$CHOST \ @@ -137,7 +148,7 @@ build() { --with-version-opt=alpine-r${pkgrel} \ --with-version-build=${_pkgver#*+} - MAKEFLAGS= make jdk-image + MAKEFLAGS= make jdk-image } check() { @@ -227,6 +238,32 @@ _dbg() { mv "$_fromroot"/lib/*.debuginfo "$_toroot"/lib } +_jre() { + pkgdesc="Oracle OpenJDK 9 (JRE)" + depends="$pkgname-jre-headless" + _fromroot="$pkgdir/$_java_home" + _toroot="$subpkgdir/$_java_home" + + mkdir -p "$_toroot/lib" + mv "$_fromroot/lib/libawt_xawt.so" \ + "$_fromroot/lib/libfontmanager.so" \ + "$_fromroot/lib/libjavajpeg.so" \ + "$_fromroot/lib/libjawt.so" \ + "$_fromroot/lib/libjsoundalsa.so" \ + "$_fromroot/lib/liblcms.so" \ + "$_fromroot/lib/libsplashscreen.so" \ + "$_toroot/lib" +} + + +_src() { + pkgdesc="OpenJDK $_majorver Source Bundle" + depends="$pkgname-jre-headless" + mkdir -p "$subpkgdir/$_java_home"/lib + mv "$pkgdir"/$_java_home/lib/src.zip \ + "$subpkgdir"/$_java_home/lib/ +} + _jre_headless() { pkgdesc="Oracle OpenJDK 9 (JRE headless)" depends="java-common java-cacerts" @@ -236,18 +273,6 @@ _jre_headless() { mkdir -p "$_toroot" mv "$_fromroot/lib" "$_toroot" - # move back unwanted libs - mkdir -p "$_fromroot/lib" - mv "$_toroot/lib/src.zip" \ - "$_toroot/lib/libawt_xawt.so" \ - "$_toroot/lib/libfontmanager.so" \ - "$_toroot/lib/libjavajpeg.so" \ - "$_toroot/lib/libjawt.so" \ - "$_toroot/lib/libjsoundalsa.so" \ - "$_toroot/lib/liblcms.so" \ - "$_toroot/lib/libsplashscreen.so" \ - "$_fromroot/lib" - mkdir -p "$_toroot/bin" for i in appletviewer \ idlj \ @@ -281,23 +306,6 @@ _jre_headless() { ln -sf . "$_toroot/jre" } -_jre() { - pkgdesc="Oracle OpenJDK 9 (JRE)" - depends="$pkgname-jre-headless" - _fromroot="$pkgdir/$_java_home" - _toroot="$subpkgdir/$_java_home" - - mkdir -p "$_toroot/lib" - mv "$_fromroot/lib/libawt_xawt.so" \ - "$_fromroot/lib/libfontmanager.so" \ - "$_fromroot/lib/libjavajpeg.so" \ - "$_fromroot/lib/libjawt.so" \ - "$_fromroot/lib/libjsoundalsa.so" \ - "$_fromroot/lib/liblcms.so" \ - "$_fromroot/lib/libsplashscreen.so" \ - "$_toroot/lib" -} - _jdk() { pkgdesc="Oracle OpenJDK 9 (JDK)" depends="$pkgname-jre" @@ -305,7 +313,6 @@ _jdk() { _toroot="$subpkgdir/$_java_home" mkdir -p "$_toroot" - mv "$_fromroot/lib" "$_toroot" mv "$_fromroot/bin" "$_toroot" mv "$_fromroot/include" "$_toroot" } |