Convert integration-test-suite into a virtual test

Split tmt metadata into several tests based on the package set
to be tested, and select one or another depending on the tmt context.
Created subtests for devtools, rhel, fedora and snapshots.
This commit is contained in:
Jesus Checa Hidalgo 2024-04-10 19:33:02 +02:00 committed by jcheca
commit 6ad9cfeb01
5 changed files with 169 additions and 124 deletions

View file

@ -0,0 +1,69 @@
# DevTools collections settings.
environment+:
CMAKE_CXXLIB: "-DENABLE_LIBCXX=OFF -DENABLE_STATIC_LIBCXX=OFF"
CMAKE_LIBUNWIND: "-DENABLE_LIBUNWIND=OFF"
adjust+:
- enabled: false
when: collection is not defined
continue: false
# Requirements for SCL-ized LLVM
- require+:
- llvm-toolset-13.0-cmake
- llvm-toolset-13.0-clang
- llvm-toolset-13.0-clang-analyzer
- llvm-toolset-13.0-clang-devel
- llvm-toolset-13.0-clang-tools-extra
- llvm-toolset-13.0-compiler-rt
- llvm-toolset-13.0-lld
- llvm-toolset-13.0-lldb
- llvm-toolset-13.0-libomp-devel
- llvm-toolset-13.0-llvm-devel
- llvm-toolset-13.0-python3-lit
when: "collection == llvm-toolset-13.0"
- require+:
- llvm-toolset-14.0-cmake
- llvm-toolset-14.0-clang
- llvm-toolset-14.0-clang-analyzer
- llvm-toolset-14.0-clang-devel
- llvm-toolset-14.0-clang-tools-extra
- llvm-toolset-14.0-compiler-rt
- llvm-toolset-14.0-lld
- llvm-toolset-14.0-lldb
- llvm-toolset-14.0-libomp-devel
- llvm-toolset-14.0-llvm-devel
- llvm-toolset-14.0-python3-lit
when: "collection == llvm-toolset-14.0"
- require+:
- llvm-toolset-15.0-cmake
- llvm-toolset-15.0-clang
- llvm-toolset-15.0-clang-analyzer
- llvm-toolset-15.0-clang-devel
- llvm-toolset-15.0-clang-tools-extra
- llvm-toolset-15.0-compiler-rt
- llvm-toolset-15.0-lld
- llvm-toolset-15.0-lldb
- llvm-toolset-15.0-libomp-devel
- llvm-toolset-15.0-llvm-devel
- llvm-toolset-15.0-python3-lit
when: "collection == llvm-toolset-15.0"
# lld not supported in s390x or ppc64. If any lld package was added to
# requirements, remove it.
- require-:
- llvm-toolset-13.0-lld
- llvm-toolset-14.0-lld
- llvm-toolset-15.0-lld
when: >-
collection is defined and arch == s390x
or arch == ppc64
# libomp not supported in s390x. If any libomp-devel package was added to
# requirements, remove it.
- require-:
- llvm-toolset-13.0-libomp-devel
- llvm-toolset-14.0-libomp-devel
- llvm-toolset-15.0-libomp-devel
when: collection is defined and arch == s390x

View file

@ -0,0 +1,39 @@
# Fedora system repos package testing.
# This setup is meant to be used with packages in system repos, not with
# compat packages, or snapshots.
require+:
- cmake
- clang
- clang-analyzer
- clang-devel
- clang-tools-extra
- compiler-rt
- lld
- lldb
- libomp-devel
- llvm-devel
- python3-lit
- libcxx-devel
- libcxx-static
- mlir-devel
- llvm-libunwind-devel
adjust+:
- enabled: false
when: distro != fedora or snapshot is defined
continue: false
# libomp and lld are supported in s390x for LLVM >= 18. Until tmt provides
# a way to provide custom contexts, we need to filter out by distro versions.
- require-:
- lld
- libomp-devel
when: arch == s390x and distro < fedora-40
# libunwind is not built for s390x in LLVM < 17
- require-:
- llvm-libunwind-devel
environment+:
CMAKE_LIBUNWIND: "-DENABLE_LIBUNWIND=OFF"
when: arch == s390x and distro < fedora-39

View file

