diff --git a/java-11-alibaba-dragonwell.spec b/java-11-alibaba-dragonwell.spec index a22067477473432a2b89b160396b88cc92642c12..b347e823c089e2e91eb55efe953f8f16be51698b 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 @@ -168,6 +168,7 @@ URL: https://github.com/dragonwell-project/dragonwell11 Source0: https://github.com/dragonwell-project/dragonwell11/archive/refs/tags/%{dragsourcename}.tar.gz Source11: tapsets-icedtea-6.0.0pre00-c848b93a8598.tar.xz +Source12: jtreg-6.1.1.zip BuildArch: x86_64 aarch64 @@ -661,6 +662,10 @@ chmod +x %{top_level_dir_name}/configure # Extract systemtap tapsets tar --strip-components=1 -x -I xz -f %{SOURCE11} + +# Extrace jtreg zip file +rm -rf jtreg +unzip %{SOURCE12} %if %{with slowdebug} cp -r tapset tapset-slowdebug @@ -687,12 +692,18 @@ done 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} @@ -732,7 +743,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 \ @@ -741,6 +753,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 } @@ -2095,6 +2108,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 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