public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Michael Orlitzky" <mjo@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-auth/oath-toolkit/files/, sys-auth/oath-toolkit/
Date: Sat, 31 Aug 2024 13:18:47 +0000 (UTC)	[thread overview]
Message-ID: <1725110310.6cd7e5165b7750317d42a65b9bc20ce65eec8302.mjo@gentoo> (raw)

commit:     6cd7e5165b7750317d42a65b9bc20ce65eec8302
Author:     Michael Orlitzky <mjo <AT> gentoo <DOT> org>
AuthorDate: Sat Aug 31 11:03:45 2024 +0000
Commit:     Michael Orlitzky <mjo <AT> gentoo <DOT> org>
CommitDate: Sat Aug 31 13:18:30 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6cd7e516

sys-auth/oath-toolkit: fix the build on musl

Add an upstream patch to fix the build on musl, and then fix a new
problem introduced by the patch: the build system is extremely sensitive
to mtime changes in the source tree, in that patching triggers a
rebuild of some Makefile sources, which ultimately tries to invoke
automake. We have to fudge the mtime on the patched file to avoid this.

Bug: https://bugs.gentoo.org/936309
Closes: https://bugs.gentoo.org/933086
Signed-off-by: Michael Orlitzky <mjo <AT> gentoo.org>

 .../files/oath-toolkit-2.6.11-fix-musl-build.patch | 24 ++++++++++++++++++++++
 sys-auth/oath-toolkit/oath-toolkit-2.6.11.ebuild   | 12 +++++++++++
 2 files changed, 36 insertions(+)

diff --git a/sys-auth/oath-toolkit/files/oath-toolkit-2.6.11-fix-musl-build.patch b/sys-auth/oath-toolkit/files/oath-toolkit-2.6.11-fix-musl-build.patch
new file mode 100644
index 000000000000..5affd40c3111
--- /dev/null
+++ b/sys-auth/oath-toolkit/files/oath-toolkit-2.6.11-fix-musl-build.patch
@@ -0,0 +1,24 @@
+From 65f37d4deb6ac87dd64df1bb281588d300a1bf3e Mon Sep 17 00:00:00 2001
+From: orbea <orbea@riseup.net>
+Date: Mon, 12 Feb 2024 18:18:31 -0800
+Subject: [PATCH] libpskc: fix implicit declaration with musl
+
+---
+ libpskc/global.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/libpskc/global.c b/libpskc/global.c
+index 1a514506..6082e11a 100644
+--- a/libpskc/global.c
++++ b/libpskc/global.c
+@@ -24,6 +24,7 @@
+ #include <pskc/pskc.h>
+ 
+ #include "internal.h"
++#include <stdlib.h>		/* free */
+ #include <string.h>		/* strverscmp */
+ #include <libxml/parser.h>	/* xmlInitParser */
+ #include <libxml/catalog.h>	/* xmlLoadCatalog */
+-- 
+GitLab
+

diff --git a/sys-auth/oath-toolkit/oath-toolkit-2.6.11.ebuild b/sys-auth/oath-toolkit/oath-toolkit-2.6.11.ebuild
index 03d2801fa64c..80f393cfd4d0 100644
--- a/sys-auth/oath-toolkit/oath-toolkit-2.6.11.ebuild
+++ b/sys-auth/oath-toolkit/oath-toolkit-2.6.11.ebuild
@@ -27,6 +27,8 @@ BDEPEND="
 	test? ( dev-libs/libxml2 )
 "
 
+PATCHES=( "${FILESDIR}/${P}-fix-musl-build.patch" )
+
 QA_CONFIG_IMPL_DECL_SKIP=(
 	MIN # glibc fp
 	unreachable
@@ -34,6 +36,16 @@ QA_CONFIG_IMPL_DECL_SKIP=(
 	static_assert
 )
 
+src_prepare() {
+	default
+
+	# After patching, we have to fix the mtime on libpskc/global.c so
+	# that it doesn't cause Makefile.gdoc to be rebuilt so that it
+	# doesn't cause Makefile.in to be rebuilt so that it doesn't try to
+	# run automake-1.16.5 for no reason. Bug 936309.
+	touch --reference=libpskc/errors.c libpskc/global.c || die
+}
+
 src_configure() {
 	local myeconfargs=(
 		--cache-file="${S}"/config.cache


             reply	other threads:[~2024-08-31 13:18 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-31 13:18 Michael Orlitzky [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-11-01 16:07 [gentoo-commits] repo/gentoo:master commit in: sys-auth/oath-toolkit/files/, sys-auth/oath-toolkit/ Andreas K. Hüttel
2023-03-05 12:37 Sam James
2018-10-27 20:17 Andreas Hüttel

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=1725110310.6cd7e5165b7750317d42a65b9bc20ce65eec8302.mjo@gentoo \
    --to=mjo@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