@ -20,129 +20,5 @@ require+:
- libstdc++-static
# scanbuild_py_makefile needs cc1plus provided by gcc-c++
- gcc-c++
adjust+:
# Common requirements when LLVM is not SCL-ized
- require+:
- cmake
- clang
- clang-analyzer
- clang-devel
- clang-tools-extra
- compiler-rt
- lld
- lldb
- libomp-devel
- llvm-devel
- python3-lit
when: "collection is not defined"
# Requirements for SCL-ized LLVM
- require+:
- llvm-toolset-13.0-cmake
- llvm-toolset-13.0-clang
- llvm-toolset-13.0-clang-analyzer
- llvm-toolset-13.0-clang-devel
- llvm-toolset-13.0-clang-tools-extra
- llvm-toolset-13.0-compiler-rt
- llvm-toolset-13.0-lld
- llvm-toolset-13.0-lldb
- llvm-toolset-13.0-libomp-devel
- llvm-toolset-13.0-llvm-devel
- llvm-toolset-13.0-python3-lit
when: "collection == llvm-toolset-13.0"
- require+:
- llvm-toolset-14.0-cmake
- llvm-toolset-14.0-clang
- llvm-toolset-14.0-clang-analyzer
- llvm-toolset-14.0-clang-devel
- llvm-toolset-14.0-clang-tools-extra
- llvm-toolset-14.0-compiler-rt
- llvm-toolset-14.0-lld
- llvm-toolset-14.0-lldb
- llvm-toolset-14.0-libomp-devel
- llvm-toolset-14.0-llvm-devel
- llvm-toolset-14.0-python3-lit
when: "collection == llvm-toolset-14.0"
- require+:
- llvm-toolset-15.0-cmake
- llvm-toolset-15.0-clang
- llvm-toolset-15.0-clang-analyzer
- llvm-toolset-15.0-clang-devel
- llvm-toolset-15.0-clang-tools-extra
- llvm-toolset-15.0-compiler-rt
- llvm-toolset-15.0-lld
- llvm-toolset-15.0-lldb
- llvm-toolset-15.0-libomp-devel
- llvm-toolset-15.0-llvm-devel
- llvm-toolset-15.0-python3-lit
when: "collection == llvm-toolset-15.0"
# lld not supported in s390x or ppc64. If any lld package was added to
# requirements, remove it.
- require-:
- llvm-toolset-13.0-lld
- llvm-toolset-14.0-lld
- llvm-toolset-15.0-lld
when: >-
collection is defined and arch == s390x
or arch == ppc64
# libomp not supported in s390x. If any libomp-devel package was added to
# requirements, remove it.
- require-:
- llvm-toolset-13.0-libomp-devel
- llvm-toolset-14.0-libomp-devel
- llvm-toolset-15.0-libomp-devel
when: collection is defined and arch == s390x
# libomp and lld are supported in s390x for LLVM >= 18. Until tmt provides
# a way to provide custom contexts, we need to filter out by distro versions.
- require-:
- lld
- libomp-devel
when: arch == s390x and distro < rhel-9, rhel-9.5, fedora-40, centos-stream-9
# libcxx shall be required in Fedora, it's not shipped with RHEL.
# Same applies for mlir.
- require+:
- libcxx-devel
- libcxx-static
- mlir-devel
when: "distro == fedora"
because: Require extra packages supported in Fedora
- require+:
- llvm-libunwind-devel
when: "distro == fedora"
- require-:
- llvm-libunwind-devel
environment+:
CMAKE_LIBUNWIND: "-DENABLE_LIBUNWIND=OFF"
when: distro < fedora-39 and arch == s390x
because: libunwind is not built for s390x in LLVM < 17
- environment+:
CMAKE_CXXLIB: "-DENABLE_LIBCXX=OFF -DENABLE_STATIC_LIBCXX=OFF"
CMAKE_LIBUNWIND: "-DENABLE_LIBUNWIND=OFF"
when: >-
distro == centos
or distro == rhel
because: libcxx and libunwind is not shipped with neither Centos nor RHEL
# llvm-snapshots specific adjustments.
# These are daily builds of a reduced set of the llvm components in currently
# supported Fedora releases. We remove anything that it's not supported.
# Supported components can be checked in:
# https://copr.fedorainfracloud.org/coprs/g/fedora-llvm-team/llvm-snapshots/monitor/
- require-:
- lldb
- libcxx-devel
- libcxx-static
- mlir-devel
- llvm-libunwind-devel
environment+:
CMAKE_CXXLIB: "-DENABLE_LIBCXX=OFF -DENABLE_STATIC_LIBCXX=OFF"
CMAKE_LIBUNWIND: "-DENABLE_LIBUNWIND=OFF"
when: distro == fedora and snapshot is defined
extra-nitrate: TC#0614094

View file

@ -0,0 +1,34 @@
# RHEL and CentOS settings
require+:
- cmake
- clang
- clang-analyzer
- clang-devel
- clang-tools-extra
- compiler-rt
- lld
- lldb
- libomp-devel
- llvm-devel
- python3-lit
environment+:
CMAKE_CXXLIB: "-DENABLE_LIBCXX=OFF -DENABLE_STATIC_LIBCXX=OFF"
CMAKE_LIBUNWIND: "-DENABLE_LIBUNWIND=OFF"
adjust+:
- enabled: false
when: distro != rhel and distro != centos or collection is defined
continue: false
# lld is supported in s390x for LLVM >= 18. Until tmt provides
# a way to provide custom contexts, we need to filter out by distro versions.
- require-:
- lld
when: arch == s390x and distro < rhel-9, rhel-9.5, centos-stream-9
# libomp is not supported in s390x in RHEL.
- require-:
- libomp-devel
when: arch == s390x

View file

@ -0,0 +1,27 @@
# llvm-snapshots specific setup.
# These are daily builds (latest upstream sources) of a reduced set of the llvm
# components in currently supported Fedora releases.
# Supported components can be checked in:
# https://copr.fedorainfracloud.org/coprs/g/fedora-llvm-team/llvm-snapshots/monitor/
require+:
- cmake
- clang
- clang-analyzer
- clang-devel
- clang-tools-extra
- compiler-rt
- lld
- lldb
- libomp-devel
- llvm-devel
- python3-lit
environment+:
CMAKE_CXXLIB: "-DENABLE_LIBCXX=OFF -DENABLE_STATIC_LIBCXX=OFF"
CMAKE_LIBUNWIND: "-DENABLE_LIBUNWIND=OFF"
adjust+:
- enabled: false
when: snapshot is not defined
continue: false