#89 Spec file cleanups and improvements
Opened a year ago by tstellar. Modified a year ago
rpms/ tstellar/clang spec-cleanups  into  rawhide

@@ -32,10 +32,10 @@ 

   create mode 100644 test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-redhat-linux/7/crtbegin.o

   create mode 100644 test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-redhat-linux/7/libgcc_s.so

  

- diff --git a/lib/Driver/ToolChains/Gnu.cpp b/lib/Driver/ToolChains/Gnu.cpp

+ diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp

  index c8a7fce0..f28792b7 100644

- --- a/lib/Driver/ToolChains/Gnu.cpp

- +++ b/lib/Driver/ToolChains/Gnu.cpp

+ --- a/clang/lib/Driver/ToolChains/Gnu.cpp

+ +++ b/clang/lib/Driver/ToolChains/Gnu.cpp

  @@ -2500,6 +2500,8 @@ void Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(

          (TargetArch == llvm::Triple::x86 &&

           TargetTriple.getOS() != llvm::Triple::Solaris)}};
@@ -73,10 +73,10 @@ 

       }

     }

   }

- diff --git a/lib/Driver/ToolChains/Gnu.h b/lib/Driver/ToolChains/Gnu.h

+ diff --git a/clang/lib/Driver/ToolChains/Gnu.h b/clang/lib/Driver/ToolChains/Gnu.h

  index 52690ab4..2a4452d9 100644

- --- a/lib/Driver/ToolChains/Gnu.h

- +++ b/lib/Driver/ToolChains/Gnu.h

+ --- a/clang/lib/Driver/ToolChains/Gnu.h

