Hello community,

here is the log from the commit of package llvm5 for openSUSE:Factory checked 
in at 2018-03-26 12:01:17
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/llvm5 (Old)
 and      /work/SRC/openSUSE:Factory/.llvm5.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "llvm5"

Mon Mar 26 12:01:17 2018 rev:7 rq:589018 version:5.0.1

Changes:
--------
--- /work/SRC/openSUSE:Factory/llvm5/llvm5.changes      2018-02-03 
15:37:54.946225330 +0100
+++ /work/SRC/openSUSE:Factory/.llvm5.new/llvm5.changes 2018-03-26 
12:01:25.194373524 +0200
@@ -1,0 +2,27 @@
+Fri Mar 16 12:25:57 UTC 2018 - [email protected]
+
+- Use alternatives for clang's bash autocomplete to prevent
+  conflicts with future versions.
+
+-------------------------------------------------------------------
+Thu Feb 15 11:38:38 UTC 2018 - [email protected]
+
+- Remove liblldb5 and lldb5-devel from baselibs.conf. They are only
+  build for x86_64, so no point having them in baselibs.conf.
+
+-------------------------------------------------------------------
+Wed Feb  7 14:21:48 UTC 2018 - [email protected]
+
+- Use %optflags, except for FORTIFY_SOURCE which is not compatible
+  with compiler-rt.
+- Exclude static libraries differently.
+  * Drop llvm-split-static-library-exports-into-their-own-export-file.diff
+  * Drop clang-split-static-library-exports-into-their-own-export-file.diff
+  * Update llvm-do-not-install-static-libraries.patch to not use
+    EXCLUDE_FROM_ALL which is not available in cmake 3.5.
+    - This fixes build on SLE12.
+- Do not force gcc6 on OpenSUSE - fixes build.
+- Reduce the amount of concurent link jobs by increasing their
+  memory requirement - to reduce stalls in OBS.
+
+-------------------------------------------------------------------

Old:
----
  clang-split-static-library-exports-into-their-own-export-file.diff
  llvm-split-static-library-exports-into-their-own-export-file.diff

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ llvm5.spec ++++++
--- /var/tmp/diff_new_pack.EYEcf0/_old  2018-03-26 12:01:29.882204399 +0200
+++ /var/tmp/diff_new_pack.EYEcf0/_new  2018-03-26 12:01:29.906203533 +0200
@@ -87,8 +87,6 @@
 Patch6:         llvm-fix-find-gcc5-install.patch
 Patch7:         aarch64-disable-memorytest.patch
 Patch8:         clang-ignore-stack-clash-protector.patch
-Patch9:         
llvm-split-static-library-exports-into-their-own-export-file.diff
-Patch10:        
clang-split-static-library-exports-into-their-own-export-file.diff
 # PATCH-FIX-OPENSUSE lldb-cmake.patch -- Let us set LLDB_REVISION and fix 
ncurses include path.
 Patch11:        lldb-cmake.patch
 # PATCH-FIX-OPENSUSE lldb-add-pthread-dl-libs.patch -- Add -lpthread and -ldl 
options to the end of LDFLAGS to fix linking problems.
@@ -117,7 +115,7 @@
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 # llvm does not work on ppc or s390
 ExcludeArch:    ppc s390
-%if 0%{?sle_version} && 0%{?sle_version} <= 130000
+%if 0%{?sle_version} && 0%{?sle_version} <= 130000 && !0%{?is_opensuse}
 BuildRequires:  gcc6
 BuildRequires:  gcc6-c++
 %else
@@ -500,7 +498,6 @@
 %patch7 -p1
 %endif
 
-%patch9 -p0
 %patch13 -p1
 %patch14 -p1
 %patch15 -p1
@@ -513,7 +510,6 @@
 %patch4 -p1
 %patch6 -p1
 %patch8 -p1
-%patch10 -p1
 popd
 
 %if %{with lldb}
@@ -565,9 +561,14 @@
 sed -i s,LLVM_REVISION,\"%{_revsn}\",g tools/clang/lib/Basic/Version.cpp
 
 %build
