diff --git a/openjdk13-boot/Pkgfile b/openjdk13-boot/Pkgfile index 0f6f6a2..cd0ddbf 100644 --- a/openjdk13-boot/Pkgfile +++ b/openjdk13-boot/Pkgfile @@ -7,16 +7,13 @@ name=openjdk13-boot version=13.0.5.1+1 _boot_ver=20210207 _cert_ver=20200215 +_jdkhash=7f0467e5aa8e release=1 source=(https://crux.ster.zone/downloads/java/openjdk-$version.tar.bz2 https://crux.ster.zone/downloads/java/openjdk12-boot-$_boot_ver.tar.xz https://crux.ster.zone/downloads/java/java_cacerts-${_cert_ver}) build() { - # Make sure we do not have ccache masquerade directory in PATH. - # Use --enable-ccache instead of providing a wrapped compiler. - # NOTE: the check for usr/bin/ccache may be too specific, since it rules out - # local or opt installs. if [ -e '/usr/bin/ccache' ]; then PATH=$(echo ${PATH} | awk -v RS=: -v ORS=: '/ccache/ {next} {print}' | sed 's/:*$//') PKGMK_JDK13+=' --enable-ccache' @@ -30,39 +27,43 @@ build() { unset CXXFLAGS unset LDFLAGS unset MAKEFLAGS + export _CFLAGS+=' -fcommon' + export _CXXFLAGS+=' -fcommon' [ -z $JOBS ] && JOBS=$(nproc) mkdir $SRC/{build-boot,build} cd $SRC/build-boot - export _CFLAGS+=' -fcommon' - export _CXXFLAGS+=' -fcommon' - LC_ALL=C - /bin/bash ../jdk13u-jdk-$version/configure $PKGMK_JDK13 \ + local _COMMON_OPTIONS=" + --disable-hotspot-gtest + --disable-precompiled-headers + --disable-warnings-as-errors + --enable-dtrace=no + --enable-headless-only + --enable-unlimited-crypto + --with-native-debug-symbols=none + --with-debug-level=release + --with-stdc++lib=dynamic + --with-jvm-variants=server + --with-cacerts-file=$SRC/java_cacerts-$_cert_ver + --with-jtreg=no + --with-boot-jdk=$JAVA_HOME + --with-version-opt=CRUX-r$release + --with-version-build=${version#*+} + --with-vendor-name=CRUX + --with-jobs=$JOBS + --with-libjpeg=system + --with-giflib=system + --with-libpng=system + --with-zlib=system + --with-lcms=system" + + + LC_ALL=C \ + /bin/bash $SRC/jdk13u-$_jdkhash/configure $PKGMK_JDK13 \ + $_COMMON_OPTIONS \ --prefix=$SRC/build-boot/images/jdk \ - --disable-hotspot-gtest \ - --disable-precompiled-headers \ - --disable-warnings-as-errors \ - --enable-dtrace=no \ - --enable-headless-only \ - --enable-unlimited-crypto \ - --with-native-debug-symbols=none \ - --with-debug-level=release \ - --with-stdc++lib=dynamic \ - --with-jvm-variants=server \ - --with-cacerts-file=$SRC/java_cacerts-$_cert_ver \ - --with-jtreg=no \ - --with-boot-jdk=$JAVA_HOME \ - --with-version-opt="CRUX-r$release" \ - --with-version-build="${version#*+}" \ - --with-vendor-name="CRUX" \ - --with-jobs=$JOBS \ - --with-libjpeg=system \ - --with-giflib=system \ - --with-libpng=system \ - --with-zlib=system \ - --with-lcms=system \ --with-extra-cflags="$_CFLAGS" \ --with-extra-cxxflags="$_CXXFLAGS" @@ -75,31 +76,10 @@ build() { cd $SRC/build - LC_ALL=C - /bin/bash ../jdk13u-jdk-$version/configure $PKGMK_JDK13 \ + LC_ALL=C \ + /bin/bash $SRC/jdk13u-$_jdkhash/configure $PKGMK_JDK13 \ + $_COMMON_OPTIONS \ --prefix=/$name \ - --disable-hotspot-gtest \ - --disable-precompiled-headers \ - --disable-warnings-as-errors \ - --enable-dtrace=no \ - --enable-headless-only \ - --enable-unlimited-crypto \ - --with-native-debug-symbols=none \ - --with-debug-level=release \ - --with-stdc++lib=dynamic \ - --with-jvm-variants=server \ - --with-cacerts-file=$SRC/java_cacerts-$_cert_ver \ - --with-jtreg=no \ - --with-boot-jdk=$JAVA_HOME \ - --with-version-opt="CRUX-r$release" \ - --with-version-build="${version#*+}" \ - --with-vendor-name="CRUX" \ - --with-jobs=$JOBS \ - --with-libjpeg=system \ - --with-giflib=system \ - --with-libpng=system \ - --with-zlib=system \ - --with-lcms=system \ --with-extra-cflags="$_CFLAGS" \ --with-extra-cxxflags="$_CXXFLAGS"