+ +++ b/clang/lib/Driver/ToolChains/Gnu.h

  @@ -190,6 +190,7 @@ public:

     /// Driver, and has logic for fuzzing that where appropriate.

     class GCCInstallationDetector {
@@ -95,19 +95,19 @@ 

       void init(const llvm::Triple &TargetTriple, const llvm::opt::ArgList &Args,

                 ArrayRef<std::string> ExtraTripleAliases = None);

   

- diff --git a/test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-linux-gnu/7/crtbegin.o b/test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-linux-gnu/7/crtbegin.o

+ diff --git a/clang/test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-linux-gnu/7/crtbegin.o b/clang/test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-linux-gnu/7/crtbegin.o

  new file mode 100644

  index 00000000..e69de29b

- diff --git a/test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-redhat-linux/7/crtbegin.o b/test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-redhat-linux/7/crtbegin.o

+ diff --git a/clang/test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-redhat-linux/7/crtbegin.o b/clang/test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-redhat-linux/7/crtbegin.o

  new file mode 100644

  index 00000000..e69de29b

- diff --git a/test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-redhat-linux/7/libgcc_s.so b/test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-redhat-linux/7/libgcc_s.so

+ diff --git a/clang/test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-redhat-linux/7/libgcc_s.so b/clang/test/Driver/Inputs/fedora_28_tree/usr/lib/gcc/x86_64-redhat-linux/7/libgcc_s.so

  new file mode 100644

  index 00000000..e69de29b

- diff --git a/test/Driver/linux-ld.c b/test/Driver/linux-ld.c

+ diff --git a/clang/test/Driver/linux-ld.c b/test/Driver/linux-ld.c

  index ec539522..95725d5c 100644

- --- a/test/Driver/linux-ld.c

- +++ b/test/Driver/linux-ld.c

+ --- a/clang/test/Driver/linux-ld.c

+ +++ b/clang/test/Driver/linux-ld.c

  @@ -784,6 +784,18 @@

   // CHECK-FEDORA-31-RISCV64: "{{.*}}/usr/lib/gcc/riscv64-redhat-linux/9{{/|\\\\}}crtend.o"

   // CHECK-FEDORA-31-RISCV64: "{{.*}}/usr/lib/gcc/riscv64-redhat-linux/9{{/|\\\\}}crtn.o"

@@ -11,10 +11,10 @@ 

   clang/test/Driver/netbsd.cpp   | 4 ++--

   2 files changed, 3 insertions(+), 2 deletions(-)

  

- diff --git a/lib/Driver/ToolChain.cpp b/lib/Driver/ToolChain.cpp

+ diff --git a/clang/lib/Driver/ToolChain.cpp b/clang/lib/Driver/ToolChain.cpp

  index 88a627e..cb99844 100644

- --- a/lib/Driver/ToolChain.cpp

- +++ b/lib/Driver/ToolChain.cpp

+ --- a/clang/lib/Driver/ToolChain.cpp

+ +++ b/clang/lib/Driver/ToolChain.cpp

  @@ -767,6 +767,7 @@ void ToolChain::AddCXXStdlibLibArgs(const ArgList &Args,

     switch (Type) {

     case ToolChain::CST_Libcxx:
@@ -23,10 +23,10 @@ 

       break;

   

     case ToolChain::CST_Libstdcxx:

- diff --git a/test/Driver/netbsd.cpp b/test/Driver/netbsd.cpp

+ diff --git a/clang/test/Driver/netbsd.cpp b/clang/test/Driver/netbsd.cpp

  index 4af7d83..ff18c62 100644

- --- a/test/Driver/netbsd.cpp

- +++ b/test/Driver/netbsd.cpp

+ --- a/clang/test/Driver/netbsd.cpp

+ +++ b/clang/test/Driver/netbsd.cpp

  @@ -131,7 +131,7 @@

   // ARM-7: clang{{.*}}" "-cc1" "-triple" "armv5e-unknown-netbsd7.0.0-eabi"

   // ARM-7: ld{{.*}}" "--eh-frame-hdr" "-dynamic-linker" "/libexec/ld.elf_so"

file modified
+3 -3
@@ -7,10 +7,10 @@ 

   CMakeLists.txt | 12 +++++-------

   1 file changed, 5 insertions(+), 7 deletions(-)

  

- diff --git a/CMakeLists.txt b/CMakeLists.txt

+ diff --git a/clang/CMakeLists.txt b/clang/CMakeLists.txt

  index c2016a45ca..48ea3c3bb9 100644

- --- a/CMakeLists.txt

- +++ b/CMakeLists.txt

+ --- a/clang/CMakeLists.txt

+ +++ b/clang/CMakeLists.txt

  @@ -157,12 +157,6 @@ Please install Python or specify the PYTHON_EXECUTABLE CMake variable.")

           set(LLVM_UTILS_PROVIDED ON)

           set(CLANG_TEST_DEPS FileCheck count not)

file modified
+127 -111
@@ -1,10 +1,24 @@ 

- %global compat_build 0

+ %bcond_with compat_build

+ %bcond_without tests

+ 

+ # A "full build" which is a normal build with all the sub-packages and

+ # everything enabled.

+ %global with_full_build 1

+ 

+ %if %{with compat_build}

+ %undefine with_full_build

+ %undefine with_tests

+ %endif

+ 

+ %if %{without full_build} && %{without compat_build}

+ %{error:Must enable either full_build or compat_build}

+ %endif

  

  %global maj_ver 11

  %global min_ver 1

  %global patch_ver 0

  %global rc_ver 2

- %global baserelease 5

+ %global baserelease 6

  

  %global clang_tools_binaries \

  	%{_bindir}/clang-apply-replacements \
@@ -36,22 +50,28 @@ 

  	%{_bindir}/clang-cl \

  	%{_bindir}/clang-cpp \

  

- %if 0%{?compat_build}

- %global pkg_name clang%{maj_ver}.%{min_ver}

+ %if %{with compat_build}

+ %global pkg_name clang%{maj_ver}

  # Install clang to same prefix as llvm, so that apps that use llvm-config

  # will also be able to find clang libs.

- %global install_prefix %{_libdir}/llvm%{maj_ver}.%{min_ver}

+ %global install_prefix %{_libdir}/llvm%{maj_ver}

+ %global install_libdir %{install_prefix}/lib

  %global install_bindir %{install_prefix}/bin

  %global install_includedir %{install_prefix}/include

- %global install_libdir %{install_prefix}/lib

+ %global pkg_includedir %{_includedir}/llvm%{maj_ver}

+ %global llvm_pkg llvm%{maj_ver}

+ %global llvm_libdir_suffix %{nil}

+ %endif

  

- %global pkg_bindir %{install_bindir}

- %global pkg_includedir %{_includedir}/llvm%{maj_ver}.%{min_ver}

- %global pkg_libdir %{install_libdir}

- %else

+ %if %{with full_build}

  %global pkg_name clang

- %global install_prefix /usr

- %global pkg_libdir %{_libdir}

+ %global install_prefix %{_prefix}

+ %global install_libdir %{_libdir}

+ %global pkg_includedir %{_includedir}

+ %global llvm_pkg llvm

+ %if 0%{?__isa_bits} == 64

+ %global llvm_libdir_suffix 64

+ %endif

  %endif

  

  %if 0%{?fedora} || 0%{?rhel} > 7
@@ -60,8 +80,6 @@ 

  %bcond_with python3

  %endif

  

- %global build_install_prefix %{buildroot}%{install_prefix}

- 

  %ifarch ppc64le

  # Too many threads on ppc64 systems causes OOM errors.

  %global _smp_mflags -j8
@@ -79,7 +97,7 @@ 

  URL:		http://llvm.org

  Source0:	https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}%{?rc_ver:-rc%{rc_ver}}/%{clang_srcdir}.tar.xz

  Source3:	https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}%{?rc_ver:-rc%{rc_ver}}/%{clang_srcdir}.tar.xz.sig

- %if !0%{?compat_build}

+ %if %{with full_build}

  Source1:	https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}%{?rc_ver:-rc%{rc_ver}}/%{clang_tools_srcdir}.tar.xz

  Source2:	https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}%{?rc_ver:-rc%{rc_ver}}/%{clang_tools_srcdir}.tar.xz.sig

  %endif