-# Disable c/xx/flags as the clang fails to build with hardening right now
-#flags="%%{optflags} -fno-strict-aliasing"
-flags="-fno-strict-aliasing"
+
+# Remove the -D_FORTIFY_SOURCE=2 from optflags because llvm does not build
+# correctly with hardening. The problem is in sanitizers from compiler-rt.
+flags="%{optflags}"
+flags=${flags//-D_FORTIFY_SOURCE=?/-D_FORTIFY_SOURCE=0}
+
+flags+=" -fno-strict-aliasing"
+
 %ifarch armv6hl
 flags+=" -mfloat-abi=hard -march=armv6zk -mtune=arm1176jzf-s -mfpu=vfp"
 %endif
@@ -597,15 +598,21 @@
 cat /proc/meminfo
 echo "System limits:"
 ulimit -a
+max_mem=$(awk '/MemTotal/ { print $2 }' /proc/meminfo)
 if test -n "$max_link_jobs" -a "$max_link_jobs" -gt 1 ; then
-    mem_per_process=2000000
-    max_mem=$(awk '/MemTotal/ { print $2 }' /proc/meminfo)
-    max_jobs="$(($max_mem / $mem_per_process))"
+    mem_per_link_job=3000000
+    max_jobs="$(($max_mem / $mem_per_link_job))"
     test "$max_link_jobs" -gt "$max_jobs" && max_link_jobs="$max_jobs" && echo 
"Warning: Reducing number of link jobs to $max_jobs because of memory limits"
     test "$max_link_jobs" -le 0 && max_link_jobs=1 && echo "Warning: Not 
linking in parallel at all becuse of memory limits"
 fi
+if test -n "$max_compile_jobs" -a "$max_compile_jobs" -gt 1 ; then
+    mem_per_compile_job=1500000
+    max_jobs="$(($max_mem / $mem_per_compile_job))"
+    test "$max_compile_jobs" -gt "$max_jobs" && max_compile_jobs="$max_jobs" 
&& echo "Warning: Reducing number of compile jobs to $max_jobs because of 
memory limits"
+    test "$max_compile_jobs" -le 0 && max_compile_jobs=1 && echo "Warning: Not 
compiling in parallel at all becuse of memory limits"
+fi
 
-%if 0%{?sle_version} && 0%{?sle_version} <= 130000
+%if 0%{?sle_version} && 0%{?sle_version} <= 130000 && !0%{?is_opensuse}
 export CC=gcc-6
 export CXX=g++-6
 %endif
@@ -673,8 +680,8 @@
     -DLLVM_PARALLEL_COMPILE_JOBS="$max_compile_jobs" \
     -DLLVM_PARALLEL_LINK_JOBS="$max_link_jobs" \
 %ifarch %arm s390 %{ix86}
-    -DCMAKE_C_FLAGS_RELWITHDEBINFO="-O2 -g1 -DNDEBUG" \
-    -DCMAKE_CXX_FLAGS_RELWITHDEBINFO="-O2 -g1 -DNDEBUG" \
+    -DCMAKE_C_FLAGS_RELWITHDEBINFO="$flags -g1" \
+    -DCMAKE_CXX_FLAGS_RELWITHDEBINFO="$flags -g1" \
 %endif
     -DENABLE_LINKER_BUILD_ID=ON \
     -DLLVM_TABLEGEN="${LLVM_TABLEGEN}" \
@@ -777,9 +784,10 @@
 mv %{buildroot}%{_datadir}/opt-viewer/optpmap.py 
%{buildroot}%{python3_sitelib}/optpmap.py
 mv %{buildroot}%{_datadir}/opt-viewer/optrecord.py 
%{buildroot}%{python3_sitelib}/optrecord.py
 
+mkdir -p %{buildroot}%{_libdir}/clang/%{version}
+mv %{buildroot}%{_datadir}/clang/bash-autocomplete.sh 
%{buildroot}%{_libdir}/clang/%{version}/bash-autocomplete.sh
 mkdir -p %{buildroot}%{_sysconfdir}/bash_completion.d
-mv %{buildroot}%{_datadir}/clang/bash-autocomplete.sh 
%{buildroot}%{_sysconfdir}/bash_completion.d/clang.sh
-chmod -x %{buildroot}%{_sysconfdir}/bash_completion.d/clang.sh
+ln -s %{_sysconfdir}/alternatives/clang-bash-autocomplete.sh 
%{buildroot}%{_sysconfdir}/bash_completion.d/clang.sh
 
 chmod -x %{buildroot}%{_mandir}/man1/scan-build.1
 
@@ -797,8 +805,6 @@
 # Stuff we don't want to include
 rm %{buildroot}%{_mandir}/man1/lit.1
 
-rm %{buildroot}%{_libdir}/cmake/llvm/LLVMStaticExports*.cmake
-
 rm -rf %{buildroot}%{_includedir}/lld
 
 %if %{with libcxx}
@@ -1081,7 +1087,8 @@
    --slave %{_bindir}/git-clang-format git-clang-format 
%{_bindir}/git-clang-format-%{version} \
    --slave %{_bindir}/modularize modularize %{_bindir}/modularize-%{version} \
    --slave %{_bindir}/run-clang-tidy run-clang-tidy 
%{_bindir}/run-clang-tidy-%{version} \
-   --slave %{_mandir}/man1/clang.1%{ext_man} clang.1%{ext_man} 
%{_mandir}/man1/clang-%{version}.1%{ext_man}
+   --slave %{_mandir}/man1/clang.1%{ext_man} clang.1%{ext_man} 
%{_mandir}/man1/clang-%{version}.1%{ext_man} \
+   --slave %{_sysconfdir}/bash_completion.d/clang.sh clang-bash-autocomplete 
%{_libdir}/clang/%{version}/bash-autocomplete.sh
 
 %postun -n clang%{_sonum}
 if [ ! -f %{_bindir}/clang-%{version} ] ; then
@@ -1405,11 +1412,13 @@
 %ghost %{_sysconfdir}/alternatives/git-clang-format
 %ghost %{_sysconfdir}/alternatives/modularize
 %ghost %{_sysconfdir}/alternatives/run-clang-tidy
+%ghost %{_sysconfdir}/alternatives/clang-bash-autocomplete.sh
 %{_mandir}/man1/clang.1%{ext_man}
 %{_mandir}/man1/clang-%{version}.1%{ext_man}
 %ghost %{_sysconfdir}/alternatives/clang.1%{ext_man}
 %dir %{_libdir}/clang/
 %{_libdir}/clang/%{_relver}/
+%{_libdir}/clang/%{version}/bash-autocomplete.sh
 %{_sysconfdir}/bash_completion.d/clang.sh
 
 %files -n clang%{_sonum}-checker

++++++ baselibs.conf ++++++
--- /var/tmp/diff_new_pack.EYEcf0/_old  2018-03-26 12:01:30.018199492 +0200
+++ /var/tmp/diff_new_pack.EYEcf0/_new  2018-03-26 12:01:30.018199492 +0200
@@ -1,6 +1,5 @@
 libLLVM5
 libclang5
-liblldb5
 libLTO5
 llvm5-devel
   provides "llvm-devel-<targettype> = <version>"
@@ -8,7 +7,6 @@
 clang5-devel
   provides "clang-devel-<targettype> = <version>"
   conflicts "otherproviders(clang-devel-<targettype>)"
-lldb5-devel
 llvm5-LTO-devel
   provides "llvm-LTO-devel-<targettype> = <version>"
   conflicts "otherproviders(llvm-LTO-devel-<targettype>)"

++++++ llvm-do-not-install-static-libraries.patch ++++++
--- /var/tmp/diff_new_pack.EYEcf0/_old  2018-03-26 12:01:30.114196029 +0200
+++ /var/tmp/diff_new_pack.EYEcf0/_new  2018-03-26 12:01:30.118195885 +0200
@@ -6,7 +6,7 @@
 ===================================================================
 --- llvm-5.0.1.src.orig/cmake/modules/AddLLVM.cmake
 +++ llvm-5.0.1.src/cmake/modules/AddLLVM.cmake
-@@ -595,10 +595,18 @@ macro(add_llvm_library name)
+@@ -611,10 +611,19 @@ macro(add_llvm_library name)
          set_property(GLOBAL PROPERTY LLVM_HAS_EXPORTS True)
        endif()
  
@@ -20,11 +20,12 @@
 +                ${install_type} DESTINATION ${install_dir}
 +                COMPONENT ${name})
 +      else()
