diff options
author | 2025-01-09 16:09:39 +0400 | |
---|---|---|
committer | 2025-01-10 10:09:00 +0100 | |
commit | 47a80abd5c3fdd6ed00b2085324f60f093f031e5 (patch) | |
tree | 9d09cf9bd69b96a46bed91661bdecbe17c1208e4 /media-sound | |
parent | dev-vcs/stgit: version bump 2.5.0, drop 2.4.12 (diff) | |
download | gentoo-47a80abd5c3fdd6ed00b2085324f60f093f031e5.tar.gz gentoo-47a80abd5c3fdd6ed00b2085324f60f093f031e5.tar.bz2 gentoo-47a80abd5c3fdd6ed00b2085324f60f093f031e5.zip |
media-sound/flake: fix direct calls to cc, impl. declarations
Bespoke configure demands bespoke methods. Also prepare for C23
Closes: https://bugs.gentoo.org/947767
Signed-off-by: NHOrus <jy6x2b32pie9@yahoo.com>
Closes: https://github.com/gentoo/gentoo/pull/40068
Signed-off-by: Miroslav Šulc <fordfrog@gentoo.org>
Diffstat (limited to 'media-sound')
-rw-r--r-- | media-sound/flake/files/flake-0.11-make-instability.patch | 24 | ||||
-rw-r--r-- | media-sound/flake/flake-0.11-r1.ebuild (renamed from media-sound/flake/flake-0.11.ebuild) | 6 |
2 files changed, 29 insertions, 1 deletions
diff --git a/media-sound/flake/files/flake-0.11-make-instability.patch b/media-sound/flake/files/flake-0.11-make-instability.patch index ac2bd95859fb..66cb47a4e53d 100644 --- a/media-sound/flake/files/flake-0.11-make-instability.patch +++ b/media-sound/flake/files/flake-0.11-make-instability.patch @@ -31,3 +31,27 @@ diff -ru a/flake/Makefile b/flake/Makefile flake_g$(EXESUF): flake.o wav.o $(DEP_LIBS) $(CC) $(FLAKE_LIBDIRS) $(LDFLAGS) -o $@ flake.o wav.o $(FLAKE_LIBS) $(EXTRALIBS) cp -p flake_g$(EXESUF) flake$(EXESUF) +Clean up implicit declaration in configure and prepare for C23 +diff -ru a/configure b/configure +@@ -666,6 +667,7 @@ + # test for strnlen in string.h + check_exec <<EOF && have_strnlen=yes || have_strnlen=no + #define _ISOC9X_SOURCE 1 ++#define _GNU_SOURCE 1 ++#include <strings.h> + #include <string.h> + int main( void ) { return (strnlen("help", 6) == 4)?0:1; } + EOF +diff -ru a/common.h b/common.h +--- a/common.h 2025-01-09 16:06:00.978525674 +0400 ++++ b//common.h 2025-01-09 16:07:06.592168373 +0400 +@@ -87,7 +87,8 @@ + return i; + } + #elif !defined(__USE_GNU) +-extern size_t strnlen(const char *s, size_t maxlen); ++#include <strings.h> ++//extern size_t strnlen(const char *s, size_t maxlen); + #endif + + #endif /* COMMON_H */ diff --git a/media-sound/flake/flake-0.11.ebuild b/media-sound/flake/flake-0.11-r1.ebuild index 995a85be4f49..25a2b34a6e6f 100644 --- a/media-sound/flake/flake-0.11.ebuild +++ b/media-sound/flake/flake-0.11-r1.ebuild @@ -16,7 +16,11 @@ KEYWORDS="amd64 x86" PATCHES=("${FILESDIR}"/${P}-make-instability.patch) src_configure() { - # NIH configure script + # NIH configure script that uses hardcoded cc for discovery + # https://bugs.gentoo.org/947767 + sed -i -e "s:cc=\"gcc\":cc=\"$(tc-getCC)\":" configure \ + || die failed to patch CC + ./configure \ --ar="$(tc-getAR)" \ --cc="$(tc-getCC)" \ |