@@ -96,46 +114,50 @@ 

  Patch18:	0001-scan-view-Remove-Reporter.py-and-associated-AppleScr.patch

  Patch19:	0001-Partially-Revert-scan-view-Remove-Reporter.py-and-as.patch

  

+ #---Packaging Dependencies-----------------------------------------------------#

+ 

+ # We need python3-devel for pathfix.py.

+ BuildRequires:	python3-devel

+ # Needed for %%multilib_fix_c_header

+ BuildRequires:	multilib-rpm-config

+ # For origin certification

+ BuildRequires:	gnupg2

+ 

+ #---Build Dependencies---------------------------------------------------------#

+ 

  BuildRequires:	gcc

  BuildRequires:	gcc-c++

  BuildRequires:	cmake

  BuildRequires:	ninja-build

- %if 0%{?compat_build}

- BuildRequires:	llvm%{maj_ver}.%{min_ver}-devel = %{version}

- BuildRequires:	llvm%{maj_ver}.%{min_ver}-static = %{version}

- %else

- BuildRequires:	llvm-devel = %{version}

- BuildRequires:	llvm-test = %{version}

+ 

+ #---Library Dependencies-------------------------------------------------------#

+ 

+ BuildRequires:	libxml2-devel

+ BuildRequires:	ncurses-devel

  # llvm-static is required, because clang-tablegen needs libLLVMTableGen, which

  # is not included in libLLVM.so.

- BuildRequires:	llvm-static = %{version}

- BuildRequires:	llvm-googletest = %{version}

- %endif

+ BuildRequires:	%{llvm_pkg}-static = %{version}

+ BuildRequires:	%{llvm_pkg}-devel = %{version}

+ 

+ #---Misc Dependencies---------------------------------------------------------#

  

- BuildRequires:	libxml2-devel

  BuildRequires:	perl-generators

- BuildRequires:	ncurses-devel

  # According to https://fedoraproject.org/wiki/Packaging:Emacs a package

  # should BuildRequires: emacs if it packages emacs integration files.

  BuildRequires:	emacs

- 

- # These build dependencies are required for the test suite.

- %if %with python3

- # The testsuite uses /usr/bin/lit which is part of the python3-lit package.

- BuildRequires:	python3-lit

- %endif

- 

  BuildRequires:	python3-sphinx

  BuildRequires:	libatomic

  

- # We need python3-devel for pathfix.py.

- BuildRequires:	python3-devel

+ #---Test Dependencies----------------------------------------------------------#

  

- # Needed for %%multilib_fix_c_header

- BuildRequires:	multilib-rpm-config

+ %if %{with tests}

+ BuildRequires:	llvm-googletest = %{version}

+ BuildRequires:	llvm-test = %{version}

  

- # For origin certification

- BuildRequires:	gnupg2

+ %if %with python3

+ # The testsuite uses /usr/bin/lit which is part of the python3-lit package.

+ BuildRequires:	python3-lit

+ %endif

  

  # scan-build uses these perl modules so they need to be installed in order

  # to run the tests.
@@ -151,14 +173,19 @@ 

  BuildRequires: perl(Text::ParseWords)

  BuildRequires: perl(Sys::Hostname)

  