-+        install(TARGETS ${name}
-+                ${export_to_llvmexports}
-+                ${install_type} DESTINATION ${install_dir}
-+                COMPONENT ${name}
-+                EXCLUDE_FROM_ALL)
++        if(NOT LLVM_BUILD_LLVM_DYLIB)
++          install(TARGETS ${name}
++                  ${export_to_llvmexports}
++                  ${install_type} DESTINATION ${install_dir}
++                  COMPONENT ${name})
++        endif()
 +      endif()
  
        if (NOT CMAKE_CONFIGURATION_TYPES)
@@ -51,13 +52,20 @@
 ===================================================================
 --- llvm-5.0.1.src.orig/lldb-5.0.1.src/cmake/modules/AddLLDB.cmake
 +++ llvm-5.0.1.src/lldb-5.0.1.src/cmake/modules/AddLLDB.cmake
-@@ -88,7 +88,8 @@ function(add_lldb_library name)
-         install(TARGETS ${name}
-           COMPONENT ${name}
-           LIBRARY DESTINATION lib${LLVM_LIBDIR_SUFFIX}
+@@ -58,10 +58,12 @@ function(add_lldb_library name)
+           LIBRARY DESTINATION ${out_dir}
+           ARCHIVE DESTINATION ${out_dir})
+       else()
+-        install(TARGETS ${name}
+-          COMPONENT ${name}
+-          LIBRARY DESTINATION lib${LLVM_LIBDIR_SUFFIX}
 -          ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX})
-+          ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX}
-+          EXCLUDE_FROM_ALL)
++        if(NOT LLVM_BUILD_LLVM_DYLIB)
++          install(TARGETS ${name}
++            COMPONENT ${name}
++            LIBRARY DESTINATION lib${LLVM_LIBDIR_SUFFIX}
++            ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX})
++        endif()
        endif()
        if (NOT CMAKE_CONFIGURATION_TYPES)
          add_custom_target(install-${name}


Reply via email to