From 95363f8f968f8a1321a9af224b5b40ff807d3d37 Mon Sep 17 00:00:00 2001 From: Eli Schwartz Date: Sun, 11 Aug 2024 19:03:52 -0400 Subject: [PATCH 01/21] dev-util/gcovr: drop old Signed-off-by: Eli Schwartz --- dev-util/gcovr/Manifest | 1 - dev-util/gcovr/gcovr-6.0.ebuild | 44 ------ dev-util/gcovr/gcovr-7.2.ebuild | 258 -------------------------------- 3 files changed, 303 deletions(-) delete mode 100644 dev-util/gcovr/gcovr-6.0.ebuild delete mode 100644 dev-util/gcovr/gcovr-7.2.ebuild diff --git a/dev-util/gcovr/Manifest b/dev-util/gcovr/Manifest index 21af1035f2c29..644a30963fb65 100644 --- a/dev-util/gcovr/Manifest +++ b/dev-util/gcovr/Manifest @@ -1,2 +1 @@ -DIST gcovr-6.0.tar.gz 1054940 BLAKE2B 1947950d06926cf48d456e6bc389db46cfe4c7ed0395da1ebdb75aa1ea4b85f3cea536d77a4ddca5621885daaaf54462160592a5a384247f12ad3ed5c299b0b7 SHA512 3b4d30417b5000d2d28bc156dc9db43ba62cf8756aa5a9619391457d0042dc8eaf1743c5defdaabffb6b423bf2fcf8172b3e6c8795419758abc1acf4853de4bb DIST gcovr-7.2.gh.tar.gz 2800014 BLAKE2B e334688f129868d9affe0fa5c5280eb7dd4c57825bec31f32d529c579f622e7c60985f8aad506bd714ebe00c47fd61b673ad2352e51a0fd8175777bb6a1c93e7 SHA512 fc4acbfeef48866c5c8884681375069c7308a86aaefe5b36e631240a96dcdc7c56b3e8d0c221f66dbbe29302b549c5c9b9c5e01bbf4103165b085ae33c369f55 diff --git a/dev-util/gcovr/gcovr-6.0.ebuild b/dev-util/gcovr/gcovr-6.0.ebuild deleted file mode 100644 index 0ea329e5cd7e2..0000000000000 --- a/dev-util/gcovr/gcovr-6.0.ebuild +++ /dev/null @@ -1,44 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DISTUTILS_USE_PEP517=setuptools -PYTHON_COMPAT=( python3_{9..11} ) - -inherit distutils-r1 - -DESCRIPTION="A Python script for summarizing gcov data" -HOMEPAGE="https://github.com/gcovr/gcovr" -SRC_URI="https://github.com/gcovr/gcovr/archive/${PV}.tar.gz -> ${P}.tar.gz" - -LICENSE="BSD" -SLOT="0" -KEYWORDS="amd64 ~loong ~x86" - -RDEPEND=" - dev-python/jinja[${PYTHON_USEDEP}] - dev-python/lxml[${PYTHON_USEDEP}] - dev-python/pygments[${PYTHON_USEDEP}] - dev-python/yaxmldiff[${PYTHON_USEDEP}] -" -BDEPEND=" - test? ( - dev-python/pytest-timeout[${PYTHON_USEDEP}] - ) -" - -distutils_enable_tests pytest - -python_test() { - local -x PATH="${TEST_DIR}/scripts:${PATH}" \ - PYTHONPATH="${TEST_DIR}/lib" - - local deselect=( - # those tests fail on gcc newer than 5.8 - # https://github.com/gcovr/gcovr/issues/206 - gcovr/tests/test_gcovr.py - ) - - epytest gcovr ${deselect[@]/#/--deselect } -} diff --git a/dev-util/gcovr/gcovr-7.2.ebuild b/dev-util/gcovr/gcovr-7.2.ebuild deleted file mode 100644 index 8368a742ef0ba..0000000000000 --- a/dev-util/gcovr/gcovr-7.2.ebuild +++ /dev/null @@ -1,258 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DISTUTILS_USE_PEP517=setuptools -PYTHON_COMPAT=( python3_{10..12} ) - -inherit toolchain-funcs distutils-r1 - -DESCRIPTION="A Python script for summarizing gcov data" -HOMEPAGE="https://github.com/gcovr/gcovr" -SRC_URI="https://github.com/gcovr/gcovr/archive/${PV}.tar.gz -> ${P}.gh.tar.gz" - -LICENSE="BSD" -SLOT="0" -KEYWORDS="amd64 ~loong ~x86" - -RDEPEND=" - dev-python/jinja[${PYTHON_USEDEP}] - dev-python/lxml[${PYTHON_USEDEP}] - dev-python/colorlog[${PYTHON_USEDEP}] - dev-python/pygments[${PYTHON_USEDEP}] - dev-python/tomli[${PYTHON_USEDEP}] -" -BDEPEND=" - test? ( - dev-python/pytest-timeout[${PYTHON_USEDEP}] - dev-python/yaxmldiff[${PYTHON_USEDEP}] - ) -" - -distutils_enable_tests pytest - -python_test() { - local -x PATH="${TEST_DIR}/scripts:${PATH}" \ - PYTHONPATH="${TEST_DIR}/lib" - - # these tests assume gcc-8, and fail with newer gcc versions - local -a test_build_deselect=( - "add_coverages-coveralls" - "add_coverages-html" - "add_coverages-html" - "bad++char-coveralls" - "bad++char-html" - "calls-html" - "cmake_oos-coveralls" - "cmake_oos-html" - "cmake_oos_ninja-coveralls" - "cmake_oos_ninja-html" - "coexisting_object_directories-from_build_dir-cobertura" - "coexisting_object_directories-from_build_dir-html" - "coexisting_object_directories-from_build_dir-without_object_dir-cobertura" - "coexisting_object_directories-from_build_dir-without_object_dir-html" - "coexisting_object_directories-from_build_dir-without_object_dir-sonarqube" - "coexisting_object_directories-from_build_dir-without_object_dir-txt" - "coexisting_object_directories-from_build_dir-without_search_dir-cobertura" - "coexisting_object_directories-from_build_dir-without_search_dir-html" - "coexisting_object_directories-from_build_dir-without_search_dir-sonarqube" - "coexisting_object_directories-from_build_dir-without_search_dir-txt" - "coexisting_object_directories-from_root_dir-cobertura" - "coexisting_object_directories-from_root_dir-html" - "coexisting_object_directories-from_root_dir-without_object_dir-cobertura" - "coexisting_object_directories-from_root_dir-without_object_dir-html" - "coexisting_object_directories-from_root_dir-without_object_dir-sonarqube" - "coexisting_object_directories-from_root_dir-without_object_dir-txt" - "coexisting_object_directories-from_root_dir-without_search_dir-cobertura" - "coexisting_object_directories-from_root_dir-without_search_dir-html" - "coexisting_object_directories-from_root_dir-without_search_dir-sonarqube" - "coexisting_object_directories-from_root_dir-without_search_dir-txt" - "config-output-html" - "config-toml-html" - "config-toml-txt" - "decisions-html" - "decisions-json" - "decisions-neg-delta-html" - "different-function-lines-separate-coveralls" - "different-function-lines-separate-html" - "different-function-lines-use-0-coveralls" - "different-function-lines-use-0-html" - "different-function-lines-use-max-coveralls" - "different-function-lines-use-max-html" - "different-function-lines-use-min-coveralls" - "different-function-lines-use-min-html" - "dot-coveralls" - "dot-html" - "excl-branch-coveralls" - "excl-branch-html" - "excl-line-branch-coveralls" - "excl-line-branch-html" - "excl-line-coveralls" - "excl-line-custom-coveralls" - "excl-line-custom-html" - "excl-line-html" - "exclude-directories-relative-coveralls" - "exclude-directories-relative-html" - "exclude-lines-by-pattern-coveralls" - "exclude-lines-by-pattern-html" - "exclude-relative-coveralls" - "exclude-relative-from-unfiltered-tracefile-html" - "exclude-relative-html" - "exclude-throw-branches-cobertura" - "exclude-throw-branches-coveralls" - "exclude-throw-branches-html" - "exclude-throw-branches-jacoco" - "exclude-throw-branches-json" - "exclude-throw-branches-lcov" - "exclude-throw-branches-sonarqube" - "exclude-throw-branches-txt" - "filter-absolute-coveralls" - "filter-absolute-from-unfiltered-tracefile-html" - "filter-absolute-html" - "filter-relative-coveralls" - "filter-relative-from-unfiltered-tracefile-html" - "filter-relative-html" - "filter-relative-lib-coveralls" - "filter-relative-lib-from-unfiltered-tracefile-html" - "filter-relative-lib-html" - "html-css-html" - "html-default-html" - "html-encoding-cp1252-html" - "html-encoding-iso-8859-15-html" - "html-high-100-html" - "html-high-75-html" - "html-line-branch-html" - "html-medium-100-high-100-html" - "html-medium-50-html" - "html-nested-filter-html" - "html-nested-nonsort-html" - "html-nested-sort-casefold-html" - "html-nested-sort-percentage-html" - "html-nested-sort-uncovered-html" - "html-source-encoding-cp1252-html" - "html-source-encoding-utf8-html" - "html-tab-size-2-html" - "html-template-dir-html" - "html-themes-github-html" - "html-themes-html" - "html-title-html" - "linked-coveralls" - "linked-html" - "nested-coveralls" - "nested-html" - "nested2-coveralls" - "nested2-coveralls" - "nested2-html" - "nested2-html" - "nested2-use-existing-coveralls" - "nested2-use-existing-html" - "nested3-coveralls" - "no-markers-html" - "nobranch-coveralls" - "nobranch-html" - "noncode-coveralls" - "noncode-html" - "oos-coveralls" - "oos-html" - "oos2-coveralls" - "oos2-html" - "rounding-html" - "shadow-coveralls" - "shadow-html" - "shared_lib-coveralls" - "shared_lib-html" - "simple1-coveralls" - "simple1-dir-coveralls" - "simple1-dir-html" - "simple1-html" - "simple1-stdout-coveralls" - "simple1-stdout-html" - "sort-percentage-html" - "sort-uncovered-html" - "source_from_pipe-cobertura" - "source_from_pipe-coveralls" - "source_from_pipe-html" - "source_from_pipe-lcov" - "subfolder-includes-html" - "threaded-coveralls" - "threaded-html" - "update-data-coveralls" - "update-data-html" - "use-existing-coveralls" - "use-existing-html" - "wspace-coveralls" - "wspace-html" - ) - - local cc cc_ver - cc="$(tc-get-compiler-type)" - case "${cc}" in - gcc) - cc_ver="$(gcc-major-version)" - - # a bunch of tests are broken on gcc-14 - # https://bugs.gentoo.org/930680 - if [[ $(gcc-major-version) -ge 14 ]]; then - test_build_deselect+=( - "calls-json" - "decisions-neg-delta-json" - "different-function-lines-separate-lcov" - "different-function-lines-use-0-lcov" - "different-function-lines-use-max-lcov" - "different-function-lines-use-min-lcov" - "dot-lcov" - "excl-branch-lcov" - "excl-line-json" - "excl-line-lcov" - "excl-line-branch-lcov" - "excl-line-custom-lcov" - "exclude-directories-relative-lcov" - "exclude-lines-by-pattern-lcov" - "exclude-relative-lcov" - "exclude-relative-from-unfiltered-tracefile-lcov" - "filter-absolute-lcov" - "filter-absolute-from-unfiltered-tracefile-lcov" - "filter-relative-lcov" - "filter-relative-from-unfiltered-tracefile-lcov" - "filter-relative-lib-lcov" - "filter-relative-lib-from-unfiltered-tracefile-lcov" - "linked-lcov" - "nested-lcov" - "nested2-lcov" - "nested3-lcov" - "no-markers-json" - "no-markers-lcov" - "noncode-json" - "noncode-lcov" - "oos-lcov" - "oos2-lcov" - "shadow-json" - "simple1-txt" - "simple1-json" - "simple1-dir-json" - "simple1-stdout-json" - "simple1-stdout-lcov" - "threaded-lcov" - "update-data-lcov" - "wspace-lcov" - ) - fi - ;; - clang) cc_ver="$(clang-major-version)";; - # placeholder since tests need CC_REFERENCE to be string-number - *) cc_ver=1;; - esac - - readarray -t EPYTEST_DESELECT < <(printf 'gcovr/tests/test_gcovr.py::test_build[%s]\n' "${test_build_deselect[@]}") - - EPYTEST_DESELECT+=( - # tests that don't work in the ebuild environment - gcovr/tests/test_args.py::test_html_template_dir - gcovr/tests/test_args.py::test_multiple_output_formats_to_stdout - gcovr/tests/test_args.py::test_multiple_output_formats_to_stdout_1 - ) - local -x CC_REFERENCE="${cc}-${cc_ver}" - - epytest gcovr -} From 0bf450f5e4fae70aea1615b1ef6885e750c904c8 Mon Sep 17 00:00:00 2001 From: Eli Schwartz Date: Sun, 11 Aug 2024 20:59:12 -0400 Subject: [PATCH 02/21] games-simulation/flightgear: use https for git clones in live Using git:// is a really bad idea and the eclass yells at you for it. And the second uri does not actually exist (anymore). Note: the live ebuild still doesn't actually build. The patch is stale and then there are a bunch of weird "XXX does not name a type" and "YYY was not declared in this scope" errors that I have no patience to debug. Perhaps an upstream bug. I was able to determine that existing LTO errors are still present and then gave up. Baby steps... :D Signed-off-by: Eli Schwartz --- games-simulation/flightgear/flightgear-9999.ebuild | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/games-simulation/flightgear/flightgear-9999.ebuild b/games-simulation/flightgear/flightgear-9999.ebuild index b35e56b521a84..ec1215fc6d90a 100644 --- a/games-simulation/flightgear/flightgear-9999.ebuild +++ b/games-simulation/flightgear/flightgear-9999.ebuild @@ -7,8 +7,7 @@ inherit cmake toolchain-funcs git-r3 DESCRIPTION="Open Source Flight Simulator" HOMEPAGE="https://www.flightgear.org/" -EGIT_REPO_URI="git://git.code.sf.net/p/${PN}/${PN} - git://mapserver.flightgear.org/${PN}" +EGIT_REPO_URI="https://git.code.sf.net/p/${PN}/${PN}" EGIT_BRANCH="next" LICENSE="GPL-2" From 8d54fe01bba0a0402b0fef8e99974766cc1956c3 Mon Sep 17 00:00:00 2001 From: Eli Schwartz Date: Sun, 11 Aug 2024 21:00:58 -0400 Subject: [PATCH 03/21] dev-games/simgear: use https for git clones in live Using git:// is a really bad idea and the eclass yells at you for it. And the second uri does not actually exist (anymore). Signed-off-by: Eli Schwartz --- dev-games/simgear/simgear-9999.ebuild | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/dev-games/simgear/simgear-9999.ebuild b/dev-games/simgear/simgear-9999.ebuild index f86ab21c32aa0..a00bfb2e0bd78 100644 --- a/dev-games/simgear/simgear-9999.ebuild +++ b/dev-games/simgear/simgear-9999.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2022 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=7 @@ -7,8 +7,7 @@ inherit cmake toolchain-funcs git-r3 DESCRIPTION="Development library for simulation games" HOMEPAGE="https://www.flightgear.org/" -EGIT_REPO_URI="git://git.code.sf.net/p/flightgear/${PN} - git://mapserver.flightgear.org/${PN}" +EGIT_REPO_URI="https://git.code.sf.net/p/flightgear/${PN}" EGIT_BRANCH="next" LICENSE="GPL-2" From cdcfeb1855998c43033042d3980d38f5f695bd91 Mon Sep 17 00:00:00 2001 From: Eli Schwartz Date: Sun, 11 Aug 2024 21:08:47 -0400 Subject: [PATCH 04/21] games-simulation/flightgear: mark as LTO-unsafe Closes: https://bugs.gentoo.org/859217 Signed-off-by: Eli Schwartz --- games-simulation/flightgear/flightgear-2020.3.19.ebuild | 7 ++++++- games-simulation/flightgear/flightgear-9999.ebuild | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/games-simulation/flightgear/flightgear-2020.3.19.ebuild b/games-simulation/flightgear/flightgear-2020.3.19.ebuild index fffe97177e829..9d6373a47ddb9 100644 --- a/games-simulation/flightgear/flightgear-2020.3.19.ebuild +++ b/games-simulation/flightgear/flightgear-2020.3.19.ebuild @@ -3,7 +3,7 @@ EAPI=7 -inherit cmake toolchain-funcs +inherit cmake flag-o-matic toolchain-funcs DESCRIPTION="Open Source Flight Simulator" HOMEPAGE="https://www.flightgear.org/" @@ -79,6 +79,11 @@ pkg_setup() { } src_configure() { + # -Werror=lto-type-mismatch, -Werror=odr + # https://bugs.gentoo.org/859217 + # https://sourceforge.net/p/flightgear/codetickets/2908/ + filter-lto + local mycmakeargs=( -DBUILD_SHARED_LIBS=OFF -DENABLE_AUTOTESTING=OFF diff --git a/games-simulation/flightgear/flightgear-9999.ebuild b/games-simulation/flightgear/flightgear-9999.ebuild index ec1215fc6d90a..720c1042bbd6c 100644 --- a/games-simulation/flightgear/flightgear-9999.ebuild +++ b/games-simulation/flightgear/flightgear-9999.ebuild @@ -3,7 +3,7 @@ EAPI=7 -inherit cmake toolchain-funcs git-r3 +inherit cmake flag-o-matic toolchain-funcs git-r3 DESCRIPTION="Open Source Flight Simulator" HOMEPAGE="https://www.flightgear.org/" @@ -80,6 +80,11 @@ pkg_setup() { } src_configure() { + # -Werror=lto-type-mismatch, -Werror=odr + # https://bugs.gentoo.org/859217 + # https://sourceforge.net/p/flightgear/codetickets/2908/ + filter-lto + local mycmakeargs=( -DBUILD_SHARED_LIBS=OFF -DENABLE_AUTOTESTING=OFF From 5ea011f3d6691b8093be519474d3303ea388f260 Mon Sep 17 00:00:00 2001 From: Sam James Date: Mon, 12 Aug 2024 02:05:33 +0100 Subject: [PATCH 05/21] toolchain.eclass: add comment re GCC_TEST_RUN_EXPENSIVE Make clear it's not a typo as it comes from gcc's testsuite (could look like an accidental 'TEST' instead of 'TESTS' like the eclassvars we use for tests.) Signed-off-by: Sam James --- eclass/toolchain.eclass | 2 ++ 1 file changed, 2 insertions(+) diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass index 984c37a3fa734..b2d4692bc2e14 100644 --- a/eclass/toolchain.eclass +++ b/eclass/toolchain.eclass @@ -1920,6 +1920,8 @@ toolchain_src_test() { local -x LD_PRELOAD= # Controls running expensive tests in e.g. the torture testsuite. + # Note that 'TEST', not 'TESTS', is correct here as it's a GCC + # testsuite variable, not ours. local -x GCC_TEST_RUN_EXPENSIVE=1 # Use a subshell to allow meddling with flags just for the testsuite From 15ce82749db7922e462f900df9b7edbda37f152b Mon Sep 17 00:00:00 2001 From: Sam James Date: Mon, 12 Aug 2024 02:06:45 +0100 Subject: [PATCH 06/21] toolchain.eclass: don't pass user flags in src_test This is obvious in hindsight. The flags we were passing *precisely because* we wanted e.g. -Wno-format to be passed to every test also included -O2 or whatever from the user's flags which breaks tests that may require no optimisation and so on. Instead of trying to filter out options in a whack-a-mole game, let's introduce special GCC_TESTS_* *FLAGS variables which we append the needed -Wno-* to (etc.) which users can also specify if they really want or need to. Note that this isn't as scary or as weird as it sounds. We were only trying to jam these flags in **purely** to counteract some defaults we set, these tests really aren't supposed to be run with arbitrary flags stuck in, but a workaround we added started to introduce way more than intended. The torture tests are fine with being run with various optimisation flags but the rest of the testesuite isn't. This fixes 361c3758642891759b0ed60a8f96bc0776d19f15 and some of the attempts afterwards, although not everything in those commits was bad. Fixes: 361c3758642891759b0ed60a8f96bc0776d19f15 Signed-off-by: Sam James --- eclass/toolchain.eclass | 49 +++++++++++++++++++++++------------------ 1 file changed, 27 insertions(+), 22 deletions(-) diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass index b2d4692bc2e14..326daf66586ca 100644 --- a/eclass/toolchain.eclass +++ b/eclass/toolchain.eclass @@ -1941,15 +1941,19 @@ toolchain_src_test() { # Workaround our -Wformat-security default which breaks # various tests as it adds unexpected warning output. - append-flags -Wno-format-security -Wno-format + GCC_TESTS_CFLAGS+=" -Wno-format-security -Wno-format" + GCC_TESTS_CXXFLAGS+=" -Wno-format-security -Wno-format" + # Workaround our -Wtrampolines default which breaks # tests too. - append-flags -Wno-trampolines + GCC_TESTS_CFLAGS+=" -Wno-trampolines" + GCC_TESTS_CXXFLAGS+=" -Wno-trampolines" # A handful of Ada (and objc++?) tests need an executable stack - append-ldflags -Wl,--no-warn-execstack + GCC_TESTS_LDFLAGS+=" -Wl,--no-warn-execstack" # Avoid confusing tests like Fortran/C interop ones where # CFLAGS are used. - append-flags -Wno-complain-wrong-lang + GCC_TESTS_CFLAGS+=" -Wno-complain-wrong-lang" + GCC_TESTS_CXXFLAGS+=" -Wno-complain-wrong-lang" # Issues with Ada tests: # gnat.dg/align_max.adb @@ -1960,11 +1964,12 @@ toolchain_src_test() { # # TODO: This isn't ideal given it obv. affects codegen # and we want to be sure it works. - append-flags -fno-stack-clash-protection + GCC_TESTS_CFLAGS+=" -fno-stack-clash-protection" + GCC_TESTS_CXXFLAGS+=" -fno-stack-clash-protection" # configure defaults to '-O2 -g' and some tests expect it # accordingly. - append-flags -g + GCC_TESTS_CFLAGS+=" -g" # TODO: Does this handle s390 (-m31) correctly? # TODO: What if there are multiple ABIs like x32 too? @@ -1980,23 +1985,23 @@ toolchain_src_test() { nonfatal emake -C "${WORKDIR}"/build -k "${GCC_TESTS_CHECK_TARGET}" \ RUNTESTFLAGS=" \ ${GCC_TESTS_RUNTESTFLAGS} \ - CFLAGS_FOR_TARGET='${CFLAGS_FOR_TARGET:-${CFLAGS}}' \ - CXXFLAGS_FOR_TARGET='${CXXFLAGS_FOR_TARGET:-${CXXFLAGS}}' \ - LDFLAGS_FOR_TARGET='${LDFLAGS_FOR_TARGET:-${LDFLAGS}}' \ - CFLAGS='${CFLAGS}' \ - CXXFLAGS='${CXXFLAGS}' \ - FCFLAGS='${FCFLAGS}' \ - FFLAGS='${FFLAGS}' \ - LDFLAGS='${LDFLAGS}' \ + CFLAGS_FOR_TARGET='${GCC_TESTS_CFLAGS_FOR_TARGET:-${GCC_TESTS_CFLAGS}}' \ + CXXFLAGS_FOR_TARGET='${GCC_TESTS_CXXFLAGS_FOR_TARGET:-${GCC_TESTS_CXXFLAGS}}' \ + LDFLAGS_FOR_TARGET='${TEST_LDFLAGS_FOR_TARGET:-${GCC_TESTS_LDFLAGS}}' \ + CFLAGS='${GCC_TESTS_CFLAGS}' \ + CXXFLAGS='${GCC_TESTS_CXXFLAGS}' \ + FCFLAGS='${GCC_TESTS_FCFLAGS}' \ + FFLAGS='${GCC_TESTS_FFLAGS}' \ + LDFLAGS='${GCC_TESTS_LDFLAGS}' \ " \ - CFLAGS_FOR_TARGET="${CFLAGS_FOR_TARGET:-${CFLAGS}}" \ - CXXFLAGS_FOR_TARGET="${CXXFLAGS_FOR_TARGET:-${CXXFLAGS}}" \ - LDFLAGS_FOR_TARGET="${LDFLAGS_FOR_TARGET:-${LDFLAGS}}" \ - CFLAGS="${CFLAGS}" \ - CXXFLAGS="${CXXFLAGS}" \ - FCFLAGS="${FCFLAGS}" \ - FFLAGS="${FFLAGS}" \ - LDFLAGS="${LDFLAGS}" + CFLAGS_FOR_TARGET="${GCC_TESTS_CFLAGS_FOR_TARGET:-${GCC_TESTS_CFLAGS}}" \ + CXXFLAGS_FOR_TARGET="${GCC_TESTS_CXXFLAGS_FOR_TARGET:-${GCC_TESTS_CXXFLAGS}}" \ + LDFLAGS_FOR_TARGET="${GCC_TESTS_LDFLAGS_FOR_TARGET:-${GCC_TESTS_LDFLAGS}}" \ + CFLAGS="${GCC_TESTS_CFLAGS}" \ + CXXFLAGS="${GCC_TESTS_CXXFLAGS}" \ + FCFLAGS="${GCC_TESTS_FCFLAGS}" \ + FFLAGS="${GCC_TESTS_FFLAGS}" \ + LDFLAGS="${GCC_TESTS_LDFLAGS}" ) # Produce an updated failure manifest. From efff53996be8ae20f332867358fd1a3af83a1ee2 Mon Sep 17 00:00:00 2001 From: Sam James Date: Mon, 12 Aug 2024 02:10:10 +0100 Subject: [PATCH 07/21] toolchain.eclass: drop filter-flags from src_test This no longer does anything after the previous commit to use custom variables for flags for tests. Signed-off-by: Sam James --- eclass/toolchain.eclass | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass index 326daf66586ca..3cd3be676f9b6 100644 --- a/eclass/toolchain.eclass +++ b/eclass/toolchain.eclass @@ -1926,19 +1926,6 @@ toolchain_src_test() { # Use a subshell to allow meddling with flags just for the testsuite ( - # Unexpected warnings confuse the tests. - filter-flags -W* - # May break parsing. - filter-flags '-fdiagnostics-color=*' '-fdiagnostics-urls=*' - # Gentoo QA flags which don't belong in tests - filter-flags -frecord-gcc-switches - filter-flags '-Wl,--defsym=__gentoo_check_ldflags__=0' - # Go doesn't support this and causes noisy warnings - filter-flags -Wbuiltin-declaration-mismatch - # The ASAN tests at least need LD_PRELOAD and the contract - # tests. - filter-flags -fno-semantic-interposition - # Workaround our -Wformat-security default which breaks # various tests as it adds unexpected warning output. GCC_TESTS_CFLAGS+=" -Wno-format-security -Wno-format" From eb9d324cb45589e287e6cce64f3110acccf1e47c Mon Sep 17 00:00:00 2001 From: Sam James Date: Mon, 12 Aug 2024 02:18:07 +0100 Subject: [PATCH 08/21] toolchain.eclass: add TODO re flags for building deps in src_test Signed-off-by: Sam James --- eclass/toolchain.eclass | 3 +++ 1 file changed, 3 insertions(+) diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass index 3cd3be676f9b6..ac236f3127f99 100644 --- a/eclass/toolchain.eclass +++ b/eclass/toolchain.eclass @@ -1969,6 +1969,9 @@ toolchain_src_test() { # # CFLAGS and so on are repeated here because of tests vs building test # deps like libbacktrace. + # + # TODO: Should we try pass in the regular user flags for the non-RUNTESTFLAGS + # instances below for building e.g. libbacktrace? nonfatal emake -C "${WORKDIR}"/build -k "${GCC_TESTS_CHECK_TARGET}" \ RUNTESTFLAGS=" \ ${GCC_TESTS_RUNTESTFLAGS} \ From b8247f2bb4971d1b3525bdcc25e5b316909676ef Mon Sep 17 00:00:00 2001 From: Filip Kobierski Date: Tue, 30 Jul 2024 15:09:57 +0200 Subject: [PATCH 09/21] sys-apps/mcstrans: drop 3.5 Signed-off-by: Filip Kobierski Signed-off-by: Jason Zaman --- sys-apps/mcstrans/Manifest | 1 - sys-apps/mcstrans/mcstrans-3.5.ebuild | 52 --------------------------- 2 files changed, 53 deletions(-) delete mode 100644 sys-apps/mcstrans/mcstrans-3.5.ebuild diff --git a/sys-apps/mcstrans/Manifest b/sys-apps/mcstrans/Manifest index d137545f54615..61ae8187f4948 100644 --- a/sys-apps/mcstrans/Manifest +++ b/sys-apps/mcstrans/Manifest @@ -1,3 +1,2 @@ -DIST mcstrans-3.5.tar.gz 45091 BLAKE2B c6604075a6b37d7bf10e2daee40d9f034a26c5d56b81973cbc3b39621bdf5e2cb1d5906e91942e09ff077a14facafcc2464995675d8df31930707033fac5db90 SHA512 f4d3b04750e197c6abd31f1642af4b53a4fe0e968952a7ade992909f903d7486c1e72733963453563fcbc9745273c8238f169f520550df1470e7f6e4d6e56665 DIST mcstrans-3.6.tar.gz 42199 BLAKE2B 0f1b4ed212994037b062c42887e2629ae7374e0cbbd79692588ce164440eafddc6d7ab15d58f6064d68781a5a8fd614c9cfa734c4dbe1d3fea1dbb0f8191ddc1 SHA512 2c01a70741675faa41e8a9243f3cf08b558e568d7ae343874ff9c269473ba2748d42e0b45871d82d6c9b01bf71547835d547683f1aa5a8cf626708c7c69569fc DIST mcstrans-3.7.tar.gz 42501 BLAKE2B b1112a5098a6681ade55e9fada8b0e4629bda8ff4334242b570bc042113204374bd2ca72face7fd7bc0958981a3c39284fa953a02e0860c4101e966f77f7e49a SHA512 51483ce4fd0b0a4bcba0d52eb418aa56104732888782f32c27a855c167cdb267de22eeb414ad8c6b2e733620c3e59db39646136c97f7bcb8901ce12fed44583a diff --git a/sys-apps/mcstrans/mcstrans-3.5.ebuild b/sys-apps/mcstrans/mcstrans-3.5.ebuild deleted file mode 100644 index 641549bb91e30..0000000000000 --- a/sys-apps/mcstrans/mcstrans-3.5.ebuild +++ /dev/null @@ -1,52 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" - -inherit toolchain-funcs - -MY_PV="${PV//_/-}" -MY_P="${PN}-${MY_PV}" - -DESCRIPTION="SELinux context translation to human readable names" -HOMEPAGE="https://github.com/SELinuxProject/selinux/wiki" - -if [[ ${PV} == *9999 ]] ; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/SELinuxProject/selinux.git" - S="${WORKDIR}/${P}/${PN}" -else - SRC_URI="https://github.com/SELinuxProject/selinux/releases/download/${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="amd64 arm arm64 ~mips x86" - S="${WORKDIR}/${MY_P}" -fi - -LICENSE="GPL-2" -SLOT="0" -IUSE="" - -DEPEND=">=sys-libs/libsepol-${PV}:=[static-libs(+)] - >=sys-libs/libselinux-${PV}:= - dev-libs/libpcre2:= - >=sys-libs/libcap-1.10-r10:=" - -RDEPEND="${DEPEND}" - -src_prepare() { - default - - sed -i 's/-Werror//g' "${S}"/*/Makefile || die "Failed to remove Werror" -} - -src_compile() { - tc-export CC - default -} - -src_install() { - emake DESTDIR="${D}" install - - rm -rf "${D}/etc/rc.d" || die - - newinitd "${FILESDIR}/mcstransd.init" mcstransd -} From d20d0a2a4e2f23a75ee4c131f4c0b027e9f0727b Mon Sep 17 00:00:00 2001 From: Filip Kobierski Date: Tue, 30 Jul 2024 15:06:36 +0200 Subject: [PATCH 10/21] sys-apps/restorecond: drop 3.5 Signed-off-by: Filip Kobierski Signed-off-by: Jason Zaman --- sys-apps/restorecond/Manifest | 1 - sys-apps/restorecond/restorecond-3.5.ebuild | 54 --------------------- 2 files changed, 55 deletions(-) delete mode 100644 sys-apps/restorecond/restorecond-3.5.ebuild diff --git a/sys-apps/restorecond/Manifest b/sys-apps/restorecond/Manifest index 68daa3551b549..270d7a4f56a30 100644 --- a/sys-apps/restorecond/Manifest +++ b/sys-apps/restorecond/Manifest @@ -1,3 +1,2 @@ -DIST restorecond-3.5.tar.gz 19070 BLAKE2B 6db7d0fc9085a07669d346e025836a94acca610572e986e2c90974b0bd21b55e66b57a2dafd7d42011bed5f06363b654f5431ac43530fccf7b68d3edd9d63850 SHA512 80cb84e62c7072a12fe57ebaafc0bcb441c853862c67f9ea35b86faa2d8e49ea22a70b9e05a3ff24e8ce08ca2999604d7961efd534f89167cd6fcb05c852de40 DIST restorecond-3.6.tar.gz 18020 BLAKE2B 306b4a7c9990c0b2f229cc7963dbd0481df5f9fbecd709b37d254839177fc604f6f85ac19235209f4fbb12d9186f01dd71a11f98deca5d01bd70c415240ddf5a SHA512 e21fa23bfea488f2bddd01b4bab353f22863e09247078e47db9852995d7a0153aee6483cbeaaaf033b482b60f80affad0b6a3e829f935c3901c034a7efb1ebef DIST restorecond-3.7.tar.gz 18072 BLAKE2B 3f352345fa169a438fd6dc073d329c68aca67b3c49d100b1dc619ae40eae3764fa07327306ec0f1232450433e27908493711cc6aec20ebb60f2b66dbceed0cb8 SHA512 6b0ed20a5d6654281cae78a337254558a2170040f09c1f7ba023b40cf2a5b33b36d6f3c57d9e32d55523fbe78a8b212c0de377ce201778e2211aa37dc0b2b936 diff --git a/sys-apps/restorecond/restorecond-3.5.ebuild b/sys-apps/restorecond/restorecond-3.5.ebuild deleted file mode 100644 index 010553a8791dc..0000000000000 --- a/sys-apps/restorecond/restorecond-3.5.ebuild +++ /dev/null @@ -1,54 +0,0 @@ -# Copyright 1999-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" - -inherit systemd toolchain-funcs - -MY_PV="${PV//_/-}" -MY_P="${PN}-${MY_PV}" - -if [[ ${PV} == *9999 ]] ; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/SELinuxProject/selinux.git" - S="${WORKDIR}/${P}/${PN}" -else - SRC_URI="https://github.com/SELinuxProject/selinux/releases/download/${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="amd64 arm arm64 ~mips x86" - S="${WORKDIR}/${MY_P}" -fi - -DESCRIPTION="Daemon to watch for creation and set default SELinux fcontexts" -HOMEPAGE="https://github.com/SELinuxProject/selinux/wiki" - -LICENSE="GPL-2" -SLOT="0" -IUSE="" - -DEPEND="dev-libs/glib:2 - >=sys-libs/libsepol-${PV}:= - >=sys-libs/libselinux-${PV}:=" - -RDEPEND="${DEPEND}" - -src_prepare() { - default - - sed -i 's/-Werror//g' "${S}"/Makefile || die "Failed to remove Werror" -} - -src_compile() { - tc-export CC - default -} - -src_install() { - emake DESTDIR="${D}" \ - SYSTEMDSYSTEMUNITDIR="$(systemd_get_systemunitdir)" \ - SYSTEMDUSERUNITDIR=$(systemd_get_userunitdir) \ - install - - rm -rf "${D}/etc/rc.d" || die - - newinitd "${FILESDIR}/restorecond.init" restorecond -} From 8803694d433296304821e7432152779252de35db Mon Sep 17 00:00:00 2001 From: Filip Kobierski Date: Tue, 30 Jul 2024 15:04:42 +0200 Subject: [PATCH 11/21] sys-apps/semodule-utils: drop 3.5 Signed-off-by: Filip Kobierski Signed-off-by: Jason Zaman --- sys-apps/semodule-utils/Manifest | 1 - .../semodule-utils/semodule-utils-3.5.ebuild | 43 ------------------- 2 files changed, 44 deletions(-) delete mode 100644 sys-apps/semodule-utils/semodule-utils-3.5.ebuild diff --git a/sys-apps/semodule-utils/Manifest b/sys-apps/semodule-utils/Manifest index 8e4644e36f7d1..72580447cbc4b 100644 --- a/sys-apps/semodule-utils/Manifest +++ b/sys-apps/semodule-utils/Manifest @@ -1,3 +1,2 @@ -DIST semodule-utils-3.5.tar.gz 14383 BLAKE2B a1bb432013bca1023d99b32f43b2c972b6b807a4677f9d8c9fb9aff10225232506f3ecca86fc231b4c63d04582a91a1c4218f87ce5532a4d35a26a09665c6f10 SHA512 7c32f425ae71745040d1c6a6585149a1efb319913aa9d4c8bf185b0a4216dc66378fa38595b171614ee3ae4ade997d3ae56a060346e334faec55c419a87d71dd DIST semodule-utils-3.6.tar.gz 12844 BLAKE2B e5e7501c412649f471e89cc89569d6c51421e0b46f172f243ce778bbe3a2c658ef9a92e3f3e1e07fb3358e25f63e004b6bd4b56619472fbcae8cb5b916d54170 SHA512 16b58bbafcaef9a2e8e34a20d0e1e4024a9044024de8fa3137c5ba1b9af600afac51c15ccb648dd6bff77747c047f4c9feafeea07c19b1eb14955acc92697a48 DIST semodule-utils-3.7.tar.gz 12896 BLAKE2B 7487c74585e281f6c44e9977efb85e89bf01d93285c6cc6593dd876e948cc385ec9f11b52f3fc182b2bac3621bcc89c53fc217c41b1a01d586274139b0a40fa6 SHA512 133f76ddff0cc4121e59560f4167e15288cc7f6172a39b49ea631803f6e3365fef95166a55498fa2e036de85466e37bb6ec164ef60855eef8c888c9b384b0120 diff --git a/sys-apps/semodule-utils/semodule-utils-3.5.ebuild b/sys-apps/semodule-utils/semodule-utils-3.5.ebuild deleted file mode 100644 index b67d886e7b9cc..0000000000000 --- a/sys-apps/semodule-utils/semodule-utils-3.5.ebuild +++ /dev/null @@ -1,43 +0,0 @@ -# Copyright 1999-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" - -inherit toolchain-funcs - -MY_PV="${PV//_/-}" -MY_P="${PN}-${MY_PV}" - -DESCRIPTION="SELinux policy module utilities" -HOMEPAGE="https://github.com/SELinuxProject/selinux/wiki" - -if [[ ${PV} == *9999 ]] ; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/SELinuxProject/selinux.git" - S="${WORKDIR}/${P}/${PN}" -else - SRC_URI="https://github.com/SELinuxProject/selinux/releases/download/${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="amd64 arm arm64 ~mips x86" - S="${WORKDIR}/${MY_P}" -fi - -LICENSE="GPL-2" -SLOT="0" -IUSE="" - -DEPEND=">=sys-libs/libsepol-${PV}:=" -RDEPEND="${DEPEND}" - -src_prepare() { - default - - sed -i 's/-Werror//g' "${S}"/*/Makefile || die "Failed to remove Werror" -} - -src_compile() { - emake CC="$(tc-getCC)" -} - -src_install() { - emake DESTDIR="${D}" install -} From 4ed3fbd9c91d8d6996644faffec4b894eacec33a Mon Sep 17 00:00:00 2001 From: Jason Zaman Date: Sun, 11 Aug 2024 16:58:43 -0700 Subject: [PATCH 12/21] sys-apps/secilc: drop 3.5 Signed-off-by: Jason Zaman --- sys-apps/secilc/Manifest | 1 - sys-apps/secilc/secilc-3.5.ebuild | 37 ------------------------------- 2 files changed, 38 deletions(-) delete mode 100644 sys-apps/secilc/secilc-3.5.ebuild diff --git a/sys-apps/secilc/Manifest b/sys-apps/secilc/Manifest index be70f2c54d395..9f2038f9dffaf 100644 --- a/sys-apps/secilc/Manifest +++ b/sys-apps/secilc/Manifest @@ -1,3 +1,2 @@ -DIST secilc-3.5.tar.gz 180803 BLAKE2B a42620318b312a5ef35565e3b40a89fd7ff44aaf73de835bc349f927193121b72c07bd2151a8a6b2cee53e2699a3ae6bb246084e18a181d334ebc082fdfdc56e SHA512 eff37a981072c4b9c7c15bf4709db8797d8af5325883515f5c2fe611136b24419f6d01c797e4f131c9c08e1ba40576fcb2094b1e34325aae8351b6299bdba3dd DIST secilc-3.6.tar.gz 185186 BLAKE2B 47fdc281cad69339eb23226a277df8c8086557fe3a2c7f013eef38bbfcd62584e318ce2d79552388617687b39c37e67a1328b808becbecad364253b7527d3a52 SHA512 91381aae1444822c7897729c1695ca221a4226dcec042b2223a55800d1247510ef2033b844d8d0627623fb15b8169a626fb0ca2efeee8090635219c4139eabf5 DIST secilc-3.7.tar.gz 185694 BLAKE2B c7bdfb01bc23008c5f360aeae9473db096a62ba535b2ec54d8f4ec766495f6de2642656c52d5ca8d28335e84bc42e76c9d5294db73a588aa4bceda8f3d59f814 SHA512 1f6061587242b63583370e04cc113b4884060c6071774b90908655df17ddc702187960d1f5b1ed53de9eb6ebd7f0029160e58d8c5f0c1126464bf6222f6f7d3e diff --git a/sys-apps/secilc/secilc-3.5.ebuild b/sys-apps/secilc/secilc-3.5.ebuild deleted file mode 100644 index a61159147c34f..0000000000000 --- a/sys-apps/secilc/secilc-3.5.ebuild +++ /dev/null @@ -1,37 +0,0 @@ -# Copyright 1999-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" -inherit toolchain-funcs - -MY_PV="${PV//_/-}" -MY_P="${PN}-${MY_PV}" - -DESCRIPTION="SELinux Common Intermediate Language (CIL) Compiler" -HOMEPAGE="https://github.com/SELinuxProject/selinux/wiki" - -if [[ ${PV} == 9999 ]]; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/SELinuxProject/selinux.git" - S="${WORKDIR}/${P}/${PN}" -else - SRC_URI="https://github.com/SELinuxProject/selinux/releases/download/${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="amd64 arm arm64 x86" - S="${WORKDIR}/${MY_P}" -fi - -LICENSE="GPL-2" -SLOT="0" - -DEPEND=">=sys-libs/libsepol-${PV}" -RDEPEND="${DEPEND}" -BDEPEND="app-text/xmlto" - -# tests are not meant to be run outside of the -# full SELinux userland repo -RESTRICT="test" - -src_compile() { - tc-export CC - default -} From c60876e98e4a3e0690d8aae39791ddd4c0c9c5f1 Mon Sep 17 00:00:00 2001 From: Jason Zaman Date: Sun, 11 Aug 2024 17:00:38 -0700 Subject: [PATCH 13/21] sys-apps/policycoreutils: drop 3.5 Signed-off-by: Jason Zaman --- sys-apps/policycoreutils/Manifest | 1 - .../policycoreutils-3.5.ebuild | 168 ------------------ 2 files changed, 169 deletions(-) delete mode 100644 sys-apps/policycoreutils/policycoreutils-3.5.ebuild diff --git a/sys-apps/policycoreutils/Manifest b/sys-apps/policycoreutils/Manifest index 6bc51afcdd254..65e7ebd2adf11 100644 --- a/sys-apps/policycoreutils/Manifest +++ b/sys-apps/policycoreutils/Manifest @@ -1,4 +1,3 @@ -DIST policycoreutils-3.5.tar.gz 775639 BLAKE2B 777b8564484e89385db7a184c4cad9a99aabf1fd1ac41abd5826c7e6ad29118ae9d6f0d0fd968b6ced87f2f04bc6d7cd207b67428151522915367f656fb8d3f8 SHA512 7978ef6b7a278c6384c9b397734d03c4932c8aefecceaa1e6a1345be27b253dbe276fdcd219ce83ad732c6ed55d53bbc3254e39bccadd67d2cd1152a14749444 DIST policycoreutils-3.6.tar.gz 755682 BLAKE2B a8b180c8006989192d152651dcfa51856956780bfe1139cc1dc0162eb66ba1eef4f7d64f68a48479572b02e2e97a68c7082722a745d22a9453e8378373319e3c SHA512 e1f32e6e0310b879a5aadab157b103314a61bf3b8fd59c1212d701fbf39900e3b9a0b727338988103d784a7e505355a871ba519dd91520b135a3b9dae40bf1b0 DIST policycoreutils-3.7.tar.gz 757142 BLAKE2B 95794d48ef80882803199af5330f0ac4f1cee6710562a559e3d8fd94475d117286f8b612ffc5dc9027f4f8f4cd55e82ddb4d328e91d6c9846b18460c9bee159b SHA512 30e3413b15df0bf1a994d2b3a03a719f89b3ee521a708b92fcc684822152145722cb3ef28fd5b7c42b779281b0bd4d69d65c0bc2605eec1af3f388609d985500 DIST policycoreutils-extra-1.37.tar.bz2 8809 BLAKE2B a7f6122c2e27f54b018174e962bd7f4c14af04e09bbb5300bde6967ea7f2dc5cd03b5787919a4e7f5288bcbc6747922962b5bd3b588ab1e3a035fbff4910d8f5 SHA512 0a85cd7cf279256b5e1927f9dfdd89626a1c8b77b0aeb62b496e7e8d1dccbaa315e39f9308fb2df7270f0bc1c10787b19990e7365cad74b47b61e30394c8b23f diff --git a/sys-apps/policycoreutils/policycoreutils-3.5.ebuild b/sys-apps/policycoreutils/policycoreutils-3.5.ebuild deleted file mode 100644 index 5d45077b38c60..0000000000000 --- a/sys-apps/policycoreutils/policycoreutils-3.5.ebuild +++ /dev/null @@ -1,168 +0,0 @@ -# Copyright 1999-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" -PYTHON_COMPAT=( python3_{9..11} ) -PYTHON_REQ_USE="xml(+)" - -inherit multilib python-r1 toolchain-funcs bash-completion-r1 - -MY_PV="${PV//_/-}" -MY_P="${PN}-${MY_PV}" -EXTRAS_VER="1.37" - -DESCRIPTION="SELinux core utilities" -HOMEPAGE="https://github.com/SELinuxProject/selinux/wiki" - -if [[ ${PV} == 9999 ]]; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/SELinuxProject/selinux.git" - SRC_URI="https://dev.gentoo.org/~perfinion/distfiles/policycoreutils-extra-${EXTRAS_VER}.tar.bz2" - S1="${WORKDIR}/${P}/${PN}" - S2="${WORKDIR}/policycoreutils-extra" - S="${S1}" -else - SRC_URI="https://github.com/SELinuxProject/selinux/releases/download/${MY_PV}/${MY_P}.tar.gz - https://dev.gentoo.org/~perfinion/distfiles/policycoreutils-extra-${EXTRAS_VER}.tar.bz2" - KEYWORDS="amd64 arm arm64 ~mips x86" - S1="${WORKDIR}/${MY_P}" - S2="${WORKDIR}/policycoreutils-extra" - S="${S1}" -fi - -LICENSE="GPL-2" -SLOT="0" -IUSE="audit pam split-usr" -REQUIRED_USE="${PYTHON_REQUIRED_USE}" - -DEPEND=">=sys-libs/libselinux-${PV}:=[python,${PYTHON_USEDEP}] - >=sys-libs/libsemanage-${PV}:=[python(+),${PYTHON_USEDEP}] - >=sys-libs/libsepol-${PV}:= - sys-libs/libcap-ng:= - >=app-admin/setools-4.2.0[${PYTHON_USEDEP}] - audit? ( >=sys-process/audit-1.5.1[python,${PYTHON_USEDEP}] ) - pam? ( sys-libs/pam:= ) - ${PYTHON_DEPS}" - -# Avoid dependency loop in the cross-compile case, bug #755173 -# (Still exists in native) -BDEPEND="sys-devel/gettext" - -# pax-utils for scanelf used by rlpkg -RDEPEND="${DEPEND} - app-misc/pax-utils" - -PDEPEND="sys-apps/semodule-utils - sys-apps/selinux-python" - -src_unpack() { - # Override default one because we need the SRC_URI ones even in case of 9999 ebuilds - default - if [[ ${PV} == 9999 ]] ; then - git-r3_src_unpack - fi -} - -src_prepare() { - S="${S1}" - cd "${S}" || die "Failed to switch to ${S}" - if [[ ${PV} != 9999 ]] ; then - # If needed for live ebuilds please use /etc/portage/patches - eapply "${FILESDIR}/policycoreutils-3.1-0001-newrole-not-suid.patch" - fi - - # rlpkg is more useful than fixfiles - sed -i -e '/^all/s/fixfiles//' "${S}/scripts/Makefile" \ - || die "fixfiles sed 1 failed" - sed -i -e '/fixfiles/d' "${S}/scripts/Makefile" \ - || die "fixfiles sed 2 failed" - - eapply_user - - sed -i 's/-Werror//g' "${S1}"/*/Makefile || die "Failed to remove Werror" - - python_copy_sources - # Our extra code is outside the regular directory, so set it to the extra - # directory. We really should optimize this as it is ugly, but the extra - # code is needed for Gentoo at the same time that policycoreutils is present - # (so we cannot use an additional package for now). - S="${S2}" - python_copy_sources -} - -src_compile() { - building() { - emake -C "${BUILD_DIR}" \ - AUDIT_LOG_PRIVS="y" \ - AUDITH="$(usex audit y n)" \ - PAMH="$(usex pam y n)" \ - SESANDBOX="n" \ - CC="$(tc-getCC)" \ - LIBDIR="\$(PREFIX)/$(get_libdir)" - } - S="${S1}" # Regular policycoreutils - python_foreach_impl building - S="${S2}" # Extra set - python_foreach_impl building -} - -src_install() { - # Python scripts are present in many places. There are no extension modules. - installation-policycoreutils() { - einfo "Installing policycoreutils" - emake -C "${BUILD_DIR}" DESTDIR="${D}" \ - AUDIT_LOG_PRIVS="y" \ - AUDITH="$(usex audit y n)" \ - PAMH="$(usex pam y n)" \ - SESANDBOX="n" \ - CC="$(tc-getCC)" \ - LIBDIR="\$(PREFIX)/$(get_libdir)" \ - install - python_optimize - } - - installation-extras() { - einfo "Installing policycoreutils-extra" - emake -C "${BUILD_DIR}" \ - DESTDIR="${D}" \ - install - python_optimize - } - - S="${S1}" # policycoreutils - python_foreach_impl installation-policycoreutils - S="${S2}" # extras - python_foreach_impl installation-extras - S="${S1}" # back for later - - # remove redhat-style init script - rm -fR "${D}/etc/rc.d" || die - - # compatibility symlinks - if use split-usr; then - dosym ../../sbin/setfiles /usr/sbin/setfiles - else - # remove sestatus symlink - rm -f "${D}"/usr/sbin/sestatus || die - fi - - bashcomp_alias setsebool getsebool - - # location for policy definitions - dodir /var/lib/selinux - keepdir /var/lib/selinux - - # Set version-specific scripts - for pyscript in rlpkg; do - python_replicate_script "${ED}/usr/sbin/${pyscript}" - done -} - -pkg_postinst() { - for POLICY_TYPE in ${POLICY_TYPES} ; do - # There have been some changes to the policy store, rebuilding now. - # https://marc.info/?l=selinux&m=143757277819717&w=2 - einfo "Rebuilding store ${POLICY_TYPE} in '${ROOT:-/}' (without re-loading)." - semodule -p "${ROOT:-/}" -s "${POLICY_TYPE}" -n -B || die "Failed to rebuild policy store ${POLICY_TYPE}" - done -} From 0011c69be710c02fa4c03e213aa8a6d849b94903 Mon Sep 17 00:00:00 2001 From: Jason Zaman Date: Sun, 11 Aug 2024 17:02:45 -0700 Subject: [PATCH 14/21] sys-apps/selinux-python: drop 3.5 Signed-off-by: Jason Zaman --- sys-apps/selinux-python/Manifest | 1 - .../selinux-python/selinux-python-3.5.ebuild | 114 ------------------ 2 files changed, 115 deletions(-) delete mode 100644 sys-apps/selinux-python/selinux-python-3.5.ebuild diff --git a/sys-apps/selinux-python/Manifest b/sys-apps/selinux-python/Manifest index 2891961c7ef03..00d542eb53737 100644 --- a/sys-apps/selinux-python/Manifest +++ b/sys-apps/selinux-python/Manifest @@ -1,3 +1,2 @@ -DIST selinux-python-3.5.tar.gz 3604439 BLAKE2B 5a7fcd303c337cb0f5ae0066d13c945bb5cacaba472c7b17f0496295294998fcc6d81c153720ef704b749a01590c28b48b4f471a48fc386b8f02564c3550250b SHA512 2ac176a9f078f2b2721e5871ba21e92041eed54fc692fd8d809ff14327beee6de63b3084d0f1053a640b9e40bcc6461498915bb9b038a658cd772f77d80fd217 DIST selinux-python-3.6.tar.gz 3633272 BLAKE2B c2b99779eda2c7698f7f68740e3136cbfa5ab471a5d154142aafd2694d8c32aa605df3609a3667c687449d3ba44e72bcc3b37c36adecba8e34fcc629b9f04de5 SHA512 6289f3f2a3038b2cb62f6b3b12c729a9981c34a5ee80c0830e6316e8c77f5283dffa46007f6e7dc073332b829ed9953ba54e64c986fb18c7dc40759ec0375dc9 DIST selinux-python-3.7.tar.gz 3652377 BLAKE2B 59fd7cab0034c175f42f6120ba665701945adcbd4e8af97a0dc2a1c79688a596b199528886ceea079a3f7a969258611fb660449d313d9e893de381293e786381 SHA512 036bc1f0e64cbbaade592dc7899a92765a0bac426140d7d3960f73bad6eb5f95d79d91e0f0e1604f88a991ebf59c4c90ccaaa4158f5dc4d3275ca2aed1673b09 diff --git a/sys-apps/selinux-python/selinux-python-3.5.ebuild b/sys-apps/selinux-python/selinux-python-3.5.ebuild deleted file mode 100644 index 9fa9dc5ecf0f3..0000000000000 --- a/sys-apps/selinux-python/selinux-python-3.5.ebuild +++ /dev/null @@ -1,114 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 -PYTHON_COMPAT=( python3_{9..11} ) -PYTHON_REQ_USE="xml(+)" - -inherit python-r1 toolchain-funcs - -MY_PV="${PV//_/-}" -MY_P="${PN}-${MY_PV}" - -DESCRIPTION="SELinux core utilities" -HOMEPAGE="https://github.com/SELinuxProject/selinux/wiki" - -if [[ ${PV} == 9999 ]] ; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/SELinuxProject/selinux.git" - S="${WORKDIR}/${P}/${PN#selinux-}" -else - SRC_URI="https://github.com/SELinuxProject/selinux/releases/download/${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="amd64 arm arm64 ~mips x86" - S="${WORKDIR}/${MY_P}" -fi - -LICENSE="GPL-2" -SLOT="0" -IUSE="test" -RESTRICT="!test? ( test )" -REQUIRED_USE="${PYTHON_REQUIRED_USE}" - -RDEPEND=">=sys-libs/libselinux-${PV}:=[python] - >=sys-libs/libsemanage-${PV}:=[python(+)] - >=sys-libs/libsepol-${PV}:=[static-libs(+)] - >=app-admin/setools-4.2.0[${PYTHON_USEDEP}] - >=sys-process/audit-1.5.1[python,${PYTHON_USEDEP}] - ${PYTHON_DEPS}" -DEPEND="${RDEPEND}" -BDEPEND=" - test? ( - ${RDEPEND} - >=sys-apps/secilc-${PV} - )" - -src_prepare() { - default - sed -i 's/-Werror//g' "${S}"/*/Makefile || die "Failed to remove Werror" - - python_copy_sources -} - -src_compile() { - building() { - emake -C "${BUILD_DIR}" \ - CC="$(tc-getCC)" \ - LIBDIR="\$(PREFIX)/$(get_libdir)" - } - python_foreach_impl building -} - -src_test() { - testing() { - # The different subprojects have some interproject dependencies: - # - audit2allow depens on sepolgen - # - chcat depends on semanage - # and maybe others. - # Add all the modules of the individual subprojects to the - # PYTHONPATH, so they get actually found and used. In - # particular, already installed versions on the system are not - # used. - for dir in audit2allow chcat semanage sepolgen/src sepolicy ; do - PYTHONPATH="${BUILD_DIR}/${dir}:${PYTHONPATH}" - done - PYTHONPATH=${PYTHONPATH} \ - emake -C "${BUILD_DIR}" \ - test - } - python_foreach_impl testing -} - -src_install() { - installation() { - emake -C "${BUILD_DIR}" \ - DESTDIR="${D}" \ - LIBDIR="\$(PREFIX)/$(get_libdir)" \ - install - python_optimize - } - python_foreach_impl installation - - # Set version-specific scripts - for pyscript in audit2allow sepolgen-ifgen sepolicy chcat; do - python_replicate_script "${ED}/usr/bin/${pyscript}" - done - for pyscript in semanage; do - python_replicate_script "${ED}/usr/sbin/${pyscript}" - done - - # Create sepolgen.conf with different devel location definition - mkdir -p "${D}"/etc/selinux || die "Failed to create selinux directory"; - if [[ -f /etc/selinux/config ]]; - then - local selinuxtype=$(awk -F'=' '/^SELINUXTYPE/ {print $2}' /etc/selinux/config); - echo "SELINUX_DEVEL_PATH=/usr/share/selinux/${selinuxtype}/include:/usr/share/selinux/${selinuxtype}" > "${D}"/etc/selinux/sepolgen.conf; - else - local selinuxtype="${POLICY_TYPES%% *}"; - if [[ -n "${selinuxtype}" ]]; - then - echo "SELINUX_DEVEL_PATH=/usr/share/selinux/${selinuxtype}/include:/usr/share/selinux/${selinuxtype}" > "${D}"/etc/selinux/sepolgen.conf; - else - echo "SELINUX_DEVEL_PATH=/usr/share/selinux/strict/include:/usr/share/selinux/strict" > "${D}"/etc/selinux/sepolgen.conf; - fi - fi -} From 62560fb10e03bb9c299cba031e74a55a6a5a767e Mon Sep 17 00:00:00 2001 From: Jason Zaman Date: Sun, 11 Aug 2024 17:04:01 -0700 Subject: [PATCH 15/21] sys-apps/checkpolicy: drop 3.5 Signed-off-by: Jason Zaman --- sys-apps/checkpolicy/Manifest | 1 - sys-apps/checkpolicy/checkpolicy-3.5.ebuild | 53 --------------------- 2 files changed, 54 deletions(-) delete mode 100644 sys-apps/checkpolicy/checkpolicy-3.5.ebuild diff --git a/sys-apps/checkpolicy/Manifest b/sys-apps/checkpolicy/Manifest index de87eb345ea38..8507bbc18d9af 100644 --- a/sys-apps/checkpolicy/Manifest +++ b/sys-apps/checkpolicy/Manifest @@ -1,3 +1,2 @@ -DIST checkpolicy-3.5.tar.gz 69904 BLAKE2B e02ccad07534568a1bbb612330018bbe486800ea40df20ed6f9dc38c88aff7f8858782a28ba7915a58c3bb384f180eb8da7a8fe97a92bcb9baa61eec18da6cbc SHA512 fcd490d865af3b4350c32c5dd9916f8406219841e1e255d8945c6dcc958535247aa27af5597a6988e19f11faea7beeabcb46e8ba2431112bb4aa5c7697bca529 DIST checkpolicy-3.6.tar.gz 70684 BLAKE2B d32a8b86897bd4a08caf61a096a691c8d049fa7b5b4561f4847e0dfbb62a82fc6c3ddb5be163c7cd6163491c50513aec14e4c67842f256f48688b26178c2887a SHA512 0d48fb385b4d1e66d562e40b6e794406f46d8803cc504705b26547130cb13b65fab5fdb4fc032b1c95d4f91862ff134a89fffde854c5ce466c2dd2657e416070 DIST checkpolicy-3.7.tar.gz 74992 BLAKE2B 78f419fa89981ad16364b3d6406e313fda5230588063c9a9dbb70535f0421c5b402b9c86d2f63d4ab7b8119c38044b6dc556fb2dd40240428c914cb25a2facbe SHA512 f428edcbe17bd5b5f22dd827cf21c89c2cf645bae6c0342c6663743cafd9f8a8d7c8b5a1b48c04569fdb0cce11ffcb6c0b6d7fa76075a1a274948ba418bcc5b4 diff --git a/sys-apps/checkpolicy/checkpolicy-3.5.ebuild b/sys-apps/checkpolicy/checkpolicy-3.5.ebuild deleted file mode 100644 index 938ef02c35959..0000000000000 --- a/sys-apps/checkpolicy/checkpolicy-3.5.ebuild +++ /dev/null @@ -1,53 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" - -inherit toolchain-funcs - -MY_PV="${PV//_/-}" -MY_P="${PN}-${MY_PV}" - -DESCRIPTION="SELinux policy compiler" -HOMEPAGE="http://userspace.selinuxproject.org" - -if [[ ${PV} == 9999 ]] ; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/SELinuxProject/selinux.git" - S="${WORKDIR}/${P}/${PN}" -else - SRC_URI="https://github.com/SELinuxProject/selinux/releases/download/${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="amd64 arm arm64 ~mips ~riscv x86" - S="${WORKDIR}/${MY_P}" -fi - -LICENSE="GPL-2" -SLOT="0" -IUSE="debug" - -RDEPEND=">=sys-libs/libsepol-${PV}:=[static-libs(+)]" -DEPEND="${RDEPEND}" -BDEPEND="sys-devel/flex - sys-devel/bison" - -src_compile() { - emake \ - CC="$(tc-getCC)" \ - YACC="bison -y" \ - LIBDIR="\$(PREFIX)/$(get_libdir)" -} - -src_install() { - default - - if use debug; then - dobin "${S}/test/dismod" - dobin "${S}/test/dispol" - fi -} - -pkg_postinst() { - if ! tc-is-cross-compiler; then - einfo "This checkpolicy can compile version `checkpolicy -V | cut -f 1 -d ' '` policy." - fi -} From 5fdf8f592f6e6b3269201e9ca528af13abcad5f7 Mon Sep 17 00:00:00 2001 From: Jason Zaman Date: Sun, 11 Aug 2024 17:52:04 -0700 Subject: [PATCH 16/21] sys-libs/libsemanage: drop 3.4-r1, 3.5 Signed-off-by: Jason Zaman --- sys-libs/libsemanage/Manifest | 2 - .../libsemanage/libsemanage-3.4-r1.ebuild | 130 ------------------ sys-libs/libsemanage/libsemanage-3.5.ebuild | 130 ------------------ 3 files changed, 262 deletions(-) delete mode 100644 sys-libs/libsemanage/libsemanage-3.4-r1.ebuild delete mode 100644 sys-libs/libsemanage/libsemanage-3.5.ebuild diff --git a/sys-libs/libsemanage/Manifest b/sys-libs/libsemanage/Manifest index f434e28c3dd24..4f26371658c1b 100644 --- a/sys-libs/libsemanage/Manifest +++ b/sys-libs/libsemanage/Manifest @@ -1,4 +1,2 @@ -DIST libsemanage-3.4.tar.gz 185177 BLAKE2B 45276ae6f54cf3dc453bc0d99fb4d7439970bb14ff5b909ebc5511ec31bce1d2bdc477ba9c1fb4fd04ab494ccb37cd8bf47a90d81460c2974af2196d9019bf67 SHA512 831dc789545bb9a0b009bdb4f7fe52f6197ad8325946640f886a960d08e40b8a69eccd5a70cce51466bb5cb7f742feb78d19a9ec63383fbd03aa451508677e73 -DIST libsemanage-3.5.tar.gz 185060 BLAKE2B 3e08b15cb6b335a2747bd5f0bd84f74abdd22a7e8ec91ebb443ca6fe3886d5e8cd2827fefdaa0e9caf2af3280cffbf593ee828fee54dd423a21b257493cc754c SHA512 959fbd0d6bc6849da6caa13dc41c3f8818cbbd29f04b5d2ac7246c4b395b4f370f113a04cc9cfcb52be2afebfa636013ac4ad4011384c58c7ce066a45cae2751 DIST libsemanage-3.6.tar.gz 182583 BLAKE2B 3ed9ef06601093983fa41ad6ab9f7eeae241dce98937db04efca6f421afcfd3f59cf5e51d24c596ae03997a398949ed84fbdf629518e3c382a5453129b0a87ab SHA512 8998b6a1b254a9673b99ae4d70a1edc769bb728a44f573cdf62e0a9c9392b77644ee2d70e1936a2f8a9a7f8b063ce98a981f4b8b7060f5b82791889330d69364 DIST libsemanage-3.7.tar.gz 182896 BLAKE2B e8a4a9a57f1862efac7e46b33f34f2fdcd116a14487ca07f65aebed62b3914bb1892606a76ed8addcbdb111f361507294ae3c75975a10b90f5d554ba59d2562d SHA512 4b6370b02116364964ff24b93fb6629c885611de78419f649a027db38b4f1c3b3adf3b438efb34a92b49407ab8f9446ed4091fe4c99fa4752f0f5e3e31589415 diff --git a/sys-libs/libsemanage/libsemanage-3.4-r1.ebuild b/sys-libs/libsemanage/libsemanage-3.4-r1.ebuild deleted file mode 100644 index 42c8c982f7d24..0000000000000 --- a/sys-libs/libsemanage/libsemanage-3.4-r1.ebuild +++ /dev/null @@ -1,130 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 -PYTHON_COMPAT=( python3_{9..11} ) - -inherit python-r1 toolchain-funcs multilib-minimal - -MY_PV="${PV//_/-}" -MY_P="${PN}-${MY_PV}" - -DESCRIPTION="SELinux kernel and policy management library" -HOMEPAGE="https://github.com/SELinuxProject/selinux/wiki" - -if [[ ${PV} == 9999 ]]; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/SELinuxProject/selinux.git" - S="${WORKDIR}/${P}/${PN}" -else - SRC_URI="https://github.com/SELinuxProject/selinux/releases/download/${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="amd64 arm arm64 ~mips ~riscv x86" - S="${WORKDIR}/${MY_P}" -fi - -LICENSE="GPL-2" -SLOT="0/2" -REQUIRED_USE="${PYTHON_REQUIRED_USE}" - -RDEPEND="app-arch/bzip2[${MULTILIB_USEDEP}] - >=sys-libs/libsepol-${PV}:=[${MULTILIB_USEDEP}] - >=sys-libs/libselinux-${PV}:=[${MULTILIB_USEDEP}] - >=sys-process/audit-2.2.2[${MULTILIB_USEDEP}] - ${PYTHON_DEPS}" -DEPEND="${RDEPEND}" -BDEPEND=">=dev-lang/swig-2.0.4-r1 - app-alternatives/yacc - app-alternatives/lex - virtual/pkgconfig" - -# tests are not meant to be run outside of the -# full SELinux userland repo -RESTRICT="test" - -src_prepare() { - eapply_user - - echo >> "${S}/src/semanage.conf" - echo "# Set this to true to save the linked policy." >> "${S}/src/semanage.conf" - echo "# This is normally only useful for analysis" >> "${S}/src/semanage.conf" - echo "# or debugging of policy." >> "${S}/src/semanage.conf" - echo "save-linked=false" >> "${S}/src/semanage.conf" - echo >> "${S}/src/semanage.conf" - echo "# Set this to 0 to disable assertion checking." >> "${S}/src/semanage.conf" - echo "# This should speed up building the kernel policy" >> "${S}/src/semanage.conf" - echo "# from policy modules, but may leave you open to" >> "${S}/src/semanage.conf" - echo "# dangerous rules which assertion checking" >> "${S}/src/semanage.conf" - echo "# would catch." >> "${S}/src/semanage.conf" - echo "expand-check=1" >> "${S}/src/semanage.conf" - echo >> "${S}/src/semanage.conf" - echo "# Modules in the module store can be compressed" >> "${S}/src/semanage.conf" - echo "# with bzip2. Set this to the bzip2 blocksize" >> "${S}/src/semanage.conf" - echo "# 1-9 when compressing. The higher the number," >> "${S}/src/semanage.conf" - echo "# the more memory is traded off for disk space." >> "${S}/src/semanage.conf" - echo "# Set to 0 to disable bzip2 compression." >> "${S}/src/semanage.conf" - echo "bzip-blocksize=0" >> "${S}/src/semanage.conf" - echo >> "${S}/src/semanage.conf" - echo "# Reduce memory usage for bzip2 compression and" >> "${S}/src/semanage.conf" - echo "# decompression of modules in the module store." >> "${S}/src/semanage.conf" - echo "bzip-small=true" >> "${S}/src/semanage.conf" - - multilib_copy_sources -} - -multilib_src_compile() { - local -x CFLAGS="${CFLAGS} -fno-semantic-interposition" - - emake \ - AR="$(tc-getAR)" \ - CC="$(tc-getCC)" \ - LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ - all - - if multilib_is_native_abi; then - building_py() { - emake \ - AR="$(tc-getAR)" \ - CC="$(tc-getCC)" \ - PKG_CONFIG="$(tc-getPKG_CONFIG)" \ - LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ - "$@" - } - python_foreach_impl building_py swigify - python_foreach_impl building_py pywrap - fi -} - -multilib_src_install() { - emake \ - LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ - DESTDIR="${ED}" install - - if multilib_is_native_abi; then - installation_py() { - emake DESTDIR="${ED}" \ - LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ - PKG_CONFIG="$(tc-getPKG_CONFIG)" \ - install-pywrap - python_optimize # bug 531638 - } - python_foreach_impl installation_py - fi -} - -multiib_src_install_all() { - python_setup - python_fix_shebang "${ED}"/usr/libexec/selinux/semanage_migrate_store -} - -pkg_postinst() { - # Migrate the SELinux semanage configuration store if not done already - local selinuxtype=$(awk -F'=' '/SELINUXTYPE=/ {print $2}' "${EROOT}"/etc/selinux/config 2>/dev/null) - if [ -n "${selinuxtype}" ] && [ ! -d "${EROOT}"/var/lib/selinux/${selinuxtype}/active ] ; then - ewarn "Since the 2.4 SELinux userspace, the policy module store is moved" - ewarn "from /etc/selinux to /var/lib/selinux. The migration will be run now." - ewarn "If there are any issues, it can be done manually by running:" - ewarn "/usr/libexec/selinux/semanage_migrate_store" - ewarn "For more information, please see" - ewarn "- https://github.com/SELinuxProject/selinux/wiki/Policy-Store-Migration" - fi -} diff --git a/sys-libs/libsemanage/libsemanage-3.5.ebuild b/sys-libs/libsemanage/libsemanage-3.5.ebuild deleted file mode 100644 index 42c8c982f7d24..0000000000000 --- a/sys-libs/libsemanage/libsemanage-3.5.ebuild +++ /dev/null @@ -1,130 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 -PYTHON_COMPAT=( python3_{9..11} ) - -inherit python-r1 toolchain-funcs multilib-minimal - -MY_PV="${PV//_/-}" -MY_P="${PN}-${MY_PV}" - -DESCRIPTION="SELinux kernel and policy management library" -HOMEPAGE="https://github.com/SELinuxProject/selinux/wiki" - -if [[ ${PV} == 9999 ]]; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/SELinuxProject/selinux.git" - S="${WORKDIR}/${P}/${PN}" -else - SRC_URI="https://github.com/SELinuxProject/selinux/releases/download/${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="amd64 arm arm64 ~mips ~riscv x86" - S="${WORKDIR}/${MY_P}" -fi - -LICENSE="GPL-2" -SLOT="0/2" -REQUIRED_USE="${PYTHON_REQUIRED_USE}" - -RDEPEND="app-arch/bzip2[${MULTILIB_USEDEP}] - >=sys-libs/libsepol-${PV}:=[${MULTILIB_USEDEP}] - >=sys-libs/libselinux-${PV}:=[${MULTILIB_USEDEP}] - >=sys-process/audit-2.2.2[${MULTILIB_USEDEP}] - ${PYTHON_DEPS}" -DEPEND="${RDEPEND}" -BDEPEND=">=dev-lang/swig-2.0.4-r1 - app-alternatives/yacc - app-alternatives/lex - virtual/pkgconfig" - -# tests are not meant to be run outside of the -# full SELinux userland repo -RESTRICT="test" - -src_prepare() { - eapply_user - - echo >> "${S}/src/semanage.conf" - echo "# Set this to true to save the linked policy." >> "${S}/src/semanage.conf" - echo "# This is normally only useful for analysis" >> "${S}/src/semanage.conf" - echo "# or debugging of policy." >> "${S}/src/semanage.conf" - echo "save-linked=false" >> "${S}/src/semanage.conf" - echo >> "${S}/src/semanage.conf" - echo "# Set this to 0 to disable assertion checking." >> "${S}/src/semanage.conf" - echo "# This should speed up building the kernel policy" >> "${S}/src/semanage.conf" - echo "# from policy modules, but may leave you open to" >> "${S}/src/semanage.conf" - echo "# dangerous rules which assertion checking" >> "${S}/src/semanage.conf" - echo "# would catch." >> "${S}/src/semanage.conf" - echo "expand-check=1" >> "${S}/src/semanage.conf" - echo >> "${S}/src/semanage.conf" - echo "# Modules in the module store can be compressed" >> "${S}/src/semanage.conf" - echo "# with bzip2. Set this to the bzip2 blocksize" >> "${S}/src/semanage.conf" - echo "# 1-9 when compressing. The higher the number," >> "${S}/src/semanage.conf" - echo "# the more memory is traded off for disk space." >> "${S}/src/semanage.conf" - echo "# Set to 0 to disable bzip2 compression." >> "${S}/src/semanage.conf" - echo "bzip-blocksize=0" >> "${S}/src/semanage.conf" - echo >> "${S}/src/semanage.conf" - echo "# Reduce memory usage for bzip2 compression and" >> "${S}/src/semanage.conf" - echo "# decompression of modules in the module store." >> "${S}/src/semanage.conf" - echo "bzip-small=true" >> "${S}/src/semanage.conf" - - multilib_copy_sources -} - -multilib_src_compile() { - local -x CFLAGS="${CFLAGS} -fno-semantic-interposition" - - emake \ - AR="$(tc-getAR)" \ - CC="$(tc-getCC)" \ - LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ - all - - if multilib_is_native_abi; then - building_py() { - emake \ - AR="$(tc-getAR)" \ - CC="$(tc-getCC)" \ - PKG_CONFIG="$(tc-getPKG_CONFIG)" \ - LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ - "$@" - } - python_foreach_impl building_py swigify - python_foreach_impl building_py pywrap - fi -} - -multilib_src_install() { - emake \ - LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ - DESTDIR="${ED}" install - - if multilib_is_native_abi; then - installation_py() { - emake DESTDIR="${ED}" \ - LIBDIR="${EPREFIX}/usr/$(get_libdir)" \ - PKG_CONFIG="$(tc-getPKG_CONFIG)" \ - install-pywrap - python_optimize # bug 531638 - } - python_foreach_impl installation_py - fi -} - -multiib_src_install_all() { - python_setup - python_fix_shebang "${ED}"/usr/libexec/selinux/semanage_migrate_store -} - -pkg_postinst() { - # Migrate the SELinux semanage configuration store if not done already - local selinuxtype=$(awk -F'=' '/SELINUXTYPE=/ {print $2}' "${EROOT}"/etc/selinux/config 2>/dev/null) - if [ -n "${selinuxtype}" ] && [ ! -d "${EROOT}"/var/lib/selinux/${selinuxtype}/active ] ; then - ewarn "Since the 2.4 SELinux userspace, the policy module store is moved" - ewarn "from /etc/selinux to /var/lib/selinux. The migration will be run now." - ewarn "If there are any issues, it can be done manually by running:" - ewarn "/usr/libexec/selinux/semanage_migrate_store" - ewarn "For more information, please see" - ewarn "- https://github.com/SELinuxProject/selinux/wiki/Policy-Store-Migration" - fi -} From 5d4b3caf8014e9e1ad97f029f2f9b935ace5581e Mon Sep 17 00:00:00 2001 From: Jason Zaman Date: Sun, 11 Aug 2024 17:53:47 -0700 Subject: [PATCH 17/21] sys-libs/libselinux: drop 3.5-r1 Signed-off-by: Jason Zaman --- sys-libs/libselinux/Manifest | 1 - sys-libs/libselinux/libselinux-3.5-r1.ebuild | 161 ------------------- 2 files changed, 162 deletions(-) delete mode 100644 sys-libs/libselinux/libselinux-3.5-r1.ebuild diff --git a/sys-libs/libselinux/Manifest b/sys-libs/libselinux/Manifest index 7eadd0d8cbc41..21b7f934eefe9 100644 --- a/sys-libs/libselinux/Manifest +++ b/sys-libs/libselinux/Manifest @@ -1,3 +1,2 @@ -DIST libselinux-3.5.tar.gz 211453 BLAKE2B f7f3067c4bb0448e18bd7085135f11d94ae99728949480a655c0f660486817beb5829d8a43dff7bce286ccd50705b0c657bde85970f01c794e01fb707f469d8b SHA512 4e13261a5821018a5f3cdce676f180bb62e5bc225981ca8a498ece0d1c88d9ba8eaa0ce4099dd0849309a8a7c5a9a0953df841a9922f2c284e5a109e5d937ba7 DIST libselinux-3.6.tar.gz 194210 BLAKE2B 615198d47ecfb4b6274810cbe32cce5953dd44d1d04e8ce244213dc4ddbd61cde3515f4650046b805cf98f341aba718af8d7a9e1d66773172031ac19599f6032 SHA512 182dcdf3510083ff4b9376a4a6d6a7b33905ac3c5e974c188bf3965686c54b663162c543ecf15eab75102f3c91a2502d33d0f1104dec01dd9b14737ef3f2b544 DIST libselinux-3.7.tar.gz 194834 BLAKE2B 07d87c37608b480d17355334459ecb006573d61a7d3fbf622033838559397abcf343e6399f3a49b6cf24e106d03fd997397d061491d2129c15a378960dacc350 SHA512 e949c20b606c50ad521b9592ce55ad6658e8c4b24d9838028f5aba0a4fc762b6d0d0d0d207f5bef7a2e41485e12d91382fa6090df27152dbb40071b273419352 diff --git a/sys-libs/libselinux/libselinux-3.5-r1.ebuild b/sys-libs/libselinux/libselinux-3.5-r1.ebuild deleted file mode 100644 index dd4272b05308a..0000000000000 --- a/sys-libs/libselinux/libselinux-3.5-r1.ebuild +++ /dev/null @@ -1,161 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" -PYTHON_COMPAT=( python3_{10..12} ) -USE_RUBY="ruby30 ruby31 ruby32" - -# No, I am not calling ruby-ng -inherit flag-o-matic python-r1 toolchain-funcs multilib-minimal - -MY_PV="${PV//_/-}" -MY_P="${PN}-${MY_PV}" - -DESCRIPTION="SELinux userland library" -HOMEPAGE="https://github.com/SELinuxProject/selinux/wiki" - -if [[ ${PV} == 9999 ]]; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/SELinuxProject/selinux.git" - S="${WORKDIR}/${P}/${PN}" -else - SRC_URI="https://github.com/SELinuxProject/selinux/releases/download/${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="amd64 arm arm64 ~mips ~riscv x86" - S="${WORKDIR}/${MY_P}" -fi - -LICENSE="public-domain" -SLOT="0" -IUSE="python ruby static-libs ruby_targets_ruby30 ruby_targets_ruby31 ruby_targets_ruby32" -REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" - -RDEPEND="dev-libs/libpcre2:=[static-libs?,${MULTILIB_USEDEP}] - >=sys-libs/libsepol-${PV}:=[${MULTILIB_USEDEP},static-libs(+)] - python? ( ${PYTHON_DEPS} ) - ruby? ( - ruby_targets_ruby30? ( dev-lang/ruby:3.0 ) - ruby_targets_ruby31? ( dev-lang/ruby:3.1 ) - ruby_targets_ruby32? ( dev-lang/ruby:3.2 ) - ) - elibc_musl? ( sys-libs/fts-standalone )" -DEPEND="${RDEPEND}" -BDEPEND="virtual/pkgconfig - python? ( - >=dev-lang/swig-2.0.9 - dev-python/pip[${PYTHON_USEDEP}] - ) - ruby? ( >=dev-lang/swig-2.0.9 )" - -src_prepare() { - eapply_user - - multilib_copy_sources -} - -multilib_src_compile() { - tc-export AR CC PKG_CONFIG RANLIB - - # bug 905711 - use elibc_musl && append-cppflags -D_LARGEFILE64_SOURCE - - local -x CFLAGS="${CFLAGS} -fno-semantic-interposition" - - emake \ - LIBDIR="\$(PREFIX)/$(get_libdir)" \ - SHLIBDIR="/$(get_libdir)" \ - LDFLAGS="-fPIC ${LDFLAGS} -pthread" \ - USE_PCRE2=y \ - FTS_LDLIBS="$(usex elibc_musl '-lfts' '')" \ - all - - if multilib_is_native_abi && use python; then - building() { - emake \ - LDFLAGS="-fPIC ${LDFLAGS} -lpthread" \ - LIBDIR="\$(PREFIX)/$(get_libdir)" \ - SHLIBDIR="/$(get_libdir)" \ - USE_PCRE2=y \ - FTS_LDLIBS="$(usex elibc_musl '-lfts' '')" \ - pywrap - } - python_foreach_impl building - fi - - if multilib_is_native_abi && use ruby; then - building() { - einfo "Calling rubywrap for ${1}" - # Clean up .lo file to force rebuild - rm -f src/selinuxswig_ruby_wrap.lo || die - emake \ - RUBY=${1} \ - LDFLAGS="-fPIC ${LDFLAGS} -lpthread" \ - LIBDIR="\$(PREFIX)/$(get_libdir)" \ - SHLIBDIR="/$(get_libdir)" \ - USE_PCRE2=y \ - FTS_LDLIBS="$(usex elibc_musl '-lfts' '')" \ - rubywrap - } - for RUBYTARGET in ${USE_RUBY}; do - use ruby_targets_${RUBYTARGET} || continue - - building ${RUBYTARGET} - done - fi -} - -multilib_src_install() { - emake DESTDIR="${D}" \ - LIBDIR="\$(PREFIX)/$(get_libdir)" \ - SHLIBDIR="/$(get_libdir)" \ - USE_PCRE2=y \ - install - - if multilib_is_native_abi && use python; then - installation() { - emake DESTDIR="${D}" \ - LIBDIR="\$(PREFIX)/$(get_libdir)" \ - SHLIBDIR="/$(get_libdir)" \ - USE_PCRE2=y \ - install-pywrap - python_optimize # bug 531638 - } - python_foreach_impl installation - fi - - if multilib_is_native_abi && use ruby; then - installation() { - einfo "Calling install-rubywrap for ${1}" - # Forcing (re)build here as otherwise the resulting SO file is used for all ruby versions - rm src/selinuxswig_ruby_wrap.lo - emake DESTDIR="${D}" \ - LIBDIR="\$(PREFIX)/$(get_libdir)" \ - SHLIBDIR="/$(get_libdir)" \ - RUBY=${1} \ - USE_PCRE2=y \ - install-rubywrap - } - for RUBYTARGET in ${USE_RUBY}; do - use ruby_targets_${RUBYTARGET} || continue - - installation ${RUBYTARGET} - done - fi - - use static-libs || rm "${D}"/usr/lib*/*.a || die -} - -pkg_postinst() { - # Fix bug 473502 - for POLTYPE in ${POLICY_TYPES}; - do - mkdir -p "${ROOT}/etc/selinux/${POLTYPE}/contexts/files" || die - touch "${ROOT}/etc/selinux/${POLTYPE}/contexts/files/file_contexts.local" || die - # Fix bug 516608 - for EXPRFILE in file_contexts file_contexts.homedirs file_contexts.local ; do - if [[ -f "${ROOT}/etc/selinux/${POLTYPE}/contexts/files/${EXPRFILE}" ]]; then - sefcontext_compile "${ROOT}/etc/selinux/${POLTYPE}/contexts/files/${EXPRFILE}" \ - || die "Failed to recompile contexts" - fi - done - done -} From babe86a253d5af6c1c9b5e9e96ff337015ded6e3 Mon Sep 17 00:00:00 2001 From: Jason Zaman Date: Sun, 11 Aug 2024 17:56:29 -0700 Subject: [PATCH 18/21] sys-libs/libsepol: drop 3.5 Signed-off-by: Jason Zaman --- sys-libs/libsepol/Manifest | 1 - sys-libs/libsepol/libsepol-3.5.ebuild | 50 --------------------------- 2 files changed, 51 deletions(-) delete mode 100644 sys-libs/libsepol/libsepol-3.5.ebuild diff --git a/sys-libs/libsepol/Manifest b/sys-libs/libsepol/Manifest index 959bbca8e5e53..bced87d076445 100644 --- a/sys-libs/libsepol/Manifest +++ b/sys-libs/libsepol/Manifest @@ -1,3 +1,2 @@ -DIST libsepol-3.5.tar.gz 497522 BLAKE2B dad2d346605be53fe41aef69e2e4bd4f1ce68a15f0b9307deb6b66bbe7bf06a9ee6be580e60d2f19aebbc8ee5041ac8a7b831b51342ba7c7089e1f1a447e7691 SHA512 66f45a9f4951589855961955db686b006b4c0cddead6ac49ad238a0e4a34775905bd10fb8cf0c0ff2ab64f9b7d8366b97fcd5b19c382dec39971a2835cc765c8 DIST libsepol-3.6.tar.gz 509100 BLAKE2B c073c9437004df0c723125971ed26354dc6b8a78b069c593977062527342061303bcc48917fcd9623d17998748254f63408b233173f3c62e92ee0ea2f3c4a430 SHA512 35a42d2749fc4f71bc6b7488380714f56975564007128566f1c73e5c50bf81c17535b2cfda4583aacb4870aa2cd5885321c01523e415bda8b3326bfefb13d58e DIST libsepol-3.7.tar.gz 511487 BLAKE2B 8e4a0b2b3731f49d8bc8ea03bd5269672428119578046bc7f38230e3c77459e6b9d4ab39285ea33c89d8e807499ef89faa606e4b4e1ecfac2c3d445454b16420 SHA512 85d12d0ba5a7a3225f08d041a18fd59641608db5e0a78a1e9649754e45be54a807cd422d4889b88da6e806b4af546336c7a0913448f08ac33dc6ffb983890ef8 diff --git a/sys-libs/libsepol/libsepol-3.5.ebuild b/sys-libs/libsepol/libsepol-3.5.ebuild deleted file mode 100644 index 16ea268dc5c0d..0000000000000 --- a/sys-libs/libsepol/libsepol-3.5.ebuild +++ /dev/null @@ -1,50 +0,0 @@ -# Copyright 1999-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" - -inherit toolchain-funcs multilib-minimal - -MY_PV="${PV//_/-}" -MY_P="${PN}-${MY_PV}" - -DESCRIPTION="SELinux binary policy representation library" -HOMEPAGE="https://github.com/SELinuxProject/selinux/wiki" - -if [[ ${PV} == 9999 ]]; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/SELinuxProject/selinux.git" - S="${WORKDIR}/${P}/${PN}" -else - SRC_URI="https://github.com/SELinuxProject/selinux/releases/download/${MY_PV}/${MY_P}.tar.gz" - KEYWORDS="amd64 arm arm64 ~mips ~riscv x86" - S="${WORKDIR}/${MY_P}" -fi - -LICENSE="GPL-2" -SLOT="0/2" - -# tests are not meant to be run outside of the full SELinux userland repo -RESTRICT="test" - -src_prepare() { - eapply_user - multilib_copy_sources -} - -multilib_src_compile() { - tc-export CC AR RANLIB - - local -x CFLAGS="${CFLAGS} -fno-semantic-interposition" - - emake \ - LIBDIR="\$(PREFIX)/$(get_libdir)" \ - SHLIBDIR="/$(get_libdir)" -} - -multilib_src_install() { - emake DESTDIR="${D}" \ - LIBDIR="\$(PREFIX)/$(get_libdir)" \ - SHLIBDIR="/$(get_libdir)" \ - install -} From d3771b043dfdec33674fde9f8541048555dddbb8 Mon Sep 17 00:00:00 2001 From: Sam James Date: Mon, 12 Aug 2024 02:23:28 +0100 Subject: [PATCH 19/21] net-libs/udns: Stabilize 0.4-r3 amd64, #937790 Signed-off-by: Sam James --- net-libs/udns/udns-0.4-r3.ebuild | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/net-libs/udns/udns-0.4-r3.ebuild b/net-libs/udns/udns-0.4-r3.ebuild index 76ee1d6bd4c5c..3939133f516bb 100644 --- a/net-libs/udns/udns-0.4-r3.ebuild +++ b/net-libs/udns/udns-0.4-r3.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2023 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -11,7 +11,7 @@ SRC_URI="http://www.corpit.ru/mjt/udns/${P}.tar.gz" LICENSE="LGPL-2.1" SLOT="0" -KEYWORDS="~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86" +KEYWORDS="amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86" IUSE="ipv6 static +tools" PATCHES=( From 7d9f7057a904a4b9e1120a990734a3f0aa3cdae5 Mon Sep 17 00:00:00 2001 From: Sam James Date: Mon, 12 Aug 2024 02:23:30 +0100 Subject: [PATCH 20/21] net-libs/udns: Stabilize 0.4-r3 x86, #937790 Signed-off-by: Sam James --- net-libs/udns/udns-0.4-r3.ebuild | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net-libs/udns/udns-0.4-r3.ebuild b/net-libs/udns/udns-0.4-r3.ebuild index 3939133f516bb..b6ff24ac2143e 100644 --- a/net-libs/udns/udns-0.4-r3.ebuild +++ b/net-libs/udns/udns-0.4-r3.ebuild @@ -11,7 +11,7 @@ SRC_URI="http://www.corpit.ru/mjt/udns/${P}.tar.gz" LICENSE="LGPL-2.1" SLOT="0" -KEYWORDS="amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86" +KEYWORDS="amd64 ~hppa ~ppc ~ppc64 ~sparc x86" IUSE="ipv6 static +tools" PATCHES=( From f56fbc99b204ce52fc60aca503b0671f833ac059 Mon Sep 17 00:00:00 2001 From: Sam James Date: Mon, 12 Aug 2024 02:23:31 +0100 Subject: [PATCH 21/21] net-libs/udns: Stabilize 0.4-r3 ppc, #937790 Signed-off-by: Sam James --- net-libs/udns/udns-0.4-r3.ebuild | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net-libs/udns/udns-0.4-r3.ebuild b/net-libs/udns/udns-0.4-r3.ebuild index b6ff24ac2143e..ccc3d9b26b6ac 100644 --- a/net-libs/udns/udns-0.4-r3.ebuild +++ b/net-libs/udns/udns-0.4-r3.ebuild @@ -11,7 +11,7 @@ SRC_URI="http://www.corpit.ru/mjt/udns/${P}.tar.gz" LICENSE="LGPL-2.1" SLOT="0" -KEYWORDS="amd64 ~hppa ~ppc ~ppc64 ~sparc x86" +KEYWORDS="amd64 ~hppa ppc ~ppc64 ~sparc x86" IUSE="ipv6 static +tools" PATCHES=(