summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarek Szuba <marecki@gentoo.org>2023-08-22 00:55:21 +0100
committerMarek Szuba <marecki@gentoo.org>2023-08-22 01:26:16 +0100
commitcd98bb25989a12fb6d7bea3fe6d6c0e2490c2ecd (patch)
tree5e81b1f7eaf8d4eff256c73730993f90175cc219 /dev-libs/sentry-native
parentsys-apps/baselayout: drop 2.13-r1 (diff)
downloadgentoo-cd98bb25989a12fb6d7bea3fe6d6c0e2490c2ecd.tar.gz
gentoo-cd98bb25989a12fb6d7bea3fe6d6c0e2490c2ecd.tar.bz2
gentoo-cd98bb25989a12fb6d7bea3fe6d6c0e2490c2ecd.zip
dev-libs/sentry-native: new package, add 0.6.5
Needed by >=mail-mta/proton-mail-bridge-3[gui]. Signed-off-by: Marek Szuba <marecki@gentoo.org>
Diffstat (limited to 'dev-libs/sentry-native')
-rw-r--r--dev-libs/sentry-native/Manifest1
-rw-r--r--dev-libs/sentry-native/files/sentry-native-0.6.5_no-fuzz-test.patch20
-rw-r--r--dev-libs/sentry-native/metadata.xml15
-rw-r--r--dev-libs/sentry-native/sentry-native-0.6.5.ebuild42
4 files changed, 78 insertions, 0 deletions
diff --git a/dev-libs/sentry-native/Manifest b/dev-libs/sentry-native/Manifest
new file mode 100644
index 000000000000..edea38c2f4c5
--- /dev/null
+++ b/dev-libs/sentry-native/Manifest
@@ -0,0 +1 @@
+DIST sentry-native-0.6.5.tar.gz 325573 BLAKE2B 6308bef5cc194c3eb8f6f30d1ee894f3d7528d31604f26d6d54cfcc1545ef561346f60c9f35e80662431ad6145cf27a4adac70255b01f230551a541fd4dae709 SHA512 0c0be06f72f53277c9a34ca6514dc96ad14b4239ee92ae65e00d45a515ce13bc314982a651c476ddbb453079ea3fc3fa0bb75cc683dce046f69f0fe1d024f32e
diff --git a/dev-libs/sentry-native/files/sentry-native-0.6.5_no-fuzz-test.patch b/dev-libs/sentry-native/files/sentry-native-0.6.5_no-fuzz-test.patch
new file mode 100644
index 000000000000..70231c02da9e
--- /dev/null
+++ b/dev-libs/sentry-native/files/sentry-native-0.6.5_no-fuzz-test.patch
@@ -0,0 +1,20 @@
+On the one hand the bundled upstream README only mentions sentry_test_unit
+as a test suite meant for the users to run, on the other comments
+in sentry_fuzz_json sources state that it has to be built in a very
+special - and performance-killing - way in order to work.
+
+--- a/tests/unit/CMakeLists.txt
++++ b/tests/unit/CMakeLists.txt
+@@ -89,6 +89,7 @@
+
+ add_test(NAME sentry_test_unit COMMAND sentry_test_unit)
+
++if(0)
+ add_executable(sentry_fuzz_json
+ ${SENTRY_SOURCES}
+ fuzz.c
+@@ -114,3 +115,4 @@
+ endif()
+
+ add_test(NAME sentry_fuzz_json COMMAND sentry_fuzz_json)
++endif()
diff --git a/dev-libs/sentry-native/metadata.xml b/dev-libs/sentry-native/metadata.xml
new file mode 100644
index 000000000000..aecfa74c176a
--- /dev/null
+++ b/dev-libs/sentry-native/metadata.xml
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>marecki@gentoo.org</email>
+ <name>Marek Szuba</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">getsentry/sentry-native</remote-id>
+ </upstream>
+ <use>
+ <flag name="breakpad">Use <pkg>dev-util/breakpad</pkg> as the crash handler</flag>
+ <flag name="curl">Enable support for automated uploading of crash reports</flag>
+ </use>
+</pkgmetadata>
diff --git a/dev-libs/sentry-native/sentry-native-0.6.5.ebuild b/dev-libs/sentry-native/sentry-native-0.6.5.ebuild
new file mode 100644
index 000000000000..c3aebc25ea41
--- /dev/null
+++ b/dev-libs/sentry-native/sentry-native-0.6.5.ebuild
@@ -0,0 +1,42 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake
+
+DESCRIPTION="Sentry SDK for C, C++ and native applications"
+HOMEPAGE="https://sentry.io/ https://github.com/getsentry/sentry-native"
+SRC_URI="https://github.com/getsentry/${PN}/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="+breakpad +curl test"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ breakpad? ( dev-util/breakpad )
+ curl? ( net-misc/curl )
+"
+DEPEND="${RDEPEND}"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-0.6.5_no-fuzz-test.patch
+)
+
+src_configure() {
+ local mycmakeargs=(
+ -DSENTRY_BUILD_EXAMPLES=OFF
+ -DSENTRY_BACKEND=$(usex breakpad "breakpad" "inproc")
+ -DSENTRY_BUILD_TESTS=$(usex test)
+ -DSENTRY_TRANSPORT=$(usex curl "curl" "none")
+ )
+ # Avoid "not used by the project" warnings when USE=-breakpad
+ if use breakpad; then
+ mycmakeargs+=( -DSENTRY_BREAKPAD_SYSTEM=ON )
+ fi
+
+ cmake_src_configure
+}