mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 04:59:14 -07:00
@@ -1,11 +1,7 @@
|
||||
DIST lld-4.0.1.src.tar.xz 593796 BLAKE2B 58eb8f013a4562ef60dd7e17ddd741f434b8f0228a3d3d746ec8c30521ce667863d0b6db6565659a1b86cb91550cdaa43a27600d3a979460523faf24eac8ea3f SHA512 63bd0813094dc7fa9a95fdee93eb7b97026882a15548f819b5c67f3f0f9fa2a582d968af27ad8f802dbff1f6cd1b8c2fb26b3c7c80379488d05c4a4984d7af68
|
||||
DIST lld-5.0.2.src.tar.xz 671776 BLAKE2B 11c470fb7eb4e8ddad043cff7daa714b55b862fe0a540e135db7252314caa101e3bb9063d5a7b32e0a86721cc01f602cafe087566d49ef5c6865f19ba3daf6b3 SHA512 6edafc277a5475a4b44fdf2d77bb8d0a80e8717f74c6db6c0208e0f1492a552f50640503ba8687bcd87a3d677b571dc4f9579b1e5c0bf53059c259ecbcc78c0e
|
||||
DIST lld-6.0.1.src.tar.xz 787804 BLAKE2B 6b1d42bf24ca4c4dbfd060f1e40efa106e4adb73ee44a219f1568168b90b2a1430c3bd9c9e7996fda1f90423f8154678d6ee795ba4e179a0a72d86e980cbba52 SHA512 856ccc125255ab6184919f1424372f0f8a5de8477777047e2ab1a131a2ecec0caa9b5163d01409c7c510df9c794f0bc8d65cc904df2baf6462ef53bc163e002a
|
||||
DIST lld-7.0.1.src.tar.xz 912812 BLAKE2B 586f869350cb49eec661b72d575686d3627f2e094b492ad1d62ebad2a7aa14cff5582b51713ab02889c1f1bab20b38cfcb038e6753936688e6530f7b044e73ba SHA512 e5d3ed280d8ac6014cd6bbe080b11e2c4ebbae81dc14b637e779ec027d818dbae91c6f0de9e94bcecd6bdaa37f12c35141b5d81f0a15251d27932aa9bebd4047
|
||||
DIST lld-8.0.0rc2.src.tar.xz 999024 BLAKE2B 866a36f95fc51408b511392cd48c923b1deb9307d72fae93726c189b78fae9ba0586a1ff188335e80f66a86c8c6de9d1c609deb72ed25438b558a7e4df7a00bd SHA512 ba59b603f83283a75b8b020a339c7381e2397e55165ffe86e194d8c1da5845a1e5187ba45d7a46bb136d69c2fac64fb4f97f0fa5eab1d17232e5f474764cc5f6
|
||||
DIST lld-8.0.0rc3.src.tar.xz 999892 BLAKE2B e62141c0d93a762aecd12d72ab8a8fbfeb91896421f356401d1018bd09f713f8ebc73fc3e1a80e4260c413d705ae7f5a51a7009f056e040ab5851909b19efabc SHA512 4858afd97ab605440590c5fdcdeb82b0496e391b2719eb805b799b645c9c3d305c71cf1cf2d9eb37a845903a149d2461a582de3ef97fa9b662c3ad31c5cb1064
|
||||
DIST llvm-4.0.1.src.tar.xz 21065652 BLAKE2B 6327eed2d1feb108440f22d2581d1ff86c10a10c29793538d8d899c7e2dc83d3f7b147d3fd4bcce2bd2bf57c071b08c624aeafe40a3e7a3914506e7751727e6c SHA512 16adc39b34ddb628f81b171119a8e2a0e9138b25011e803ef0b688e2fbea116fc4953d3a1b61b90a98a75e33619f81566b7cb06a9a2ea4d04ac5e0eb303a2d1d
|
||||
DIST llvm-5.0.2.src.tar.xz 23451868 BLAKE2B b7082be2e4ad557b29b9f6869811f262adcf5c73d552faf91b339bede75cf5eab58afefa12fa779a38be71fe2b8f4ea297c3213ee4e8370cc01972c59249d91c SHA512 3588be5ed969c3f7f6f16f56a12a6af2814d3d3c960d4a36ffebb0446cc75f19220bccee7fc605f9b01f5d5c188a905a046193cc12dec42dd5922048b5c27fe1
|
||||
DIST llvm-6.0.1.src.tar.xz 25306628 BLAKE2B 60232d4d22f8096b565cc8d81fea0639f24f14e8fc4f66ade69fa15479181f07f655f26dff3fa24bf105762b495da316c5c9352db234bd0af6b9c3fff6d4d881 SHA512 cbbb00eb99cfeb4aff623ee1a5ba075e7b5a76fc00c5f9f539ff28c108598f5708a0369d5bd92683def5a20c2fe60cab7827b42d628dbfcc79b57e0e91b84dd9
|
||||
DIST llvm-7.0.1.src.tar.xz 28311056 BLAKE2B 737aa6144a415e41a4ff2c8bd5a727d6f14d7b1810c62cbefa5a25fe642c98cddf8a28e35c7e9783373aa3b96f5c0943229e229ad1b43e56e9ed6db0f27ab128 SHA512 ac43a3cb71a53deb55e3693653847cf20bf6f5d9056f224e6956c96d63bc59ebee9404f088eec9cabe65337b4607a905ef931354b373cf64e0004c6905a6b5df
|
||||
DIST llvm-8.0.0rc2.src.tar.xz 30492444 BLAKE2B e7afd3b66e3eb204e07348f0bc77f0ae03d8e9581de4c94cba7c0b43b53f36ecd891c1272ce43ea6c78999fd404a7db105266a2eaca22975133571e1152961af SHA512 9d93197848e9472cc2fef2477897e4f4d74a79b17a164fd43446b0ffb327e7f484cf64f0c294d9a99707c0b46282eb0d16e6ceb5d2d568f25e4235f70ae3c5e7
|
||||
|
||||
@@ -1,97 +0,0 @@
|
||||
From 72b099306f586382a32cb0b37ad6a07dc7cddcf9 Mon Sep 17 00:00:00 2001
|
||||
From: Michal Gorny <mgorny@gentoo.org>
|
||||
Date: Wed, 8 Feb 2017 20:08:25 +0000
|
||||
Subject: [PATCH 2/3] [test] Use LLD-specific binary&library dirs when building
|
||||
stand-alone
|
||||
|
||||
Use both LLD- and LLVM-specific binary&library directories when LLD is
|
||||
being built stand-alone. This ensures that the freshly built tools and
|
||||
libraries are found and used correctly.
|
||||
|
||||
Without this patch, the test suite uses LLVM_TOOLS_DIR and LLVM_LIBS_DIR
|
||||
to locate lld, and set PATH and LD_LIBRARY_PATH. When doing
|
||||
a stand-alone builds, these variables represent the installed LLVM.
|
||||
As a result, tests either fail due to missing lld executables/libraries
|
||||
or use an earlier installed LLD version rather than the one being built.
|
||||
|
||||
To solve this, an additional LLD_TOOLS_DIR and LLD_LIBS_DIR variables
|
||||
are added that are populated using LLVM_*_OUTPUT_INTDIR. Those variables
|
||||
are populated with directories used to output built executables
|
||||
and libraries. In stand-alone builds, they represent the directories
|
||||
used by LLD. In integrated builds, they have the same values as
|
||||
LLVM_*_DIR and therefore using them does not harm.
|
||||
|
||||
The new variables are prepended to PATH and LD_LIBRARY_PATH to ensure
|
||||
that freshly built binaries are preferred over potentially earlier
|
||||
installed ones. Furthermore, the resulting PATH is used to locate tools
|
||||
for substitutions since the search includes both tools built as part of
|
||||
LLD and of LLVM.
|
||||
|
||||
Differential Revision: https://reviews.llvm.org/D29335
|
||||
|
||||
git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@294507 91177308-0d34-0410-b5e6-96231b3b80d8
|
||||
---
|
||||
test/lit.cfg | 14 ++++++++++----
|
||||
test/lit.site.cfg.in | 2 ++
|
||||
2 files changed, 12 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/test/lit.cfg b/test/lit.cfg
|
||||
index 0db879312..8dff2fb4e 100644
|
||||
--- a/test/lit.cfg
|
||||
+++ b/test/lit.cfg
|
||||
@@ -66,18 +66,24 @@ config.llvm_obj_root = getattr(config, 'llvm_obj_root', None)
|
||||
|
||||
# Tweak the PATH to include the tools dir and the scripts dir.
|
||||
if lld_obj_root is not None:
|
||||
+ lld_tools_dir = getattr(config, 'lld_tools_dir', None)
|
||||
+ if not lld_tools_dir:
|
||||
+ lit_config.fatal('No LLD tools dir set!')
|
||||
llvm_tools_dir = getattr(config, 'llvm_tools_dir', None)
|
||||
if not llvm_tools_dir:
|
||||
lit_config.fatal('No LLVM tools dir set!')
|
||||
- path = os.path.pathsep.join((llvm_tools_dir, config.environment['PATH']))
|
||||
+ path = os.path.pathsep.join((lld_tools_dir, llvm_tools_dir, config.environment['PATH']))
|
||||
path = os.path.pathsep.join((os.path.join(getattr(config, 'llvm_src_root', None),'test','Scripts'),path))
|
||||
|
||||
config.environment['PATH'] = path
|
||||
|
||||
+ lld_libs_dir = getattr(config, 'lld_libs_dir', None)
|
||||
+ if not lld_libs_dir:
|
||||
+ lit_config.fatal('No LLD libs dir set!')
|
||||
llvm_libs_dir = getattr(config, 'llvm_libs_dir', None)
|
||||
if not llvm_libs_dir:
|
||||
lit_config.fatal('No LLVM libs dir set!')
|
||||
- path = os.path.pathsep.join((llvm_libs_dir,
|
||||
+ path = os.path.pathsep.join((lld_libs_dir, llvm_libs_dir,
|
||||
config.environment.get('LD_LIBRARY_PATH','')))
|
||||
config.environment['LD_LIBRARY_PATH'] = path
|
||||
|
||||
@@ -174,10 +180,10 @@ for pattern in tool_patterns:
|
||||
pattern)
|
||||
tool_pipe = tool_match.group(2)
|
||||
tool_name = tool_match.group(4)
|
||||
- tool_path = lit.util.which(tool_name, llvm_tools_dir)
|
||||
+ tool_path = lit.util.which(tool_name, config.environment['PATH'])
|
||||
if not tool_path:
|
||||
# Warn, but still provide a substitution.
|
||||
- lit_config.note('Did not find ' + tool_name + ' in ' + llvm_tools_dir)
|
||||
+ lit_config.note('Did not find ' + tool_name + ' in ' + path)
|
||||
tool_path = llvm_tools_dir + '/' + tool_name
|
||||
config.substitutions.append((pattern, tool_pipe + tool_path))
|
||||
|
||||
diff --git a/test/lit.site.cfg.in b/test/lit.site.cfg.in
|
||||
index 5293f24c1..9dcb48174 100644
|
||||
--- a/test/lit.site.cfg.in
|
||||
+++ b/test/lit.site.cfg.in
|
||||
@@ -6,6 +6,8 @@ config.llvm_tools_dir = "@LLVM_TOOLS_DIR@"
|
||||
config.llvm_libs_dir = "@LLVM_LIBS_DIR@"
|
||||
config.lit_tools_dir = "@LLVM_LIT_TOOLS_DIR@"
|
||||
config.lld_obj_root = "@LLD_BINARY_DIR@"
|
||||
+config.lld_libs_dir = "@LLVM_LIBRARY_OUTPUT_INTDIR@"
|
||||
+config.lld_tools_dir = "@LLVM_RUNTIME_OUTPUT_INTDIR@"
|
||||
config.target_triple = "@TARGET_TRIPLE@"
|
||||
config.python_executable = "@PYTHON_EXECUTABLE@"
|
||||
config.have_zlib = "@HAVE_LIBZ@"
|
||||
--
|
||||
2.12.0
|
||||
|
||||
@@ -1,82 +0,0 @@
|
||||
From a7fe305520085cff8e4bec0110d323c4f1ccbcab Mon Sep 17 00:00:00 2001
|
||||
From: Michal Gorny <mgorny@gentoo.org>
|
||||
Date: Wed, 8 Feb 2017 20:08:29 +0000
|
||||
Subject: [PATCH 3/3] [test] Fix zlib cond when building stand-alone, clean up
|
||||
|
||||
Fix the test zlib conditional to use LLVM_ENABLE_ZLIB value when
|
||||
building stand-alone. The HAVE_LIBZ is not available when performing
|
||||
a stand-alone build. Since the zlib support is a feature of
|
||||
the underlying LLVM library, it exports the actual status as the final
|
||||
value of LLVM_ENABLE_ZLIB in LLVMConfig.
|
||||
|
||||
While at it, canonicalize the boolean value into 0/1 and remove unused
|
||||
CMake definitions (most likely copied from clang).
|
||||
|
||||
Differential Revision: https://reviews.llvm.org/D29340
|
||||
|
||||
git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@294508 91177308-0d34-0410-b5e6-96231b3b80d8
|
||||
---
|
||||
test/CMakeLists.txt | 19 ++++++++++++-------
|
||||
test/lit.cfg | 2 +-
|
||||
test/lit.site.cfg.in | 2 +-
|
||||
3 files changed, 14 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
|
||||
index ede92c13d..962274160 100644
|
||||
--- a/test/CMakeLists.txt
|
||||
+++ b/test/CMakeLists.txt
|
||||
@@ -3,13 +3,18 @@ set(LLVM_BINARY_DIR "${LLVM_BINARY_DIR}")
|
||||
set(LLVM_BUILD_MODE "%(build_mode)s")
|
||||
set(LLVM_TOOLS_DIR "${LLVM_TOOLS_BINARY_DIR}/%(build_config)s")
|
||||
set(LLVM_LIBS_DIR "${LLVM_BINARY_DIR}/lib${LLVM_LIBDIR_SUFFIX}/%(build_config)s")
|
||||
-set(CLANG_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/..")
|
||||
-set(CLANG_BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/..")
|
||||
-if(BUILD_SHARED_LIBS)
|
||||
- set(ENABLE_SHARED 1)
|
||||
-else()
|
||||
- set(ENABLE_SHARED 0)
|
||||
-endif(BUILD_SHARED_LIBS)
|
||||
+
|
||||
+if(LLD_BUILT_STANDALONE)
|
||||
+ # Set HAVE_LIBZ according to recorded LLVM_ENABLE_ZLIB value. This
|
||||
+ # value is forced to 0 if zlib was not found, so it is fine to use it
|
||||
+ # instead of HAVE_LIBZ (not recorded).
|
||||
+ if(LLVM_ENABLE_ZLIB)
|
||||
+ set(HAVE_LIBZ 1)
|
||||
+ endif()
|
||||
+endif()
|
||||
+
|
||||
+llvm_canonicalize_cmake_booleans(
|
||||
+ HAVE_LIBZ)
|
||||
|
||||
configure_lit_site_cfg(
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/lit.site.cfg.in
|
||||
diff --git a/test/lit.cfg b/test/lit.cfg
|
||||
index 8dff2fb4e..85469ff6f 100644
|
||||
--- a/test/lit.cfg
|
||||
+++ b/test/lit.cfg
|
||||
@@ -202,7 +202,7 @@ if execute_external:
|
||||
config.available_features.add('shell')
|
||||
|
||||
# zlib compression library
|
||||
-if config.have_zlib == "1":
|
||||
+if config.have_zlib:
|
||||
config.available_features.add("zlib")
|
||||
|
||||
# Running on Darwin OS
|
||||
diff --git a/test/lit.site.cfg.in b/test/lit.site.cfg.in
|
||||
index 9dcb48174..1fb8d3690 100644
|
||||
--- a/test/lit.site.cfg.in
|
||||
+++ b/test/lit.site.cfg.in
|
||||
@@ -10,7 +10,7 @@ config.lld_libs_dir = "@LLVM_LIBRARY_OUTPUT_INTDIR@"
|
||||
config.lld_tools_dir = "@LLVM_RUNTIME_OUTPUT_INTDIR@"
|
||||
config.target_triple = "@TARGET_TRIPLE@"
|
||||
config.python_executable = "@PYTHON_EXECUTABLE@"
|
||||
-config.have_zlib = "@HAVE_LIBZ@"
|
||||
+config.have_zlib = @HAVE_LIBZ@
|
||||
|
||||
# Support substitution of the tools and libs dirs with user parameters. This is
|
||||
# used when we can't determine the tool dir at configuration time.
|
||||
--
|
||||
2.12.0
|
||||
|
||||
@@ -1,76 +0,0 @@
|
||||
# Copyright 1999-2017 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=6
|
||||
|
||||
: ${CMAKE_MAKEFILE_GENERATOR:=ninja}
|
||||
# (needed due to CMAKE_BUILD_TYPE != Gentoo)
|
||||
CMAKE_MIN_VERSION=3.7.0-r1
|
||||
PYTHON_COMPAT=( python2_7 )
|
||||
|
||||
inherit cmake-utils llvm python-any-r1
|
||||
|
||||
DESCRIPTION="The LLVM linker (link editor)"
|
||||
HOMEPAGE="https://llvm.org/"
|
||||
SRC_URI="https://releases.llvm.org/${PV/_//}/${P/_/}.src.tar.xz
|
||||
test? ( https://releases.llvm.org/${PV/_//}/llvm-${PV/_/}.src.tar.xz )"
|
||||
|
||||
LICENSE="UoI-NCSA"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~arm64 ~x86"
|
||||
IUSE="test"
|
||||
|
||||
RDEPEND="~sys-devel/llvm-${PV}"
|
||||
DEPEND="${RDEPEND}
|
||||
test? ( $(python_gen_any_dep "~dev-python/lit-${PV}[\${PYTHON_USEDEP}]") )"
|
||||
|
||||
S=${WORKDIR}/${P/_/}.src
|
||||
|
||||
# least intrusive of all
|
||||
CMAKE_BUILD_TYPE=RelWithDebInfo
|
||||
|
||||
python_check_deps() {
|
||||
has_version "dev-python/lit[${PYTHON_USEDEP}]"
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
LLVM_MAX_SLOT=${PV%%.*} llvm_pkg_setup
|
||||
use test && python-any-r1_pkg_setup
|
||||
}
|
||||
|
||||
src_unpack() {
|
||||
default
|
||||
|
||||
if use test; then
|
||||
mv llvm-* llvm || die
|
||||
fi
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# backport stand-alone build test fixes from master
|
||||
eapply "${FILESDIR}/4.0.1/0002-test-Use-LLD-specific-binary-library-dirs-when-build.patch"
|
||||
eapply "${FILESDIR}/4.0.1/0003-test-Fix-zlib-cond-when-building-stand-alone-clean-u.patch"
|
||||
|
||||
cmake-utils_src_prepare
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
local mycmakeargs=(
|
||||
-DBUILD_SHARED_LIBS=ON
|
||||
|
||||
-DLLVM_INCLUDE_TESTS=$(usex test)
|
||||
# TODO: fix detecting pthread upstream in stand-alone build
|
||||
-DPTHREAD_LIB='-lpthread'
|
||||
)
|
||||
use test && mycmakeargs+=(
|
||||
-DLLVM_BUILD_TESTS=ON
|
||||
-DLLVM_MAIN_SRC_DIR="${WORKDIR}/llvm"
|
||||
-DLIT_COMMAND="${EPREFIX}/usr/bin/lit"
|
||||
)
|
||||
|
||||
cmake-utils_src_configure
|
||||
}
|
||||
|
||||
src_test() {
|
||||
cmake-utils_src_make check-lld
|
||||
}
|
||||
@@ -1,73 +0,0 @@
|
||||
# Copyright 1999-2017 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=6
|
||||
|
||||
: ${CMAKE_MAKEFILE_GENERATOR:=ninja}
|
||||
# (needed due to CMAKE_BUILD_TYPE != Gentoo)
|
||||
CMAKE_MIN_VERSION=3.7.0-r1
|
||||
PYTHON_COMPAT=( python2_7 )
|
||||
|
||||
inherit cmake-utils llvm python-any-r1
|
||||
|
||||
MY_P=${P/_/}.src
|
||||
LLVM_P=llvm-${PV/_/}.src
|
||||
|
||||
DESCRIPTION="The LLVM linker (link editor)"
|
||||
HOMEPAGE="https://llvm.org/"
|
||||
SRC_URI="https://releases.llvm.org/${PV/_//}/${MY_P}.tar.xz
|
||||
test? ( https://releases.llvm.org/${PV/_//}/${LLVM_P}.tar.xz )"
|
||||
|
||||
LICENSE="UoI-NCSA"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~arm64 ~x86"
|
||||
IUSE="test"
|
||||
|
||||
RDEPEND="~sys-devel/llvm-${PV}"
|
||||
DEPEND="${RDEPEND}
|
||||
test? ( $(python_gen_any_dep "~dev-python/lit-${PV}[\${PYTHON_USEDEP}]") )"
|
||||
|
||||
S=${WORKDIR}/${MY_P}
|
||||
|
||||
# least intrusive of all
|
||||
CMAKE_BUILD_TYPE=RelWithDebInfo
|
||||
|
||||
python_check_deps() {
|
||||
has_version "dev-python/lit[${PYTHON_USEDEP}]"
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
LLVM_MAX_SLOT=${PV%%.*} llvm_pkg_setup
|
||||
use test && python-any-r1_pkg_setup
|
||||
}
|
||||
|
||||
src_unpack() {
|
||||
einfo "Unpacking ${MY_P}.tar.xz ..."
|
||||
tar -xf "${DISTDIR}/${MY_P}.tar.xz" || die
|
||||
|
||||
if use test; then
|
||||
einfo "Unpacking parts of ${LLVM_P}.tar.xz ..."
|
||||
tar -xf "${DISTDIR}/${LLVM_P}.tar.xz" \
|
||||
"${LLVM_P}"/utils/{lit,unittest} || die
|
||||
mv "${LLVM_P}" llvm || die
|
||||
fi
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
local mycmakeargs=(
|
||||
-DBUILD_SHARED_LIBS=ON
|
||||
|
||||
-DLLVM_INCLUDE_TESTS=$(usex test)
|
||||
)
|
||||
use test && mycmakeargs+=(
|
||||
-DLLVM_BUILD_TESTS=ON
|
||||
-DLLVM_MAIN_SRC_DIR="${WORKDIR}/llvm"
|
||||
-DLIT_COMMAND="${EPREFIX}/usr/bin/lit"
|
||||
)
|
||||
|
||||
cmake-utils_src_configure
|
||||
}
|
||||
|
||||
src_test() {
|
||||
cmake-utils_src_make check-lld
|
||||
}
|
||||
Reference in New Issue
Block a user