- Requires:	%{name}-libs%{?_isa} = %{version}-%{release}

+ %endif

+ 

+ #---Runtime Dependencies-------------------------------------------------------#

  

+ Requires:	%{name}-libs%{?_isa} = %{version}-%{release}

  # clang requires gcc, clang++ requires libstdc++-devel

  # - https://bugzilla.redhat.com/show_bug.cgi?id=1021645

  # - https://bugzilla.redhat.com/show_bug.cgi?id=1158594

  Requires:	libstdc++-devel

  Requires:	gcc-c++

  

+ #---Provides/Conflicts---------------------------------------------------------#

+ 

  Provides:	clang(major) = %{maj_ver}

  

  Conflicts:	compiler-rt < %{version}
@@ -192,12 +219,12 @@ 

  

  %package devel

  Summary: Development header files for clang

- %if !0%{?compat_build}

+ %if %{with full_build}

  Requires: %{name}%{?_isa} = %{version}-%{release}

  # The clang CMake files reference tools from clang-tools-extra.

  Requires: %{name}-tools-extra%{?_isa} = %{version}-%{release}

- Requires: %{name}-libs = %{version}-%{release}

  %endif

+ Requires: %{name}-libs = %{version}-%{release}

  

  %description devel

  Development header files for clang.
@@ -209,7 +236,7 @@ 

  %description resource-filesystem

  This package owns the clang resouce directory: $libdir/clang/$version/

  

- %if !0%{?compat_build}

+ %if %{with full_build}

  %package analyzer

  Summary:	A source code analysis framework

  License:	NCSA and MIT
@@ -253,12 +280,11 @@ 

  

  %endif

  

- 

  %prep

  %{gpgverify} --keyring='%{SOURCE4}' --signature='%{SOURCE3}' --data='%{SOURCE0}'

  

- %if 0%{?compat_build}

- %autosetup -n %{clang_srcdir} -p1

+ %if %{with compat_build}

+ %autosetup -n %{clang_srcdir} -p2

  %else

  

  %{gpgverify} --keyring='%{SOURCE4}' --signature='%{SOURCE2}' --data='%{SOURCE1}'
@@ -271,12 +297,12 @@ 

  

  %setup -q -n %{clang_srcdir}

  

- %patch4 -p1 -b .gtest

- %patch11 -p1 -b .libcxx-fix

+ %patch4 -p2 -b .gtest

+ %patch11 -p2 -b .libcxx-fix

  %patch13 -p2 -b .unwind-all

  %patch15 -p2 -b .no-install-static

  %patch16 -p2 -b .test-fix2

- %patch17 -p1 -b .check-gcc_s

+ %patch17 -p2 -b .check-gcc_s

  %patch18 -p2 -b .scan-view-remove-files

  %patch19 -p2 -b .scan-view-remove-files-fix

  
@@ -309,11 +335,7 @@ 

  # lto builds with gcc 11 fail while running the lit tests.

  %define _lto_cflags %{nil}

  

- %if 0%{?__isa_bits} == 64

- sed -i 's/\@FEDORA_LLVM_LIB_SUFFIX\@/64/g' test/lit.cfg.py

- %else

- sed -i 's/\@FEDORA_LLVM_LIB_SUFFIX\@//g' test/lit.cfg.py

- %endif

+ sed -i 's/\@FEDORA_LLVM_LIB_SUFFIX\@/%{llvm_libdir_suffix}/g' test/lit.cfg.py

  

  %ifarch s390 s390x %{arm} %ix86 ppc64le

  # Decrease debuginfo verbosity to reduce memory consumption during final library linking
@@ -325,35 +347,32 @@ 

  # if CAMKE_INSTALL_RPATH is set to a value, but cmake interprets this value

  # as nothing, so it sets the rpath to "" when installing.

  %cmake  -G Ninja \

- 	-DLLVM_PARALLEL_LINK_JOBS=1 \

- 	-DLLVM_LINK_LLVM_DYLIB:BOOL=ON \

- 	-DCMAKE_BUILD_TYPE=RelWithDebInfo \

- 	-DPYTHON_EXECUTABLE=%{__python3} \

- 	-DCMAKE_INSTALL_RPATH:BOOL=";" \

+ %if 0%{debug_package}

+         -DCMAKE_BUILD_TYPE=RelWithDebInfo \

+ %else

+         -DCMAKE_BUILD_TYPE=Release \

