commit
ddf4c85987
|
@ -31,3 +31,4 @@
|
|||
/llvm-3.9.0.src.tar.xz
|
||||
/llvm-3.9.1.src.tar.xz
|
||||
/llvm-4.0.0.src.tar.xz
|
||||
/llvm-4.0.1.src.tar.xz
|
||||
|
|
|
@ -0,0 +1,44 @@
|
|||
From 974c288631ef8d05bf3a3f91b32bf38eae16e5c8 Mon Sep 17 00:00:00 2001
|
||||
From: Tom Stellard <tstellar@redhat.com>
|
||||
Date: Mon, 6 Mar 2017 13:55:55 +0000
|
||||
Subject: [PATCH] CMake: Add LLVM_UTILS_INSTALL_DIR option
|
||||
|
||||
This is like the LLVM_TOOLS_INSTALL_DIR option, but for the utils
|
||||
that are installed when the LLVM_INSTALL_UTILS. This option
|
||||
defaults to 'bin' to remain consistent with the current behavior, but
|
||||
distros may want to install these to libexec/llvm.
|
||||
---
|
||||
CMakeLists.txt | 3 +++
|
||||
cmake/modules/AddLLVM.cmake | 2 +-
|
||||
2 files changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 58ee3cf..f93405c 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -281,6 +281,9 @@ set(LLVM_LIBDIR_SUFFIX "" CACHE STRING "Define suffix of library directory name
|
||||
set(LLVM_TOOLS_INSTALL_DIR "bin" CACHE STRING "Path for binary subdirectory (defaults to 'bin')")
|
||||
mark_as_advanced(LLVM_TOOLS_INSTALL_DIR)
|
||||
|
||||
+set(LLVM_UTILS_INSTALL_DIR "bin" CACHE STRING "Path to install LLVM utilities (enabled by LLVM_INSTALL_UTILS=ON) (defaults to 'bin')")
|
||||
+mark_as_advanced(LLVM_TOOLS_INSTALL_DIR)
|
||||
+
|
||||
# They are used as destination of target generators.
|
||||
set(LLVM_RUNTIME_OUTPUT_INTDIR ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/bin)
|
||||
set(LLVM_LIBRARY_OUTPUT_INTDIR ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/lib${LLVM_LIBDIR_SUFFIX})
|
||||
diff --git a/cmake/modules/AddLLVM.cmake b/cmake/modules/AddLLVM.cmake
|
||||
index 7f7608c..0da8162 100644
|
||||
--- a/cmake/modules/AddLLVM.cmake
|
||||
+++ b/cmake/modules/AddLLVM.cmake
|
||||
@@ -864,7 +864,7 @@ macro(add_llvm_utility name)
|
||||
set_target_properties(${name} PROPERTIES FOLDER "Utils")
|
||||
if( LLVM_INSTALL_UTILS AND LLVM_BUILD_UTILS )
|
||||
install (TARGETS ${name}
|
||||
- RUNTIME DESTINATION bin
|
||||
+ RUNTIME DESTINATION ${LLVM_UTILS_INSTALL_DIR}
|
||||
COMPONENT ${name})
|
||||
if (NOT CMAKE_CONFIGURATION_TYPES)
|
||||
add_custom_target(install-${name}
|
||||
--
|
||||
2.9.3
|
||||
|
|
@ -0,0 +1,42 @@
|
|||
From af79e4116c4476153869e1fd4aa30c87d4c7c21e Mon Sep 17 00:00:00 2001
|
||||
From: Tom Stellard <tstellar@redhat.com>
|
||||
Date: Mon, 15 May 2017 09:34:23 +0000
|
||||
Subject: [PATCH] CMake: Fix docs-llvm-man target when clang+llvm is in the
|
||||
same source tree
|
||||
|
||||
Summary:
|
||||
This was broken by r302499. Configuring with -DLLVM_BUILD_DOCS=ON would
|
||||
cause the docs-llvm-man target not to be created.
|
||||
|
||||
Reviewers: anemet, beanz
|
||||
|
||||
Reviewed By: anemet
|
||||
|
||||
Subscribers: llvm-commits, mgorny
|
||||
|
||||
Differential Revision: https://reviews.llvm.org/D33146
|
||||
|
||||
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@303042 91177308-0d34-0410-b5e6-96231b3b80d8
|
||||
---
|
||||
cmake/modules/AddSphinxTarget.cmake | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/cmake/modules/AddSphinxTarget.cmake b/cmake/modules/AddSphinxTarget.cmake
|
||||
index c3a676d..4540c5c 100644
|
||||
--- a/cmake/modules/AddSphinxTarget.cmake
|
||||
+++ b/cmake/modules/AddSphinxTarget.cmake
|
||||
@@ -1,9 +1,9 @@
|
||||
|
||||
# Create sphinx target
|
||||
-if (LLVM_ENABLE_SPHINX AND NOT TARGET sphinx)
|
||||
+if (LLVM_ENABLE_SPHINX)
|
||||
message(STATUS "Sphinx enabled.")
|
||||
find_package(Sphinx REQUIRED)
|
||||
- if (LLVM_BUILD_DOCS)
|
||||
+ if (LLVM_BUILD_DOCS AND NOT TARGET sphinx)
|
||||
add_custom_target(sphinx ALL)
|
||||
endif()
|
||||
else()
|
||||
--
|
||||
1.8.3.1
|
||||
|
|
@ -0,0 +1,86 @@
|
|||
From a5f39924a3466eb12d764993aaa8c1c308f92925 Mon Sep 17 00:00:00 2001
|
||||
From: Tom Stellard <tstellar@redhat.com>
|
||||
Date: Sat, 29 Apr 2017 02:03:23 +0000
|
||||
Subject: [PATCH] CMake: Split static library exports into their own export
|
||||
file
|
||||
|
||||
Summary:
|
||||
This is to better support distros which split the static libraries into
|
||||
their own package.
|
||||
|
||||
The current problem is that any project the includes LLVMConfig.cmake
|
||||
will fail to configure unless the static libraries are installed. This
|
||||
is because LLVMConfig.cmake includes LLVMExports.cmake, which throws an
|
||||
error if it can't find files linked to one of the exported targets.
|
||||
|
||||
This patch resolves the problem by putting the static library targets
|
||||
into their own export file, LLVMStaticExports.cmake. This file
|
||||
is optionally included by LLVMConfig.cmake, so distros can put this
|
||||
new file in their static library package to make LLVMConfig.cmake
|
||||
no longer depend on these libraries when they are not installed.
|
||||
|
||||
Reviewers: beanz, mgorny, chapuni
|
||||
|
||||
Subscribers: llvm-commits
|
||||
|
||||
Differential Revision: https://reviews.llvm.org/D32668
|
||||
---
|
||||
cmake/modules/AddLLVM.cmake | 6 +++++-
|
||||
cmake/modules/CMakeLists.txt | 3 +++
|
||||
cmake/modules/LLVMConfig.cmake.in | 2 ++
|
||||
3 files changed, 10 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/cmake/modules/AddLLVM.cmake b/cmake/modules/AddLLVM.cmake
|
||||
index b3c7746..7d9d253 100644
|
||||
--- a/cmake/modules/AddLLVM.cmake
|
||||
+++ b/cmake/modules/AddLLVM.cmake
|
||||
@@ -587,7 +587,11 @@ macro(add_llvm_library name)
|
||||
|
||||
if(${name} IN_LIST LLVM_DISTRIBUTION_COMPONENTS OR
|
||||
NOT LLVM_DISTRIBUTION_COMPONENTS)
|
||||
- set(export_to_llvmexports EXPORT LLVMExports)
|
||||
+ if (ARG_SHARED)
|
||||
+ set(export_to_llvmexports EXPORT LLVMExports)
|
||||
+ else()
|
||||
+ set(export_to_llvmexports EXPORT LLVMStaticExports)
|
||||
+ endif()
|
||||
set_property(GLOBAL PROPERTY LLVM_HAS_EXPORTS True)
|
||||
endif()
|
||||
|
||||
diff --git a/cmake/modules/CMakeLists.txt b/cmake/modules/CMakeLists.txt
|
||||
index ac4b0b7..f77c905 100644
|
||||
--- a/cmake/modules/CMakeLists.txt
|
||||
+++ b/cmake/modules/CMakeLists.txt
|
||||
@@ -91,6 +91,7 @@ set(LLVM_CONFIG_BINARY_DIR "\${LLVM_INSTALL_PREFIX}")
|
||||
set(LLVM_CONFIG_TOOLS_BINARY_DIR "\${LLVM_INSTALL_PREFIX}/bin")
|
||||
set(LLVM_CONFIG_EXPORTS_FILE "\${LLVM_CMAKE_DIR}/LLVMExports.cmake")
|
||||
set(LLVM_CONFIG_EXPORTS "${LLVM_EXPORTS}")
|
||||
+set(LLVM_CONFIG_STATIC_EXPORTS_FILE "\${LLVM_CMAKE_DIR}/LLVMStaticExports.cmake")
|
||||
configure_file(
|
||||
LLVMConfig.cmake.in
|
||||
${CMAKE_CURRENT_BINARY_DIR}/CMakeFiles/LLVMConfig.cmake
|
||||
@@ -107,6 +108,8 @@ if (NOT LLVM_INSTALL_TOOLCHAIN_ONLY)
|
||||
if(llvm_has_exports)
|
||||
install(EXPORT LLVMExports DESTINATION ${LLVM_INSTALL_PACKAGE_DIR}
|
||||
COMPONENT cmake-exports)
|
||||
+ install(EXPORT LLVMStaticExports DESTINATION ${LLVM_INSTALL_PACKAGE_DIR}
|
||||
+ COMPONENT cmake-exports)
|
||||
endif()
|
||||
|
||||
install(FILES
|
||||
diff --git a/cmake/modules/LLVMConfig.cmake.in b/cmake/modules/LLVMConfig.cmake.in
|
||||
index c30c92b..f0f17b2 100644
|
||||
--- a/cmake/modules/LLVMConfig.cmake.in
|
||||
+++ b/cmake/modules/LLVMConfig.cmake.in
|
||||
@@ -73,6 +73,8 @@ if(NOT TARGET LLVMSupport)
|
||||
set(LLVM_EXPORTED_TARGETS "@LLVM_CONFIG_EXPORTS@")
|
||||
include("@LLVM_CONFIG_EXPORTS_FILE@")
|
||||
@llvm_config_include_buildtree_only_exports@
|
||||
+
|
||||
+ include("@LLVM_CONFIG_STATIC_EXPORTS_FILE@" OPTIONAL)
|
||||
endif()
|
||||
|
||||
include(${LLVM_CMAKE_DIR}/LLVM-Config.cmake)
|
||||
--
|
||||
2.9.3
|
||||
|
|
@ -0,0 +1,76 @@
|
|||
From 9c50cf0c6d8f0b11cd76a28cc4ef9bca6ef732e0 Mon Sep 17 00:00:00 2001
|
||||
From: Tom Stellard <tstellar@redhat.com>
|
||||
Date: Tue, 9 May 2017 01:41:28 +0000
|
||||
Subject: [PATCH] Revert "Revert "CMake: Move sphinx detection into
|
||||
AddSphinxTarget.cmake""
|
||||
|
||||
This reverts commit r302054.
|
||||
|
||||
Re-commit now that I have fixes for clang/lld.
|
||||
|
||||
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@302499 91177308-0d34-0410-b5e6-96231b3b80d8
|
||||
---
|
||||
cmake/config-ix.cmake | 10 ----------
|
||||
cmake/modules/AddSphinxTarget.cmake | 13 +++++++++++++
|
||||
docs/CMakeLists.txt | 2 +-
|
||||
3 files changed, 14 insertions(+), 11 deletions(-)
|
||||
|
||||
diff --git a/cmake/config-ix.cmake b/cmake/config-ix.cmake
|
||||
index 0331d0f..de8e9bf 100755
|
||||
--- a/cmake/config-ix.cmake
|
||||
+++ b/cmake/config-ix.cmake
|
||||
@@ -530,16 +530,6 @@ else()
|
||||
message(STATUS "Doxygen disabled.")
|
||||
endif()
|
||||
|
||||
-if (LLVM_ENABLE_SPHINX)
|
||||
- message(STATUS "Sphinx enabled.")
|
||||
- find_package(Sphinx REQUIRED)
|
||||
- if (LLVM_BUILD_DOCS)
|
||||
- add_custom_target(sphinx ALL)
|
||||
- endif()
|
||||
-else()
|
||||
- message(STATUS "Sphinx disabled.")
|
||||
-endif()
|
||||
-
|
||||
set(LLVM_BINDINGS "")
|
||||
if(WIN32)
|
||||
message(STATUS "Go bindings disabled.")
|
||||
diff --git a/cmake/modules/AddSphinxTarget.cmake b/cmake/modules/AddSphinxTarget.cmake
|
||||
index cfc7f38..c3a676d 100644
|
||||
--- a/cmake/modules/AddSphinxTarget.cmake
|
||||
+++ b/cmake/modules/AddSphinxTarget.cmake
|
||||
@@ -1,3 +1,16 @@
|
||||
+
|
||||
+# Create sphinx target
|
||||
+if (LLVM_ENABLE_SPHINX AND NOT TARGET sphinx)
|
||||
+ message(STATUS "Sphinx enabled.")
|
||||
+ find_package(Sphinx REQUIRED)
|
||||
+ if (LLVM_BUILD_DOCS)
|
||||
+ add_custom_target(sphinx ALL)
|
||||
+ endif()
|
||||
+else()
|
||||
+ message(STATUS "Sphinx disabled.")
|
||||
+endif()
|
||||
+
|
||||
+
|
||||
# Handy function for creating the different Sphinx targets.
|
||||
#
|
||||
# ``builder`` should be one of the supported builders used by
|
||||
diff --git a/docs/CMakeLists.txt b/docs/CMakeLists.txt
|
||||
index 6dff219..4437610 100644
|
||||
--- a/docs/CMakeLists.txt
|
||||
+++ b/docs/CMakeLists.txt
|
||||
@@ -103,8 +103,8 @@ endif()
|
||||
endif()
|
||||
|
||||
if (LLVM_ENABLE_SPHINX)
|
||||
+ include(AddSphinxTarget)
|
||||
if (SPHINX_FOUND)
|
||||
- include(AddSphinxTarget)
|
||||
if (${SPHINX_OUTPUT_HTML})
|
||||
add_sphinx_target(html llvm)
|
||||
endif()
|
||||
--
|
||||
1.8.3.1
|
||||
|
42
llvm.spec
42
llvm.spec
|
@ -5,9 +5,11 @@
|
|||
%bcond_with gold
|
||||
%endif
|
||||
|
||||
%global llvm_bindir %{_libdir}/%{name}
|
||||
|
||||
Name: llvm
|
||||
Version: 4.0.0
|
||||
Release: 2%{?dist}
|
||||
Version: 4.0.1
|
||||
Release: 1%{?dist}
|
||||
Summary: The Low Level Virtual Machine
|
||||
|
||||
License: NCSA
|
||||
|
@ -16,8 +18,11 @@ Source0: http://llvm.org/releases/%{version}/%{name}-%{version}.src.tar.xz
|
|||
|
||||
# recognize s390 as SystemZ when configuring build
|
||||
Patch0: llvm-3.7.1-cmake-s390.patch
|
||||
Patch1: 0001-CMake-Fix-pthread-handling-for-out-of-tree-builds.patch
|
||||
Patch67: rust-lang-llvm-pr67.patch
|
||||
Patch2: rust-lang-llvm-pr67.patch
|
||||
Patch3: 0001-CMake-Split-static-library-exports-into-their-own-ex.patch
|
||||
Patch4: 0001-Revert-Revert-CMake-Move-sphinx-detection-into-AddSp.patch
|
||||
Patch5: 0001-CMake-Fix-docs-llvm-man-target-when-clang-llvm-is-in.patch
|
||||
Patch6: 0001-CMake-Add-LLVM_UTILS_INSTALL_DIR-option.patch
|
||||
|
||||
BuildRequires: cmake
|
||||
BuildRequires: zlib-devel
|
||||
|
@ -123,7 +128,8 @@ cd _build
|
|||
-DLLVM_BUILD_EXAMPLES:BOOL=OFF \
|
||||
\
|
||||
-DLLVM_INCLUDE_UTILS:BOOL=ON \
|
||||
-DLLVM_INSTALL_UTILS:BOOL=OFF \
|
||||
-DLLVM_INSTALL_UTILS:BOOL=ON \
|
||||
-DLLVM_UTILS_INSTALL_DIR:PATH=%{llvm_bindir} \
|
||||
\
|
||||
-DLLVM_INCLUDE_DOCS:BOOL=ON \
|
||||
-DLLVM_BUILD_DOCS:BOOL=ON \
|
||||
|
@ -167,6 +173,7 @@ fi
|
|||
|
||||
%files
|
||||
%{_bindir}/*
|
||||
%{llvm_bindir}
|
||||
%{_mandir}/man1/*.1.*
|
||||
%exclude %{_bindir}/llvm-config-%{__isa_bits}
|
||||
%exclude %{_mandir}/man1/llvm-config.1.*
|
||||
|
@ -187,22 +194,39 @@ fi
|
|||
%{_includedir}/llvm-c
|
||||
%{_libdir}/libLLVM.so
|
||||
%{_libdir}/cmake/llvm
|
||||
%exclude %{_libdir}/cmake/llvm/LLVMStaticExports.cmake
|
||||
|
||||
%files doc
|
||||
%doc %{_pkgdocdir}/html
|
||||
|
||||
%files static
|
||||
%{_libdir}/*.a
|
||||
%{_libdir}/cmake/llvm/LLVMStaticExports.cmake
|
||||
|
||||
%changelog
|
||||
* Wed May 10 2017 Tom Stellard <tstellar@redhat.com> - 4.0.0-2
|
||||
* Wed Jun 21 2017 Tom Stellard <tstellar@redhat.com> - 4.0.1-1
|
||||
- 4.0.1 Release
|
||||
|
||||
* Thu Jun 15 2017 Tom Stellard <tstellar@redhat.com> - 4.0.0-6
|
||||
- Install llvm utils
|
||||
|
||||
* Thu Jun 08 2017 Tom Stellard <tstellar@redhat.com> - 4.0.0-5
|
||||
- Fix docs-llvm-man target
|
||||
|
||||
* Mon May 01 2017 Tom Stellard <tstellar@redhat.com> - 4.0.0-4
|
||||
- Make cmake files no longer depend on static libs (rhbz 1388200)
|
||||
|
||||
* Tue Apr 18 2017 Josh Stone <jistone@redhat.com> - 4.0.0-3
|
||||
- Fix computeKnownBits for ARMISD::CMOV (rust-lang/llvm#67)
|
||||
|
||||
* Mon Apr 03 2017 Tom Stellard <tstellar@redhat.com> - 4.0.0-2
|
||||
- Simplify spec with rpm macros.
|
||||
|
||||
* Wed May 10 2017 Tom Stellard <tstellar@redhat.com> - 4.0.0-1
|
||||
* Thu Mar 23 2017 Tom Stellard <tstellar@redhat.com> - 4.0.0-1
|
||||
- LLVM 4.0.0 Final Release
|
||||
|
||||
* Tue Apr 18 2017 Josh Stone <jistone@redhat.com> - 3.9.1-6
|
||||
- Fix computeKnownBits for ARMISD::CMOV (rust-lang/llvm#67)
|
||||
* Wed Mar 22 2017 tstellar@redhat.com - 3.9.1-6
|
||||
- Fix %postun sep for -devel package.
|
||||
|
||||
* Mon Mar 13 2017 Tom Stellard <tstellar@redhat.com> - 3.9.1-5
|
||||
- Disable failing tests on ARM.
|
||||
|
|
2
sources
2
sources
|
@ -1 +1 @@
|
|||
SHA512 (llvm-4.0.0.src.tar.xz) = cf681f0626ef6d568d951cdc3e143471a1d7715a0ba11e52aa273cf5d8d421e1357ef2645cc85879eaefcd577e99e74d07b01566825b3d0461171ef2cbfc7704
|
||||
SHA512 (llvm-4.0.1.src.tar.xz) = 16adc39b34ddb628f81b171119a8e2a0e9138b25011e803ef0b688e2fbea116fc4953d3a1b61b90a98a75e33619f81566b7cb06a9a2ea4d04ac5e0eb303a2d1d
|
||||
|
|
Loading…
Reference in New Issue