update to 10.0.1
This commit is contained in:
parent
73da1c13c7
commit
774495f618
@ -1,27 +0,0 @@
|
|||||||
From 1e0f1c5481a96d760f7840d4dde103353a0131f8 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Tom Stellard <tstellar@redhat.com>
|
|
||||||
Date: Thu, 30 Aug 2018 11:38:51 -0700
|
|
||||||
Subject: [PATCH] CMake: Don't prefer python2.7
|
|
||||||
|
|
||||||
---
|
|
||||||
CMakeLists.txt | 4 ----
|
|
||||||
1 file changed, 4 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
|
||||||
index 31df640..2603f1c 100644
|
|
||||||
--- a/CMakeLists.txt
|
|
||||||
+++ b/CMakeLists.txt
|
|
||||||
@@ -613,10 +613,6 @@ message(STATUS "LLVM default target triple: ${LLVM_DEFAULT_TARGET_TRIPLE}")
|
|
||||||
|
|
||||||
include(HandleLLVMOptions)
|
|
||||||
|
|
||||||
-# Verify that we can find a Python 2 interpreter. Python 3 is unsupported.
|
|
||||||
-# FIXME: We should support systems with only Python 3, but that requires work
|
|
||||||
-# on LLDB.
|
|
||||||
-set(Python_ADDITIONAL_VERSIONS 2.7)
|
|
||||||
include(FindPythonInterp)
|
|
||||||
if( NOT PYTHONINTERP_FOUND )
|
|
||||||
message(FATAL_ERROR
|
|
||||||
--
|
|
||||||
1.8.3.1
|
|
||||||
|
|
||||||
@ -1,86 +0,0 @@
|
|||||||
From f9e66a883e1fb748e6ac826fde188efaae249361 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 fd5627e..78f106f 100644
|
|
||||||
--- a/cmake/modules/AddLLVM.cmake
|
|
||||||
+++ b/cmake/modules/AddLLVM.cmake
|
|
||||||
@@ -635,7 +635,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 6074e83..e9fcb11 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 0772016..f471625 100644
|
|
||||||
--- a/cmake/modules/LLVMConfig.cmake.in
|
|
||||||
+++ b/cmake/modules/LLVMConfig.cmake.in
|
|
||||||
@@ -78,6 +78,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()
|
|
||||||
|
|
||||||
# By creating intrinsics_gen here, subprojects that depend on LLVM's
|
|
||||||
--
|
|
||||||
1.8.3.1
|
|
||||||
|
|
||||||
@ -1,24 +0,0 @@
|
|||||||
From e67ace2ecb42c24e124f1738dc67b22055a22500 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Tom Stellard <tstellar@redhat.com>
|
|
||||||
Date: Thu, 13 Sep 2018 10:10:08 -0700
|
|
||||||
Subject: [PATCH] Don't set rpath when installing
|
|
||||||
|
|
||||||
---
|
|
||||||
cmake/modules/AddLLVM.cmake | 1 +
|
|
||||||
1 file changed, 1 insertion(+)
|
|
||||||
|
|
||||||
diff --git a/cmake/modules/AddLLVM.cmake b/cmake/modules/AddLLVM.cmake
|
|
||||||
index ce2057f..de309b5 100644
|
|
||||||
--- a/cmake/modules/AddLLVM.cmake
|
|
||||||
+++ b/cmake/modules/AddLLVM.cmake
|
|
||||||
@@ -1621,6 +1621,7 @@ function(llvm_codesign name)
|
|
||||||
endfunction()
|
|
||||||
|
|
||||||
function(llvm_setup_rpath name)
|
|
||||||
+ return()
|
|
||||||
if(CMAKE_INSTALL_RPATH)
|
|
||||||
return()
|
|
||||||
endif()
|
|
||||||
--
|
|
||||||
1.8.3.1
|
|
||||||
|
|
||||||
@ -1,60 +0,0 @@
|
|||||||
From da1fb72bb305d6bc1f3899d541414146934bf80f Mon Sep 17 00:00:00 2001
|
|
||||||
From: Jonas Devlieghere <jonas@devlieghere.com>
|
|
||||||
Date: Fri, 21 Sep 2018 12:03:14 +0000
|
|
||||||
Subject: [PATCH] Ensure that variant part discriminator is read by
|
|
||||||
MetadataLoader
|
|
||||||
|
|
||||||
https://reviews.llvm.org/D42082 introduced variant parts to debug info
|
|
||||||
in LLVM. Subsequent work on the Rust compiler has found a bug in that
|
|
||||||
patch; namely, there is a path in MetadataLoader that fails to restore
|
|
||||||
the discriminator.
|
|
||||||
|
|
||||||
This patch fixes the bug.
|
|
||||||
|
|
||||||
Patch by: Tom Tromey
|
|
||||||
|
|
||||||
Differential revision: https://reviews.llvm.org/D52340
|
|
||||||
|
|
||||||
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@342725 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
||||||
---
|
|
||||||
lib/Bitcode/Reader/MetadataLoader.cpp | 2 +-
|
|
||||||
test/Assembler/debug-variant-discriminator.ll | 14 ++++++++++++++
|
|
||||||
2 files changed, 15 insertions(+), 1 deletion(-)
|
|
||||||
create mode 100644 test/Assembler/debug-variant-discriminator.ll
|
|
||||||
|
|
||||||
diff --git a/lib/Bitcode/Reader/MetadataLoader.cpp b/lib/Bitcode/Reader/MetadataLoader.cpp
|
|
||||||
index 3fe7d22..4781cfe 100644
|
|
||||||
--- a/lib/Bitcode/Reader/MetadataLoader.cpp
|
|
||||||
+++ b/lib/Bitcode/Reader/MetadataLoader.cpp
|
|
||||||
@@ -1313,7 +1313,7 @@ Error MetadataLoader::MetadataLoaderImpl::parseOneMetadata(
|
|
||||||
(Context, Tag, Name, File, Line, Scope, BaseType,
|
|
||||||
SizeInBits, AlignInBits, OffsetInBits, Flags,
|
|
||||||
Elements, RuntimeLang, VTableHolder, TemplateParams,
|
|
||||||
- Identifier));
|
|
||||||
+ Identifier, Discriminator));
|
|
||||||
if (!IsNotUsedInTypeRef && Identifier)
|
|
||||||
MetadataList.addTypeRef(*Identifier, *cast<DICompositeType>(CT));
|
|
||||||
|
|
||||||
diff --git a/test/Assembler/debug-variant-discriminator.ll b/test/Assembler/debug-variant-discriminator.ll
|
|
||||||
new file mode 100644
|
|
||||||
index 0000000..5be001c
|
|
||||||
--- /dev/null
|
|
||||||
+++ b/test/Assembler/debug-variant-discriminator.ll
|
|
||||||
@@ -0,0 +1,14 @@
|
|
||||||
+; RUN: llvm-as < %s | llvm-dis | llvm-as | llvm-dis | FileCheck %s
|
|
||||||
+; RUN: verify-uselistorder %s
|
|
||||||
+
|
|
||||||
+; CHECK: !named = !{!0, !1, !2}
|
|
||||||
+!named = !{!0, !1, !2}
|
|
||||||
+
|
|
||||||
+; CHECK: !0 = !DICompositeType(tag: DW_TAG_structure_type, name: "Outer", size: 64, align: 64, identifier: "Outer")
|
|
||||||
+; CHECK-NEXT: !1 = !DICompositeType(tag: DW_TAG_variant_part, scope: !0, size: 64, discriminator: !2)
|
|
||||||
+; CHECK-NEXT: !2 = !DIDerivedType(tag: DW_TAG_member, scope: !1, baseType: !3, size: 64, align: 64, flags: DIFlagArtificial)
|
|
||||||
+; CHECK-NEXT: !3 = !DIBasicType(name: "u64", size: 64, encoding: DW_ATE_unsigned)
|
|
||||||
+!0 = !DICompositeType(tag: DW_TAG_structure_type, name: "Outer", size: 64, align: 64, identifier: "Outer")
|
|
||||||
+!1 = !DICompositeType(tag: DW_TAG_variant_part, scope: !0, size: 64, discriminator: !2)
|
|
||||||
+!2 = !DIDerivedType(tag: DW_TAG_member, scope: !1, baseType: !3, size: 64, align: 64, flags: DIFlagArtificial)
|
|
||||||
+!3 = !DIBasicType(name: "u64", size: 64, encoding: DW_ATE_unsigned)
|
|
||||||
--
|
|
||||||
1.8.3.1
|
|
||||||
|
|
||||||
@ -1,28 +0,0 @@
|
|||||||
From 5f7fd92155db77c7608e3a07e5dcfad1ec7bd4e4 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Tom Stellard <tstellar@redhat.com>
|
|
||||||
Date: Fri, 16 Mar 2018 07:52:33 -0700
|
|
||||||
Subject: [PATCH] Filter out cxxflags not supported by clang
|
|
||||||
|
|
||||||
---
|
|
||||||
tools/llvm-config/CMakeLists.txt | 4 ++++
|
|
||||||
1 file changed, 4 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/tools/llvm-config/CMakeLists.txt b/tools/llvm-config/CMakeLists.txt
|
|
||||||
index a0bd36c..4193b0e 100644
|
|
||||||
--- a/tools/llvm-config/CMakeLists.txt
|
|
||||||
+++ b/tools/llvm-config/CMakeLists.txt
|
|
||||||
@@ -34,7 +34,11 @@ set(LLVM_SRC_ROOT ${LLVM_MAIN_SRC_DIR})
|
|
||||||
set(LLVM_OBJ_ROOT ${LLVM_BINARY_DIR})
|
|
||||||
set(LLVM_CPPFLAGS "${CMAKE_CPP_FLAGS} ${CMAKE_CPP_FLAGS_${uppercase_CMAKE_BUILD_TYPE}} ${LLVM_DEFINITIONS}")
|
|
||||||
set(LLVM_CFLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_FLAGS_${uppercase_CMAKE_BUILD_TYPE}} ${LLVM_DEFINITIONS}")
|
|
||||||
+STRING(REGEX REPLACE "-mcet" "" LLVM_CFLAGS ${LLVM_CFLAGS})
|
|
||||||
+STRING(REGEX REPLACE "-fcf-protection" "" LLVM_CFLAGS ${LLVM_CFLAGS})
|
|
||||||
set(LLVM_CXXFLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_CXX_FLAGS_${uppercase_CMAKE_BUILD_TYPE}} ${COMPILE_FLAGS} ${LLVM_DEFINITIONS}")
|
|
||||||
+STRING(REGEX REPLACE "-mcet" "" LLVM_CXXFLAGS ${LLVM_CXXFLAGS})
|
|
||||||
+STRING(REGEX REPLACE "-fcf-protection" "" LLVM_CXXFLAGS ${LLVM_CXXFLAGS})
|
|
||||||
set(LLVM_BUILD_SYSTEM cmake)
|
|
||||||
set(LLVM_HAS_RTTI ${LLVM_CONFIG_HAS_RTTI})
|
|
||||||
set(LLVM_DYLIB_VERSION "${LLVM_VERSION_MAJOR}${LLVM_VERSION_SUFFIX}")
|
|
||||||
--
|
|
||||||
1.8.3.1
|
|
||||||
|
|
||||||
Binary file not shown.
26
llvm.spec
26
llvm.spec
@ -1,20 +1,15 @@
|
|||||||
Name: llvm
|
Name: llvm
|
||||||
Version: 7.0.0
|
Version: 10.0.1
|
||||||
Release: 10
|
Release: 1
|
||||||
Summary: The Low Level Virtual Machine
|
Summary: The Low Level Virtual Machine
|
||||||
License: NCSA
|
License: NCSA
|
||||||
URL: http://llvm.org
|
URL: http://llvm.org
|
||||||
Source0: http://releases.llvm.org/7.0.0/%{name}-%{version}.src.tar.xz
|
Source0: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/%{name}-%{version}.src.tar.xz
|
||||||
|
|
||||||
Patch0: CMake-Split-static-library-exports-into-their-own-ex.patch
|
|
||||||
Patch1: Filter-out-cxxflags-not-supported-by-clang.patch
|
|
||||||
Patch2: CMake-Don-t-prefer-python2.7.patch
|
|
||||||
Patch3: Don-t-set-rpath-when-installing.patch
|
|
||||||
Patch4: Ensure-that-variant-part-discriminator-is-read-by-Me.patch
|
|
||||||
Patch5: test-Fix-Assembler-debug-info.ll.patch
|
|
||||||
|
|
||||||
BuildRequires: gcc gcc-c++ cmake ninja-build zlib-devel libffi-devel ncurses-devel libstdc++-static
|
BuildRequires: gcc gcc-c++ cmake ninja-build zlib-devel libffi-devel ncurses-devel libstdc++-static
|
||||||
BuildRequires: python3-sphinx binutils-devel valgrind-devel libedit-devel python3-devel
|
BuildRequires: python3-sphinx binutils-devel valgrind-devel libedit-devel python3-devel
|
||||||
|
BuildRequires: python3-recommonmark
|
||||||
|
BuildRequires: llvm-libs
|
||||||
|
|
||||||
%description
|
%description
|
||||||
LLVM is a compiler infrastructure designed for compile-time, link-time,
|
LLVM is a compiler infrastructure designed for compile-time, link-time,
|
||||||
@ -120,6 +115,7 @@ ninja -v
|
|||||||
cd _build
|
cd _build
|
||||||
ninja -v install
|
ninja -v install
|
||||||
|
|
||||||
|
find %{buildroot}%{_libdir}/cmake/llvm -type f | xargs sed -i "s|%{buildroot}||g"
|
||||||
mv -v %{buildroot}%{_bindir}/llvm-config{,-%{__isa_bits}}
|
mv -v %{buildroot}%{_bindir}/llvm-config{,-%{__isa_bits}}
|
||||||
|
|
||||||
for f in lli-child-target llvm-isel-fuzzer llvm-opt-fuzzer yaml-bench; do
|
for f in lli-child-target llvm-isel-fuzzer llvm-opt-fuzzer yaml-bench; do
|
||||||
@ -150,6 +146,10 @@ tar -czf %{install_srcdir}/test.tar.gz test/
|
|||||||
cp -R _build/unittests %{buildroot}%{_libdir}/%{name}/
|
cp -R _build/unittests %{buildroot}%{_libdir}/%{name}/
|
||||||
find %{buildroot}%{_libdir}/%{name} -ignore_readdir_race -iname 'cmake*' -exec rm -Rf '{}' ';' || true
|
find %{buildroot}%{_libdir}/%{name} -ignore_readdir_race -iname 'cmake*' -exec rm -Rf '{}' ';' || true
|
||||||
|
|
||||||
|
#TODO: clang rust mesa packages will be unresolvable without this work-around
|
||||||
|
cp -p %{_libdir}/libLLVM-7*.so %{buildroot}%{_libdir}
|
||||||
|
cp -p %{_libdir}/libLTO.so.7 %{buildroot}%{_libdir}
|
||||||
|
|
||||||
%check
|
%check
|
||||||
cd _build
|
cd _build
|
||||||
ninja check-all || :
|
ninja check-all || :
|
||||||
@ -193,6 +193,12 @@ fi
|
|||||||
%{_mandir}/man1/*
|
%{_mandir}/man1/*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Jul 28 2020 Liquor <lirui130@huawei.com> - 10.0.1-1
|
||||||
|
- Type: update
|
||||||
|
- ID: NA
|
||||||
|
- SUG: NA
|
||||||
|
- DESC:update to 10.0.1
|
||||||
|
|
||||||
* Wed Jul 22 2020 Hugel <gengqihu1@huawei.com> - 7.0.0-10
|
* Wed Jul 22 2020 Hugel <gengqihu1@huawei.com> - 7.0.0-10
|
||||||
- Type: enhancement
|
- Type: enhancement
|
||||||
- ID: NA
|
- ID: NA
|
||||||
|
|||||||
@ -1,28 +0,0 @@
|
|||||||
From cc1f2a595ead516812a6c50398f0f3480ebe031f Mon Sep 17 00:00:00 2001
|
|
||||||
From: Jonas Devlieghere <jonas@devlieghere.com>
|
|
||||||
Date: Fri, 21 Sep 2018 12:28:44 +0000
|
|
||||||
Subject: [PATCH] [test] Fix Assembler/debug-info.ll
|
|
||||||
|
|
||||||
Update Assembler/debug-info.ll to contain discriminator.
|
|
||||||
|
|
||||||
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@342727 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
||||||
---
|
|
||||||
test/Assembler/debug-info.ll | 2 +-
|
|
||||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/test/Assembler/debug-info.ll b/test/Assembler/debug-info.ll
|
|
||||||
index 4404b74..d54dba0 100644
|
|
||||||
--- a/test/Assembler/debug-info.ll
|
|
||||||
+++ b/test/Assembler/debug-info.ll
|
|
||||||
@@ -83,7 +83,7 @@
|
|
||||||
; CHECK-NEXT: !32 = !DIFile(filename: "file", directory: "dir", checksumkind: CSK_MD5, checksum: "000102030405060708090a0b0c0d0e0f")
|
|
||||||
!35 = !DIFile(filename: "file", directory: "dir", checksumkind: CSK_MD5, checksum: "000102030405060708090a0b0c0d0e0f")
|
|
||||||
|
|
||||||
-; CHECK-NEXT: !33 = !DICompositeType(tag: DW_TAG_variant_part, name: "A", scope: !14, size: 64)
|
|
||||||
+; CHECK-NEXT: !33 = !DICompositeType(tag: DW_TAG_variant_part, name: "A", scope: !14, size: 64, discriminator: !34)
|
|
||||||
; CHECK-NEXT: !34 = !DIDerivedType(tag: DW_TAG_member, scope: !33, baseType: !35, size: 64, align: 64, flags: DIFlagArtificial)
|
|
||||||
; CHECK-NEXT: !35 = !DIBasicType(name: "u64", size: 64, encoding: DW_ATE_unsigned)
|
|
||||||
!36 = !DICompositeType(tag: DW_TAG_variant_part, name: "A", scope: !16, size: 64, discriminator: !37)
|
|
||||||
--
|
|
||||||
1.8.3.1
|
|
||||||
|
|
||||||
Loading…
x
Reference in New Issue
Block a user