+ %endif

  %ifarch s390 s390x %{arm} %ix86 ppc64le

  	-DCMAKE_C_FLAGS_RELWITHDEBINFO="%{optflags} -DNDEBUG" \

  	-DCMAKE_CXX_FLAGS_RELWITHDEBINFO="%{optflags} -DNDEBUG" \

  %endif

- %if 0%{?compat_build}

- 	-DLLVM_CONFIG:FILEPATH=%{_bindir}/llvm-config-%{maj_ver}.%{min_ver}-%{__isa_bits} \

- 	-DCMAKE_INSTALL_PREFIX=%{install_prefix} \

- 	-DCLANG_INCLUDE_TESTS:BOOL=OFF \

- %else

+ %if %{with compat_build}

+ 	-DLLVM_CONFIG:FILEPATH=%{_bindir}/llvm-config-%{maj_ver}-%{__isa_bits} \

+ 	-DLLVM_TABLEGEN_EXE:FILEPATH=%{_bindir}/llvm-tblgen-%{maj_ver} \

+ %endif

+ 	\

+ %if %{with tests}

  	-DCLANG_INCLUDE_TESTS:BOOL=ON \

  	-DLLVM_EXTERNAL_LIT=%{_bindir}/lit \

  	-DLLVM_MAIN_SRC_DIR=%{_datadir}/llvm/src \

- %if 0%{?__isa_bits} == 64

- 	-DLLVM_LIBDIR_SUFFIX=64 \

- %else

- 	-DLLVM_LIBDIR_SUFFIX= \

- %endif

- %endif

- 	\

- %if !0%{compat_build}

- 	-DLLVM_TABLEGEN_EXE:FILEPATH=%{_bindir}/llvm-tblgen \

  %else

- 	-DLLVM_TABLEGEN_EXE:FILEPATH=%{_bindir}/llvm-tblgen-%{maj_ver}.%{min_ver} \

+ 	-DCLANG_INCLUDE_TESTS:BOOL=OFF \

  %endif

+ 	-DCMAKE_INSTALL_PREFIX=%{install_prefix} \

+ 	-DLLVM_PARALLEL_LINK_JOBS=1 \

+ 	-DPYTHON_EXECUTABLE=%{__python3} \

+ 	-DCMAKE_INSTALL_RPATH:BOOL=";" \

+ 	-DLLVM_LIBDIR_SUFFIX="%{llvm_libdir_suffix}" \

  	-DCLANG_ENABLE_ARCMT:BOOL=ON \

  	-DCLANG_ENABLE_STATIC_ANALYZER:BOOL=ON \

  	-DCLANG_INCLUDE_DOCS:BOOL=ON \
@@ -376,7 +395,7 @@ 

  

  %cmake_install

  

- %if 0%{?compat_build}

+ %if %{with compat_build}

  

  # Remove binaries/other files

  rm -Rf %{buildroot}%{install_bindir}
@@ -388,7 +407,9 @@ 

  mv  %{buildroot}/%{install_includedir}/clang %{buildroot}/%{pkg_includedir}/

  mv  %{buildroot}/%{install_includedir}/clang-c %{buildroot}/%{pkg_includedir}/

  

- %else

+ %endif

+ 

+ %if %{with full_build}

  

  # install clang python bindings

  mkdir -p %{buildroot}%{python3_sitelib}/clang/
@@ -429,26 +450,26 @@ 

  chmod u-x %{buildroot}%{_mandir}/man1/scan-build.1*

  chmod a+x %{buildroot}%{_datadir}/scan-view/{Reporter.py,startfile.py}

  

+ %endif

+ 

+ # Create sub-directories in the clang resource directory that will be

+ # populated by other packages

+ mkdir -p %{buildroot}%{install_libdir}/clang/%{version}/{include,lib,share}/

+ 

  # create a link to clang's resource directory that is "constant" across minor

  # version bumps

  # this is required for packages like ccls that hardcode the link to clang's

  # resource directory to not require rebuilds on minor version bumps

  # Fix for bugs like rhbz#1807574

- pushd %{buildroot}%{_libdir}/clang/

+ pushd %{buildroot}%{install_libdir}/clang/

  ln -s %{version} %{maj_ver}

  popd

  

- # Create sub-directories in the clang resource directory that will be

- # populated by other packages

- mkdir -p %{buildroot}%{_libdir}/clang/%{version}/{include,lib,share}/

- 

