2023-11-30 16:02:59 +08:00
|
|
|
%bcond_without sys_llvm
|
|
|
|
|
%bcond_without check
|
2024-04-19 16:07:18 +08:00
|
|
|
%bcond_with classic_flang
|
2024-07-30 23:35:03 +00:00
|
|
|
%bcond_with toolchain_clang
|
2024-05-13 10:46:05 +08:00
|
|
|
%bcond_without bisheng_autotuner
|
2024-07-05 10:51:12 +08:00
|
|
|
|
|
|
|
|
%if %{with toolchain_clang}
|
|
|
|
|
%global toolchain clang
|
|
|
|
|
%endif
|
2023-07-06 14:40:49 +08:00
|
|
|
|
2023-11-30 16:02:59 +08:00
|
|
|
%global maj_ver 17
|
2019-12-17 21:09:38 +08:00
|
|
|
%global min_ver 0
|
2023-11-30 16:02:59 +08:00
|
|
|
%global patch_ver 6
|
2023-07-06 14:40:49 +08:00
|
|
|
%global clang_version %{maj_ver}.%{min_ver}.%{patch_ver}
|
|
|
|
|
|
|
|
|
|
%if %{with sys_llvm}
|
|
|
|
|
%global pkg_name clang
|
|
|
|
|
%global install_prefix %{_prefix}
|
2023-11-30 16:02:59 +08:00
|
|
|
%global install_datadir %{_datadir}
|
2023-07-06 14:40:49 +08:00
|
|
|
%else
|
|
|
|
|
%global pkg_name clang%{maj_ver}
|
|
|
|
|
%global install_prefix %{_libdir}/llvm%{maj_ver}
|
2023-11-30 16:02:59 +08:00
|
|
|
%global install_datadir %{install_prefix}/share
|
2023-07-06 14:40:49 +08:00
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%global install_bindir %{install_prefix}/bin
|
|
|
|
|
%global install_includedir %{install_prefix}/include
|
|
|
|
|
%if 0%{?__isa_bits} == 64
|
|
|
|
|
%global install_libdir %{install_prefix}/lib64
|
|
|
|
|
%else
|
|
|
|
|
%global install_libdir %{install_prefix}/lib
|
|
|
|
|
%endif
|
|
|
|
|
%global install_libexecdir %{install_prefix}/libexec
|
|
|
|
|
%global install_sharedir %{install_prefix}/share
|
|
|
|
|
%global install_docdir %{install_sharedir}/doc
|
|
|
|
|
|
|
|
|
|
%global clang_srcdir clang-%{clang_version}.src
|
|
|
|
|
%global clang_tools_srcdir clang-tools-extra-%{clang_version}.src
|
|
|
|
|
%global max_link_jobs %{_smp_build_ncpus}
|
|
|
|
|
|
|
|
|
|
# Disable LTO as this causes crash if gcc lto enabled.
|
|
|
|
|
%define _lto_cflags %{nil}
|
|
|
|
|
|
|
|
|
|
Name: %{pkg_name}
|
|
|
|
|
Version: %{clang_version}
|
2024-07-30 23:35:03 +00:00
|
|
|
Release: 20
|
2023-07-06 14:40:49 +08:00
|
|
|
Summary: A C language family front-end for LLVM
|
|
|
|
|
|
|
|
|
|
License: NCSA
|
2019-12-17 21:09:38 +08:00
|
|
|
URL: http://llvm.org
|
2023-07-06 14:40:49 +08:00
|
|
|
Source0: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{clang_version}/%{clang_srcdir}.tar.xz
|
|
|
|
|
Source1: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{clang_version}/%{clang_tools_srcdir}.tar.xz
|
|
|
|
|
|
2023-11-30 16:02:59 +08:00
|
|
|
Patch0: fedora-PATCH-clang-Don-t-install-static-libraries.patch
|
2024-02-18 15:00:27 +08:00
|
|
|
Patch1: 0001-Add-triples-for-X86_64-AArch64-Riscv64-openEuler-gcc.patch
|
2024-02-18 16:16:38 +08:00
|
|
|
Patch2: 0002-Revert-Clang-Change-the-default-DWARF-version-to-5.patch
|
2024-02-05 11:07:44 +08:00
|
|
|
Patch3: 0003-add-BUILD_FOR_OPENEULER-build-option-to-clang.patch
|
|
|
|
|
Patch4: 0004-add-gcc-compatible-in-BUILD_FOR_OPENEULER.patch
|
2024-02-05 16:41:49 +08:00
|
|
|
Patch5: 0005-backport-Disable-InterpreterExceptionTest-on-RISC-V.patch
|
2024-03-14 10:49:03 +08:00
|
|
|
Patch6: 0006-clang-LoongArch-Add-loongarch64-to-os-triple.patch
|
2024-03-15 09:30:54 +08:00
|
|
|
Patch7: 0007-add-more-warning-options-to-fgcc-compatible.patch
|
2024-03-29 10:09:25 +08:00
|
|
|
Patch8: 0008-Backport-LoongArch-Add-the-support-for-vector.patch
|
2024-04-09 15:54:45 +08:00
|
|
|
Patch9: 0009-Backport-LoongArch-improve-the-support-for-compiler-rt-and-bugfix.patch
|
2024-04-13 07:54:56 +08:00
|
|
|
Patch10: 0010-Backport-clang-Avoid-Wshadow-warning-when-init-capture-named.patch
|
2024-04-19 16:07:18 +08:00
|
|
|
Patch11: 0011-Add-the-support-for-classic-flang.patch
|
|
|
|
|
Patch12: 0012-Fix-declaration-definition-mismatch-for-classic-flang.patch
|
2024-04-29 14:30:45 +08:00
|
|
|
Patch13: 0013-Ignored-option-Wa-generate-missing-build-notes.patch
|
|
|
|
|
Patch14: 0014-Update-llvm-lit-config-to-support-build_for_openeule.patch
|
2024-06-04 15:12:53 +08:00
|
|
|
Patch15: 0015-Backport-Defer-the-instantiation-of-explicit-specifier-until-.patch
|
2024-05-13 10:46:05 +08:00
|
|
|
Patch16: 0016-Add-BiSheng-Autotuner-support-for-LLVM-compiler.patch
|
2023-11-30 16:02:59 +08:00
|
|
|
|
|
|
|
|
# Patches for clang-tools-extra
|
|
|
|
|
# See https://reviews.llvm.org/D120301
|
|
|
|
|
Patch201: fedora-clang-tools-extra-Make-test-dependency-on-LLVMHello-.patch
|
2023-05-18 12:36:53 +00:00
|
|
|
|
2023-07-06 14:40:49 +08:00
|
|
|
BuildRequires: gcc
|
|
|
|
|
BuildRequires: gcc-c++
|
|
|
|
|
BuildRequires: cmake
|
|
|
|
|
BuildRequires: libatomic
|
|
|
|
|
|
|
|
|
|
%if %{with sys_llvm}
|
2024-01-25 21:12:12 +08:00
|
|
|
BuildRequires: llvm-libs = %{version}
|
2023-05-18 12:36:53 +00:00
|
|
|
BuildRequires: llvm-devel = %{version}
|
2023-07-06 14:40:49 +08:00
|
|
|
BuildRequires: llvm-static = %{version}
|
|
|
|
|
BuildRequires: llvm-test = %{version}
|
2023-05-18 12:36:53 +00:00
|
|
|
BuildRequires: llvm-googletest = %{version}
|
2023-11-30 16:02:59 +08:00
|
|
|
BuildRequires: llvm-cmake-utils = %{version}
|
2023-07-06 14:40:49 +08:00
|
|
|
%else
|
2024-01-25 21:12:12 +08:00
|
|
|
BuildRequires: llvm%{maj_ver}-libs = %{version}
|
2023-07-06 14:40:49 +08:00
|
|
|
BuildRequires: llvm%{maj_ver}-devel = %{version}
|
|
|
|
|
BuildRequires: llvm%{maj_ver}-static = %{version}
|
|
|
|
|
BuildRequires: llvm%{maj_ver}-test = %{version}
|
|
|
|
|
BuildRequires: llvm%{maj_ver}-googletest = %{version}
|
2023-11-30 16:02:59 +08:00
|
|
|
BuildRequires: llvm%{maj_ver}-cmake-utils = %{version}
|
2023-07-06 14:40:49 +08:00
|
|
|
%endif
|
2023-05-18 12:36:53 +00:00
|
|
|
|
2023-07-06 14:40:49 +08:00
|
|
|
BuildRequires: libxml2-devel
|
|
|
|
|
BuildRequires: multilib-rpm-config
|
|
|
|
|
BuildRequires: ninja-build
|
|
|
|
|
BuildRequires: ncurses-devel
|
|
|
|
|
BuildRequires: perl-generators
|
|
|
|
|
BuildRequires: python3-lit >= %{version}
|
|
|
|
|
BuildRequires: python3-sphinx
|
|
|
|
|
BuildRequires: python3-recommonmark
|
|
|
|
|
BuildRequires: python3-devel
|
|
|
|
|
|
|
|
|
|
BuildRequires: perl(Digest::MD5)
|
|
|
|
|
BuildRequires: perl(File::Copy)
|
|
|
|
|
BuildRequires: perl(File::Find)
|
|
|
|
|
BuildRequires: perl(File::Path)
|
|
|
|
|
BuildRequires: perl(File::Temp)
|
|
|
|
|
BuildRequires: perl(FindBin)
|
|
|
|
|
BuildRequires: perl(Hash::Util)
|
|
|
|
|
BuildRequires: perl(lib)
|
|
|
|
|
BuildRequires: perl(Term::ANSIColor)
|
|
|
|
|
BuildRequires: perl(Text::ParseWords)
|
|
|
|
|
BuildRequires: perl(Sys::Hostname)
|
2024-07-05 10:51:12 +08:00
|
|
|
%if %{with toolchain_clang}
|
|
|
|
|
BuildRequires: clang
|
|
|
|
|
%endif
|
2023-07-06 14:40:49 +08:00
|
|
|
|
|
|
|
|
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
|
|
|
|
|
|
|
|
|
|
Requires: libstdc++-devel
|
2023-11-30 16:02:59 +08:00
|
|
|
# Require gcc libs installed during rumtime
|
|
|
|
|
Requires: gcc
|
2023-07-06 14:40:49 +08:00
|
|
|
Requires: gcc-c++
|
2019-12-17 21:09:38 +08:00
|
|
|
|
|
|
|
|
Provides: clang(major) = %{maj_ver}
|
2022-02-09 18:39:15 +08:00
|
|
|
|
2023-07-06 14:40:49 +08:00
|
|
|
Conflicts: compiler-rt < 11.0.0
|
2022-10-15 12:45:14 +08:00
|
|
|
|
2019-12-17 21:09:38 +08:00
|
|
|
%description
|
2023-07-06 14:40:49 +08:00
|
|
|
clang: noun
|
|
|
|
|
1. A loud, resonant, metallic sound.
|
|
|
|
|
2. The strident call of a crane or goose.
|
|
|
|
|
3. C-language family front-end toolkit.
|
|
|
|
|
|
|
|
|
|
The goal of the Clang project is to create a new C, C++, Objective C
|
|
|
|
|
and Objective C++ front-end for the LLVM compiler. Its tools are built
|
|
|
|
|
as libraries and designed to be loosely-coupled and extensible.
|
|
|
|
|
|
|
|
|
|
Install compiler-rt if you want the Blocks C language extension or to
|
|
|
|
|
enable sanitization and profiling options when building, and
|
|
|
|
|
libomp-devel to enable -fopenmp.
|
|
|
|
|
|
|
|
|
|
%package libs
|
|
|
|
|
Summary: Runtime library for clang
|
|
|
|
|
Requires: %{name}-resource-filesystem%{?_isa} = %{version}
|
|
|
|
|
Recommends: compiler-rt%{?_isa} = %{version}
|
|
|
|
|
Recommends: libatomic%{?_isa}
|
|
|
|
|
Recommends: libomp-devel%{_isa} = %{version}
|
|
|
|
|
Recommends: libomp%{_isa} = %{version}
|
|
|
|
|
|
|
|
|
|
%description libs
|
|
|
|
|
Runtime library for clang.
|
2019-12-17 21:09:38 +08:00
|
|
|
|
|
|
|
|
%package devel
|
2023-07-06 14:40:49 +08:00
|
|
|
Summary: Development header files for clang
|
|
|
|
|
Requires: %{name}-libs = %{version}-%{release}
|
2019-12-17 21:09:38 +08:00
|
|
|
|
|
|
|
|
%description devel
|
|
|
|
|
Development header files for clang.
|
|
|
|
|
|
2022-02-09 18:39:15 +08:00
|
|
|
%package resource-filesystem
|
|
|
|
|
Summary: Filesystem package that owns the clang resource directory
|
|
|
|
|
Provides: %{name}-resource-filesystem(major) = %{maj_ver}
|
|
|
|
|
|
|
|
|
|
%description resource-filesystem
|
|
|
|
|
This package owns the clang resouce directory: $libdir/clang/$version/
|
|
|
|
|
|
2019-12-17 21:09:38 +08:00
|
|
|
|
|
|
|
|
%package analyzer
|
|
|
|
|
Summary: A source code analysis framework
|
|
|
|
|
License: NCSA and MIT
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
|
|
|
|
|
%description analyzer
|
|
|
|
|
The Clang Static Analyzer consists of both a source code analysis
|
|
|
|
|
framework and a standalone tool that finds bugs in C and Objective-C
|
|
|
|
|
programs. The standalone tool is invoked from the command-line, and is
|
|
|
|
|
intended to run in tandem with a build of a project or code base.
|
|
|
|
|
|
|
|
|
|
%package tools-extra
|
|
|
|
|
Summary: Extra tools for clang
|
2023-07-06 14:40:49 +08:00
|
|
|
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
|
2019-12-17 21:09:38 +08:00
|
|
|
Requires: emacs-filesystem
|
|
|
|
|
|
|
|
|
|
%description tools-extra
|
|
|
|
|
A set of extra tools built using Clang's tooling API.
|
|
|
|
|
|
2023-11-30 16:02:59 +08:00
|
|
|
%package tools-extra-devel
|
|
|
|
|
Summary: Development header files for clang tools
|
|
|
|
|
Requires: %{name}-tools-extra = %{version}-%{release}
|
|
|
|
|
|
|
|
|
|
%description tools-extra-devel
|
|
|
|
|
Development header files for clang tools.
|
|
|
|
|
|
2019-12-17 21:09:38 +08:00
|
|
|
%package -n git-clang-format
|
2023-07-06 14:40:49 +08:00
|
|
|
Summary: Integration of clang-format for git
|
|
|
|
|
Requires: %{name}-tools-extra = %{version}-%{release}
|
2019-12-17 21:09:38 +08:00
|
|
|
Requires: git
|
2023-07-06 14:40:49 +08:00
|
|
|
Requires: python3
|
2019-12-17 21:09:38 +08:00
|
|
|
|
|
|
|
|
%description -n git-clang-format
|
|
|
|
|
clang-format integration for git.
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%setup -T -q -b 1 -n %{clang_tools_srcdir}
|
2023-11-30 16:02:59 +08:00
|
|
|
%autopatch -m200 -p2
|
|
|
|
|
|
|
|
|
|
# failing test case
|
|
|
|
|
#rm test/clang-tidy/checkers/altera/struct-pack-align.cpp
|
2023-07-06 14:40:49 +08:00
|
|
|
|
2019-12-17 21:09:38 +08:00
|
|
|
pathfix.py -i %{__python3} -pn \
|
2023-11-30 16:02:59 +08:00
|
|
|
clang-tidy/tool/ \
|
|
|
|
|
clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py
|
2019-12-17 21:09:38 +08:00
|
|
|
|
2023-07-06 14:40:49 +08:00
|
|
|
%setup -q -n %{clang_srcdir}
|
|
|
|
|
%autopatch -M200 -p2
|
|
|
|
|
|
2019-12-17 21:09:38 +08:00
|
|
|
pathfix.py -i %{__python3} -pn \
|
2023-11-30 16:02:59 +08:00
|
|
|
tools/clang-format/ \
|
2019-12-17 21:09:38 +08:00
|
|
|
tools/clang-format/git-clang-format \
|
|
|
|
|
utils/hmaptool/hmaptool \
|
2023-11-30 16:02:59 +08:00
|
|
|
tools/scan-view/bin/scan-view \
|
|
|
|
|
tools/scan-view/share/Reporter.py \
|
|
|
|
|
tools/scan-view/share/startfile.py \
|
|
|
|
|
tools/scan-build-py/bin/* \
|
|
|
|
|
tools/scan-build-py/libexec/*
|
2019-12-17 21:09:38 +08:00
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
mkdir -p _build
|
|
|
|
|
cd _build
|
2023-07-06 14:40:49 +08:00
|
|
|
%cmake .. -G Ninja \
|
|
|
|
|
-DCLANG_DEFAULT_PIE_ON_LINUX=ON \
|
|
|
|
|
-DLLVM_PARALLEL_LINK_JOBS=%{max_link_jobs} \
|
2019-12-17 21:09:38 +08:00
|
|
|
-DLLVM_LINK_LLVM_DYLIB:BOOL=ON \
|
2023-07-06 14:40:49 +08:00
|
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
|
|
|
-DPYTHON_EXECUTABLE=%{__python3} \
|
|
|
|
|
-DCMAKE_SKIP_RPATH:BOOL=ON \
|
|
|
|
|
-DCLANG_BUILD_TOOLS:BOOL=ON \
|
|
|
|
|
-DCMAKE_INSTALL_PREFIX=%{install_prefix} \
|
2019-12-17 21:09:38 +08:00
|
|
|
-DCLANG_INCLUDE_TESTS:BOOL=ON \
|
|
|
|
|
-DLLVM_EXTERNAL_LIT=%{_bindir}/lit \
|
2023-07-06 14:40:49 +08:00
|
|
|
-DLLVM_CONFIG:FILEPATH=%{install_bindir}/llvm-config \
|
|
|
|
|
-DLLVM_TABLEGEN_EXE:FILEPATH=%{install_bindir}/llvm-tblgen \
|
|
|
|
|
-DLLVM_MAIN_SRC_DIR=%{install_prefix}/src \
|
|
|
|
|
-DLLVM_LIT_ARGS="-vv" \
|
|
|
|
|
-DLLVM_BUILD_UTILS:BOOL=ON \
|
2023-11-30 16:02:59 +08:00
|
|
|
-DLLVM_COMMON_CMAKE_UTILS=%{install_datadir}/llvm/cmake \
|
2019-12-17 21:09:38 +08:00
|
|
|
-DCLANG_ENABLE_ARCMT:BOOL=ON \
|
|
|
|
|
-DCLANG_ENABLE_STATIC_ANALYZER:BOOL=ON \
|
|
|
|
|
-DCLANG_INCLUDE_DOCS:BOOL=ON \
|
|
|
|
|
-DCLANG_PLUGIN_SUPPORT:BOOL=ON \
|
|
|
|
|
-DENABLE_LINKER_BUILD_ID:BOOL=ON \
|
|
|
|
|
-DLLVM_ENABLE_EH=ON \
|
|
|
|
|
-DLLVM_ENABLE_RTTI=ON \
|
|
|
|
|
-DLLVM_BUILD_DOCS=ON \
|
|
|
|
|
-DLLVM_ENABLE_SPHINX=ON \
|
2023-07-06 14:40:49 +08:00
|
|
|
-DCLANG_LINK_CLANG_DYLIB=ON \
|
2019-12-17 21:09:38 +08:00
|
|
|
-DSPHINX_WARNINGS_AS_ERRORS=OFF \
|
|
|
|
|
-DCLANG_BUILD_EXAMPLES:BOOL=OFF \
|
2023-07-06 14:40:49 +08:00
|
|
|
-DBUILD_SHARED_LIBS=OFF \
|
|
|
|
|
-DCLANG_REPOSITORY_STRING="%{?distro} %{version}-%{release}" \
|
2023-11-30 16:02:59 +08:00
|
|
|
-DLLVM_EXTERNAL_CLANG_TOOLS_EXTRA_SOURCE_DIR=../../%{clang_tools_srcdir} \
|
|
|
|
|
%if 0%{?__isa_bits} == 64
|
|
|
|
|
-DCLANG_RESOURCE_DIR=../lib64/clang/%{maj_ver} \
|
|
|
|
|
%else
|
|
|
|
|
-DCLANG_RESOURCE_DIR=../lib/clang/%{maj_ver} \
|
|
|
|
|
%endif
|
2023-07-06 14:40:49 +08:00
|
|
|
%if 0%{?__isa_bits} == 64
|
|
|
|
|
-DLLVM_LIBDIR_SUFFIX=64 \
|
|
|
|
|
%else
|
|
|
|
|
-DLLVM_LIBDIR_SUFFIX= \
|
2024-04-19 16:07:18 +08:00
|
|
|
%endif
|
|
|
|
|
%if %{with classic_flang}
|
|
|
|
|
-DLLVM_ENABLE_CLASSIC_FLANG=ON \
|
2024-05-13 10:46:05 +08:00
|
|
|
%endif
|
|
|
|
|
%if %{with bisheng_autotuner}
|
|
|
|
|
-DLLVM_ENABLE_AUTOTUNER=ON \
|
2023-07-06 14:40:49 +08:00
|
|
|
%endif
|
2024-02-05 11:07:44 +08:00
|
|
|
-DBUILD_FOR_OPENEULER=ON \
|
2024-07-05 10:51:12 +08:00
|
|
|
%if "%{toolchain}" == "clang"
|
|
|
|
|
-DCMAKE_C_COMPILER=clang \
|
|
|
|
|
-DCMAKE_CXX_COMPILER=clang++ \
|
|
|
|
|
%endif
|
2023-07-06 14:40:49 +08:00
|
|
|
-DCLANG_DEFAULT_UNWINDLIB=libgcc
|
2019-12-17 21:09:38 +08:00
|
|
|
|
2023-07-06 14:40:49 +08:00
|
|
|
%ninja_build
|
2019-12-17 21:09:38 +08:00
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
|
2023-07-06 14:40:49 +08:00
|
|
|
%ninja_install -C _build
|
|
|
|
|
mkdir -p %{buildroot}/%{_bindir}
|
2019-12-17 21:09:38 +08:00
|
|
|
|
2023-11-30 16:02:59 +08:00
|
|
|
rm -vf %{buildroot}%{_datadir}/clang/clang-format-bbedit.applescript
|
|
|
|
|
rm -vf %{buildroot}%{_datadir}/clang/clang-format-sublime.py*
|
|
|
|
|
|
2023-07-06 14:40:49 +08:00
|
|
|
rm -vf %{buildroot}%{install_sharedir}/clang/clang-format-bbedit.applescript
|
|
|
|
|
rm -vf %{buildroot}%{install_sharedir}/clang/clang-format-sublime.py*
|
2019-12-17 21:09:38 +08:00
|
|
|
|
2023-11-30 16:02:59 +08:00
|
|
|
rm -Rvf %{buildroot}%{install_docdir}/Clang/clang/html
|
2023-07-06 14:40:49 +08:00
|
|
|
rm -Rvf %{buildroot}%{install_sharedir}/clang/clang-doc-default-stylesheet.css
|
|
|
|
|
rm -Rvf %{buildroot}%{install_sharedir}/clang/index.js
|
|
|
|
|
rm -vf %{buildroot}%{install_sharedir}/clang/bash-autocomplete.sh
|
2019-12-17 21:09:38 +08:00
|
|
|
|
2023-11-30 16:02:59 +08:00
|
|
|
mkdir -p %{buildroot}%{install_libdir}/clang/%{maj_ver}/{bin,include,lib,share}/
|
2020-07-31 15:11:11 +08:00
|
|
|
|
2023-05-18 12:36:53 +00:00
|
|
|
%check
|
2023-07-06 14:40:49 +08:00
|
|
|
%if %{with check}
|
2021-09-16 06:18:23 +00:00
|
|
|
|
2023-07-06 14:40:49 +08:00
|
|
|
LD_LIBRARY_PATH=%{buildroot}/%{install_libdir} %{__ninja} check-all -C ./_build/
|
|
|
|
|
%endif
|
2021-09-16 06:18:23 +00:00
|
|
|
|
2019-12-17 21:09:38 +08:00
|
|
|
%files
|
2023-07-06 14:40:49 +08:00
|
|
|
%license LICENSE.TXT
|
|
|
|
|
%{install_bindir}/clang
|
|
|
|
|
%{install_bindir}/clang++
|
|
|
|
|
%{install_bindir}/clang-%{maj_ver}
|
|
|
|
|
%{install_bindir}/clang-cl
|
|
|
|
|
%{install_bindir}/clang-cpp
|
|
|
|
|
%{install_prefix}/share/man/man1/*
|
2024-04-19 16:07:18 +08:00
|
|
|
%if %{with classic_flang}
|
|
|
|
|
%{install_bindir}/flang
|
|
|
|
|
%endif
|
2023-07-06 14:40:49 +08:00
|
|
|
|
|
|
|
|
%files libs
|
|
|
|
|
%{install_libdir}/*.so.*
|
2023-11-30 16:02:59 +08:00
|
|
|
%{install_libdir}/clang/%{maj_ver}/include/*
|
2019-12-17 21:09:38 +08:00
|
|
|
|
|
|
|
|
%files devel
|
2023-07-06 14:40:49 +08:00
|
|
|
%{install_libdir}/*.so
|
|
|
|
|
%{install_includedir}/clang/
|
|
|
|
|
%{install_includedir}/clang-c/
|
|
|
|
|
%{install_libdir}/cmake/*
|
2023-11-30 16:02:59 +08:00
|
|
|
%{_bindir}/clang-tblgen
|
|
|
|
|
%dir %{_datadir}/clang/
|
2019-12-17 21:09:38 +08:00
|
|
|
|
2023-07-06 14:40:49 +08:00
|
|
|
%files resource-filesystem
|
2023-11-30 16:02:59 +08:00
|
|
|
%dir %{install_libdir}/clang/%{maj_ver}/
|
|
|
|
|
%dir %{install_libdir}/clang/%{maj_ver}/include/
|
|
|
|
|
%dir %{install_libdir}/clang/%{maj_ver}/lib/
|
|
|
|
|
%dir %{install_libdir}/clang/%{maj_ver}/share/
|
|
|
|
|
%dir %{install_libdir}/clang/
|
2023-05-15 19:12:27 +08:00
|
|
|
|
2023-05-18 12:36:53 +00:00
|
|
|
%files analyzer
|
2023-07-06 14:40:49 +08:00
|
|
|
%{install_libexecdir}/ccc-analyzer
|
|
|
|
|
%{install_libexecdir}/c++-analyzer
|
2023-11-30 16:02:59 +08:00
|
|
|
%{install_libexecdir}/analyze-c++
|
|
|
|
|
%{install_libexecdir}/analyze-cc
|
|
|
|
|
%{install_libexecdir}/intercept-c++
|
|
|
|
|
%{install_libexecdir}/intercept-cc
|
2023-07-06 14:40:49 +08:00
|
|
|
%{install_bindir}/scan-view
|
|
|
|
|
%{install_bindir}/scan-build
|
2023-11-30 16:02:59 +08:00
|
|
|
%{install_bindir}/analyze-build
|
|
|
|
|
%{install_bindir}/intercept-build
|
|
|
|
|
%{install_bindir}/scan-build-py
|
2023-07-06 14:40:49 +08:00
|
|
|
%{install_prefix}/share/man/man1/*
|
2023-11-30 16:02:59 +08:00
|
|
|
%{install_libdir}/libear
|
|
|
|
|
%{install_libdir}/libscanbuild
|
2023-07-06 14:40:49 +08:00
|
|
|
%{install_sharedir}/scan-view
|
|
|
|
|
%{install_sharedir}/scan-build
|
|
|
|
|
|
2019-12-17 21:09:38 +08:00
|
|
|
|
|
|
|
|
%files tools-extra
|
2023-11-30 16:02:59 +08:00
|
|
|
%{install_bindir}/amdgpu-arch
|
2023-07-06 14:40:49 +08:00
|
|
|
%{install_bindir}/c-index-test
|
|
|
|
|
%{install_bindir}/clang-apply-replacements
|
|
|
|
|
%{install_bindir}/clang-change-namespace
|
|
|
|
|
%{install_bindir}/clang-check
|
|
|
|
|
%{install_bindir}/clang-doc
|
|
|
|
|
%{install_bindir}/clang-extdef-mapping
|
|
|
|
|
%{install_bindir}/clang-format
|
2023-11-30 16:02:59 +08:00
|
|
|
%{install_bindir}/clang-include-cleaner
|
2023-07-06 14:40:49 +08:00
|
|
|
%{install_bindir}/clang-include-fixer
|
|
|
|
|
%{install_bindir}/clang-move
|
|
|
|
|
%{install_bindir}/clang-offload-bundler
|
2023-11-30 16:02:59 +08:00
|
|
|
%{install_bindir}/clang-offload-packager
|
|
|
|
|
%{install_bindir}/clang-linker-wrapper
|
|
|
|
|
%{install_bindir}/clang-pseudo
|
2023-07-06 14:40:49 +08:00
|
|
|
%{install_bindir}/clang-query
|
|
|
|
|
%{install_bindir}/clang-refactor
|
|
|
|
|
%{install_bindir}/clang-rename
|
|
|
|
|
%{install_bindir}/clang-reorder-fields
|
2023-11-30 16:02:59 +08:00
|
|
|
%{install_bindir}/clang-repl
|
2023-07-06 14:40:49 +08:00
|
|
|
%{install_bindir}/clang-scan-deps
|
|
|
|
|
%{install_bindir}/clang-tidy
|
|
|
|
|
%{install_bindir}/clangd
|
|
|
|
|
%{install_bindir}/diagtool
|
|
|
|
|
%{install_bindir}/hmaptool
|
2023-11-30 16:02:59 +08:00
|
|
|
%{install_bindir}/nvptx-arch
|
2023-07-06 14:40:49 +08:00
|
|
|
%{install_bindir}/pp-trace
|
|
|
|
|
%{install_bindir}/find-all-symbols
|
|
|
|
|
%{install_bindir}/modularize
|
2023-11-30 16:02:59 +08:00
|
|
|
%{install_bindir}/run-clang-tidy
|
2023-07-06 14:40:49 +08:00
|
|
|
%{install_sharedir}/clang/clang-format.el
|
|
|
|
|
%{install_sharedir}/clang/clang-rename.el
|
|
|
|
|
%{install_sharedir}/clang/clang-include-fixer.el
|
|
|
|
|
%{install_sharedir}/clang/clang-format.py
|
|
|
|
|
%{install_sharedir}/clang/clang-format-diff.py
|
|
|
|
|
%{install_sharedir}/clang/clang-include-fixer.py
|
|
|
|
|
%{install_sharedir}/clang/clang-tidy-diff.py
|
|
|
|
|
%{install_sharedir}/clang/run-find-all-symbols.py
|
|
|
|
|
%{install_sharedir}/clang/clang-rename.py
|
2019-12-17 21:09:38 +08:00
|
|
|
|
2023-11-30 16:02:59 +08:00
|
|
|
%files tools-extra-devel
|
|
|
|
|
%{install_includedir}/clang-tidy/
|
|
|
|
|
|
2019-12-17 21:09:38 +08:00
|
|
|
%files -n git-clang-format
|
2023-07-06 14:40:49 +08:00
|
|
|
%{install_bindir}/git-clang-format
|
2019-12-17 21:09:38 +08:00
|
|
|
|
2020-07-07 16:12:59 +08:00
|
|
|
%changelog
|
2024-07-30 23:35:03 +00:00
|
|
|
* Tue Jul 30 2024 liyunfei <liyunfei33@huawei.com> - 17.0.6-20
|
|
|
|
|
- Disable toolchain_clang build for BiSheng Autotuner support temporary.
|
|
|
|
|
|
2024-05-13 10:46:05 +08:00
|
|
|
* Tue Jul 16 2024 liyunfei <liyunfei33@huawei.com> - 17.0.6-19
|
|
|
|
|
- Add BiSheng Autotuner support.
|
|
|
|
|
|
2024-07-05 10:51:12 +08:00
|
|
|
* Fri Jul 5 2024 liyunfei <liyunfei33@huawei.com> - 17.0.6-18
|
|
|
|
|
- Add toolchain_clang build support
|
|
|
|
|
|
2024-06-04 15:12:53 +08:00
|
|
|
* Tue Jun 04 2024 Zhao Mengmeng <zhaomengmeng@kylinos.cn> - 17.0.6-17
|
|
|
|
|
- Fix the too-early instantiation of conditional "explict" by applying the patch
|
|
|
|
|
of https://github.com/llvm/llvm-project/commit/128b3b61fe6768c724975fd1df2be0abec848cf6
|
|
|
|
|
|
2024-04-29 14:30:45 +08:00
|
|
|
* Mon Apr 29 2024 wangqiang <wangqiang1@kylinos.cn> - 17.0.6-16
|
|
|
|
|
- Ignored the `-Wa,--generate-missing-build-notes=` option, update llvm-lit config to support macro `build_for_openeuler`
|
|
|
|
|
|
2024-04-19 16:07:18 +08:00
|
|
|
* Wed Apr 17 2024 luofeng <luofeng13@huawei.com> -17.0.6-15
|
|
|
|
|
- Add the support for classic flang
|
|
|
|
|
|
2024-04-13 07:54:56 +08:00
|
|
|
* Tue Apr 16 2024 wangqiang <wangqiang1@kylinos.cn> -17.0.6-14
|
|
|
|
|
- Avoid -Wshadow warning when init-capture named same as class field.
|
|
|
|
|
|
2024-04-13 15:06:29 +08:00
|
|
|
* Sat Apr 13 2024 liyunfei <liyunfei33@huawei.com> -17.0.6-13
|
|
|
|
|
- Add more warning options to BUILD_FOR_OPENEULER gcc compatible part 3.
|
|
|
|
|
|
2024-04-09 15:54:45 +08:00
|
|
|
* Tue Apr 09 2024 zhanglimin <zhanglimin@loongson.cn> - 17.0.6-12
|
|
|
|
|
- Improve the support for compiler-rt and fix some bugs on LoongArch.
|
|
|
|
|
|
2024-03-29 10:09:25 +08:00
|
|
|
* Fri Mar 29 2024 zhanglimin <zhanglimin@loongson.cn> -17.0.6-11
|
|
|
|
|
- Add the support for vector on LoongArch.
|
|
|
|
|
|
2024-03-26 21:20:35 +08:00
|
|
|
* Thu Mar 28 2024 liyunfei <liyunfei33@huawei.com> -17.0.6-10
|
|
|
|
|
- Add more warning options to BUILD_FOR_OPENEULER gcc compatible part 2.
|
|
|
|
|
|
2024-03-15 09:30:54 +08:00
|
|
|
* Fri Mar 15 2024 liyunfei <liyunfei33@huawei.com> -17.0.6-9
|
|
|
|
|
- Add more warning options to BUILD_FOR_OPENEULER gcc compatible.
|
|
|
|
|
|
2024-03-14 10:49:03 +08:00
|
|
|
* Thu Mar 14 2024 zhanglimin <zhanglimin@loongson.cn> -17.0.6-8
|
|
|
|
|
- Add loongarch64 to os-triple patch
|
|
|
|
|
|
2024-02-05 16:41:49 +08:00
|
|
|
* Fri Mar 1 2024 laokz <zhangkai@iscas.ac.cn> -17.0.6-7
|
|
|
|
|
- riscv64: backport 18.1.0 patch to disable unsupported test
|
|
|
|
|
|
2024-02-05 11:07:44 +08:00
|
|
|
* Thu Feb 22 2024 liyunfei<liyunfei33@huawei.com> -17.0.6-6
|
|
|
|
|
- Add BUILD_FOR_OPENEULER to clang
|
|
|
|
|
|
2024-02-18 16:16:38 +08:00
|
|
|
* Sun Feb 18 2024 liyunfei <liyunfei33@huawei.com> -17.0.6-5
|
|
|
|
|
- Change the default DWARF version from 5 to 4.
|
|
|
|
|
|
2024-02-18 15:00:27 +08:00
|
|
|
* Sun Feb 18 2024 laokz <zhangkai@iscas.ac.cn> -17.0.6-4
|
|
|
|
|
- Add riscv64 to os-triple patch
|
|
|
|
|
|
2024-01-25 21:12:12 +08:00
|
|
|
* Thu Jan 25 2024 liyunfei <liyufnei33@huawei.com> -17.0.6-3
|
|
|
|
|
- Add Buildrequires: llvm-libs
|
|
|
|
|
|
2023-12-15 11:12:03 +08:00
|
|
|
* Fri Dec 15 2023 liyunfei <liyunfei33@huawei.com> -17.0.6-2
|
|
|
|
|
- Add triples for X86_64/AArch64 openEuler gcc
|
|
|
|
|
|
2023-11-30 16:02:59 +08:00
|
|
|
* Thu Nov 30 2023 zhoujing <zhoujing106@huawei.com> -17.0.6-1
|
|
|
|
|
- Update to 17.0.6
|
|
|
|
|
|
2023-07-06 14:40:49 +08:00
|
|
|
* Thu Jul 6 2023 cf-zhao <zhaochuanfeng@huawei.com> -12.0.1-4
|
|
|
|
|
- Make this spec file support both system-version and multi-version.
|
|
|
|
|
|
2023-05-18 12:36:53 +00:00
|
|
|
* Thu Sep 22 2022 linguoxiong <cokelin@hnu.edu.cn> - 12.0.1-3
|
|
|
|
|
- Implement the "-aux-info" option to print function prototype
|
|
|
|
|
|
|
|
|
|
* Tue Aug 23 2022 linguoxiong <cokelin@hnu.edu.cn> - 12.0.1-2
|
|
|
|
|
- Implement some options to ignore and replace
|
|
|
|
|
|
|
|
|
|
* Wed Dec 29 2021 panxiaohe <panxiaohe@huawei.com> - 12.0.1-1
|
|
|
|
|
- update to 12.0.1
|
|
|
|
|
- add clang-resource-filesystem sub-package
|
|
|
|
|
|
|
|
|
|
* Tue Sep 07 2021 chenchen <chen_aka_jan@163.com> - 10.0.1-5
|
|
|
|
|
- del rpath from some binaries and bin
|
|
|
|
|
|
|
|
|
|
* Fri Apr 30 2021 licihua <licihua@huawei.com> - 10.0.1-4
|
|
|
|
|
- Reduce build time.
|
|
|
|
|
|
|
|
|
|
* Thu Apr 29 2021 licihua <licihua@huawei.com> - 10.0.1-3
|
|
|
|
|
- Reduce debuginfo verbosity.
|
|
|
|
|
|
|
|
|
|
* Thu Feb 18 2021 zhangjiapeng <zhangjiapeng9@huawei.com> - 10.0.1-2
|
|
|
|
|
- Modify the dependency to python3
|
|
|
|
|
|
|
|
|
|
* Fri Sep 25 2020 zhangjiapeng <zhangjiapeng9@huawei.com> - 10.0.1-1
|
|
|
|
|
- Delete low version dynamic library
|
|
|
|
|
|
|
|
|
|
* Thu Jul 30 2020 Guoshuai Sun <sunguoshuai> - 10.0.1-0
|
|
|
|
|
- Upgrade to 10.0.1
|
|
|
|
|
|
|
|
|
|
* Thu May 28 2020 leiju <leiju4@huawei.com> - 7.0.0-7
|
|
|
|
|
- Fix uninitialized value in ABIArgInfo
|
|
|
|
|
|
|
|
|
|
* Fri Apr 03 2020 zhouyihang <zhouyihang1@huawei.com> - 7.0.0-6
|
|
|
|
|
- Remove useless scriptlet
|
|
|
|
|
|
|
|
|
|
* Thu Feb 20 2020 openEuler Buildteam <buildteam@openeuler.org> - 7.0.0-5
|
|
|
|
|
- Add buildrequire compiler-rt
|
2020-02-20 18:35:53 +08:00
|
|
|
|
2023-05-18 12:36:53 +00:00
|
|
|
* Tue Dec 17 2019 openEuler Buildteam <buildteam@openeuler.org> - 7.0.0-4
|
|
|
|
|
- Delete redundant info
|
2019-12-17 21:09:38 +08:00
|
|
|
|
2023-05-18 12:36:53 +00:00
|
|
|
* Mon Dec 9 2019 openEuler Buildteam <buildteam@openeuler.org> - 7.0.0-3
|
2019-12-17 21:09:38 +08:00
|
|
|
- Package init
|