mirror of
https://abf.rosa.ru/djam/java-11-openjdk.git
synced 2025-02-23 13:32:53 +00:00
conditionalize clang
This commit is contained in:
parent
4961ba1e1a
commit
26f9b59d6c
1 changed files with 9 additions and 1 deletions
|
@ -30,6 +30,7 @@
|
||||||
%bcond_with timezonejava
|
%bcond_with timezonejava
|
||||||
|
|
||||||
%bcond_with binary
|
%bcond_with binary
|
||||||
|
%bcond_without clang
|
||||||
|
|
||||||
# The -g flag says to use strip -g instead of full strip on DSOs or EXEs.
|
# The -g flag says to use strip -g instead of full strip on DSOs or EXEs.
|
||||||
# This fixes detailed NMT and other tools which need minimal debug info.
|
# This fixes detailed NMT and other tools which need minimal debug info.
|
||||||
|
@ -1162,7 +1163,9 @@ Patch10: clang_stack.patch
|
||||||
# JDK 9+ only patches
|
# JDK 9+ only patches
|
||||||
#
|
#
|
||||||
#############################################
|
#############################################
|
||||||
|
%if %{with clang}
|
||||||
BuildRequires: clang
|
BuildRequires: clang
|
||||||
|
%endif
|
||||||
BuildRequires: autoconf
|
BuildRequires: autoconf
|
||||||
BuildRequires: automake
|
BuildRequires: automake
|
||||||
BuildRequires: binutils
|
BuildRequires: binutils
|
||||||
|
@ -1483,8 +1486,10 @@ sed -e "s:@NSS_LIBDIR@:%{NSS_LIBDIR}:g" %{SOURCE11} > nss.cfg
|
||||||
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
|
%if %{with clang}
|
||||||
export CC="clang"
|
export CC="clang"
|
||||||
export CXX="clang++"
|
export CXX="clang++"
|
||||||
|
%endif
|
||||||
# How many CPU's do we have?
|
# How many CPU's do we have?
|
||||||
export NUM_PROC=%(/usr/bin/getconf _NPROCESSORS_ONLN 2> /dev/null || :)
|
export NUM_PROC=%(/usr/bin/getconf _NPROCESSORS_ONLN 2> /dev/null || :)
|
||||||
export NUM_PROC=${NUM_PROC:-1}
|
export NUM_PROC=${NUM_PROC:-1}
|
||||||
|
@ -1570,7 +1575,10 @@ bash ../configure \
|
||||||
--with-jvm-features=zgc \
|
--with-jvm-features=zgc \
|
||||||
%endif
|
%endif
|
||||||
--disable-warnings-as-errors \
|
--disable-warnings-as-errors \
|
||||||
--with-toolchain-type="clang"
|
%if %{with clang}
|
||||||
|
--with-toolchain-type="clang" \
|
||||||
|
%endif
|
||||||
|
--
|
||||||
|
|
||||||
# Debug builds don't need same targets as release for
|
# Debug builds don't need same targets as release for
|
||||||
# build speed-up
|
# build speed-up
|
||||||
|
|
Loading…
Add table
Reference in a new issue