summaryrefslogtreecommitdiff
path: root/dev-libs/libspt
diff options
context:
space:
mode:
Diffstat (limited to 'dev-libs/libspt')
-rw-r--r--dev-libs/libspt/Manifest2
-rw-r--r--dev-libs/libspt/files/libspt-1.1-timeval-in-utmp.patch17
-rw-r--r--dev-libs/libspt/libspt-1.1-r5.ebuild51
3 files changed, 70 insertions, 0 deletions
diff --git a/dev-libs/libspt/Manifest b/dev-libs/libspt/Manifest
index 4ac912eaac2c..1530425843ad 100644
--- a/dev-libs/libspt/Manifest
+++ b/dev-libs/libspt/Manifest
@@ -1,7 +1,9 @@
+AUX libspt-1.1-timeval-in-utmp.patch 475 BLAKE2B 8aee32045cb1d786604e46b0d0d7918646b6af57ef8fb4a781df2981fc7ff022d6200d6fbca41fe7a1a525cf49026ea3e535bfb6d76fc4aaa5aecd484a6daadd SHA512 06576a4c161c8477eb04cf758a221a328d1448afa604026c54931e2ea66eb2d629f11fc7da81d4d726f56cd8d6596c8091e13e54485c234ffa7867069e6567d4
AUX libspt-gentoo.patch 727 BLAKE2B a98df11f3789d5e8c2aabfd538210db025a59567286df8153cc3912a7df414ad8328ba4de04cd558e3c7884102d4b431bc3c584a6f0c883a663f681fbf96bf90 SHA512 9c73f4b3eae1af1bd26d4c08eb926847fb7d8f26cb3e472afa940d12b086f5a142e9f918cab1beeebfc45e2893480a185180cc9b4bfe5930bb0cafe6b66098d0
AUX libspt-gettimeofday.patch 402 BLAKE2B 277b0b563e1b1d08270c8b0c2837f8445b79c3532c8a35468b8f4e382fe7ea635e06700cc5876aa781cfec7149ad76b1a6adab508afd02bb767ad644feacc043 SHA512 4455b243ada87ede8e84e106097e5f6c4aecf90aaac9eb3e53c7cfebe86c1d977037e541a53a5e70d0957e0f4b963f9c92d6a72139b6c77a0fe2f5a210d65156
AUX libspt-glibc-2.30.patch 233 BLAKE2B 4cc03c14f2d879566987f56e91c3f467120a7e49648c0814535c02b129e49f4d7185edac370f17e58428e180056dce31844a1accfa6503f0ebfde32c53571f0c SHA512 8f064315215fb99d7302b544b7a3da1c239bba21e8ffdc21b0bd05e496bb0ddd54ae5ed55c36b9fc0386026d007f19082d1eee95264edda1a124e9629c5093c9
AUX libspt-rpc.patch 848 BLAKE2B 982a1b8d88e2a28cb6529dd4a6c2e15c42aa7f0b0bbe34d40d91a6bb45ee2667253cabb06f31bdb757dcec7d4daf066f1271aa33edebeadfda2ba341bdd39dde SHA512 ad703547047949aa338bea0bd211a7daa3448ce728cf754be6ba4c0a058e0ab631beceb044bcce0eba9fe606b741f530fb88909891b0e86ff8898cfcf04d6cd1
DIST libspt-1.1.tar.bz2 165168 BLAKE2B a21778ba8b3c22d7fa655460ede0d04efc98635b1be74575cbb996b33bdb27ed75479ae6a2d7bc38c1052ac23547483e9d93c03531cbfe236e1e07944bad1673 SHA512 5b2ec289ce51f1f2040b68c559ef6e1ea1e59f50c3d639a93176fa8a5f3f75481651c4d0acd393eac8d2193f2aae19f882897323caf344cbfde52e32cc3a02b9
EBUILD libspt-1.1-r4.ebuild 897 BLAKE2B aa84fdc078a1edbaa3bbb09c653b8e317d4e2a914ec679ccb00538e79edafc98b360f3b98612a11ef3733992296c3abaf451c85ef1f2f0729aa55f1c89a1a883 SHA512 a87f7cd0bc6870b8f319f2beaa8bb7021c2189bc0e67ec00bce36533f3dd564cee65ae0a68a8d6ef5ea41128fba1a9e70870de0c8c1b71d3a0c1ee71239de5b1
+EBUILD libspt-1.1-r5.ebuild 924 BLAKE2B 6a63ff11c598a6fbebe3bf26c42d3255850b579026842c922ba865b74fdc91d81067d47596e46c0ff15f055d766e508f4db5cc5470f560ceb0921755ad60469f SHA512 1ebf427185b6404791e61cd23712c64c3de6cb7ef2197544137e7456f1a93243447931532f73ddec1b395cd21336becfa78a64726039bbb571ae7041fe1d1288
MISC metadata.xml 235 BLAKE2B a3e5a3109b59e3f97ef14f8d55ba13b16dc5371a1b7d6f238230aa4494db32dd4a42e3ee012ec8b18fae394feb2b1b56882bc70504aa7c6b969c1b20140f0ece SHA512 7c4e5f5dea465e45c662f5f53513626088aff514e1326593426af227d77e63d8a00d8af05aa208881a399f83dd41e73cd2ef81c8b7f275a2fa891f295231d67c
diff --git a/dev-libs/libspt/files/libspt-1.1-timeval-in-utmp.patch b/dev-libs/libspt/files/libspt-1.1-timeval-in-utmp.patch
new file mode 100644
index 000000000000..ad27b9161f1d
--- /dev/null
+++ b/dev-libs/libspt/files/libspt-1.1-timeval-in-utmp.patch
@@ -0,0 +1,17 @@
+Switch to canonic handling of timeval possibly embedded in
+struct utmp, see manpage.
+https://bugs.gentoo.org/943014
+--- a/sptagent.c
++++ b/sptagent.c
+@@ -1033,7 +1033,10 @@
+ {
+ #ifdef HAVE_UTMP_UT_TV
+ #ifdef HAVE_GETTIMEOFDAY
+- gettimeofday(&utptr->ut_tv, NULL);
++ struct timeval tv;
++ gettimeofday(&tv, NULL);
++ utptr->ut_tv.tv_sec = tv.tv_sec;
++ utptr->ut_tv.tv_usec = tv.tv_usec;
+ #else
+ utptr->ut_tv.tv_sec = time(NULL);
+ utptr->ut_tv.ut_usec = 0;
diff --git a/dev-libs/libspt/libspt-1.1-r5.ebuild b/dev-libs/libspt/libspt-1.1-r5.ebuild
new file mode 100644
index 000000000000..7d9528b5db21
--- /dev/null
+++ b/dev-libs/libspt/libspt-1.1-r5.ebuild
@@ -0,0 +1,51 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools
+
+DESCRIPTION="Library for handling root privilege"
+HOMEPAGE="http://www.j10n.org/libspt/"
+SRC_URI="http://www.j10n.org/${PN}/${P}.tar.bz2"
+
+LICENSE="BSD-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~sparc ~x86"
+IUSE="suid"
+RESTRICT="test"
+
+RDEPEND="net-libs/libtirpc"
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-gentoo.patch"
+ "${FILESDIR}/${PN}-glibc-2.30.patch"
+ "${FILESDIR}/${PN}-rpc.patch"
+ "${FILESDIR}/${PN}-gettimeofday.patch"
+ "${FILESDIR}/${P}-timeval-in-utmp.patch"
+)
+
+src_prepare() {
+ rm aclocal.m4
+
+ default
+ eautoreconf
+}
+
+src_configure() {
+ econf \
+ --with-libtirpc
+}
+
+src_install() {
+ default
+
+ # no static archives
+ find "${ED}" -name '*.la' -delete || die
+
+ if use suid; then
+ fperms 4755 /usr/libexec/sptagent
+ fi
+}