From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-util/sysdig/files/, dev-util/sysdig/
Date: Sat, 29 Apr 2023 06:44:49 +0000 (UTC) [thread overview]
Message-ID: <1682750647.d983f3ebed360ac08d153655777912f354f3dd2f.sam@gentoo> (raw)
commit: d983f3ebed360ac08d153655777912f354f3dd2f
Author: Holger Hoffstätte <holger <AT> applied-asynchrony <DOT> com>
AuthorDate: Fri Apr 28 14:52:23 2023 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat Apr 29 06:44:07 2023 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d983f3eb
dev-util/sysdig: fix build with gcc-13
Closes: https://bugs.gentoo.org/905225
Signed-off-by: Holger Hoffstätte <holger <AT> applied-asynchrony.com>
Closes: https://github.com/gentoo/gentoo/pull/30792
Signed-off-by: Sam James <sam <AT> gentoo.org>
dev-util/sysdig/files/0.29.3-libs-gcc13.patch | 28 +++++++++
dev-util/sysdig/sysdig-0.29.3-r1.ebuild | 91 +++++++++++++++++++++++++++
2 files changed, 119 insertions(+)
diff --git a/dev-util/sysdig/files/0.29.3-libs-gcc13.patch b/dev-util/sysdig/files/0.29.3-libs-gcc13.patch
new file mode 100644
index 000000000000..ce1a686cc65c
--- /dev/null
+++ b/dev-util/sysdig/files/0.29.3-libs-gcc13.patch
@@ -0,0 +1,28 @@
+
+Manual backport of the upstream fix at:
+https://github.com/falcosecurity/libs/commit/1406858fa5223d980e66e2a5fb2c1b014c9db5c8
+
+diff --git libs-e5c53d648f3c4694385bbe488e7d47eaa36c229a-orig/userspace/libsinsp/filter_value.h libs-e5c53d648f3c4694385bbe488e7d47eaa36c229a/userspace/libsinsp/filter_value.h
+index 47f5367..6cc8b83 100644
+--- libs-e5c53d648f3c4694385bbe488e7d47eaa36c229a-orig/userspace/libsinsp/filter_value.h
++++ libs-e5c53d648f3c4694385bbe488e7d47eaa36c229a/userspace/libsinsp/filter_value.h
+@@ -17,6 +17,7 @@ limitations under the License.
+
+ #pragma once
+
++#include <cstdint>
+ #include <string.h>
+ #include <utility>
+
+diff --git libs-e5c53d648f3c4694385bbe488e7d47eaa36c229a-orig/userspace/libsinsp/sinsp.h libs-e5c53d648f3c4694385bbe488e7d47eaa36c229a/userspace/libsinsp/sinsp.h
+index c15c13c..f9f9f45 100644
+--- libs-e5c53d648f3c4694385bbe488e7d47eaa36c229a-orig/userspace/libsinsp/sinsp.h
++++ libs-e5c53d648f3c4694385bbe488e7d47eaa36c229a/userspace/libsinsp/sinsp.h
+@@ -56,6 +56,7 @@ limitations under the License.
+
+ #define __STDC_FORMAT_MACROS
+
++#include <cstdint>
+ #include <string>
+ #include <unordered_map>
+ #include <map>
diff --git a/dev-util/sysdig/sysdig-0.29.3-r1.ebuild b/dev-util/sysdig/sysdig-0.29.3-r1.ebuild
new file mode 100644
index 000000000000..f114a10d5965
--- /dev/null
+++ b/dev-util/sysdig/sysdig-0.29.3-r1.ebuild
@@ -0,0 +1,91 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+LUA_COMPAT=( luajit )
+
+inherit bash-completion-r1 cmake lua-single
+
+DESCRIPTION="A system exploration and troubleshooting tool"
+HOMEPAGE="https://sysdig.com/"
+
+# For now we need to bump this version of falcosecurity/libs manually;
+# check the used git revision in <src>/cmake/modules/falcosecurity-libs.cmake
+LIBS_COMMIT="e5c53d648f3c4694385bbe488e7d47eaa36c229a"
+
+SRC_URI="https://github.com/draios/sysdig/archive/${PV}.tar.gz -> ${P}.tar.gz
+ https://github.com/falcosecurity/libs/archive/${LIBS_COMMIT}.tar.gz -> falcosecurity-libs-${LIBS_COMMIT}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="+modules"
+REQUIRED_USE="${LUA_REQUIRED_USE}"
+
+RDEPEND="${LUA_DEPS}
+ app-misc/jq
+ dev-cpp/tbb:=
+ dev-cpp/yaml-cpp:=
+ dev-libs/libb64:=
+ dev-libs/openssl:=
+ dev-libs/protobuf:=
+ net-dns/c-ares:=
+ net-libs/grpc:=
+ net-misc/curl
+ sys-libs/ncurses:=
+ sys-libs/zlib:="
+
+DEPEND="${RDEPEND}
+ dev-cpp/nlohmann_json
+ dev-cpp/valijson
+ virtual/os-headers"
+
+# for now pin the driver to the same ebuild version
+PDEPEND="modules? ( =dev-util/scap-driver-${PV}* )"
+
+src_prepare() {
+ # manually apply patch to falcosecurity-libs dependency
+ pushd $WORKDIR && eapply -p0 "${FILESDIR}/${PV}-libs-gcc13.patch" && popd
+
+ sed -i -e 's:-ggdb::' CMakeLists.txt || die
+ cmake_src_prepare
+}
+
+src_configure() {
+ local mycmakeargs=(
+ # don't build driver
+ -DBUILD_DRIVER=OFF
+
+ # libscap examples are not installed or really useful
+ -DBUILD_LIBSCAP_EXAMPLES=OFF
+
+ # point to the falcosecurity-libs tree
+ -DFALCOSECURITY_LIBS_SOURCE_DIR="${WORKDIR}"/libs-${LIBS_COMMIT}
+
+ # explicitly set version
+ -DSYSDIG_VERSION=${PV}
+
+ # unbundle the deps
+ -DUSE_BUNDLED_DEPS=OFF
+
+ # add valijson include path to prevent downloading
+ -DVALIJSON_INCLUDE="${ESYSROOT}"/usr/include
+
+ # enable chisels
+ -DWITH_CHISEL=ON
+ )
+
+ cmake_src_configure
+}
+
+src_install() {
+ cmake_src_install
+
+ # remove driver headers
+ rm -r "${ED}"/usr/src || die
+
+ # move bashcomp to the proper location
+ dobashcomp "${ED}"/usr/etc/bash_completion.d/sysdig || die
+ rm -r "${ED}"/usr/etc || die
+}
next reply other threads:[~2023-04-29 6:44 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-29 6:44 Sam James [this message]
-- strict thread matches above, loose matches on Subject: below --
2021-12-19 21:30 [gentoo-commits] repo/gentoo:master commit in: dev-util/sysdig/files/, dev-util/sysdig/ Sam James
2019-08-22 6:49 Michał Górny
2019-05-23 7:13 Michał Górny
2019-03-11 21:44 Michał Górny
2017-09-11 20:16 Michał Górny
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1682750647.d983f3ebed360ac08d153655777912f354f3dd2f.sam@gentoo \
--to=sam@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox