Compare commits

...

99 Commits
master ... f35

Author SHA1 Message Date
Tom Stellard e23a4f9e74 13.0.1 Release 2022-07-19 03:49:13 +00:00
Tom Stellard e1056b533a Fix default triple on arm
clang and gcc disagree about what gnueabi means, so we need to make
sure to specify gnueabihf as the environment.
2021-10-08 03:25:22 +00:00
Tom Stellard 84398d5b48 Set default triple 2021-10-06 05:54:41 +00:00
Tom Stellard a26e75dfb6 Drop abi_revision from soname
This way we match the upstream soname for the final release.
2021-10-05 03:10:24 +00:00
Tom Stellard d7b923e36b 13.0.0 Release 2021-10-01 03:28:44 +00:00
Tom Stellard f13f5d4d08 Restore config.guess for host triple detection
The new detection method was omitting -gnu from the triples which caused
some behavior changes in clang.
2021-09-30 20:50:48 +00:00
Tom Stellard 2b9d762f80 13.0.0-rc4 Release 2021-09-30 03:52:09 +00:00
Timm Bäder 9e342d2430 Use %py3_shebang_fix instead of calling pathfix.py manually
As documented here:
https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_shebang_macros
2021-09-23 14:47:00 +02:00
Tom Stellard efdfe5532f 13.0.0-rc3 Release 2021-09-17 20:06:08 +00:00
Tom Stellard 20aa2e6b37 Pass LLVM_DEFAULT_TARGET_TRIPLE to cmake
This will ensure that clang always defaults the system gcc install.
2021-09-17 13:30:23 +00:00
Tom Stellard bbb00db171 gating.yaml: Modernize file and attempt to get gating to work again
Added bodhi_update_push_stable_critpath to decision_contexts in
attempt to re-enable gating.
See https://pagure.io/fedora-ci/general/issue/263
2021-09-17 13:26:31 +00:00
Milos Prchlik 14cd547cf5 tests: record HW requirements
This was originally stored in provision.fmf, but after the TMT
transition, this information should be preserved. It is probably not
honoured by that many CI systems, but things will get better over time.

See https://tmt.readthedocs.io/en/stable/spec/plans.html#hardware for
specification details.
2021-09-17 13:25:29 +00:00
Milos Prchlik 027da3930a tests: returning few comments dropped during TMT conversion
I find these comments useful, especially for my future self who would be
dealing with the subtle changes between Fedora and downstream.
2021-09-17 10:51:44 +02:00
Timm Bäder b7b4d3e66b Port tests to tmt 2021-09-15 08:01:11 +02:00
Milos Prchlik b21766edbc Cleanup of tests for easier future sync to downstream repos
* tests.yml => tests-llvm.yml, to allow composition by "dumping" tests
from several LLVM components when testing a module or collection;
* more comments, to highlight part where downstream maintaners and QEs
need to modify tests;
* fixed failing tests to get a clean table as a verification tests do
work after my changes.
2021-09-13 21:56:17 +00:00
Konrad Kleine 4c4fb40d31 Add --without=check option 2021-09-13 17:03:07 +02:00
Tom Stellard a11bd8ab2a Fix Source URLs 2021-08-11 02:14:17 +00:00
serge-sans-paille bbcd893d83 13.0.0-rc1 Release 2021-08-06 06:51:44 +00:00
serge-sans-paille dbd3134b54 Maintain versionned link to llvm-config 2021-07-22 16:15:34 +02:00
Fedora Release Engineering 87a4234571 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-07-22 13:03:04 +00:00
Tom Stellard ed9052f67d Add missing sources 2021-07-13 17:49:35 +00:00
Tom Stellard 1b6487a87e 12.0.1 Release 2021-07-12 21:37:05 +00:00
Tom Stellard 086ce6b60e 12.0.1-rc3 Release 2021-06-30 12:49:06 +00:00
Tom Stellard 57a0e89ab1 Stop installing lit tests
We don't use these for CI tests any more and extracting the debuginfo
from the unittests is slowing down the builds or causing them to fail
in some cases (s390x).

This also removes the circular depednecy between llvm-test and
python-lit.
2021-06-29 21:41:56 +00:00
serge-sans-paille 300a6166b6 Verbose test run for easier debugging
And endless build logs
2021-06-25 14:46:38 +02:00
serge-sans-paille c944d8e241 Extra dependencies for integration test suite 2021-06-24 14:09:35 +02:00
Tom Stellard 084eb9adc4 12.0.1-rc1 Release 2021-05-27 13:31:14 +00:00
serge-sans-paille 578fb20cb6 Fix handling of llvm-config 2021-05-19 13:38:35 +02:00
serge-sans-paille 9fc4be03e7 Use integration test suite instead of regression test suite 2021-05-12 10:28:12 +02:00
serge-sans-paille 04d8b95430 More verbose builds thanks to python3-psutil 2021-05-03 12:44:47 +02:00
Konrad Kleine 97343414c5 Fix missing Python psutil module
In most logs (e.g.
https://kojipkgs.fedoraproject.org//work/tasks/9788/66839788/build.log)
you can find this output:

```
llvm-lit: /builddir/build/BUILD/llvm-12.0.0.src/x86_64-redhat-linux-gnu/utils/lit/tests/lit.cfg:79: warning: Setting a timeout per test not supported. Requires the Python psutil module but it could not be found. Try installing it via pip or via your operating system's package manager. Some tests will be skipped and the --timeout command line argument will not work.
```
2021-05-03 10:17:24 +02:00
serge-sans-paille 12b27392ce Decrease debuginfo weight for s390x too 2021-05-02 19:05:31 +02:00
serge-sans-paille 41e2e79b74 Fix llvm-config install 2021-05-02 07:42:49 +02:00
serge-sans-paille a49938dcf5 Minimal CI test for llvm-config
Previous release broke llvm-config, make sure this does not happen again
2021-05-01 21:08:17 +02:00
serge-sans-paille 0aa1942cbc Provide default empty value for exec_suffix when not in compat mode 2021-04-30 13:57:57 +02:00
Timm Bäder 03470c82bf Remove unused parameter from cmake invocation 2021-04-28 08:27:29 +02:00
serge-sans-paille 5ebc8337ce Fix llvm-config install 2021-04-27 11:08:22 +02:00
serge-sans-paille ad503c449d Backport compat package fix 2021-04-23 12:03:50 +02:00
Tomas Hrnciar 43ddc8aad7 BuildRequire setuptools explicitly
See https://fedoraproject.org/wiki/Changes/Reduce_dependencies_on_python3-setuptools
2021-04-19 13:18:31 +02:00
Tom Stellard f096dec97c 12.0.0 Release 2021-04-16 04:58:30 +00:00
Tom Stellard c2438a9311 Add rpmlintrc file to silence an rpmlint error 2021-04-13 04:30:17 +00:00
Tom Stellard d3a7312537 Import tests from tests/llvm repository
It's not necessary to store the tests in a separate repository, since
other packages can just reference the tests in this repo.
2021-04-09 22:47:38 +00:00
serge-sans-paille 649f50d8ed New upstream release candidate 2021-04-08 14:19:56 +02:00
serge-sans-paille b87ea61a41 Patch test case for compatibility with llvm-test layout 2021-04-08 09:37:13 +02:00
serge-sans-paille 15b5503827 Add Missing sources 2021-04-02 14:12:59 +02:00
serge-sans-paille 8e9a96e915 New upstream release candidate 2021-04-02 12:32:15 +02:00
Jonathan Wakely b210b9df54 Rebuilt for removed libstdc++ symbols (#1937698) 2021-03-31 17:34:24 +01:00
serge-sans-paille f4bd827999 Fix LD_LIBRARY_PATH to be compatible with compat package
See https://src.fedoraproject.org/rpms/llvm11/pull-request/2
2021-03-31 08:48:12 +02:00
serge-sans-paille 2d7f1de486 Revert "Only ship llvm-config manpages for compat package"
This reverts commit 8a5849ef91.
2021-03-19 20:54:05 +01:00
serge-sans-paille 8a5849ef91 Only ship llvm-config manpages for compat package 2021-03-17 13:58:30 +01:00
serge-sans-paille 23ea0783cb LLVM 12.0.0 rc3 2021-03-11 14:54:27 +01:00
Kalev Lember 238c272915 Add llvm-static(major) provides to the -static subpackage
This is similar to how other subpackages have llvm(major),
llvm-devel(major) and llvm-test(major) provides.
2021-03-10 12:47:19 +01:00
serge-sans-paille cdd5e565ec rebuilt 2021-03-09 14:58:35 +01:00
serge-sans-paille d368d987d9 Change CI working dir 2021-03-02 11:37:53 +01:00
serge-sans-paille 5ed4f59a12 Revert "Fix gating test to use /var/tmp instead of /tmp"
This reverts commit 698638eb9e.

Doesn't seem to help much.
2021-03-02 11:37:09 +01:00
serge-sans-paille 5476c44af0 12.0.0-rc2 release 2021-02-24 09:16:46 +01:00
serge-sans-paille 698638eb9e Fix gating test to use /var/tmp instead of /tmp 2021-02-24 08:33:11 +01:00
Dave Airlie f200214110 Enable LLVM_USE_PERF to allow perf integration 2021-02-23 17:31:32 +00:00
serge-sans-paille 298958146f Backport compat package updates 2021-02-23 17:18:25 +01:00
serge-sans-paille f88ef7d17f Add webassembly to the rhel targets 2021-02-17 18:14:13 +01:00
serge-sans-paille d31813f419 12.0.0-rc1 release 2021-02-03 07:33:44 +01:00
serge-sans-paille 21e2a92c0d Parametrize targets to build 2021-01-28 21:37:32 +01:00
Fedora Release Engineering 7a04c726c3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-01-26 18:36:24 +00:00
serge-sans-paille f768ecb72d 11.1.0-rc2 release 2021-01-22 18:23:01 +01:00
serge-sans-paille 4799046978 11.1.0-rc1 release 2021-01-18 17:06:17 +01:00
serge-sans-paille 11cea8ec0d LLVM 11.0.1 final 2021-01-06 10:54:54 +01:00
serge-sans-paille 036db17a5c Waive extra test case 2021-01-05 13:52:34 +01:00
serge-sans-paille 056fb9e32b Remove a failing arm test case 2020-12-22 08:55:56 +01:00
serge-sans-paille c32dd93367 11.0.1-rc2 release 2020-12-21 09:57:36 +01:00
serge-sans-paille 86790c25da Add missing sources 2020-12-01 13:56:07 +00:00
serge-sans-paille 2698f34268 11.0.1-rc1 release 2020-12-01 13:40:45 +00:00
Jeff Law e1767ba62d Fix missing #include for gcc-11 2020-10-31 11:50:44 -06:00
Josh Stone 051ec63e7b Fix coreos-installer test crash on s390x (rhbz#1883457) 2020-10-14 17:37:34 -07:00
serge-sans-paille f5cf570384 llvm 11.0.0 - final release 2020-10-12 11:30:04 +00:00
serge-sans-paille 9e83c56016 11.0.0-rc6 2020-10-08 09:12:06 +00:00
serge-sans-paille 4720785554 11.0.0-rc5 Release 2020-10-02 07:14:52 +00:00
serge-sans-paille 00e1b0677e Fix NVR 2020-09-27 13:11:33 +00:00
serge-sans-paille 23f776ed73 Obsolete patch for rhbz#1862012 2020-09-24 17:11:05 +00:00
serge-sans-paille 493675c744 11.0.0-rc3 Release 2020-09-24 14:22:13 +00:00
serge-sans-paille 014d0253f8 Increase CI capacity 2020-09-15 08:29:19 +00:00
serge-sans-paille 12632088f8 Apply upstream patch for rhbz#1862012 2020-09-02 07:27:02 +00:00
serge-sans-paille 130685912f Fix source location 2020-09-01 10:40:54 +00:00
Tom Stellard 9095ad677f 11.0.0-rc2 Release 2020-08-24 11:10:01 -04:00
Tom Stellard afed217ebc Fix regression-tests CI tests 2020-08-21 13:24:07 +00:00
Tom Stellard 764a78bf46 Remove llvm-devel-cmake test
This test is no longer relevant since llvm-devel now Requires both
llvm-static and llvm-test.
2020-08-19 00:00:55 +00:00
Tom Stellard 13d84b331e Fix rust crash on ppc64le compiling firefox
rhbz#1862012
2020-08-18 17:58:01 +00:00
Tom Stellard 3ca69f5739 Install update_cc_test_checks.py script 2020-08-12 09:40:17 -04:00
Tom Stellard 992907b031 LLVM 11.0.0-rc1 Release
Also make llvm-devel require llvm-static and llvm-test.
2020-08-07 23:50:07 -04:00
Tom Stellard 40207a4ea9 Backport upstream patch to fix build with -flto.
Also disable LTO on s390x to work-around unit test failures.
2020-08-08 03:48:41 +00:00
serge-sans-paille a58113d73c Fix update-alternative uninstall script 2020-08-08 03:48:13 +00:00
serge-sans-paille 146561a8a6 Fix gpg verification, update ninja macro and use %license 2020-08-06 23:42:59 +00:00
Fedora Release Engineering 210d1cc82b - Second attempt - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-08-01 04:17:02 +00:00
Fedora Release Engineering edf13af9da - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-07-28 06:11:32 +00:00
Aleksandra Fedorova e89816ed7a Update gating test name
Messaging scheme has changed and old centos-related test names are now deprecated.

See https://pagure.io/fedora-ci/general/issue/110
2020-07-15 00:04:17 +00:00
serge-sans-paille d7400582fd Make llvm-test.tar.gz creation reproducible
Move arch-specific content out of the tarball, and build the tarball in a reproducible way.
2020-06-18 07:49:54 +00:00
serge-sans-paille 96783870dd Instruct cmake not to generate RPATH 2020-06-02 15:55:00 +00:00
Tom Stellard 71b43061fd Install LLVMgold.so symlink in bfd-plugins directory 2020-05-12 15:47:18 +00:00
serge-sans-paille 8e1d8d6581 Update testing to pass gating tests
- Backport bab5908df544680ada0a3cf431f55aeccfbdb321 (test portability)
- Fix indentation in tests/tests.yml
- Remove testing of update utility tools
2020-04-15 19:17:21 +00:00
serge-sans-paille 63f8be8e26 Apply changes needed for the compat build
Based on llvm9 package
2020-04-01 17:17:25 +00:00
31 changed files with 689 additions and 388 deletions

50
.gitignore vendored
View File

@ -68,3 +68,53 @@
/llvm-10.0.0rc6.src.tar.xz.sig
/llvm-10.0.0.src.tar.xz
/llvm-10.0.0.src.tar.xz.sig
/llvm-11.0.0rc1.src.tar.xz
/llvm-11.0.0rc1.src.tar.xz.sig
/llvm-11.0.0rc2.src.tar.xz
/llvm-11.0.0rc2.src.tar.xz.sig
/llvm-11.0.0rc3.src.tar.xz
/llvm-11.0.0rc3.src.tar.xz.sig
/llvm-11.0.0rc5.src.tar.xz
/llvm-11.0.0rc5.src.tar.xz.sig
/llvm-11.0.0rc6.src.tar.xz
/llvm-11.0.0rc6.src.tar.xz.sig
/llvm-11.0.0.src.tar.xz
/llvm-11.0.0.src.tar.xz.sig
/llvm-11.0.1rc1.src.tar.xz
/llvm-11.0.1rc1.src.tar.xz.sig
/llvm-11.0.1rc2.src.tar.xz.sig
/llvm-11.0.1rc2.src.tar.xz
/llvm-11.0.1.src.tar.xz
/llvm-11.0.1.src.tar.xz.sig
/llvm-11.1.0rc1.src.tar.xz.sig
/llvm-11.1.0rc1.src.tar.xz
/llvm-11.1.0rc2.src.tar.xz
/llvm-11.1.0rc2.src.tar.xz.sig
/llvm-12.0.0rc1.src.tar.xz
/llvm-12.0.0rc1.src.tar.xz.sig
/llvm-12.0.0rc2.src.tar.xz
/llvm-12.0.0rc2.src.tar.xz.sig
/llvm-12.0.0rc3.src.tar.xz
/llvm-12.0.0rc3.src.tar.xz.sig
/llvm-12.0.0rc4.src.tar.xz
/llvm-12.0.0rc4.src.tar.xz.sig
/llvm-12.0.0rc5.src.tar.xz
/llvm-12.0.0rc5.src.tar.xz.sig
/llvm-12.0.0.src.tar.xz
/llvm-12.0.0.src.tar.xz.sig
/llvm-12.0.1rc1.src.tar.xz
/llvm-12.0.1rc1.src.tar.xz.sig
/llvm-12.0.1rc3.src.tar.xz
/llvm-12.0.1rc3.src.tar.xz.sig
/llvm-12.0.1.src.tar.xz
/llvm-12.0.1.src.tar.xz.sig
/llvm-13.0.0rc1.src.tar.xz
/llvm-13.0.0rc1.src.tar.xz.sig
/llvm-13.0.0rc3.src.tar.xz
/llvm-13.0.0rc3.src.tar.xz.sig
/llvm-13.0.0rc4.src.tar.xz
/llvm-13.0.0rc4.src.tar.xz.sig
/llvm-13.0.0.src.tar.xz
/llvm-13.0.0.src.tar.xz.sig
/llvm-13.0.1.src.tar.xz
/llvm-13.0.1.src.tar.xz.sig

View File

@ -1,66 +0,0 @@
From 8f6917ea11bd1bfbfe07f3577756d1c4abfdb916 Mon Sep 17 00:00:00 2001
From: Tom Stellard <tstellar@redhat.com>
Date: Fri, 6 Sep 2019 11:03:18 -0700
Subject: [PATCH] CMake: Split static library exports into their own export
file
---
llvm/cmake/modules/AddLLVM.cmake | 6 +++++-
llvm/cmake/modules/CMakeLists.txt | 3 +++
llvm/cmake/modules/LLVMConfig.cmake.in | 2 ++
3 files changed, 10 insertions(+), 1 deletion(-)
diff --git a/llvm/cmake/modules/AddLLVM.cmake b/llvm/cmake/modules/AddLLVM.cmake
index 619e986..200fc45 100644
--- a/llvm/cmake/modules/AddLLVM.cmake
+++ b/llvm/cmake/modules/AddLLVM.cmake
@@ -691,7 +691,11 @@ macro(add_llvm_library name)
if(${name} IN_LIST LLVM_DISTRIBUTION_COMPONENTS OR
(in_llvm_libs AND "llvm-libraries" 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/llvm/cmake/modules/CMakeLists.txt b/llvm/cmake/modules/CMakeLists.txt
index 9cf22b4..dc982d2 100644
--- a/llvm/cmake/modules/CMakeLists.txt
+++ b/llvm/cmake/modules/CMakeLists.txt
@@ -105,6 +105,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
@@ -121,6 +122,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/llvm/cmake/modules/LLVMConfig.cmake.in b/llvm/cmake/modules/LLVMConfig.cmake.in
index 536031f..6ef54a0 100644
--- a/llvm/cmake/modules/LLVMConfig.cmake.in
+++ b/llvm/cmake/modules/LLVMConfig.cmake.in
@@ -89,6 +89,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

View File

@ -1,65 +0,0 @@
From 9d496e978f59e153bb76e92229d5a524d92dee04 Mon Sep 17 00:00:00 2001
From: Tom Stellard <tstellar@redhat.com>
Date: Tue, 10 Sep 2019 13:33:48 -0700
Subject: [PATCH] CMake: Split test binary exports into their own export file
---
llvm/cmake/modules/AddLLVM.cmake | 7 ++++++-
llvm/cmake/modules/CMakeLists.txt | 3 +++
llvm/cmake/modules/LLVMConfig.cmake.in | 1 +
3 files changed, 10 insertions(+), 1 deletion(-)
diff --git a/llvm/cmake/modules/AddLLVM.cmake b/llvm/cmake/modules/AddLLVM.cmake
index 200fc45..9eec7a7 100644
--- a/llvm/cmake/modules/AddLLVM.cmake
+++ b/llvm/cmake/modules/AddLLVM.cmake
@@ -953,7 +953,12 @@ macro(add_llvm_utility name)
set(export_to_llvmexports)
if (${name} IN_LIST LLVM_DISTRIBUTION_COMPONENTS OR
NOT LLVM_DISTRIBUTION_COMPONENTS)
- set(export_to_llvmexports EXPORT LLVMExports)
+ if (${name} STREQUAL "not" OR ${name} STREQUAL "count" OR
+ ${name} STREQUAL "yaml-bench" OR ${name} STREQUAL "lli-child-target")
+ set(export_to_llvmexports EXPORT LLVMTestExports)
+ else()
+ set(export_to_llvmexports EXPORT LLVMExports)
+ endif()
set_property(GLOBAL PROPERTY LLVM_HAS_EXPORTS True)
endif()
diff --git a/llvm/cmake/modules/CMakeLists.txt b/llvm/cmake/modules/CMakeLists.txt
index dc982d2..c861f45 100644
--- a/llvm/cmake/modules/CMakeLists.txt
+++ b/llvm/cmake/modules/CMakeLists.txt
@@ -106,6 +106,7 @@ 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")
+set(LLVM_CONFIG_TEST_EXPORTS_FILE "\${LLVM_CMAKE_DIR}/LLVMTestExports.cmake")
configure_file(
LLVMConfig.cmake.in
${CMAKE_CURRENT_BINARY_DIR}/CMakeFiles/LLVMConfig.cmake
@@ -124,6 +125,8 @@ if (NOT LLVM_INSTALL_TOOLCHAIN_ONLY)
COMPONENT cmake-exports)
install(EXPORT LLVMStaticExports DESTINATION ${LLVM_INSTALL_PACKAGE_DIR}
COMPONENT cmake-exports)
+ install(EXPORT LLVMTestExports DESTINATION ${LLVM_INSTALL_PACKAGE_DIR}
+ COMPONENT cmake-exports)
endif()
install(FILES
diff --git a/llvm/cmake/modules/LLVMConfig.cmake.in b/llvm/cmake/modules/LLVMConfig.cmake.in
index 6ef54a0..d81b09a 100644
--- a/llvm/cmake/modules/LLVMConfig.cmake.in
+++ b/llvm/cmake/modules/LLVMConfig.cmake.in
@@ -91,6 +91,7 @@ if(NOT TARGET LLVMSupport)
@llvm_config_include_buildtree_only_exports@
include("@LLVM_CONFIG_STATIC_EXPORTS_FILE@" OPTIONAL)
+ include("@LLVM_CONFIG_TEST_EXPORTS_FILE@" OPTIONAL)
endif()
# By creating intrinsics_gen here, subprojects that depend on LLVM's
--
1.8.3.1

View File

@ -0,0 +1,33 @@
From 9320ffeda3915c8f7be744c983a3470a89107bd7 Mon Sep 17 00:00:00 2001
From: Tom Stellard <tstellar@redhat.com>
Date: Tue, 14 Sep 2021 20:21:20 -0700
Subject: [PATCH] XFAIL missing-abstract-variable.ll test on ppc64le
It's seems the strategy with this test is to XFAIL it on all
architectures that it fails on. I wonder if we should be passing
it a specific triple? Also, from what I can tell, this tests only
runs when llvm is configured with LLVM_DEFAULT_TARGET_TRIPLE set
to a non-empty value, which is why it may not fail in every build
configuration.
Differential Revision: https://reviews.llvm.org/D109806
---
llvm/test/DebugInfo/Generic/missing-abstract-variable.ll | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/llvm/test/DebugInfo/Generic/missing-abstract-variable.ll b/llvm/test/DebugInfo/Generic/missing-abstract-variable.ll
index bd0de60268b6..cc5d56b0c512 100644
--- a/llvm/test/DebugInfo/Generic/missing-abstract-variable.ll
+++ b/llvm/test/DebugInfo/Generic/missing-abstract-variable.ll
@@ -4,7 +4,7 @@
; powerpc64 (and on x86_64 at at least -O2). Presumably this is a SelectionDAG
; issue.
; FIXME: arm64 is an alias for aarch64 on macs, apparently?
-; XFAIL: powerpc64, aarch64, arm64, hexagon
+; XFAIL: powerpc64, aarch64, arm64, hexagon, ppc64le
; Build from the following source with clang -O2.
--
2.31.1

View File

@ -0,0 +1,75 @@
From 3dc5722d5c7673a879f2b4680369d3ac8b6b64b6 Mon Sep 17 00:00:00 2001
From: Tom Stellard <tstellar@redhat.com>
Date: Wed, 4 Aug 2021 14:05:38 -0700
Subject: [PATCH] cmake: Allow shared libraries to customize the soname using
LLVM_ABI_REVISION
The LLVM_ABI_REVISION variable is intended to be used for release
candidates which introduce an ABI change to a shared library. This
variable can be specified per library, so there is not one global value
for all of LLVM.
For example, if we LLVM X.0.0-rc2 introduces an ABI change for a library
compared with LLVM X.0.0-rc1, then the LLVM_ABI_REVISION number for
library will be incremented by 1.
In the main branch, LLVM_ABI_REVISION should always be 0, it is only
meant to be used in the release branch.
Differential Revision: https://reviews.llvm.org/D105594
---
llvm/cmake/modules/AddLLVM.cmake | 7 +++++--
llvm/tools/llvm-shlib/CMakeLists.txt | 9 +++++++++
3 files changed, 19 insertions(+), 2 deletions(-)
diff --git a/llvm/cmake/modules/AddLLVM.cmake b/llvm/cmake/modules/AddLLVM.cmake
index 3e009f5061d3..a09405a1be3e 100644
--- a/llvm/cmake/modules/AddLLVM.cmake
+++ b/llvm/cmake/modules/AddLLVM.cmake
@@ -586,11 +586,14 @@ function(llvm_add_library name)
# Set SOVERSION on shared libraries that lack explicit SONAME
# specifier, on *nix systems that are not Darwin.
if(UNIX AND NOT APPLE AND NOT ARG_SONAME)
+ if (NOT LLVM_ABI_REVISION)
+ set(LLVM_ABI_REVISION 0)
+ endif()
set_target_properties(${name}
PROPERTIES
# Since 4.0.0, the ABI version is indicated by the major version
- SOVERSION ${LLVM_VERSION_MAJOR}${LLVM_VERSION_SUFFIX}
- VERSION ${LLVM_VERSION_MAJOR}${LLVM_VERSION_SUFFIX})
+ SOVERSION ${LLVM_VERSION_MAJOR}.${LLVM_ABI_REVISION}
+ VERSION ${LLVM_VERSION_MAJOR}.${LLVM_ABI_REVISION})
endif()
endif()
diff --git a/llvm/tools/llvm-shlib/CMakeLists.txt b/llvm/tools/llvm-shlib/CMakeLists.txt
index 76b9a25cbbcd..b876e7fed6b5 100644
--- a/llvm/tools/llvm-shlib/CMakeLists.txt
+++ b/llvm/tools/llvm-shlib/CMakeLists.txt
@@ -2,6 +2,11 @@
# library is enabled by setting LLVM_BUILD_LLVM_DYLIB=yes on the CMake
# commandline. By default the shared library only exports the LLVM C API.
+# In the main branch, LLVM_ABI_REVISION should always be 0. In the release
+# branches, this should be incremented before each release candidate every
+# time the ABI of libLLVM.so changes.
+set(LLVM_ABI_REVISION 0 CACHE STRING "ABI Revision number for SONAMEs (default: 0)")
+
set(SOURCES
libllvm.cpp
)
@@ -67,6 +72,10 @@ if(LLVM_BUILD_LLVM_DYLIB)
set_property(TARGET LLVM APPEND_STRING PROPERTY
LINK_FLAGS
" -compatibility_version 1 -current_version ${LLVM_VERSION_MAJOR}.${LLVM_VERSION_MINOR}.${LLVM_VERSION_PATCH}")
+ else()
+ set_target_properties(LLVM
+ PROPERTIES
+ SOVERSION ${LLVM_ABI_REVISION})
endif()
if(TARGET libLLVMExports)
--
2.27.0

View File

@ -1,12 +1,10 @@
--- !Policy
product_versions:
- fedora-*
decision_context: bodhi_update_push_testing
decision_contexts:
- bodhi_update_push_testing
- bodhi_update_push_stable
- bodhi_update_push_stable_critpath
subject_type: koji_build
rules:
- !PassingTestCaseRule {test_case_name: org.centos.prod.ci.pipeline.allpackages-build.package.test.functional.complete}
--- !Policy
product_versions:
- fedora-*
decision_context: bodhi_update_push_stable
rules:
- !PassingTestCaseRule {test_case_name: org.centos.prod.ci.pipeline.allpackages-build.package.test.functional.complete}
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}

View File

@ -1,52 +0,0 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
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
67H2IH//2sf8dw==
=ADVe
-----END PGP PUBLIC KEY BLOCK-----

2
llvm.rpmlintrc Normal file
View File

@ -0,0 +1,2 @@
# This library has no dependencies.
addFilter("llvm-libs.x86_64: E: shared-lib-without-dependency-information /usr/lib64/libRemarks.so.[0-9]+")

507
llvm.spec
View File

@ -7,20 +7,22 @@
%endif
%bcond_with compat_build
%bcond_without check
%global llvm_libdir %{_libdir}/%{name}
%global build_llvm_libdir %{buildroot}%{llvm_libdir}
#%%global rc_ver 6
%global baserelease 1
%global llvm_srcdir llvm-%{version}%{?rc_ver:rc%{rc_ver}}.src
%global maj_ver 10
#global rc_ver 4
%global maj_ver 13
%global min_ver 0
%global patch_ver 0
%global patch_ver 1
%if !%{maj_ver} && 0%{?rc_ver}
%global abi_revision 2
%endif
%global llvm_srcdir llvm-%{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:rc%{rc_ver}}.src
%if %{with compat_build}
%global pkg_name llvm%{maj_ver}.%{min_ver}
%global exec_suffix -%{maj_ver}.%{min_ver}
%global pkg_name llvm%{maj_ver}
%global exec_suffix -%{maj_ver}
%global install_prefix %{_libdir}/%{name}
%global install_bindir %{install_prefix}/bin
%global install_includedir %{install_prefix}/include
@ -33,33 +35,53 @@
%global pkg_name llvm
%global install_prefix /usr
%global install_libdir %{_libdir}
%global pkg_bindir %{_bindir}
%global pkg_libdir %{install_libdir}
%global exec_suffix %{nil}
%endif
%if 0%{?rhel}
%global targets_to_build "X86;AMDGPU;PowerPC;NVPTX;SystemZ;AArch64;ARM;Mips;BPF;WebAssembly"
%global experimental_targets_to_build ""
%else
%global targets_to_build "all"
%global experimental_targets_to_build "AVR"
%endif
%global build_install_prefix %{buildroot}%{install_prefix}
# Lower memory usage of dwz on s390x
%global _dwz_low_mem_die_limit_s390x 1
%global _dwz_max_die_limit_s390x 1000000
%ifarch %{arm}
# koji overrides the _gnu variable to be gnu, which is not correct for clang, so
# we need to hard-code the correct triple here.
%global llvm_triple armv7l-redhat-linux-gnueabihf
%else
%global llvm_triple %{_host}
%endif
Name: %{pkg_name}
Version: %{maj_ver}.%{min_ver}.%{patch_ver}
Release: %{baserelease}%{?rc_ver:.rc%{rc_ver}}%{?dist}
Version: %{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:~rc%{rc_ver}}
Release: 1%{?dist}
Summary: The Low Level Virtual Machine
License: NCSA
URL: http://llvm.org
%if 0%{?rc_ver:1}
Source0: https://prereleases.llvm.org/%{version}/rc%{rc_ver}/%{llvm_srcdir}.tar.xz
Source3: https://prereleases.llvm.org/%{version}/rc%{rc_ver}/%{llvm_srcdir}.tar.xz.sig
%else
Source0: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/%{llvm_srcdir}.tar.xz
Source3: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{version}/%{llvm_srcdir}.tar.xz.sig
%endif
%if %{without compat_build}
Source1: run-lit-tests
Source2: lit.fedora.cfg.py
%endif
Source4: https://prereleases.llvm.org/%{version}/hans-gpg-key.asc
Source0: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:-rc%{rc_ver}}/%{llvm_srcdir}.tar.xz
Source1: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:-rc%{rc_ver}}/%{llvm_srcdir}.tar.xz.sig
Source2: tstellar-gpg-key.asc
Patch0: 0001-CMake-Split-static-library-exports-into-their-own-ex.patch
Patch1: 0001-CMake-Split-test-binary-exports-into-their-own-expor.patch
%if %{without compat_build}
Source3: run-lit-tests
Source4: lit.fedora.cfg.py
%endif
%if 0%{?abi_revision}
Patch0: 0001-cmake-Allow-shared-libraries-to-customize-the-soname.patch
%endif
Patch2: 0001-XFAIL-missing-abstract-variable.ll-test-on-ppc64le.patch
BuildRequires: gcc
BuildRequires: gcc-c++
@ -68,6 +90,7 @@ BuildRequires: ninja-build
BuildRequires: zlib-devel
BuildRequires: libffi-devel
BuildRequires: ncurses-devel
BuildRequires: python3-psutil
BuildRequires: python3-sphinx
BuildRequires: python3-recommonmark
BuildRequires: multilib-rpm-config
@ -80,8 +103,13 @@ BuildRequires: valgrind-devel
%endif
# LLVM's LineEditor library will use libedit if it is available.
BuildRequires: libedit-devel
# We need python3-devel for pathfix.py.
# We need python3-devel for %%py3_shebang_fix
BuildRequires: python3-devel
BuildRequires: python3-setuptools
# For origin certification
BuildRequires: gnupg2
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
@ -101,6 +129,17 @@ Requires: %{name}-libs%{?_isa} = %{version}-%{release}
# app that requires the libLLVMLineEditor, so we need to make sure
# libedit-devel is available.
Requires: libedit-devel
# The installed cmake files reference binaries from llvm-test and llvm-static.
# We tried in the past to split the cmake exports for these binaries out into
# separate files, so that llvm-devel would not need to Require these packages,
# but this caused bugs (rhbz#1773678) and forced us to carry two non-upstream
# patches.
Requires: %{name}-static%{?_isa} = %{version}-%{release}
%if %{without compat_build}
Requires: %{name}-test%{?_isa} = %{version}-%{release}
%endif
Requires(post): %{_sbindir}/alternatives
Requires(postun): %{_sbindir}/alternatives
@ -128,6 +167,8 @@ Shared libraries for the LLVM compiler infrastructure.
Summary: LLVM static libraries
Conflicts: %{name}-devel < 8
Provides: llvm-static(major) = %{maj_ver}
%description static
Static libraries for the LLVM compiler infrastructure.
@ -137,14 +178,6 @@ Static libraries for the LLVM compiler infrastructure.
Summary: LLVM regression tests
Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
Requires: python3-lit
# The regression tests need gold.
Requires: binutils
# This is for llvm-config
Requires: %{name}-devel%{?_isa} = %{version}-%{release}
# Bugpoint tests require gcc
Requires: gcc
Requires: findutils
Provides: llvm-test(major) = %{maj_ver}
@ -160,32 +193,37 @@ LLVM's modified googletest sources.
%endif
%prep
%{gpgverify} --keyring='%{SOURCE2}' --signature='%{SOURCE1}' --data='%{SOURCE0}'
%autosetup -n %{llvm_srcdir} -p2
pathfix.py -i %{__python3} -pn \
%py3_shebang_fix \
test/BugPoint/compile-custom.ll.py \
tools/opt-viewer/*.py
tools/opt-viewer/*.py \
utils/update_cc_test_checks.py
%build
mkdir -p _build
cd _build
%ifarch s390 %{arm} %ix86
# Disable LTO on s390x, this causes some test failures:
# LLVM-Unit :: Target/AArch64/./AArch64Tests/InstSizes.Authenticated
# LLVM-Unit :: Target/AArch64/./AArch64Tests/InstSizes.PATCHPOINT
# LLVM-Unit :: Target/AArch64/./AArch64Tests/InstSizes.STACKMAP
# LLVM-Unit :: Target/AArch64/./AArch64Tests/InstSizes.TLSDESC_CALLSEQ
# On X86_64, LTO builds of TableGen crash. This can be reproduced by:
# %%cmake_build --target include/llvm/IR/IntrinsicsAArch64.h
# Because of these failures, lto is disabled for now.
%global _lto_cflags %{nil}
%ifarch s390 s390x %{arm} %ix86
# Decrease debuginfo verbosity to reduce memory consumption during final library linking
%global optflags %(echo %{optflags} | sed 's/-g /-g1 /')
%endif
# force off shared libs as cmake macros turns it on.
#
# -DCMAKE_INSTALL_RPATH=";" is a workaround for llvm manually setting the
# rpath of libraries and binaries. llvm will skip the manual setting
# 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 \
%cmake -G Ninja \
-DBUILD_SHARED_LIBS:BOOL=OFF \
-DLLVM_PARALLEL_LINK_JOBS=1 \
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-DCMAKE_INSTALL_RPATH=";" \
-DCMAKE_SKIP_RPATH:BOOL=ON \
%ifarch s390 %{arm} %ix86
-DCMAKE_C_FLAGS_RELWITHDEBINFO="%{optflags} -DNDEBUG" \
-DCMAKE_CXX_FLAGS_RELWITHDEBINFO="%{optflags} -DNDEBUG" \
@ -198,15 +236,16 @@ cd _build
%endif
%endif
\
-DLLVM_TARGETS_TO_BUILD=all \
-DLLVM_TARGETS_TO_BUILD=%{targets_to_build} \
-DLLVM_ENABLE_LIBCXX:BOOL=OFF \
-DLLVM_ENABLE_ZLIB:BOOL=ON \
-DLLVM_ENABLE_FFI:BOOL=ON \
-DLLVM_ENABLE_RTTI:BOOL=ON \
-DLLVM_USE_PERF:BOOL=ON \
%if %{with gold}
-DLLVM_BINUTILS_INCDIR=%{_includedir} \
%endif
-DLLVM_EXPERIMENTAL_TARGETS_TO_BUILD=AVR \
-DLLVM_EXPERIMENTAL_TARGETS_TO_BUILD=%{experimental_targets_to_build} \
\
-DLLVM_BUILD_RUNTIME:BOOL=ON \
\
@ -215,6 +254,7 @@ cd _build
\
-DLLVM_INCLUDE_TESTS:BOOL=ON \
-DLLVM_BUILD_TESTS:BOOL=ON \
-DLLVM_LIT_EXTRA_ARGS=-v \
\
-DLLVM_INCLUDE_EXAMPLES:BOOL=ON \
-DLLVM_BUILD_EXAMPLES:BOOL=OFF \
@ -233,51 +273,55 @@ cd _build
-DLLVM_ENABLE_SPHINX:BOOL=ON \
-DLLVM_ENABLE_DOXYGEN:BOOL=OFF \
\
%if %{without compat_build}
-DLLVM_VERSION_SUFFIX='' \
%endif
-DLLVM_BUILD_LLVM_DYLIB:BOOL=ON \
-DLLVM_DYLIB_EXPORT_ALL:BOOL=ON \
-DLLVM_LINK_LLVM_DYLIB:BOOL=ON \
-DLLVM_BUILD_EXTERNAL_COMPILER_RT:BOOL=ON \
-DLLVM_INSTALL_TOOLCHAIN_ONLY:BOOL=OFF \
%{?abi_revision:-DLLVM_ABI_REVISION=%{abi_revision}} \
\
-DLLVM_DEFAULT_TARGET_TRIPLE=%{llvm_triple} \
-DSPHINX_WARNINGS_AS_ERRORS=OFF \
-DCMAKE_INSTALL_PREFIX=%{install_prefix} \
-DLLVM_INSTALL_SPHINX_HTML_DIR=%{_pkgdocdir}/html \
-DSPHINX_EXECUTABLE=%{_bindir}/sphinx-build-3
# Build libLLVM.so first. This ensures that when libLLVM.so is linking, there
# are no other compile jobs running. This will help reduce OOM errors on the
# builders without having to artificially limit the number of concurrent jobs.
%ninja_build LLVM
%ninja_build
%cmake_build --target LLVM
%cmake_build
%install
%ninja_install -C _build
%cmake_install
mkdir -p %{buildroot}/%{_bindir}
%if %{without compat_build}
mkdir -p %{buildroot}/%{_bindir}
mv %{buildroot}/%{_bindir}/llvm-config %{buildroot}/%{_bindir}/llvm-config-%{__isa_bits}
# Fix some man pages
ln -s llvm-config.1 %{buildroot}%{_mandir}/man1/llvm-config-%{__isa_bits}.1
mv %{buildroot}%{_mandir}/man1/tblgen.1 %{buildroot}%{_mandir}/man1/llvm-tblgen.1
ln -s llvm-config.1 %{buildroot}%{_mandir}/man1/llvm-config%{exec_suffix}-%{__isa_bits}.1
# Install binaries needed for lit tests
%global test_binaries llvm-isel-fuzzer llvm-opt-fuzzer
for f in %{test_binaries}
do
install -m 0755 ./_build/bin/$f %{buildroot}%{_bindir}
install -m 0755 %{_vpath_builddir}/bin/$f %{buildroot}%{_bindir}
done
# Remove testing of update utility tools
rm -rf test/tools/UpdateTestChecks
%multilib_fix_c_header --file %{_includedir}/llvm/Config/llvm-config.h
# Install libraries needed for unittests
%if 0%{?__isa_bits} == 64
%global build_libdir _build/lib64
%global build_libdir %{_vpath_builddir}/lib64
%else
%global build_libdir _build/lib
%global build_libdir %{_vpath_builddir}/lib
%endif
install %{build_libdir}/libLLVMTestingSupport.a %{buildroot}%{_libdir}
@ -292,48 +336,22 @@ install -d %{install_srcdir}
install -d %{install_srcdir}/utils/
cp -R utils/unittest %{install_srcdir}/utils/
# Generate lit config files. Strip off the last line that initiates the
# test run, so we can customize the configuration.
head -n -1 _build/test/lit.site.cfg.py >> %{lit_cfg}
head -n -1 _build/test/Unit/lit.site.cfg.py >> %{lit_unit_cfg}
# Clang needs these for running lit tests.
cp utils/update_cc_test_checks.py %{install_srcdir}/utils/
cp -R utils/UpdateTestChecks %{install_srcdir}/utils/
# Install custom fedora config file
cp %{SOURCE2} %{buildroot}%{lit_fedora_cfg}
# Patch lit config files to load custom fedora config:
for f in %{lit_cfg} %{lit_unit_cfg}; do
echo "lit_config.load_config(config, '%{lit_fedora_cfg}')" >> $f
done
install -d %{buildroot}%{_libexecdir}/tests/llvm
install -m 0755 %{SOURCE1} %{buildroot}%{_libexecdir}/tests/llvm
# Install lit tests. We need to put these in a tarball otherwise rpm will complain
# about some of the test inputs having the wrong object file format.
install -d %{buildroot}%{_datadir}/llvm/
tar -czf %{install_srcdir}/test.tar.gz test/
# Install the unit test binaries
mkdir -p %{build_llvm_libdir}
cp -R _build/unittests %{build_llvm_libdir}/
rm -rf `find %{build_llvm_libdir} -iname 'cmake*'`
# Install libraries used for testing
install -m 0755 %{build_libdir}/BugpointPasses.so %{buildroot}%{_libdir}
install -m 0755 %{build_libdir}/LLVMHello.so %{buildroot}%{_libdir}
# Install test inputs for PDB tests
echo "%{_datadir}/llvm/src/unittests/DebugInfo/PDB" > %{build_llvm_libdir}/unittests/DebugInfo/PDB/llvm.srcdir.txt
mkdir -p %{buildroot}%{_datadir}/llvm/src/unittests/DebugInfo/PDB/
cp -R unittests/DebugInfo/PDB/Inputs %{buildroot}%{_datadir}/llvm/src/unittests/DebugInfo/PDB/
%if %{with gold}
# Add symlink to lto plugin in the binutils plugin directory.
%{__mkdir_p} %{buildroot}%{_libdir}/bfd-plugins/
ln -s %{_libdir}/LLVMgold.so %{buildroot}%{_libdir}/bfd-plugins/
%endif
%else
# Add version suffix to binaries
mkdir -p %{buildroot}/%{_bindir}
for f in %{buildroot}/%{install_bindir}/*; do
filename=`basename $f`
ln -s %{install_bindir}/$filename %{buildroot}/%{_bindir}/$filename%{exec_suffix}
ln -s ../../../%{install_bindir}/$filename %{buildroot}/%{_bindir}/$filename%{exec_suffix}
done
# Move header files
@ -342,7 +360,6 @@ ln -s ../../../%{install_includedir}/llvm %{buildroot}/%{pkg_includedir}/llvm
ln -s ../../../%{install_includedir}/llvm-c %{buildroot}/%{pkg_includedir}/llvm-c
# Fix multi-lib
mv %{buildroot}%{_bindir}/llvm-config{%{exec_suffix},%{exec_suffix}-%{__isa_bits}}
%multilib_fix_c_header --file %{install_includedir}/llvm/Config/llvm-config.h
# Create ld.so.conf.d entry
@ -353,7 +370,7 @@ EOF
# Add version suffix to man pages and move them to mandir.
mkdir -p %{buildroot}/%{_mandir}/man1
for f in `ls %{build_install_prefix}/share/man/man1/*`; do
for f in %{build_install_prefix}/share/man/man1/*; do
filename=`basename $f | cut -f 1 -d '.'`
mv $f %{buildroot}%{_mandir}/man1/$filename%{exec_suffix}.1
done
@ -363,37 +380,82 @@ rm -Rf %{build_install_prefix}/share/opt-viewer
%endif
# llvm-config special casing. llvm-config is managed by update-alternatives.
# the original file must remain available for compatibility with the CMake
# infrastructure. Without compat, cmake points to the symlink, with compat it
# points to the original file.
%if %{without compat_build}
mv %{buildroot}/%{pkg_bindir}/llvm-config %{buildroot}/%{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
# We still maintain a versionned symlink for consistency across llvm versions.
# This is specific to the non-compat build and matches the exec prefix for
# compat builds. An isa-agnostic versionned symlink is also maintained in the (un)install
# steps.
(cd %{buildroot}/%{pkg_bindir} ; ln -s llvm-config%{exec_suffix}-%{__isa_bits} llvm-config-%{maj_ver}-%{__isa_bits} )
# ghost presence
touch %{buildroot}%{_bindir}/llvm-config-%{maj_ver}
%else
rm %{buildroot}%{_bindir}/llvm-config%{exec_suffix}
(cd %{buildroot}/%{pkg_bindir} ; ln -s llvm-config llvm-config%{exec_suffix}-%{__isa_bits} )
%endif
# ghost presence
touch %{buildroot}%{_bindir}/llvm-config%{exec_suffix}
%check
# TODO: Fix test failures on arm
ninja check-all -C _build || \
# Disable check section on arm due to some kind of memory related failure.
# Possibly related to https://bugzilla.redhat.com/show_bug.cgi?id=1920183
%ifnarch %{arm}
# TODO: Fix the failures below
%ifarch %{arm}
:
%else
false
rm test/tools/llvm-readobj/ELF/dependent-libraries.test
%endif
# non reproducible errors
rm test/tools/dsymutil/X86/swift-interface.test
%if %{with check}
# FIXME: use %%cmake_build instead of %%__ninja
LD_LIBRARY_PATH=%{buildroot}/%{pkg_libdir} %{__ninja} check-all -C %{_vpath_builddir}
%endif
%endif
%ldconfig_scriptlets libs
%if %{without compat_build}
%post devel
%{_sbindir}/update-alternatives --install %{_bindir}/llvm-config llvm-config %{_bindir}/llvm-config-%{__isa_bits} %{__isa_bits}
%{_sbindir}/update-alternatives --install %{_bindir}/llvm-config%{exec_suffix} llvm-config%{exec_suffix} %{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits} %{__isa_bits}
%if %{without compat_build}
%{_sbindir}/update-alternatives --install %{_bindir}/llvm-config-%{maj_ver} llvm-config-%{maj_ver} %{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits} %{__isa_bits}
%endif
%postun devel
if [ $1 -eq 0 ]; then
%{_sbindir}/update-alternatives --remove llvm-config %{_bindir}/llvm-config
%{_sbindir}/update-alternatives --remove llvm-config%{exec_suffix} %{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%if %{without compat_build}
%{_sbindir}/update-alternatives --remove llvm-config-%{maj_ver} %{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%endif
fi
%endif
%files
%license LICENSE.TXT
%exclude %{_mandir}/man1/llvm-config*
%{_mandir}/man1/*
%{_bindir}/*
%exclude %{_bindir}/llvm-config%{exec_suffix}
%exclude %{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%if %{without compat_build}
%exclude %{_bindir}/llvm-config-%{__isa_bits}
%exclude %{_bindir}/llvm-config-%{maj_ver}
%exclude %{pkg_bindir}/llvm-config-%{maj_ver}-%{__isa_bits}
%exclude %{_bindir}/not
%exclude %{_bindir}/count
%exclude %{_bindir}/yaml-bench
@ -402,17 +464,19 @@ fi
%exclude %{_bindir}/llvm-opt-fuzzer
%{_datadir}/opt-viewer
%else
%exclude %{pkg_bindir}/llvm-config
%{pkg_bindir}
%endif
%files libs
%license LICENSE.TXT
%{pkg_libdir}/libLLVM-%{maj_ver}.so
%if %{without compat_build}
%if %{with gold}
%{_libdir}/LLVMgold.so
%{_libdir}/bfd-plugins/LLVMgold.so
%endif
%{_libdir}/libLLVM-%{maj_ver}.%{min_ver}*.so
%{_libdir}/libLLVM-%{maj_ver}.so%{?abi_revision:.%{abi_revision}}
%{_libdir}/libLTO.so*
%else
%config(noreplace) %{_sysconfdir}/ld.so.conf.d/%{name}-%{_arch}.conf
@ -426,19 +490,20 @@ fi
%{pkg_libdir}/libRemarks.so*
%files devel
%if %{without compat_build}
%{_bindir}/llvm-config-%{__isa_bits}
%license LICENSE.TXT
%ghost %{_bindir}/llvm-config%{exec_suffix}
%{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%{_mandir}/man1/llvm-config*
%if %{without compat_build}
%{_includedir}/llvm
%{_includedir}/llvm-c
%{_libdir}/libLLVM.so
%{_libdir}/cmake/llvm
%exclude %{_libdir}/cmake/llvm/LLVMStaticExports.cmake
%exclude %{_libdir}/cmake/llvm/LLVMTestExports.cmake
%{pkg_bindir}/llvm-config-%{maj_ver}-%{__isa_bits}
%ghost %{_bindir}/llvm-config-%{maj_ver}
%else
%{_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%{pkg_bindir}/llvm-config
%{_mandir}/man1/llvm-config%{exec_suffix}.1.gz
%{install_includedir}/llvm
%{install_includedir}/llvm-c
%{pkg_includedir}/llvm
@ -449,13 +514,14 @@ fi
%endif
%files doc
%license LICENSE.TXT
%doc %{_pkgdocdir}/html
%files static
%license LICENSE.TXT
%if %{without compat_build}
%{_libdir}/*.a
%exclude %{_libdir}/libLLVMTestingSupport.a
%{_libdir}/cmake/llvm/LLVMStaticExports.cmake
%else
%{_libdir}/%{name}/lib/*.a
%endif
@ -463,28 +529,221 @@ fi
%if %{without compat_build}
%files test
%{_libexecdir}/tests/llvm/
%{llvm_libdir}/unittests/
%{_datadir}/llvm/src/unittests
%{_datadir}/llvm/src/test.tar.gz
%{_datadir}/llvm/lit.fedora.cfg.py
%license LICENSE.TXT
%{_bindir}/not
%{_bindir}/count
%{_bindir}/yaml-bench
%{_bindir}/lli-child-target
%{_bindir}/llvm-isel-fuzzer
%{_bindir}/llvm-opt-fuzzer
%{_libdir}/BugpointPasses.so
%{_libdir}/LLVMHello.so
%{_libdir}/cmake/llvm/LLVMTestExports.cmake
%files googletest
%license LICENSE.TXT
%{_datadir}/llvm/src/utils
%{_libdir}/libLLVMTestingSupport.a
%endif
%changelog
* Mon Jul 18 2022 Tom Stellard <tstellar@redhat.com> - 13.0.1-1
- 13.0.1 Release
* Fri Oct 08 2021 Tom Stellard <tstellar@redhat.com> - 13.0.0-4
- Fix default triple on arm
* Wed Oct 06 2021 Tom Stellard <tstellar@redhat.com> - 13.0.0-3
- Set default triple
* Mon Oct 04 2021 Tom Stellard <tstellar@redhat.com> - 13.0.0-2
- Drop abi_revision from soname
* Thu Sep 30 2021 Tom Stellard <tstellar@redhat.com> - 13.0.0-1
- 13.0.0 Release
* Thu Sep 30 2021 Tom Stellard <tstellar@redhat.com> - 13.0.0~rc4-2
- Restore config.guess for host triple detection
* Fri Sep 24 2021 Tom Stellard <tstellar@redhat.com> - 13.0.0~rc4-1
- 13.0.0-rc4 Release
* Fri Sep 17 2021 Tom Stellard <tstellar@redhta.com> - 13.0.0~rc3-1
- 13.0.0-rc3 Release
* Mon Sep 13 2021 Tom Stellard <tstellar@redhat.com> - 13.0.0~rc1-3
- Pass LLVM_DEFAULT_TARGET_TRIPLE to cmake
* Mon Sep 13 2021 Konrad Kleine <kkleine@redhat.com> - 13.0.0~rc1-2
- Add --without=check option
* Wed Aug 04 2021 Tom Stellard <tstellar@redhat.com> - 13.0.0~rc1-1
- 13.0.0-rc1 Release
* Thu Jul 22 2021 sguelton@redhat.com - 12.0.1-3
- Maintain versionned link to llvm-config
* Thu Jul 22 2021 Fedora Release Engineering <releng@fedoraproject.org> - 12.0.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Mon Jul 12 2021 Tom Stellard <tstellar@redhat.com> - 12.0.1-1
- 12.0.1 Release
* Wed Jun 30 2021 Tom Stellard <tstellar@redhat.com> - llvm-12.0.1~rc3-1
- 12.0.1-rc3 Release
* Fri May 28 2021 Tom Stellard <tstellar@redhat.com> - 12.0.1~rc1-2
- Stop installing lit tests
* Wed May 26 2021 Tom Stellard <tstellar@redhat.com> - llvm-12.0.1~rc1-1
- 12.0.1-rc1 Release
* Mon May 17 2021 sguelton@redhat.com - 12.0.0-7
- Fix handling of llvm-config
* Mon May 03 2021 kkleine@redhat.com - 12.0.0-6
- More verbose builds thanks to python3-psutil
* Sat May 01 2021 sguelton@redhat.com - 12.0.0-5
- Fix llvm-config install
* Tue Apr 27 2021 sguelton@redhat.com - 12.0.0-4
- Provide default empty value for exec_suffix when not in compat mode
* Tue Apr 27 2021 sguelton@redhat.com - 12.0.0-3
- Fix llvm-config install
* Tue Apr 20 2021 sguelton@redhat.com - 12.0.0-2
- Backport compat package fix
* Thu Apr 15 2021 Tom Stellard <tstellar@redhat.com> - 12.0.0-1
- 12.0.0 Release
* Thu Apr 08 2021 sguelton@redhat.com - 12.0.0-0.11.rc5
- New upstream release candidate
* Tue Apr 06 2021 sguelton@redhat.com - 12.0.0-0.10.rc4
- Patch test case for compatibility with llvm-test latout
* Fri Apr 02 2021 sguelton@redhat.com - 12.0.0-0.9.rc4
- New upstream release candidate
* Wed Mar 31 2021 Jonathan Wakely <jwakely@redhat.com> - 12.0.0-0.8.rc3
- Rebuilt for removed libstdc++ symbols (#1937698)
* Thu Mar 11 2021 sguelton@redhat.com - 12.0.0-0.7.rc3
- LLVM 12.0.0 rc3
* Wed Mar 10 2021 Kalev Lember <klember@redhat.com> - 12.0.0-0.6.rc2
- Add llvm-static(major) provides to the -static subpackage
* Tue Mar 09 2021 sguelton@redhat.com - 12.0.0-0.5.rc2
- rebuilt
* Tue Mar 02 2021 sguelton@redhat.com - 12.0.0-0.4.rc2
- Change CI working dir
* Wed Feb 24 2021 sguelton@redhat.com - 12.0.0-0.3.rc2
- 12.0.0-rc2 release
* Tue Feb 16 2021 Dave Airlie <airlied@redhat.com> - 12.0.0-0.2.rc1
- Enable LLVM_USE_PERF to allow perf integration
* Tue Feb 2 2021 Serge Guelton - 12.0.0-0.1.rc1
- 12.0.0-rc1 release
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 11.1.0-0.3.rc2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Fri Jan 22 2021 Serge Guelton - 11.1.0-0.2.rc2
- 11.1.0-rc2 release
* Thu Jan 14 2021 Serge Guelton - 11.1.0-0.1.rc1
- 11.1.0-rc1 release
* Tue Jan 05 2021 Serge Guelton - 11.0.1-3.rc2
- Waive extra test case
* Sun Dec 20 2020 sguelton@redhat.com - 11.0.1-2.rc2
- 11.0.1-rc2 release
* Tue Dec 01 2020 sguelton@redhat.com - 11.0.1-1.rc1
- 11.0.1-rc1 release
* Sat Oct 31 2020 Jeff Law <law@redhat.com> - 11.0.0-2
- Fix missing #include for gcc-11
* Wed Oct 14 2020 Josh Stone <jistone@redhat.com> - 11.0.0-1
- Fix coreos-installer test crash on s390x (rhbz#1883457)
* Mon Oct 12 2020 sguelton@redhat.com - 11.0.0-0.11
- llvm 11.0.0 - final release
* Thu Oct 08 2020 sguelton@redhat.com - 11.0.0-0.10.rc6
- 11.0.0-rc6
* Fri Oct 02 2020 sguelton@redhat.com - 11.0.0-0.9.rc5
- 11.0.0-rc5 Release
* Sun Sep 27 2020 sguelton@redhat.com - 11.0.0-0.8.rc3
- Fix NVR
* Thu Sep 24 2020 sguelton@redhat.com - 11.0.0-0.2.rc3
- Obsolete patch for rhbz#1862012
* Thu Sep 24 2020 sguelton@redhat.com - 11.0.0-0.1.rc3
- 11.0.0-rc3 Release
* Wed Sep 02 2020 sguelton@redhat.com - 11.0.0-0.7.rc2
- Apply upstream patch for rhbz#1862012
* Tue Sep 01 2020 sguelton@redhat.com - 11.0.0-0.6.rc2
- Fix source location
* Fri Aug 21 2020 Tom Stellard <tstellar@redhat.com> - 11.0.0-0.5.rc2
- 11.0.0-rc2 Release
* Wed Aug 19 2020 Tom Stellard <tstellar@redhat.com> - 11.0.0-0.4.rc1
- Fix regression-tests CI tests
* Tue Aug 18 2020 Tom Stellard <tstellar@redhat.com> - 11.0.0-0.3.rc1
- Fix rust crash on ppc64le compiling firefox
- rhbz#1862012
* Tue Aug 11 2020 Tom Stellard <tstellar@redhat.com> - 11.0.0-0.2.rc1
- Install update_cc_test_checks.py script
* Thu Aug 06 2020 Tom Stellard <tstellar@redhat.com> - 11.0.0-0.1-rc1
- LLVM 11.0.0-rc1 Release
- Make llvm-devel require llvm-static and llvm-test
* Tue Aug 04 2020 Tom Stellard <tstellar@redhat.com> - 10.0.0-10
- Backport upstream patch to fix build with -flto.
- Disable LTO on s390x to work-around unit test failures.
* Sat Aug 01 2020 sguelton@redhat.com - 10.0.0-9
- Fix update-alternative uninstall script
* Sat Aug 01 2020 sguelton@redhat.com - 10.0.0-8
- Fix gpg verification and update macro usage.
* Sat Aug 01 2020 Fedora Release Engineering <releng@fedoraproject.org> - 10.0.0-7
- Second attempt - Rebuilt for
https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 10.0.0-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
* Thu Jun 11 2020 sguelton@redhat.com - 10.0.0-5
- Make llvm-test.tar.gz creation reproducible.
* Tue Jun 02 2020 sguelton@redhat.com - 10.0.0-4
- Instruct cmake not to generate RPATH
* Thu Apr 30 2020 Tom Stellard <tstellar@redhat.com> - 10.0.0-3
- Install LLVMgold.so symlink in bfd-plugins directory
* Tue Apr 07 2020 sguelton@redhat.com - 10.0.0-2
- Do not package UpdateTestChecks tests in llvm-tests
- Apply upstream patch bab5908df to pass gating tests
* Wed Mar 25 2020 sguelton@redhat.com - 10.0.0-1
- 10.0.0 final

View File

@ -48,9 +48,10 @@ esac
cd $(mktemp -d)
ln -s /usr/include include
ln -s /usr/share/llvm/src/docs docs
tar -xzf /usr/share/llvm/src/test.tar.gz
ln -s $ARCH.site.cfg.py test/lit.site.cfg.py
ln -s $ARCH.site.cfg.py test/Unit/lit.site.cfg.py
ln -s /usr/share/llvm/src/$ARCH.site.cfg.py test/lit.site.cfg.py
ln -s /usr/share/llvm/src/$ARCH.Unit.site.cfg.py test/Unit/lit.site.cfg.py
lit -v -s $threads_arg test \
-Dllvm_obj_root=`pwd` \
-Dllvm_test_root=`pwd`/test \

View File

@ -1,2 +1,2 @@
SHA512 (llvm-10.0.0.src.tar.xz) = 7dc961aacee3a01ecc002ff2b688a2ef50661856d2abd5ecc90566ffcad7566e4976736cd339ea96592e452cd5a17aaceba9712b2effec805661cca8ff020ee7
SHA512 (llvm-10.0.0.src.tar.xz.sig) = 2e4c61af5d84db4bc7a8ab51367210c529ae02e401b7a73a449f79bf9d92654ccf36fdef0f552c8850df0e94bcafce2359180ad0cdf720be7c874a782a936878
SHA512 (llvm-13.0.1.src.tar.xz) = 05fbe8708ac3d0dfef3a9135ee88185a95ed492095429a97d33b8aadb0187e59ad42d1a7184f02b5c84fdd31f3d7227c65bd292ed0aa039b29522e59cf90a965
SHA512 (llvm-13.0.1.src.tar.xz.sig) = 0db0076fee269faa477ff7ff42c3ef5bd24cb3816219bbc093080fd4f7516e5414dc0f686325761ff57255d91307cd3f4dbba9066ea7cd69fb819a856f05bde8

View File

@ -0,0 +1,2 @@
summary: Make sure the the LLVM plugin for binutils' ar works
test: ./test.sh

View File

@ -0,0 +1,7 @@
#!/bin/sh -eux
set pipefail
echo "void lto_function(){}" | clang -flto -O2 -c -x c -o foo.o -
ar crs foo.a foo.o
readelf -c foo.a | grep lto_function

View File

@ -0,0 +1,3 @@
summary: Make sure rebuilding LLVM still works with the new LLVM
test: ./test.sh
enabled: false

View File

@ -1,6 +1,4 @@
#!/bin/bash
set -ex
#!/bin/sh -eux
dnf download --disablerepo=* --enablerepo=test-llvm --source llvm

12
tests/default.fmf Normal file
View File

@ -0,0 +1,12 @@
summary: All available LLVM tests
discover:
how: fmf
execute:
how: tmt
prepare:
- name: packages
how: install
package: llvm
provision:
hardware:
memory: ">= 4 GiB"

View File

@ -0,0 +1,28 @@
summary: Run the upstream LLVM integration test suite
description: |
Run the upstream LLVM integration test suite
NOTE: don't forget to disable libcxx tests when libcxx is not available, by adding -DENABLE_LIBCXX=OFF.
test: ./test.sh
require:
- cmake
- llvm-devel
- clang
- clang-analyzer
- clang-tools-extra
- compiler-rt
- ninja-build
- libomp-devel
- lld
- lldb
- git
- make
- libstdc++-static
- clang-devel
# In Fedora, python-lit is valid. In RHEL, however, the actual package is python3-lit.
- python-lit
# - python3-lit
# Required in Fedora, but not shipped with RHEL. For future reference, comment the libcxx out as needed.
- libcxx-devel

View File

@ -0,0 +1,37 @@
#!/bin/sh -eux
usage() {
echo "usage `basename $0` [OPTIONS]"
echo " --threads NUM The number of threads to use for running tests."
}
threads=0
thread_args=""
repo_url=https://github.com/opencollab/llvm-toolchain-integration-test-suite
while [ $# -gt 0 ]; do
case $1 in
--threads)
shift
threads="$1"
;;
* )
echo "unknown option: $1"
echo ""
usage
exit 1
;;
esac
shift
done
if [ "$threads" -ge 1 ]; then
thread_args="-j$threads"
fi
cd $(mktemp -d -p /var/tmp)
git clone $repo_url
cd llvm-toolchain-integration-test-suite
mkdir _build && cd _build
cmake .. -GNinja
ninja $thread_args check

View File

@ -0,0 +1,2 @@
summary: Check that libLLVM.so has been properly stripped
test: ./test.sh

10
tests/libllvm-size/test.sh Executable file
View File

@ -0,0 +1,10 @@
#!/bin/sh -eux
# There is a bug in the build process when it runs out of disk space
# while stripping binaries, which causes the strip to fail, but does
# not fail the build. This results in a libLLVM.so that is over 2GB
# which breaks the nightly compose. So this test checks that libLLVM.so
# is less than 100MB to ensure it was successfully stripped.
# https://bugzilla.redhat.com/show_bug.cgi?id=1793250
test $(stat -L -c %s /usr/lib64/libLLVM.so) -lt 104857600

View File

@ -0,0 +1,2 @@
summary: Make sure llvm-config symlink is properly set up
test: ./test.sh

3
tests/llvm-config/test.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/sh -eux
llvm-config --version

View File

@ -1,5 +0,0 @@
---
standard-inventory-qcow2:
qemu:
m: 2G

View File

@ -0,0 +1,16 @@
summary: Test basic cargo usage
test: ./test.sh
require:
# Required for rust and possibly other dependant packages
#
# NOTE #1: drop the requirement once the transitional period between releases is gone
# and llvm-compat is no longer a) needed, and b) part of the build.
#
# NOTE #2: keep it the first requirement. Depending on the order of requirements, placing it somewhere
# else in the list may lead to harness uninstalling and re-installing LLVM packages. That a) would be
# a waste of time, b) could potentially hide issues, leading to testing unexpected NVRs.
#
# - llvm-compat
- cargo
- rust

5
tests/rust-sanity/test.sh Executable file
View File

@ -0,0 +1,5 @@
#!/bin/sh -eux
cargo new hello
cd hello
cargo run

View File

@ -1,30 +0,0 @@
- hosts: localhost
roles:
- role: standard-test-basic
tags:
- classic
required_packages:
- llvm-test
- rust
- cargo
tests:
- regression-tests:
dir: ./
run: /usr/libexec/tests/llvm/run-lit-tests --threads 1
- rust-sanity:
dir: ./
run: cargo new hello && cd hello && cargo run
# There is a bug in the build process when it runs out of disk space
# while stripping binaries, which causes the strip to fail, but does
# not fail the build. This results in a libLLVM.so that is over 2GB
# which breaks the nightly compose. So this test checks that libLLVM.so
# is less than 100MB to ensure it was successfully stripped.
# https://bugzilla.redhat.com/show_bug.cgi?id=1793250
- libllvm-size:
dir: ./
run: test `stat -L -c %s /usr/lib64/libLLVM.so` -lt 100000000
# This test ensures that the spec file still builds correctly with
# %global compat_build 1
# FIXME: This fails, because the CI system has a hard-coded timeout of 4
# hours.
#- build-compat

View File

@ -1,31 +0,0 @@
- hosts: localhost
pre_tasks:
# Make sure we uninstall all sub-packages, so we can test that the cmake files
# in llvm-devel are useable when only llvm-devel is installed.
- name: Uninstall llvm sub-packages
package:
name: "{{ item }}"
state: absent
tags: classic
with_items:
- llvm
- llvm-devel
- llvm-doc
- llvm-googletest
- llvm-libs
- llvm-static
- llvm-test
roles:
- role: standard-test-basic
tags: classic
required_packages:
- llvm-devel
- cmake
- ninja-build
- gcc
- gcc-c++
repositories:
- repo: "https://src.fedoraproject.org/tests/llvm.git"
dest: "llvm"
tests:
- llvm/llvm-devel-cmake

View File

@ -0,0 +1,2 @@
summary: Make sure the versioned llvm-config symlink is properly set up
test: ./test.sh

View File

@ -0,0 +1,5 @@
#!/bin/sh -eux
major=$(llvm-config --version | cut -d '.' -f1)
llvm-config-$major --version

BIN
tstellar-gpg-key.asc Normal file

Binary file not shown.