source: projects/specs/trunk/l/llvm/llvm-vl.spec @ 12506

Revision 12506, 30.6 KB checked in by tomop, 3 years ago (diff)

updated 16 packages

bluez-5.55-1

firefox-78.4.0-1

llvm-11.0.0-2

libdrm-2.4.102-1

libmodsecurity-3.0.4-2

mesa-20.2.1-1

nginx-1.18.0-8

nspr-4.29-1

nss-3.58-1

oniguruma-6.9.5.rev1-3

python-mako-1.1.3-1

python-markupsafe-1.1.1-2

rust-1.47.0-1

thunderbird-78.4.0-1

tigervnc-1.11.0-1

xorg-x11-server-1.20.9-2

RevLine 
[12228]1%bcond_with test
2
[9470]3%define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
4
[11969]5%define ver_suffix %(echo "%{version}" | cut -d . -f 1)
6
[11308]7%define _unpackaged_files_terminate_build 1
8
[1073]9# Build options:
[9470]10# Components skipped by default:
11%bcond_with doxygen
[11293]12%bcond_with ocaml
13%bcond_with force_gold
[11969]14%bcond_with lld_libs
15%bcond_with clang_tools_extra
[1073]16
[9470]17# Documentation install path
18%global llvmdocdir() %{_docdir}/%1-%{version}
19
[11293]20%define _unpackaged_files_terminate_build 1
21
[1073]22Summary:        The Low Level Virtual Machine
23Summary(ja):    LLVM - 低レベルバーチャルマシン
[12474]24Name:           llvm
[12506]25Version:        11.0.0
26Release:        2%{?_dist_release}
[12474]27Group:          programming
28Vendor:         Project Vine
29Distribution:   Vine Linux
[1073]30
31License:        NCSA
[12320]32URL:            https://llvm.org/
33Source0:        https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/llvm-%{version}.src.tar.xz
34Source1:        https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/clang-%{version}.src.tar.xz
35Source2:        https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/compiler-rt-%{version}.src.tar.xz
36Source3:        https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/lldb-%{version}.src.tar.xz
37Source4:        https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/lld-%{version}.src.tar.xz
[11985]38%if %{with clang_tools_extra}
[12320]39Source5:        https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/clang-tools-extra-%{version}.src.tar.xz
[11985]40%endif
[12320]41Source6:        https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/openmp-%{version}.src.tar.xz
[7943]42
[4656]43# multilib fixes
[11293]44Source10:        llvm-config.h
45Source11:        clang-config.h
[4656]46
[9470]47# patches
[1073]48
[11969]49# llvm
[12228]50Patch0:         0001-Filter-out-cxxflags-not-supported-by-clang.patch
51# TODO: I'm not sure why this is needed.  Could be a change in newer version
52# of gold.
53Patch1:         0001-Pass-target-to-gold-linker-to-avoid-faliures-on-i686.patch
54Patch2:         0001-CMake-Split-static-library-exports-into-their-own-ex.patch
55Patch3:         0001-CMake-Split-test-binary-exports-into-their-own-expor.patch
[7197]56
[11969]57# clang
[12228]58Patch100:       0002-gtest-reorg.patch
59Patch101:       0001-Fix-uninitialized-value-in-ABIArgInfo.patch
60Patch102:       0001-ToolChain-Add-lgcc_s-to-the-linker-flags-when-using-.patch
61Patch103:       0001-Fix-Driver-modules.cpp-test-to-work-when-build-direc.patch
[11308]62
[12228]63# compiler-rt
64Patch200:       0001-PATCH-std-thread-copy.patch
65
[11969]66# lld
[12228]67Patch400:       0001-CMake-Check-for-gtest-headers-even-if-lit.py-is-not-.patch
[11969]68
[7201]69# Vine Patch
[11293]70Patch1000: clang-3.8.1-driver-ld.gold.patch
71Patch1002: clang-3.8.1-driver-vine.patch
[7201]72
[1073]73BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
74
[5424]75BuildRequires:  binutils-devel
[11293]76BuildRequires:  cmake
[12228]77BuildRequires:  ninja
[1073]78BuildRequires:  bison
[12228]79BuildRequires:  python3
80BuildRequires:  python3-rpm-macros
[1073]81BuildRequires:  chrpath
82BuildRequires:  flex
[12228]83BuildRequires:  git
[1073]84BuildRequires:  gcc-c++ >= 3.4
85BuildRequires:  groff
[12376]86BuildRequires:  libffi-devel >= 3.3
[11293]87BuildRequires:  libstdc++-devel
88BuildRequires:  libstdc++-static
[1073]89BuildRequires:  libtool-ltdl-devel
[9594]90BuildRequires:  libxml2-devel
[11969]91%if %{with ocaml}
[9594]92BuildRequires:  ocaml-findlib
[9734]93BuildRequires:  ocaml-ctypes
[9594]94BuildRequires:  ocaml-ounit
[11969]95%endif
[1073]96# for DejaGNU test suite
[12228]97BuildRequires:  dejagnu tcl-devel
[9470]98%if %{with doxygen}
[1073]99BuildRequires:  doxygen graphviz
100%endif
[9594]101# pod2man
102BuildRequires:  perl
[9470]103# lldb
104BuildRequires:  swig
105BuildRequires:  libedit-devel
[12228]106BuildRequires:  python3-devel
[11969]107# lld
108BuildRequires: ncurses-devel
109BuildRequires: zlib-devel
[9470]110
[11969]111Requires:       llvm%{ver_suffix}-libs = %{version}-%{release}
[1073]112
113# LLVM is not supported on PPC64
114# http://llvm.org/bugs/show_bug.cgi?id=3729
115ExcludeArch:    ppc64
116
117%description
118LLVM is a compiler infrastructure designed for compile-time,
119link-time, runtime, and idle-time optimization of programs from
120arbitrary programming languages.  The compiler infrastructure includes
121mirror sets of programming tools as well as libraries with equivalent
122functionality.
123
124
125%package devel
126Summary:        Libraries and header files for LLVM
127Summary(ja):    LLVM のライブラリおよびヘッダファイル
[12474]128Group:          programming
[1073]129Requires:       %{name} = %{version}-%{release}
130Requires:       libstdc++-devel
[4656]131Requires:       libffi-devel
[11969]132Requires:       libedit-devel
[1073]133
134%description devel
135This package contains library and header files needed to develop new
136native programs that use the LLVM infrastructure.
137
138
139%package doc
140Summary:        Documentation for LLVM
141Summary(ja):    LLVM のドキュメント
[12474]142Group:          documentation
[9470]143BuildArch:      noarch
[1073]144Requires:       %{name} = %{version}-%{release}
[9470]145# might seem redundant, but needed to kill off the old arch-ed -doc subpackage
146Obsoletes:      %{name}-doc < %{version}-%{release}
[1073]147
148%description doc
149Documentation for the LLVM compiler infrastructure.
150
151
[11969]152%package -n llvm%{ver_suffix}-libs
[4656]153Summary:        LLVM shared libraries
[9470]154Summary(ja):    LLVM 共有ライブラリ
[12474]155Group:          system
[11969]156Provides:       llvm-libs = %{version}-%{release}
[11985]157Obsoletes:      llvm-libs <= 7.0.0
[4656]158
[11969]159%description -n llvm%{ver_suffix}-libs
[4656]160Shared libraries for the LLVM compiler infrastructure.
161
[11969]162%description -n llvm%{ver_suffix}-libs -l ja
[9594]163LLVM コンパイラ基盤の共有ライブラリです.
[4656]164
[11308]165%package static
166Summary:        LLVM static libraries
167Summary(ja):    LLVM 静的ライブラリ
[12474]168Group:          programming
[11308]169Requires:       llvm-devel = %{version}-%{release}
170
171%description static
172Static libraries for the LLVM compiler infrastructure.
173
174%description static -l ja
175LLVM コンパイラ基盤の静的ライブラリです.
176
177
[1073]178%package -n clang
179Summary:        A C language family front-end for LLVM
[9470]180Summary(ja):    LLVM の C 言語フロントエンド
[1073]181License:        NCSA
[12474]182Group:          programming
[9470]183Requires:       %{name} = %{version}-%{release}
184# clang requires gcc, clang++ requires libstdc++-devel
185Requires:       libstdc++-devel
186# remove clang-doc pacakge
187Obsoletes:      clang-doc < %{version}-%{release}
[1073]188
189%description -n clang
190clang: noun
191    1. A loud, resonant, metallic sound.
192    2. The strident call of a crane or goose.
193    3. C-language family front-end toolkit.
194
195The goal of the Clang project is to create a new C, C++, Objective C
196and Objective C++ front-end for the LLVM compiler. Its tools are built
197as libraries and designed to be loosely-coupled and extensible.
198
[9470]199%Package -n clang-libs
200Summary:        Runtime library for clang
201Summary(ja):    Clang のランタイムライブラリ
[12474]202Group:          system
[1073]203
[9470]204%description -n clang-libs
205Runtime library for clang.
206
[9594]207%description -n clang-libs -l ja
208Clang のランタイムライブラリです.
[9470]209
[1073]210%package -n clang-devel
211Summary:        Header files for clang
[9470]212Summary(ja):    Clang のヘッダファイル
[12474]213Group:          programming
[1073]214Requires:       clang = %{version}-%{release}
215
216%description -n clang-devel
217This package contains header files for the Clang compiler.
218
[9594]219%description -n clang-devel -l ja
220Clang コンパイラのヘッダファイル集です.
[1073]221
222%package -n clang-analyzer
223Summary:        A source code analysis framework
[11293]224Summary(ja):    ソースコード分析フレームワーク
[1073]225License:        NCSA
[12474]226Group:          programming
[1073]227Requires:       clang = %{version}-%{release}
228# not picked up automatically since files are currently not instaled
229# in standard Python hierarchies yet
[12228]230Requires:       python3
[1073]231
232%description -n clang-analyzer
233The Clang Static Analyzer consists of both a source code analysis
234framework and a standalone tool that finds bugs in C and Objective-C
235programs. The standalone tool is invoked from the command-line, and is
236intended to run in tandem with a build of a project or code base.
237
[12228]238%package -n python3-clang
239Summary: Python3 bindings for clang
[12474]240Group:          programming
[11969]241Requires: %{name}%{ver_suffix}-libs%{?_isa} = %{version}-%{release}
[12228]242Requires: python3
243%description -n python3-clang
244Python3 bindings for clang
[11308]245
246
[9470]247#%package -n clang-doc
248#Summary:        Documentation for Clang
249#Summary(ja):    Clang のドキュメント
250#Group:          Documentation
251#Requires:       %{name} = %{version}-%{release}
252#
253#%description -n clang-doc
254#Documentation for the Clang compiler front-end.
[1073]255
[9470]256%package -n lldb
257Summary:        Next generation high-performance debugger
258Summary(ja):    高性能デバッガー
259License:        NCSA
[12474]260Group:          programming
[1073]261Requires:       %{name} = %{version}-%{release}
262
[9470]263%description -n lldb
264LLDB is a next generation, high-performance debugger. It is built as a set
265of reusable components which highly leverage existing libraries in the
266larger LLVM Project, such as the Clang expression parser and LLVM
267disassembler.
[1073]268
[9470]269%package -n lldb-devel
270Summary:        Header files for LLDB
271Summary(ja):    LLDB のヘッダファイル
[12474]272Group:          programming
[9470]273Requires:       lldb = %{version}-%{release}
[1073]274
[9470]275%description -n lldb-devel
276This package contains header files for the LLDB debugger.
277
278
[11969]279%package -n lld
280Summary:        The LLVM Linker
281Summary(ja):    LLVMリンカー
282License:        NCSA
[12474]283Group:          programming
[11969]284
285%description -n lld
286The LLVM project linker.
287
288%if %{with lld_libs}
289%package -n lld-libs
290Summary:        LLD shared libraries
291Summary(ja):    LLD 共有ライブラリ
292License:        NCSA
[12474]293Group:          programming
[11969]294
295%description -n lld-libs
296Shared libraries for LLD.
297
298
299%package -n lld-devel
300Summary:        Libraries and header files for LLD
301Summary(ja):    LLD 用ライブラリとヘッダファイル
302License:        NCSA
[12474]303Group:          programming
[11969]304Requires:       lld-libs = %{version}-%{release}
305
306%description -n lld-devel
307This package contains library and header files needed to develop new native
308programs that use the LLD infrastructure.
309%endif
310
[9470]311%if %{with doxygen}
[1073]312%package apidoc
313Summary:        API documentation for LLVM
314Summary(ja):    LLVM の API ドキュメント
[12474]315Group:          documentation
[9470]316BuildArch:      noarch
[1073]317Requires:       %{name}-docs = %{version}-%{release}
318
319%description apidoc
320API documentation for the LLVM compiler infrastructure.
[9470]321
322%package -n clang-apidoc
323Summary:        API documentation for Clang
324Summary(ja):    Clang の API ドキュメント
325Group:          Documentation
326BuildArch:      noarch
327
328%description -n clang-apidoc
329API documentation for the Clang compiler.
[1073]330%endif
331
[11308]332
[12228]333%package -n python3-lldb
334Summary:        Python3 module for LLDB
335Summary(ja):    LLDB用Python3モジュール
[12474]336Group:          programming
[11308]337BuildRequires:  python-devel
338Requires:       python-six
339
[12228]340%description -n python3-lldb
341The package contains the LLDB Python3 module.
[11308]342
343
[12221]344%package -n libomp
345Summary:        OpenMP runtime for clang
346Summary(ja):    clang用OpenMPランタイム
[12474]347Group:          system
[12221]348
349%description -n libomp
350The package contains the OpenMP runtime for clang.
351
352
353%package -n libomp-devel
354Summary:        OpenMP header files
355Summary(ja):    OpenMPヘッダファイル
[12474]356Group:          programming
[12221]357Requires:       clang-devel%{?isa} = %{version}
358
359%description -n libomp-devel
360The package contains the OpenMP header files.
361
362
[11293]363%if %{with ocaml}
[1073]364%package        ocaml
365Summary:        OCaml binding for LLVM
366Summary(ja):    LLVM の OCaml バインディング
[12474]367Group:          system
[1073]368Requires:       %{name} = %{version}-%{release}
369Requires:       ocaml
370
371%description    ocaml
372OCaml binding for LLVM.
373
374%package        ocaml-devel
375Summary:        Development files for %{name}-ocaml
376Summary(ja):    %{name}-ocaml の開発ファイル
[12474]377Group:          programming
[1073]378Requires:       %{name}-devel = %{version}-%{release}
379Requires:       %{name}-ocaml = %{version}-%{release}
380Requires:       ocaml
381
382%description    ocaml-devel
383The %{name}-ocaml-devel package contains libraries and signature files
384for developing applications that use %{name}-ocaml.
385
386%package ocaml-doc
387Summary:        Documentation for %{name}-ocaml
388Summary(ja):    %{name}-ocaml のドキュメント
[12474]389Group:          documentation
[9470]390BuildArch:      noarch
[1073]391Requires:       %{name}-ocaml = %{version}-%{release}
[9470]392# might seem redundant, but needed to kill off the old arch-ed -doc subpackage
393Obsoletes:      %{name}-ocaml-doc < %{version}-%{release}
[1073]394
395%description ocaml-doc
396HTML documentation for LLVM's OCaml binding.
397
[11293]398%endif
399
[9470]400# compat32'
[11969]401%package -n compat32-%{name}%{ver_suffix}-libs
[9470]402Summary:        LLVM shared libraries
403Summary(ja):    LLVM 共有ライブラリ
[12474]404Group:          system
[11969]405Provides:       compat32-llvm-libs = %{version}-%{release}
406Requires:       %{name}%{ver_suffix}-libs = %{version}-%{release}
[1073]407
[11969]408%description -n compat32-%{name}%{ver_suffix}-libs
[9470]409Shared libraries for the LLVM compiler infrastructure.
[1073]410
[9470]411
[12506]412%debug_package
413
414
[1073]415%prep
[12221]416%setup -q -a1 -a2 -a3 -a4 -a6 -n llvm-%{version}.src
[11308]417
[12228]418#%patch0 -p2
419#%patch1 -p2
420#%patch2 -p2
421##patch3 -p2
[11308]422
[11969]423rm -rf tools/clang tools/lld tools/lldb projects/compiler-rt
[12320]424mv clang-%{version}.src tools/clang
[9470]425mv compiler-rt-%{version}.src projects/compiler-rt
426mv lldb-%{version}.src tools/lldb
[11969]427mv lld-%{version}.src tools/lld
[12221]428mv openmp-%{version}.src projects/openmp
[1073]429
[11969]430%if %{with clang_tools_extra}
431tar xvf %{SOURCE5}
432mv clang-tools-extra-%{version}.src tools/clang/tools/extra
433%endif
434
[11293]435pushd tools/clang
[12228]436##patch100 -p1
437#%patch101 -p2
438#%patch102 -p1
439#%patch103 -p2
[9470]440popd
441
[12228]442pushd projects/compiler-rt
443#%patch200 -p1
444popd
445
[11969]446pushd tools/lld
[12228]447#%patch400 -p1
[11308]448popd
449
[9470]450# Vine Linux
[11293]451%if %{with force_gold}
452pushd tools/clang
[9121]453%patch1000 -p1 -b .driver-ld.gold
[11293]454popd
455%endif
[11308]456#%patch1002 -p1 -b .driver-vine
[7201]457
[12228]458sed -i -e 's/"i686-linux-gnu",/"i686-linux-gnu","i686-vine-linux","i686-vine-linux-gnu",/' tools/clang/lib/Driver/ToolChains/Gnu.cpp
459sed -i -e 's/"x86_64-linux-gnu",/"x86_64-linux-gnu","x86_64-vine-linux","x86_64-vine-linux-gnu",/' tools/clang/lib/Driver/ToolChains/Gnu.cpp
[11308]460
[11293]461sed -i -e 's/"ld"/"ld.gold"/' tools/clang/include/clang/Driver/ToolChain.h
[1073]462
463%build
[11293]464mkdir build
465cd build
466
[12228]467%ifarch s390 s390x %{arm} %ix86
468# Decrease debuginfo verbosity to reduce memory consumption during final library linking
469%global optflags %(echo %{optflags} | sed 's/-g /-g1 /')
470%endif
[11293]471
[12228]472#CFLAGS="%{optflags} -fno-strict-aliasing -Wno-error=format-security -fPIC"
473#CXXFLAGS="%{optflags} -fno-strict-aliasing -Wno-error=format-security -fPIC -std=c++11"
474#TMP_PWD=$(pwd)
475#LDFLAGS="%{?__global_ldflags} -L$TMP_PWD/%{_lib} -lpthread -ldl"
476
[11293]477%cmake .. \
[12228]478        -GNinja \
[11293]479        -DBUILD_SHARED_LIBS:BOOL=OFF \
[12228]480        -DLLVM_PARALLEL_LINK_JOBS=1 \
[11293]481        -DCMAKE_BUILD_TYPE=Release \
[12228]482        -DCMAKE_INSTALL_RPATH=";" \
[11293]483%if 0%{?__isa_bits} == 64
484        -DLLVM_LIBDIR_SUFFIX=64 \
485%else
486        -DLLVM_LIBDIR_SUFFIX= \
487%endif
[12228]488        -DLLVM_TARGETS_TO_BUILD=all \
[11293]489        -DLLVM_ENABLE_LIBCXX:BOOL=OFF \
490        -DLLVM_ENABLE_ZLIB:BOOL=ON \
491        -DLLVM_ENABLE_FFI:BOOL=ON \
492        -DLLVM_ENABLE_RTTI:BOOL=ON \
[12228]493        -DLLVM_ENABLE_EH=ON \
[11293]494        -DLLVM_BINUTILS_INCDIR=%{_includedir} \
495        -DLLVM_BUILD_RUNTIME:BOOL=ON \
[12506]496        \
[11293]497        -DLLVM_INCLUDE_TOOLS:BOOL=ON \
498        -DLLVM_BUILD_TOOLS:BOOL=ON \
[12506]499        \
[11293]500        -DLLVM_INCLUDE_TESTS:BOOL=ON \
501        -DLLVM_BUILD_TESTS:BOOL=ON \
[12506]502        \
[11293]503        -DLLVM_INCLUDE_EXAMPLES:BOOL=ON \
504        -DLLVM_BUILD_EXAMPLES:BOOL=OFF \
[12506]505        \
[11293]506        -DLLVM_INCLUDE_UTILS:BOOL=ON \
[12506]507        -DLLVM_INSTALL_UTILS:BOOL=ON \
508        -DLLVM_UTILS_INSTALL_DIR:PATH=%{_bindir} \
509        -DLLVM_TOOLS_INSTALL_DIR:PATH=bin \
510        \
[11293]511        -DLLVM_INCLUDE_DOCS:BOOL=ON \
512        -DLLVM_ENABLE_SPHINX:BOOL=OFF \
[9470]513%if %{with doxygen}
[11293]514        -DLLVM_ENABLE_DOXYGEN:BOOL=ON \
[9470]515%else
[11293]516        -DLLVM_ENABLE_DOXYGEN:BOOL=OFF \
[5555]517%endif
[11293]518        -DLLVM_BUILD_LLVM_DYLIB:BOOL=ON \
[11969]519        -DLLVM_DYLIB_EXPORT_ALL:BOOL=ON \
[11293]520        -DLLVM_LINK_LLVM_DYLIB:BOOL=ON \
521        -DLLVM_INSTALL_TOOLCHAIN_ONLY:BOOL=OFF \
522        -DLLVM_OPTIMIZED_TABLEGEN:BOOL=ON \
523        \
524        -DCLANG_ENABLE_ARCMT:BOOL=ON \
525        -DCLANG_ENABLE_STATIC_ANALYZER:BOOL=ON \
526        -DCLANG_INCLUDE_DOCS:BOOL=ON \
527        -DCLANG_INCLUDE_TESTS:BOOL=ON \
528        -DCLANG_PLUGIN_SUPPORT:BOOL=ON \
529        -DCLANG_BUILD_EXAMPLES:BOOL=OFF \
[12228]530        -DCLANG_LINK_CLANG_DYLIB=ON \
531        -DCLANG_REPOSITORY_STRING="Vine Linux %{version}-%{release}" \
[11293]532        -DLIB_SUFFIX= \
533        \
534        -DLLDB_DISABLE_CURSES:BOOL=OFF \
535        -DLLDB_DISABLE_LIBEDIT:BOOL=OFF \
536        -DLLDB_DISABLE_PYTHON:BOOL=OFF \
537        \
[11969]538        -DLLDB_LINK_LLVM_DYLIB:BOOL=ON \
539        \
[12221]540        -DLIBOMP_INSTALL_ALIASES=OFF \
541        -DLIBOMP_HEADERS_INSTALL_PATH:PATH=%{_libdir}/clang/%{version}/include \
542        \
[12228]543        -DPYTHON_EXECUTABLE:STRING=%{__python3} \
[11293]544        -DCOMPILER_RT_INCLUDE_TESTS:BOOL=OFF # could be on?
[9594]545
[11293]546# workaround for all-in-one build
[11308]547#TMP_PWD=$(pwd)
548#LD_LIBRARY_PATH="$TMP_PWD/%{_lib}" make %{?_smp_mflags}
[9594]549
[12228]550%ninja_build
551
[1073]552%install
553rm -rf %{buildroot}
[5555]554
[11293]555cd build
[12228]556%ninja_install
[4656]557
[11293]558# llvm
[9121]559
[11293]560install -m755 ./bin/lli-child-target %{buildroot}%{_bindir}/lli-child-target
[4656]561
[11293]562# fix multi-lib
563mv -v %{buildroot}%{_bindir}/llvm-config{,-%{__isa_bits}}
[11308]564ln -sf llvm-config-%{__isa_bits} %{buildroot}%{_bindir}/llvm-config
[11293]565mv -v %{buildroot}%{_includedir}/llvm/Config/llvm-config{,-%{__isa_bits}}.h
566install -m 0644 %{SOURCE10} %{buildroot}%{_includedir}/llvm/Config/llvm-config.h
[1073]567
[11293]568# clang
[9470]569
[11308]570# remove static libraries
571rm -fv %{buildroot}%{_libdir}/libclang*.a
572
573# install clang python bindings
[12228]574mkdir -p %{buildroot}%{python3_sitelib}/clang/
575install -p -m644 ../tools/clang/bindings/python/clang/* %{buildroot}%{python3_sitelib}/clang/
[11308]576
[11293]577mv -v %{buildroot}%{_includedir}/clang/Config/config{,-%{__isa_bits}}.h
578install -m 0644 %{SOURCE11} %{buildroot}%{_includedir}/clang/Config/config.h
[9470]579
[11293]580# remove git integration
581rm -vf %{buildroot}%{_bindir}/git-clang-format
582# remove editor integrations (bbedit, sublime, emacs, vim)
583rm -vf %{buildroot}%{_datadir}/clang/clang-format-bbedit.applescript
584rm -vf %{buildroot}%{_datadir}/clang/clang-format-sublime.py*
585rm -vf %{buildroot}%{_datadir}/clang/clang-format.el
586rm -vf %{buildroot}%{_datadir}/clang/clang-format.py*
587# remove diff reformatter
588rm -vf %{buildroot}%{_datadir}/clang/clang-format-diff.py*
[9470]589
590
[11293]591# lldb
[1073]592
[11293]593# remove static libraries
[11308]594rm -fv %{buildroot}%{_libdir}/liblldb*.a
[1073]595
[11293]596# python: fix binary libraries location
597liblldb=$(basename $(readlink -e %{buildroot}%{_libdir}/liblldb.so))
[12228]598ln -vsf "../../../${liblldb}" %{buildroot}%{python3_sitearch}/lldb/_lldb.so
[1073]599
[11293]600# remove bundled six.py
[12228]601rm -f %{buildroot}%{python3_sitearch}/six.*
[1073]602
[9594]603
[11969]604# lld
[11308]605
[11969]606# remove static libraries
607rm -fv %{buildroot}%{_libdir}/liblld*.a
608
609# Remove rpath
610chrpath --delete %{buildroot}%{_bindir}/*lld
611chrpath --delete %{buildroot}%{_bindir}/lld-link
612chrpath --delete %{buildroot}%{_bindir}/wasm-ld
613find %{buildroot}%{_libdir} -type f -name 'liblld*.so*' | \
614  grep -v 'liblldb' | \
615  xargs chrpath --delete
616
617%if !%{with lld_libs}
618  rm -rf %{buildroot}%{_includedir}/lld
619%endif
620
[11293]621# compiler-rt
[9470]622
[11293]623# move sanitizer lists to better place
624mkdir -p %{buildroot}%{_libdir}/clang/%{version}
625for file in asan_blacklist.txt msan_blacklist.txt dfsan_blacklist.txt cfi_blacklist.txt dfsan_abilist.txt; do
626        mv -v %{buildroot}%{_prefix}/${file} %{buildroot}%{_libdir}/clang/%{version}/ || :
[1073]627done
628
[11293]629# move sanitizer libs to better place
630#mkdir -p %{buildroot}%{_libdir}/clang/%{version}/lib
631#mv -v %{buildroot}%{_prefix}/lib/linux/libclang_rt* %{buildroot}%{_libdir}/clang/%{version}/lib
632#mkdir -p %{buildroot}%{_libdir}/clang/%{version}/lib/linux/
633#pushd %{buildroot}%{_libdir}/clang/%{version}/lib
634#for i in *.a *.syms *.so; do
635#        ln -s ../$i linux/$i
636#done
[1073]637
[11308]638#rm -rf %{buildroot}%{_libdir}/python*
[1073]639
[11308]640rm -f %{buildroot}%{_datadir}/clang/bash-autocomplete.sh
641rm -f %{buildroot}%{_datadir}/clang/clang-rename.el
642rm -f %{buildroot}%{_datadir}/clang/clang-rename.py
[1073]643
[12228]644%if %{with test}
[4656]645%check
[12228]646ninja -C build check
647ninja -C build check-clang
648ninja -C build check-lldb
649ninja -C build check-lld
650%endif
[4656]651
[12506]652
[1073]653%clean
654rm -rf %{buildroot}
655
656
[11969]657%post -n llvm%{ver_suffix}-libs -p /sbin/ldconfig
658%postun -n llvm%{ver_suffix}-libs -p /sbin/ldconfig
[1073]659
[9470]660%post -n clang-libs -p /sbin/ldconfig
661%postun -n clang-libs -p /sbin/ldconfig
[1073]662
[9470]663%post -n lldb -p /sbin/ldconfig
664%postun -n lldb -p /sbin/ldconfig
[1073]665
[11969]666%post -n lld
667  /sbin/alternatives --install /usr/bin/ld ld \
668  /usr/bin/ld.lld 20
[1073]669
[11969]670%preun -n lld
671if [ $1 = 0 ]; then
672  /sbin/alternatives --remove ld /usr/bin/ld.lld
673fi
674
675%if %{with lld_libs}
676%post -n lld-libs -p /sbin/ldconfig
677%postun -n lld-libs -p /sbin/ldconfig
678%endif
679
[4656]680%posttrans devel
681# link llvm-config to the platform-specific file;
682# use ISA bits as priority so that 64-bit is preferred
683# over 32-bit if both are installed
684alternatives \
685  --install \
686  %{_bindir}/llvm-config \
687  llvm-config \
688  %{_bindir}/llvm-config-%{__isa_bits} \
689  %{__isa_bits}
690
691%postun devel
692if [ $1 -eq 0 ]; then
693  alternatives --remove llvm-config \
694    %{_bindir}/llvm-config-%{__isa_bits}
695fi
696exit 0
697
698
[1073]699%files
700%defattr(-,root,root,-)
[9470]701%doc CREDITS.TXT README.txt
[12506]702%{_bindir}/FileCheck
[1073]703%{_bindir}/bugpoint
[11969]704%{_bindir}/dsymutil
[1073]705%{_bindir}/llc
706%{_bindir}/lli
[9121]707%{_bindir}/lli-child-target
[11293]708%{_bindir}/obj2yaml
709%{_bindir}/sancov
[11308]710%{_bindir}/sanstats
[11293]711%{_bindir}/verify-uselistorder
712%{_bindir}/yaml2obj
[12506]713%{_bindir}/count
714%{_bindir}/not
715%{_bindir}/yaml-bench
[11308]716%exclude %{_bindir}/llvm-config
[4656]717%exclude %{_bindir}/llvm-config-%{__isa_bits}
[1073]718%{_bindir}/llvm*
719%{_bindir}/opt
[9470]720%exclude %{_mandir}/man1/scan-build.1.*
[1073]721%doc %{_mandir}/man1/*.1.*
[11308]722%{_datadir}/opt-viewer
[1073]723
[12506]724%files -n llvm%{ver_suffix}-libs
725%defattr(-,root,root,-)
726%license LICENSE.TXT
727#config(noreplace) %{_sysconfdir}/ld.so.conf.d/llvm-%{_arch}.conf
728#dir %{_libdir}/%{name}
729%{_libdir}/libLLVM-*.so
730%{_libdir}/LLVMgold.so
731%{_libdir}/libLTO.so*
732%{_libdir}/libRemarks.so*
733
[1073]734%files devel
735%defattr(-,root,root,-)
[9470]736#doc %{llvmdocdir %{name}-devel}/
[11308]737%{_bindir}/llvm-config
[4656]738%{_bindir}/llvm-config-%{__isa_bits}
[1073]739%{_includedir}/%{name}
740%{_includedir}/%{name}-c
[12221]741#{_libdir}/BugpointPasses.so
[11293]742%{_libdir}/libLLVM.so
[11308]743%{_libdir}/cmake/llvm
[12228]744#exclude %{_libdir}/cmake/llvm/LLVMStaticExports.cmake
[1073]745
[11308]746%files static
747%{_libdir}/*.a
[12228]748#{_libdir}/cmake/llvm/LLVMStaticExports.cmake
[11308]749
[1073]750%files -n clang
751%defattr(-,root,root,-)
[11293]752#doc %{llvmdocdir clang}/
[1073]753%{_bindir}/clang*
[7197]754%{_bindir}/c-index-test
[11969]755%{_bindir}/diagtool
756%{_bindir}/hmaptool
[11293]757%{_libdir}/clang
[1073]758
[9470]759%files -n clang-libs
760%defattr(-,root,root,-)
[11293]761%{_libdir}/libclang.so
762%{_libdir}/libclang.so.*
[12221]763%{_libdir}/libclang-cpp.so
764%{_libdir}/libclang-cpp.so.*
[9470]765
[1073]766%files -n clang-devel
767%defattr(-,root,root,-)
[9470]768#doc %{llvmdocdir clang-devel}/
[1073]769%{_includedir}/clang
770%{_includedir}/clang-c
[11293]771%dir %{_datadir}/clang/
[11308]772%{_libdir}/cmake/*
[1073]773
774%files -n clang-analyzer
775%defattr(-,root,root,-)
776%{_bindir}/scan-build
777%{_bindir}/scan-view
[12320]778#%{_libdir}/CheckerDependencyHandlingAnalyzerPlugin.so
779#%{_libdir}/CheckerOptionHandlingAnalyzerPlugin.so
780#%{_libdir}/SampleAnalyzerPlugin.so
[11293]781%{_libexecdir}/ccc-analyzer
782%{_libexecdir}/c++-analyzer
783%{_datadir}/scan-view
784%{_datadir}/scan-build
[9470]785%{_mandir}/man1/scan-build.1.*
[1073]786
[12228]787%files -n python3-clang
788%{python3_sitelib}/clang/
[11308]789
[9470]790%files -n lldb
[1073]791%defattr(-,root,root,-)
[11293]792#doc %{llvmdocdir lldb}/
[11308]793%{_bindir}/lldb*
[11969]794%{_libdir}/liblldb*.so.*
[1073]795
[9470]796%files -n lldb-devel
797%defattr(-,root,root,-)
798%{_includedir}/lldb
[11969]799%{_libdir}/liblldb*.so
[9470]800
[12228]801%files -n python3-lldb
802%{python3_sitearch}/lldb
[11293]803
[11969]804%files -n lld
805%defattr(-,root,root,-)
806%{_bindir}/lld*
807%{_bindir}/ld.lld
808%{_bindir}/ld64.lld
809%{_bindir}/wasm-ld
810%exclude %{_bindir}/lldb*
811
812%if %{with lld_libs}
813%files -n lld-libs
814%{_libdir}/liblld*.so.*
815%exclude %{_libdir}/liblldb*.so.*
816
817%files -n lld-devel
818%{_includedir}/lld
819%{_libdir}/liblld*.so
820%exclude %{_libdir}/liblldb*.so
821%endif
822
[12221]823%files -n libomp
[12354]824%{_libdir}/libarcher.so
[12221]825%{_libdir}/libomp.so
826%{_libdir}/libomptarget.so
827
828%files -n libomp-devel
829%{_libdir}/clang/%{version}/include/omp.h
830%{_libdir}/clang/%{version}/include/omp-tools.h
831%{_libdir}/clang/%{version}/include/ompt.h
[12506]832%{_includedir}/ompt-multiplex.h
[12221]833
[1073]834%files doc
835%defattr(-,root,root,-)
[11293]836%doc docs/*
837#doc %{llvmdocdir %{name}-doc}/
[1073]838
[11293]839%if %{with ocaml}
[1073]840%files ocaml
841%defattr(-,root,root,-)
842%{_libdir}/ocaml/*.cma
843%{_libdir}/ocaml/*.cmi
[9073]844%{_libdir}/ocaml/*.so
845%{_libdir}/ocaml/META.llvm*
[1073]846
847%files ocaml-devel
848%defattr(-,root,root,-)
849%{_libdir}/ocaml/*.a
850%{_libdir}/ocaml/*.cmx*
851%{_libdir}/ocaml/*.mli
852
853%files ocaml-doc
854%defattr(-,root,root,-)
[9594]855#doc %{llvmdocdir %{name}-ocaml-doc}/
[11293]856%endif
[1073]857
[4656]858%if 0%{?_with_doxygen}
[1073]859%files apidoc
860%defattr(-,root,root,-)
[9470]861%doc %{llvmdocdir %{name}-apidoc}/
[4656]862
863%files -n clang-apidoc
864%defattr(-,root,root,-)
[9470]865%doc %{llvmdocdir clang-apidoc}/
[1073]866%endif
867
[9470]868%if %{build_compat32}
[11969]869%files -n compat32-%{name}%{ver_suffix}-libs
[9470]870%defattr(-,root,root)
[12506]871%license LICENSE.TXT
[11293]872#config(noreplace) %{_sysconfdir}/ld.so.conf.d/llvm-%{_arch}.conf
[11985]873%exclude %{_libdir}/libLTO.so
[12228]874#exclude %{_libdir}/BugpointPasses.so
875%exclude %{_libdir}/libclang*.so
[11969]876%exclude %{_libdir}/liblld*.so
[12506]877%exclude %{_libdir}/LLVMgold.so
[11293]878%{_libdir}/*.so
[12506]879%{_libdir}/libRemarks.so.*
[9470]880%endif
[1073]881
[12506]882
[4656]883%changelog
[12506]884* Fri Oct 16 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 11.0.0-2
885- enabled to build utils.
886
887* Thu Oct 15 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 11.0.0-1
888- new upstream release.
889
[12474]890* Mon Aug 17 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.1-1
891- new upstream release.
892
[12376]893* Thu Apr 16 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.0-2
894- rebuilt with libffi-3.3.
895
896* Fri Mar 27 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.0.0-1
897- new upstream release.
898
[12320]899* Sun Dec 22 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 9.0.1-1
900- new upstream release.
901
[12228]902* Sun Sep 22 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 9.0.0-2
903- dropped all patches.
904- switched build-system to ninja.
905- switched python to python3.
906
[12221]907* Fri Sep 20 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 9.0.0-1
908- new upstream release.
909- added OpenMP.
910
[11985]911* Sun Dec 16 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 7.0.1-1
912- fixed %%files.
913
[11969]914* Wed Dec 05 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 7.0.0-1
915- new upstream release.
916- dropped Patch0, 4, 5, 100 and 200.
917- imported Patch3, 7, 12, 15, 100, 101, 102 and 400 from rawhide.
918- renamed a subpackage "llvm-libs".
919- added a subpackage "lld".
920
[11308]921* Tue Jan 02 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.0.1-2
922- added subpackages "llvm-static", "python-lldb" and "python-clang".
923
924* Mon Jan 01 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.0.1-1
925- new upstream release.
926- dropped Patch1 and 2: fixed in upstream.
927- imported Patch0, 3-5, 100 and 200 from rawhide.
928- disabled Patch1002: no longer needed?
929
[11293]930* Fri Aug  5 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.8.1-1
931- new upstream release.
932- switched to cmake.
933- disable ocaml binding as default.
934- updated Patch1000 and 1002.
935- disabled Patch1000 as default.
936- cleanup patches.
937
[10438]938* Thu Jun 30 2016 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.6.2-2
939- rebuild with gcc-5.4.0
940
[9734]941* Sat Sep  5 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 3.6.2-1
942- new upstream release
943- added BR: ocaml-ctypes
944
[9594]945* Thu Jun  4 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 3.6.1-1
946- new upstream release
947- dropt Patch 1, 201 and 1001
948- updated Patch 1000
949
[9470]950* Tue Mar 24 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 3.5.1-1
951- updated to 3.5.1
952- added Patch1, 2, 100, 101, 200, 201 and 202 from Fedora
953- added clang-libs, lldb, lldb-devel and compat32-llvm-libs subpackage
954- obsoleted clang-doc
955- built with ocaml 4.02.1
956
[9121]957* Sat Nov 29 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.5.0-2
958- fix <BTS:2832>
959  - fix configure option "--with-c-include-dirs"
960  - update Patch1000: clang-3.5.0-driver-ld.gold.patch
961  - update Patch1001: clang-3.5.0-driver-lib64.patch
962  - update Patch1002: clang-3.5.0-driver-vine.patch
963
[9073]964* Tue Oct 28 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.5.0-1
965- update to 3.5.0
966- remove Patch11 (clang-hardfloat-hack.patch)
967
[8758]968* Sun Jul 06 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.3-2
969- rebuild with libffi-3.0.13
970
[7943]971* Mon Oct 28 2013 Daisuke SUZUKI <daisuke@linux.or.jp> 3.3-1
972- update to 3.3
973
[7201]974* Mon Dec 03 2012 Daisuke SUZUKI <daisuke@linux.or.jp> 3.1-2
975- ld.gold (patch1000,1001)
976- add /%{_lib} to ld search path
977- add support *-vine-linux gcc (patch1002)
978
[7197]979* Fri Nov 30 2012 Daisuke SUZUKI <daisuke@linux.or.jp> 3.1-1
980- update to 3.1
981
[5555]982* Tue Jan 24 2012 NAKAMURA Kenta <kenta@vinelinux.org> - 3.0-1
983- updated to 3.0 release
984
[5424]985* Sun Jan 15 2012 NAKAMURA Kenta <kenta@vinelinux.org> - 2.9-3
986- added patch 2-4 to support -O4 link-time optimization
987
[4738]988* Fri Sep  9 2011 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 2.9-2
989- disable -fno-var-tracking-assignments on ppc
990  (seems like gcc-4.4.5 still doesn't support this)
991
[4656]992* Thu Aug 25 2011 Daisuke SUZUKI <daisuke@linux.or.jp> 2.9-1
993- new upstream release
994- add BR: libffi-devel
995- add R: libffi-devel to -devel
[1073]996
997* Sun May 23 2010 Daisuke SUZUKI <daisuke@linux.or.jp> 2.7-1
998- initial build for Vine Linux
999
1000* Sun May  2 2010 Michel Salim <salimma@fedoraproject.org> - 2.7-1
1001- Update to final 2.7 release
1002
1003* Sun Mar 28 2010 Michel Salim <salimma@fedoraproject.org> - 2.7-0.1.pre1
1004- Update to first 2.7 pre-release
1005
1006* Fri Sep 18 2009 Michel Salim <salimma@fedoraproject.org> - 2.6-0.6.pre2
1007- Update to 2.6 pre-release2
1008- -devel subpackage now virtually provides -static
1009
1010* Wed Sep  9 2009 Michel Salim <salimma@fedoraproject.org> - 2.6-0.5.pre1
1011- Disable var tracking assignments on PPC
1012
1013* Wed Sep  9 2009 Michel Salim <salimma@fedoraproject.org> - 2.6-0.4.pre1
1014- Don't adjust clang include dir; files there are noarch (bz#521893)
1015- Enable clang unit tests
1016- clang and clang-analyzer renamed; no longer depend on llvm at runtime
1017
1018* Mon Sep  7 2009 Michel Salim <salimma@fedoraproject.org> - 2.6-0.3.pre1
1019- Package Clang's static analyzer tools
1020
1021* Mon Sep  7 2009 Michel Salim <salimma@fedoraproject.org> - 2.6-0.2.pre1
1022- PIC is now enabled by default; explicitly disable on %%{ix86}
1023
1024* Mon Sep  7 2009 Michel Salim <salimma@fedoraproject.org> - 2.6-0.1.pre1
1025- First 2.6 prerelease
1026- Enable Clang front-end
1027- Enable debuginfo generation
1028
1029* Sat Sep  5 2009 Michel Salim <salimma@fedoraproject.org> - 2.5-6
1030- Disable assertions (needed by OpenGTL, bz#521261)
1031- Align spec file with upstream build instructions
1032- Enable unit tests
1033
1034* Sat Aug 22 2009 Michel Salim <salimma@fedoraproject.org> - 2.5-5
1035- Only disable PIC on %%ix86; ppc actually needs it
1036
1037* Sat Aug 22 2009 Michel Salim <salimma@fedoraproject.org> - 2.5-4
1038- Disable use of position-independent code on 32-bit platforms
1039  (buggy in LLVM <= 2.5)
1040
1041* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.5-3
1042- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
1043
1044* Wed Mar  4 2009 Michel Salim <salimma@fedoraproject.org> - 2.5-2
1045- Remove build scripts; they require the build directory to work
1046
1047* Wed Mar  4 2009 Michel Salim <salimma@fedoraproject.org> - 2.5-1
1048- Update to 2.5
1049- Package build scripts (bug #457881)
1050
1051* Tue Dec  2 2008 Michel Salim <salimma@fedoraproject.org> - 2.4-2
1052- Patched build process for the OCaml binding
1053
1054* Tue Dec  2 2008 Michel Salim <salimma@fedoraproject.org> - 2.4-1
1055- Update to 2.4
1056- Package Ocaml binding
1057
1058* Wed Jun 18 2008 Bryan O'Sullivan <bos@serpentine.com> - 2.3-2
1059- Add dependency on groff
1060
1061* Wed Jun 18 2008 Bryan O'Sullivan <bos@serpentine.com> - 2.3-1
1062- LLVM 2.3
1063
1064* Thu May 29 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 2.2-4
1065- fix license tags
1066
1067* Wed Mar  5 2008 Bryan O'Sullivan <bos@serpentine.com> - 2.2-3
1068- Fix compilation problems with gcc 4.3
1069
1070* Mon Feb 18 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 2.2-2
1071- Autorebuild for GCC 4.3
1072
1073* Sun Jan 20 2008 Bryan O'Sullivan <bos@serpentine.com> - 2.1-2
1074- Fix review comments
1075
1076* Sun Jan 20 2008 Bryan O'Sullivan <bos@serpentine.com> - 2.1-1
1077- Initial version
Note: See TracBrowser for help on using the repository browser.