diff --git a/java-11-alibaba-dragonwell.spec b/java-11-alibaba-dragonwell.spec index 97acf93e62d04dc320c002f75108d46b72b2a47c..8b10a16906156bb4b21d9626404ded6a448411b0 100644 --- a/java-11-alibaba-dragonwell.spec +++ b/java-11-alibaba-dragonwell.spec @@ -1,4 +1,4 @@ -%define anolis_release 1 +%define anolis_release 2 %bcond_without fastdebug %bcond_without slowdebug @@ -160,6 +160,7 @@ Summary: Alibaba Dragonwell11 JDK License: GPL-v2 URL: https://github.com/dragonwell-project/dragonwell11 Source0: https://github.com/dragonwell-project/dragonwell11/archive/refs/tags/%{dragsourcename}.tar.gz +Source12: jtreg-6.1.1.zip ExcludeArch: loongarch64 @@ -651,17 +652,27 @@ Alibaba Dragonwell11 Runtime Environment src fastdebug mv %{dragbuildname} %{top_level_dir_name} chmod +x %{top_level_dir_name}/configure +# Extrace jtreg zip file +rm -rf jtreg +unzip %{SOURCE12} + %build # How many CPU's do we have? export NUM_PROC=%(/usr/bin/getconf _NPROCESSORS_ONLN 2> /dev/null || :) export NUM_PROC=${NUM_PROC:-1} +abort_build() { + echo "An error \"${1}\" occurred. Exiting build process." + echo exit 1 +} + function buildjdk() { local outputdir=${1} local buildjdk=${2} local maketargets="${3}" local debuglevel=${4} local link_opt=${5} + local jtreg_path=$(pwd)/jtreg local top_dir_abs_src_path=$(pwd)/%{top_level_dir_name} local top_dir_abs_build_path=$(pwd)/${outputdir} @@ -701,7 +712,8 @@ function buildjdk() { --with-num-cores="$NUM_PROC" \ --disable-javac-server \ --with-jvm-features=shenandoahgc,-zgc \ - --disable-warnings-as-errors + --disable-warnings-as-errors \ + --with-jtreg=${jtreg_path} make \ LOG=trace \ @@ -710,6 +722,7 @@ function buildjdk() { CFLAGS_WARNINGS_ARE_ERRORS="-Wno-error" \ DISTRO_VERSION=%{distro_version} \ $maketargets || ( pwd; find ${top_dir_abs_src_path} ${top_dir_abs_build_path} -name "hs_err_pid*.log" | xargs cat && false ) + time make run-test-tier1 JTREG="JOBS=${NUM_PROC};TIMEOUT_FACTOR=4" || abort_build "make test fail" popd } @@ -2031,6 +2044,9 @@ alternatives --install %{_jvmdir}/java-%{major_ver}-%{origin} $key %{_jvmdir}/%{ %endif %changelog +* Thu Jun 13 2024 yansendao.ysd - 3:11.0.21.18+9-2 +- support make test during spec build + * Mon Jan 29 2024 lvfei.lv - 3:11.0.21.18+9-1 - update package to 11.0.21.18+9 @@ -2062,6 +2078,3 @@ alternatives --install %{_jvmdir}/java-%{major_ver}-%{origin} $key %{_jvmdir}/%{ * Thu May 26 2022 happy_orange - 1:11.0.15.11.9-1 - Init package from dragonwell - - - diff --git a/jtreg-6.1.1.zip b/jtreg-6.1.1.zip new file mode 100644 index 0000000000000000000000000000000000000000..23ad0804cce6ecc1e662784529046163baff61ed Binary files /dev/null and b/jtreg-6.1.1.zip differ