- %endif

- 

  # Remove clang-tidy headers.  We don't ship the libraries for these.

  rm -Rvf %{buildroot}%{_includedir}/clang-tidy/

  

  %check

- %if !0%{?compat_build}

+ %if %{with tests}

  # requires lit.py from LLVM utilities

  # FIXME: Fix failing ARM tests

  LD_LIBRARY_PATH=%{buildroot}/%{_libdir} %cmake_build --target check-all || \
@@ -461,7 +482,7 @@ 

  %endif

  

  

- %if !0%{?compat_build}

+ %if %{with full_build}

  %files

  %license LICENSE.TXT

  %{clang_binaries}
@@ -472,38 +493,30 @@ 

  %endif

  

  %files libs

- %if !0%{?compat_build}

- %{_libdir}/clang/

- %{_libdir}/*.so.*

- %else

- %{pkg_libdir}/*.so.*

- %{pkg_libdir}/clang/%{version}

- %endif

+ %{install_libdir}/*.so.*

+ %{install_libdir}/clang/

  

  %files devel

- %if !0%{?compat_build}

- %{_libdir}/*.so

- %{_includedir}/clang/

- %{_includedir}/clang-c/

- %{_libdir}/cmake/*

- %dir %{_datadir}/clang/

- %else

- %{pkg_libdir}/*.so

+ %{install_libdir}/*.so

  %{pkg_includedir}/clang/

  %{pkg_includedir}/clang-c/

- %{pkg_libdir}/cmake/

+ %{install_libdir}/cmake/

+ %if %{with full_build}

+ # Why does the devel package own this directory?

+ %dir %{_datadir}/clang/

  %endif

  

+ # %%dir means the package owns the directory and not the contents of

+ # the directory.

  %files resource-filesystem

- %dir %{pkg_libdir}/clang/%{version}/

- %dir %{pkg_libdir}/clang/%{version}/include/

- %dir %{pkg_libdir}/clang/%{version}/lib/

- %dir %{pkg_libdir}/clang/%{version}/share/

- %if !0%{?compat_build}

- %{pkg_libdir}/clang/%{maj_ver}

- %endif

- 

- %if !0%{?compat_build}

+ %dir %{install_libdir}/clang/

+ %dir %{install_libdir}/clang/%{version}/

+ %dir %{install_libdir}/clang/%{version}/include/

+ %dir %{install_libdir}/clang/%{version}/lib/

+ %dir %{install_libdir}/clang/%{version}/share/

+ %{install_libdir}/clang/%{maj_ver}

+ 

+ %if %{with full_build}

  %files analyzer

  %{_bindir}/scan-view

  %{_bindir}/scan-build
@@ -539,7 +552,10 @@ 

  

  %endif

  %changelog

- * Thu Feb 09 2021 Tom Stellard <tstellar@redhat.com> - 11.1.0-0.5.rc2

+ * Thu Feb 11 2021 Tom Stellard <tstellar@redhat.com> - 11.1.0-0.6.rc2

+ - Spec file cleanups and improvements

+ 

+ * Tue Feb 09 2021 Tom Stellard <tstellar@redhat.com> - 11.1.0-0.5.rc2

  - Remove some unnecessary scan-view files

  

  * Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 11.1.0-0.4.rc2

Clean up the spec file to make it more readable and also add some options
for enabling and disabling features.

That's a good question :-) With current setup, it is still possible to set %global with_full_build 0 and %bcond_without compat_build which leads to an unexpected state

Build failed.

That's a good question :-) With current setup, it is still possible to set %global with_full_build 0 and %bcond_without compat_build which leads to an unexpected state

Part of the reason I didn't add %bcond_without full_build is that I didn't want people to be able to do --without-full_build, which would be broken. So that's pretty much the same problem as if someone did %global with_full_build 0. Any suggestions on what would be better?

Id' just raise a %{error:...} if the state is not consistent :-)

That's a good question :-) With current setup, it is still possible to set %global with_full_build 0 and %bcond_without compat_build which leads to an unexpected state

This actually is not possible without further changes to the spec file, because setting %bcond_without compat_build will always unset with_full_build, but I'll still add some error checks to catch the inconsistent scenarios.

rebased onto 158c172

a year ago

Build failed.

rebased onto cc43ae4

a year ago

Build failed. More information on how to proceed and troubleshoot errors available at https://fedoraproject.org/wiki/Zuul-based-ci