diff options
author | Michał Górny <mgorny@gentoo.org> | 2024-01-18 15:41:31 +0100 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2024-01-19 15:44:14 +0100 |
commit | a51d470ab9fcd6932526b4534a91c46635042920 (patch) | |
tree | af41c22ae194e880d6ee217f4efba9c50c211716 /dev-debug | |
parent | Move {dev-util → dev-debug}/sysdig (diff) | |
download | gentoo-a51d470ab9fcd6932526b4534a91c46635042920.tar.gz gentoo-a51d470ab9fcd6932526b4534a91c46635042920.tar.bz2 gentoo-a51d470ab9fcd6932526b4534a91c46635042920.zip |
Move {dev-util → dev-debug}/systemtap
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'dev-debug')
-rw-r--r-- | dev-debug/systemtap/Manifest | 3 | ||||
-rw-r--r-- | dev-debug/systemtap/files/systemtap-3.1-ia64.patch | 33 | ||||
-rw-r--r-- | dev-debug/systemtap/metadata.xml | 10 | ||||
-rw-r--r-- | dev-debug/systemtap/systemtap-4.8.ebuild | 127 | ||||
-rw-r--r-- | dev-debug/systemtap/systemtap-4.9.ebuild | 128 | ||||
-rw-r--r-- | dev-debug/systemtap/systemtap-5.0.ebuild | 128 |
6 files changed, 429 insertions, 0 deletions
diff --git a/dev-debug/systemtap/Manifest b/dev-debug/systemtap/Manifest new file mode 100644 index 000000000000..e7c441bb9887 --- /dev/null +++ b/dev-debug/systemtap/Manifest @@ -0,0 +1,3 @@ +DIST systemtap-4.8.tar.gz 5628003 BLAKE2B 9f5050eba29d390c907b117187f94ef088f16bb739b4971bc32ffe88b1024a4157cd4e9793a8fc1e149a5a182a28330e3b4fd9d51213bb3637d616fbb9867f6d SHA512 fdcbc48ba17b2155c1419d99147a4cfbee2e69db945bfd0e6881b71ab11165bd23ea7ce9456856ae36807fb18f9934880a6b7c44456b63833ea260038744d9f2 +DIST systemtap-4.9.tar.gz 6684228 BLAKE2B 880747bcfbaa1909ca20a6cb30eb37d9443547783489396355b642758054ae0e0bf5b495a0adf57851c7c7a6b4300e498bb8c1c8da6df83ab1d1e18877b108a7 SHA512 a2736223fee0c801c36719a0245f31ed7e2e63c30bb7d5cab631dd57e4eb10e04abf2c9b272bda2a17c207c9dd163a1eb8a3e0759eda0c781946e644625510b7 +DIST systemtap-5.0.tar.gz 6572411 BLAKE2B db962df2fdcbc5bc11259c03d78073924f03fee4434dca8686a62fcb0818dab1ca91558160dd9d67d43b709f63ffe4f0af30ab1fe6965e19155bdd4c04501a04 SHA512 dc511a05e66abcbbd8c926973962751196180f3c571d0cd2a3b158ae367c5339ad32967a680ecd03224ab5f7ed2c55be7064867e4fb1b1cd7ea1cb21b2436e4c diff --git a/dev-debug/systemtap/files/systemtap-3.1-ia64.patch b/dev-debug/systemtap/files/systemtap-3.1-ia64.patch new file mode 100644 index 000000000000..832bfc1a47f9 --- /dev/null +++ b/dev-debug/systemtap/files/systemtap-3.1-ia64.patch @@ -0,0 +1,33 @@ +Workaround build failure on ia64 + +Avoid 'o' constraint to allow gcc to select register operand. +That way instruction selector can satisfy all constraints +for PROBE2 macro. + +Reported-by: Émeric Maschino +Bug: https://bugs.gentoo.org/510134 +--- a/cache.cxx ++++ b/cache.cxx +@@ -8,2 +8,10 @@ + ++#ifdef __ia64__ ++// Default is: nor ++// We disable 'o' because gcc fails to select register ++// constraint for second instruction in 'add_script_to_cache' ++// https://bugs.gentoo.org/510134 ++# define STAP_SDT_ARG_CONSTRAINT nr ++#endif ++ + #include "config.h" +--- a/staprun/mainloop.c ++++ b/staprun/mainloop.c +@@ -1 +1,9 @@ ++#ifdef __ia64__ ++// Default is: nor ++// We disable 'o' because gcc fails to select register ++// constraint for second instruction in 'add_script_to_cache' ++// https://bugs.gentoo.org/510134 ++# define STAP_SDT_ARG_CONSTRAINT nr ++#endif ++ + /* -*- linux-c -*- diff --git a/dev-debug/systemtap/metadata.xml b/dev-debug/systemtap/metadata.xml new file mode 100644 index 000000000000..4a3d4007cae0 --- /dev/null +++ b/dev-debug/systemtap/metadata.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<maintainer type="person"> + <email>swegener@gentoo.org</email> +</maintainer> + <use> + <flag name="libvirt">Support probing of libvirt domains.</flag> + </use> +</pkgmetadata> diff --git a/dev-debug/systemtap/systemtap-4.8.ebuild b/dev-debug/systemtap/systemtap-4.8.ebuild new file mode 100644 index 000000000000..203f02f9b82c --- /dev/null +++ b/dev-debug/systemtap/systemtap-4.8.ebuild @@ -0,0 +1,127 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..11} pypy3 ) + +inherit autotools linux-info python-single-r1 + +DESCRIPTION="A linux trace/probe tool" +HOMEPAGE="https://www.sourceware.org/systemtap" +SRC_URI="https://www.sourceware.org/ftp/${PN}/releases/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha amd64 arm arm64 ~ia64 ~loong ~mips ppc ppc64 ~riscv ~s390 sparc x86" +IUSE="libvirt selinux sqlite +ssl test zeroconf" + +CDEPEND=" + ${PYTHON_DEPS} + + dev-libs/boost:= + >=dev-libs/elfutils-0.142 + dev-libs/json-c:= + sys-libs/ncurses:= + sys-libs/readline:= + + libvirt? ( >=app-emulation/libvirt-1.0.2 ) + selinux? ( sys-libs/libselinux ) + sqlite? ( dev-db/sqlite:3 ) + ssl? ( + dev-libs/nspr + dev-libs/nss + ) + zeroconf? ( net-dns/avahi ) +" +DEPEND=" + ${CDEPEND} + app-alternatives/cpio + app-text/xmlto + $(python_gen_cond_dep 'dev-python/setuptools[${PYTHON_USEDEP}]') + >=sys-devel/gettext-0.18.2 + + libvirt? ( dev-libs/libxml2 ) +" +RDEPEND=" + ${CDEPEND} + acct-group/stapdev + acct-group/stapsys + acct-group/stapusr +" +BDEPEND="test? ( dev-util/dejagnu )" + +CONFIG_CHECK="~KPROBES ~RELAY ~DEBUG_FS" +ERROR_KPROBES="${PN} requires support for KProbes Instrumentation (KPROBES) - this can be enabled in 'Instrumentation Support -> Kprobes'." +ERROR_RELAY="${PN} works with support for user space relay support (RELAY) - this can be enabled in 'General setup -> Kernel->user space relay support (formerly relayfs)'." +ERROR_DEBUG_FS="${PN} works best with support for Debug Filesystem (DEBUG_FS) - this can be enabled in 'Kernel hacking -> Debug Filesystem'." + +DOCS="AUTHORS HACKING NEWS README" +REQUIRED_USE="${PYTHON_REQUIRED_USE}" +RESTRICT="!test? ( test )" +PATCHES=( + "${FILESDIR}/${PN}-3.1-ia64.patch" +) + +pkg_setup() { + linux-info_pkg_setup + python-single-r1_pkg_setup +} + +src_prepare() { + python_fix_shebang . + + sed -i \ + -e 's|-Werror||g' \ + configure.ac \ + Makefile.am \ + stapbpf/Makefile.am \ + stapdyn/Makefile.am \ + staprun/Makefile.am \ + testsuite/systemtap.unprivileged/unprivileged_probes.exp \ + testsuite/systemtap.unprivileged/unprivileged_myproc.exp \ + testsuite/systemtap.base/stmt_rel_user.exp \ + testsuite/systemtap.base/sdt_va_args.exp \ + testsuite/systemtap.base/sdt_misc.exp \ + testsuite/systemtap.base/sdt.exp \ + scripts/kprobes_test/gen_code.py \ + || die "Failed to clean up sources" + + default + eautoreconf +} + +src_configure() { + local myeconfargs=( + --disable-docs + --disable-grapher + --disable-refdocs + --disable-server + # Our toolchain sets this for us already and adding in + # -D_FORTIFY_SOURCE=2 breaks builds w/ no optimisation. + # This option (at least as of 4.5) doesn't pass -fno* etc, + # it just doesn't _add_ options, which is good. If it changes + # to actually pass -fno-stack-protector and friends, we'll + # need to change course. Forcing =2 also has problems for + # setting it to 3. + # bug #794667. + --disable-ssp + --enable-pie + --with-python3 + --without-java + --without-openssl + --without-python2-probes + --without-rpm + $(use_enable libvirt virt) + $(use_enable sqlite) + $(use_with zeroconf avahi) + $(use_with ssl nss) + $(use_with selinux) + ) + PYTHON3="${PYTHON}" econf "${myeconfargs[@]}" +} + +src_install() { + default + python_optimize +} diff --git a/dev-debug/systemtap/systemtap-4.9.ebuild b/dev-debug/systemtap/systemtap-4.9.ebuild new file mode 100644 index 000000000000..629bdf77f7c4 --- /dev/null +++ b/dev-debug/systemtap/systemtap-4.9.ebuild @@ -0,0 +1,128 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..11} pypy3 ) + +inherit autotools linux-info python-single-r1 + +DESCRIPTION="A linux trace/probe tool" +HOMEPAGE="https://www.sourceware.org/systemtap" +SRC_URI="https://www.sourceware.org/ftp/${PN}/releases/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" +IUSE="libvirt selinux sqlite +ssl test zeroconf" + +CDEPEND=" + ${PYTHON_DEPS} + + dev-libs/boost:= + >=dev-libs/elfutils-0.142 + dev-libs/json-c:= + sys-libs/ncurses:= + sys-libs/readline:= + + libvirt? ( >=app-emulation/libvirt-1.0.2 ) + selinux? ( sys-libs/libselinux ) + sqlite? ( dev-db/sqlite:3 ) + ssl? ( + dev-libs/nspr + dev-libs/nss + ) + zeroconf? ( net-dns/avahi ) +" +DEPEND=" + ${CDEPEND} + app-alternatives/cpio + app-text/xmlto + $(python_gen_cond_dep 'dev-python/setuptools[${PYTHON_USEDEP}]') + >=sys-devel/gettext-0.18.2 + + libvirt? ( dev-libs/libxml2 ) +" +RDEPEND=" + ${CDEPEND} + acct-group/stapdev + acct-group/stapsys + acct-group/stapusr +" +BDEPEND="test? ( dev-util/dejagnu )" + +CONFIG_CHECK="~KPROBES ~RELAY ~DEBUG_FS" +ERROR_KPROBES="${PN} requires support for KProbes Instrumentation (KPROBES) - this can be enabled in 'Instrumentation Support -> Kprobes'." +ERROR_RELAY="${PN} works with support for user space relay support (RELAY) - this can be enabled in 'General setup -> Kernel->user space relay support (formerly relayfs)'." +ERROR_DEBUG_FS="${PN} works best with support for Debug Filesystem (DEBUG_FS) - this can be enabled in 'Kernel hacking -> Debug Filesystem'." + +DOCS="AUTHORS HACKING NEWS README" +REQUIRED_USE="${PYTHON_REQUIRED_USE}" +RESTRICT="!test? ( test )" +PATCHES=( + "${FILESDIR}/${PN}-3.1-ia64.patch" +) + +pkg_setup() { + linux-info_pkg_setup + python-single-r1_pkg_setup +} + +src_prepare() { + python_fix_shebang . + + sed -i \ + -e 's|-Werror||g' \ + configure.ac \ + Makefile.am \ + stapbpf/Makefile.am \ + stapdyn/Makefile.am \ + staprun/Makefile.am \ + testsuite/systemtap.unprivileged/unprivileged_probes.exp \ + testsuite/systemtap.unprivileged/unprivileged_myproc.exp \ + testsuite/systemtap.base/stmt_rel_user.exp \ + testsuite/systemtap.base/sdt_va_args.exp \ + testsuite/systemtap.base/sdt_misc.exp \ + testsuite/systemtap.base/sdt.exp \ + scripts/kprobes_test/gen_code.py \ + || die "Failed to clean up sources" + + default + eautoreconf +} + +src_configure() { + local myeconfargs=( + --cache-file="${S}"/config.cache + --disable-docs + --disable-grapher + --disable-refdocs + --disable-server + # Our toolchain sets this for us already and adding in + # -D_FORTIFY_SOURCE=2 breaks builds w/ no optimisation. + # This option (at least as of 4.5) doesn't pass -fno* etc, + # it just doesn't _add_ options, which is good. If it changes + # to actually pass -fno-stack-protector and friends, we'll + # need to change course. Forcing =2 also has problems for + # setting it to 3. + # bug #794667. + --disable-ssp + --enable-pie + --with-python3 + --without-java + --without-openssl + --without-python2-probes + --without-rpm + $(use_enable libvirt virt) + $(use_enable sqlite) + $(use_with zeroconf avahi) + $(use_with ssl nss) + $(use_with selinux) + ) + PYTHON3="${PYTHON}" econf "${myeconfargs[@]}" +} + +src_install() { + default + python_optimize +} diff --git a/dev-debug/systemtap/systemtap-5.0.ebuild b/dev-debug/systemtap/systemtap-5.0.ebuild new file mode 100644 index 000000000000..7bc3f9abc5df --- /dev/null +++ b/dev-debug/systemtap/systemtap-5.0.ebuild @@ -0,0 +1,128 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..11} pypy3 ) + +inherit autotools linux-info python-single-r1 + +DESCRIPTION="A linux trace/probe tool" +HOMEPAGE="https://www.sourceware.org/systemtap" +SRC_URI="https://www.sourceware.org/ftp/${PN}/releases/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" +IUSE="libvirt selinux sqlite +ssl test zeroconf" + +CDEPEND=" + ${PYTHON_DEPS} + + dev-libs/boost:= + >=dev-libs/elfutils-0.142[debuginfod] + dev-libs/json-c:= + sys-libs/ncurses:= + sys-libs/readline:= + + libvirt? ( >=app-emulation/libvirt-1.0.2 ) + selinux? ( sys-libs/libselinux ) + sqlite? ( dev-db/sqlite:3 ) + ssl? ( + dev-libs/nspr + dev-libs/nss + ) + zeroconf? ( net-dns/avahi ) +" +DEPEND=" + ${CDEPEND} + app-alternatives/cpio + app-text/xmlto + $(python_gen_cond_dep 'dev-python/setuptools[${PYTHON_USEDEP}]') + >=sys-devel/gettext-0.18.2 + + libvirt? ( dev-libs/libxml2 ) +" +RDEPEND=" + ${CDEPEND} + acct-group/stapdev + acct-group/stapsys + acct-group/stapusr +" +BDEPEND="test? ( dev-util/dejagnu )" + +CONFIG_CHECK="~KPROBES ~RELAY ~DEBUG_FS" +ERROR_KPROBES="${PN} requires support for KProbes Instrumentation (KPROBES) - this can be enabled in 'Instrumentation Support -> Kprobes'." +ERROR_RELAY="${PN} works with support for user space relay support (RELAY) - this can be enabled in 'General setup -> Kernel->user space relay support (formerly relayfs)'." +ERROR_DEBUG_FS="${PN} works best with support for Debug Filesystem (DEBUG_FS) - this can be enabled in 'Kernel hacking -> Debug Filesystem'." + +DOCS="AUTHORS HACKING NEWS README" +REQUIRED_USE="${PYTHON_REQUIRED_USE}" +RESTRICT="!test? ( test )" +PATCHES=( + "${FILESDIR}/${PN}-3.1-ia64.patch" +) + +pkg_setup() { + linux-info_pkg_setup + python-single-r1_pkg_setup +} + +src_prepare() { + python_fix_shebang . + + sed -i \ + -e 's|-Werror||g' \ + configure.ac \ + Makefile.am \ + stapbpf/Makefile.am \ + stapdyn/Makefile.am \ + staprun/Makefile.am \ + testsuite/systemtap.unprivileged/unprivileged_probes.exp \ + testsuite/systemtap.unprivileged/unprivileged_myproc.exp \ + testsuite/systemtap.base/stmt_rel_user.exp \ + testsuite/systemtap.base/sdt_va_args.exp \ + testsuite/systemtap.base/sdt_misc.exp \ + testsuite/systemtap.base/sdt.exp \ + scripts/kprobes_test/gen_code.py \ + || die "Failed to clean up sources" + + default + eautoreconf +} + +src_configure() { + local myeconfargs=( + --cache-file="${S}"/config.cache + --disable-docs + --disable-grapher + --disable-refdocs + --disable-server + # Our toolchain sets this for us already and adding in + # -D_FORTIFY_SOURCE=2 breaks builds w/ no optimisation. + # This option (at least as of 4.5) doesn't pass -fno* etc, + # it just doesn't _add_ options, which is good. If it changes + # to actually pass -fno-stack-protector and friends, we'll + # need to change course. Forcing =2 also has problems for + # setting it to 3. + # bug #794667. + --disable-ssp + --enable-pie + --with-python3 + --without-java + --without-openssl + --without-python2-probes + --without-rpm + $(use_enable libvirt virt) + $(use_enable sqlite) + $(use_with zeroconf avahi) + $(use_with ssl nss) + $(use_with selinux) + ) + PYTHON3="${PYTHON}" econf "${myeconfargs[@]}" +} + +src_install() { + default + python_optimize +} |