@ -1,6 +1,6 @@
@@ -1,6 +1,6 @@
%global maj_ver 7
%global min_ver 0
%global patch_ver 1
%global min_ver 1
%global patch_ver 0
# Components enabled if supported by target architecture:
%ifarch x86_64 ppc64le ppc64 s390x
@ -37,8 +37,8 @@ Summary: llvm engine for Mesa
@@ -37,8 +37,8 @@ Summary: llvm engine for Mesa
Group: System Environment/Libraries
License: NCSA
URL: http://llvm.org
Source0: http://llvm.org/releases/%{version}/llvm-%{version}%{?rc_ver:rc%{rc_ver}}.src.tar.xz
Source2: http://llvm.org/releases/%{version}/cfe-%{version}%{?rc_ver:rc%{rc_ver}}.src.tar.xz
Source0: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/llvm-%{version}.src.tar.xz
Source2: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/cfe-%{version}.src.tar.xz
Source100: llvm-config.h
Source101: clang-config.h
@ -66,19 +66,15 @@ This package contains library and header files needed to build the LLVM
@@ -66,19 +66,15 @@ This package contains library and header files needed to build the LLVM
support in Mesa.
%prep
%setup -T -q -b 2 -n cfe-%{version}%{?rc_ver:rc%{rc_ver}}.src
%setup -T -q -b 2 -n cfe-%{version}.src
%setup -q -n llvm-%{version}%{?rc_ver:rc%{rc_ver}}.src
%setup -q -n llvm-%{version}.src
%patch0 -p1 -b .rpath
%patch1 -p1 -b .fixinc
%ifarch %{arm}
find ../cfe-%{version}%{?rc_ver:rc%{rc_ver}}.src -name illegal-UTF8.m -delete
%endif
%build
#sed -i 's|ActiveIncludeDir = ActivePrefix + "/include|&/llvm-private|g' tools/llvm-config/llvm-config.cpp
mkdir -p _build
@ -128,6 +124,7 @@ export PATH=$BUILD_DIR/bin:$PATH
@@ -128,6 +124,7 @@ export PATH=$BUILD_DIR/bin:$PATH
-DLLVM_DYLIB_EXPORT_ALL:BOOL=ON \
-DLLVM_LINK_LLVM_DYLIB:BOOL=ON \
-DLLVM_BUILD_EXTERNAL_COMPILER_RT:BOOL=ON \
-DLLVM_ENABLE_RTTI:BOOT=ON \
-DLLVM_INSTALL_TOOLCHAIN_ONLY:BOOL=OFF
make %{?_smp_mflags} VERBOSE=1 LLVM llvm-config FileCheck not count gtest gtest_main
@ -174,6 +171,7 @@ make install DESTDIR=%{buildroot}
@@ -174,6 +171,7 @@ make install DESTDIR=%{buildroot}
# fix multi-lib
mv -v %{buildroot}%{_bindir}/llvm-config %{buildroot}%{_bindir}/%{name}-config-%{__isa_bits}
ln -s %{_bindir}/%{name}-config-%{__isa_bits} %{buildroot}%{_bindir}/%{name}-config
mv -v %{buildroot}%{_includedir}/llvm/llvm/Config/llvm-config{,-%{__isa_bits}}.h
install -m 0644 %{SOURCE100} %{buildroot}%{_includedir}/llvm/llvm/Config/llvm-config.h
mv -v %{buildroot}%{_includedir}/clang/Config/config{,-%{__isa_bits}}.h