- Enable OpenMP for x86, x86_64, ppc64 and ppc64le
OBS-URL: https://build.opensuse.org/package/show/devel:tools:compiler/llvm?expand=0&rev=424
This commit is contained in:
committed by
Git OBS Bridge
parent
3361748dd0
commit
1917264ada
@@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Sun Sep 27 12:03:57 UTC 2015 - idonmez@suse.com
|
||||||
|
|
||||||
|
- Enable OpenMP for x86, x86_64, ppc64 and ppc64le
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Mon Sep 14 13:10:49 UTC 2015 - idonmez@suse.com
|
Mon Sep 14 13:10:49 UTC 2015 - idonmez@suse.com
|
||||||
|
|
||||||
|
29
llvm.spec
29
llvm.spec
@@ -25,6 +25,10 @@
|
|||||||
%define build_libcxx 1
|
%define build_libcxx 1
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
%ifarch ppc64 ppc64le %{ix86} x86_64
|
||||||
|
%define build_openmp 1
|
||||||
|
%endif
|
||||||
|
|
||||||
Name: llvm
|
Name: llvm
|
||||||
Version: 3.7.0
|
Version: 3.7.0
|
||||||
Release: 0
|
Release: 0
|
||||||
@@ -37,13 +41,14 @@ Source1: http://llvm.org/releases/%{version}/cfe-%{version}.src.tar.xz
|
|||||||
Source2: http://llvm.org/releases/%{version}/compiler-rt-%{version}.src.tar.xz
|
Source2: http://llvm.org/releases/%{version}/compiler-rt-%{version}.src.tar.xz
|
||||||
Source3: http://llvm.org/releases/%{version}/libcxx-%{version}.src.tar.xz
|
Source3: http://llvm.org/releases/%{version}/libcxx-%{version}.src.tar.xz
|
||||||
Source4: http://llvm.org/releases/%{version}/libcxxabi-%{version}.src.tar.xz
|
Source4: http://llvm.org/releases/%{version}/libcxxabi-%{version}.src.tar.xz
|
||||||
|
Source5: http://llvm.org/releases/%{version}/openmp-%{version}.src.tar.xz
|
||||||
# Manually created docs
|
# Manually created docs
|
||||||
# cd docs
|
# cd docs
|
||||||
# make -f Makefile.sphinx man html
|
# make -f Makefile.sphinx man html
|
||||||
# cd ..
|
# cd ..
|
||||||
# tar cvJf llvm-docs-3.7.0.src.tar.xz llvm-3.7.0.src/docs/_build/{man,html}
|
# tar cvJf llvm-docs-3.7.0.src.tar.xz llvm-3.7.0.src/docs/_build/{man,html}
|
||||||
Source5: llvm-docs-%{version}.src.tar.xz
|
Source6: llvm-docs-%{version}.src.tar.xz
|
||||||
Source6: cfe-docs-%{version}.src.tar.xz
|
Source7: cfe-docs-%{version}.src.tar.xz
|
||||||
Source100: %{name}-rpmlintrc
|
Source100: %{name}-rpmlintrc
|
||||||
Source101: baselibs.conf
|
Source101: baselibs.conf
|
||||||
# PATCH-FIX-OPENSUSE set-revision.patch idoenmez@suse.de -- Allow us to set revision
|
# PATCH-FIX-OPENSUSE set-revision.patch idoenmez@suse.de -- Allow us to set revision
|
||||||
@@ -152,7 +157,7 @@ Requires: python
|
|||||||
This package contains the Python bindings to clang (C language) frontend for LLVM.
|
This package contains the Python bindings to clang (C language) frontend for LLVM.
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -a 1 -a 2 -a 3 -a 4 -a 6 -b 5 -n %{name}-%{version}.src
|
%setup -q -a 1 -a 2 -a 3 -a 4 -a 5 -a 7 -b 6 -n %{name}-%{version}.src
|
||||||
%patch1
|
%patch1
|
||||||
%patch2
|
%patch2
|
||||||
%patch3
|
%patch3
|
||||||
@@ -168,6 +173,10 @@ This package contains the Python bindings to clang (C language) frontend for LLV
|
|||||||
mv cfe-%{version}.src tools/clang
|
mv cfe-%{version}.src tools/clang
|
||||||
mv compiler-rt-%{version}.src projects/compiler-rt
|
mv compiler-rt-%{version}.src projects/compiler-rt
|
||||||
|
|
||||||
|
%if %{build_openmp}
|
||||||
|
mv openmp-%{version}.src projects/openmp
|
||||||
|
%endif
|
||||||
|
|
||||||
%if %{build_libcxx}
|
%if %{build_libcxx}
|
||||||
mv libcxx-%{version}.src projects/libcxx
|
mv libcxx-%{version}.src projects/libcxx
|
||||||
mv libcxxabi-%{version}.src projects/libcxxabi
|
mv libcxxabi-%{version}.src projects/libcxxabi
|
||||||
@@ -262,6 +271,9 @@ cmake -G "Ninja" \
|
|||||||
-DLLVM_ENABLE_ASSERTIONS=OFF \
|
-DLLVM_ENABLE_ASSERTIONS=OFF \
|
||||||
-DLLVM_ENABLE_PIC=ON \
|
-DLLVM_ENABLE_PIC=ON \
|
||||||
-DLLVM_BINUTILS_INCDIR=/usr/include \
|
-DLLVM_BINUTILS_INCDIR=/usr/include \
|
||||||
|
%if %{build_openmp}
|
||||||
|
-DCLANG_DEFAULT_OPENMP_RUNTIME=libomp \
|
||||||
|
%endif
|
||||||
%ifarch %{ix86} x86_64
|
%ifarch %{ix86} x86_64
|
||||||
-DLLVM_TARGETS_TO_BUILD="all" \
|
-DLLVM_TARGETS_TO_BUILD="all" \
|
||||||
%else
|
%else
|
||||||
@@ -309,6 +321,9 @@ cmake -G "Ninja" \
|
|||||||
-DLLVM_ENABLE_ASSERTIONS=OFF \
|
-DLLVM_ENABLE_ASSERTIONS=OFF \
|
||||||
-DLLVM_ENABLE_PIC=ON \
|
-DLLVM_ENABLE_PIC=ON \
|
||||||
-DLLVM_BINUTILS_INCDIR=/usr/include \
|
-DLLVM_BINUTILS_INCDIR=/usr/include \
|
||||||
|
%if %{build_openmp}
|
||||||
|
-DCLANG_DEFAULT_OPENMP_RUNTIME=libomp \
|
||||||
|
%endif
|
||||||
%ifarch %{ix86} x86_64
|
%ifarch %{ix86} x86_64
|
||||||
-DLLVM_TARGETS_TO_BUILD="all" \
|
-DLLVM_TARGETS_TO_BUILD="all" \
|
||||||
%else
|
%else
|
||||||
@@ -417,6 +432,10 @@ mv utils/vim/README utils/vim/README.vim
|
|||||||
# Stuff we don't want to include
|
# Stuff we don't want to include
|
||||||
rm %{buildroot}%{_mandir}/man1/lit.1
|
rm %{buildroot}%{_mandir}/man1/lit.1
|
||||||
|
|
||||||
|
%if %{build_openmp}
|
||||||
|
rm -f %{buildroot}%{_libdir}/libgomp.so
|
||||||
|
%endif
|
||||||
|
|
||||||
%if %{build_libcxx}
|
%if %{build_libcxx}
|
||||||
# Create an libc++.so as an ldscript
|
# Create an libc++.so as an ldscript
|
||||||
rm %{buildroot}%{_libdir}/libc++.so
|
rm %{buildroot}%{_libdir}/libc++.so
|
||||||
@@ -483,6 +502,10 @@ EOF
|
|||||||
%{_datadir}/clang
|
%{_datadir}/clang
|
||||||
%{_mandir}/man1/clang.1%{ext_man}
|
%{_mandir}/man1/clang.1%{ext_man}
|
||||||
%{_libdir}/libLTO.*
|
%{_libdir}/libLTO.*
|
||||||
|
%if %{build_openmp}
|
||||||
|
%{_libdir}/libomp.so
|
||||||
|
%{_libdir}/libiomp5.so
|
||||||
|
%endif
|
||||||
%if %{build_libcxx}
|
%if %{build_libcxx}
|
||||||
%{_libdir}/libc++*
|
%{_libdir}/libc++*
|
||||||
%{_includedir}/c++/*
|
%{_includedir}/c++/*
|
||||||
|
3
openmp-3.7.0.src.tar.xz
Normal file
3
openmp-3.7.0.src.tar.xz
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:8d8a224e5689596a35652fda87e4be29853c4b85fbc7a6562019badfad779f2a
|
||||||
|
size 2251108
|
Reference in New Issue
Block a user