summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJosiah Mullins <JoMull01@protonmail.com>2023-03-29 11:35:49 -0400
committerJoonas Niilola <juippis@gentoo.org>2023-04-10 11:10:02 +0300
commitf0540c6ca7d2220a420537c68666e6dde3621585 (patch)
tree881445c167e79077be001b02ea9031a38a65efda /net-im/toxic
parentnet-im/toxic: Added python 3.11 to PYTHON_COMPAT (diff)
downloadgentoo-f0540c6ca7d2220a420537c68666e6dde3621585.tar.gz
gentoo-f0540c6ca7d2220a420537c68666e6dde3621585.tar.bz2
gentoo-f0540c6ca7d2220a420537c68666e6dde3621585.zip
net-im/toxic: Fixes implicit function declaration
This commit adds an include statement and a macro declaration to the USER_CFLAGS variable. The include statement includes strings.h for strcasecmp (see man strcasecmp). The macro declaration causes strcasestr to be included (see man strcasestr). Closes: https://bugs.gentoo.org/897856 Signed-off-by: Josiah Mullins <JoMull01@protonmail.com> Closes: https://github.com/gentoo/gentoo/pull/30400 Signed-off-by: Joonas Niilola <juippis@gentoo.org>
Diffstat (limited to 'net-im/toxic')
-rw-r--r--net-im/toxic/toxic-0.11.1-r1.ebuild (renamed from net-im/toxic/toxic-0.11.1.ebuild)4
-rw-r--r--net-im/toxic/toxic-0.11.3-r1.ebuild (renamed from net-im/toxic/toxic-0.11.3.ebuild)4
2 files changed, 6 insertions, 2 deletions
diff --git a/net-im/toxic/toxic-0.11.1.ebuild b/net-im/toxic/toxic-0.11.1-r1.ebuild
index fead2de553a3..1a535eb7fcaa 100644
--- a/net-im/toxic/toxic-0.11.1.ebuild
+++ b/net-im/toxic/toxic-0.11.1-r1.ebuild
@@ -101,7 +101,9 @@ src_configure() {
if ! use X; then
export DISABLE_X11=1
fi
- export USER_CFLAGS="${CFLAGS}"
+ #include strings.h fixes undefined reference to strcasecmp()
+ #defining _GNU_SOURCE fixes undefined reference to strcasestr()
+ export USER_CFLAGS="${CFLAGS} -include strings.h -D _GNU_SOURCE"
export USER_LDFLAGS="${LDFLAGS}"
#set install directory to /usr.
sed -i -e "s,/usr/local,${EPREFIX}/usr,g" cfg/global_vars.mk || die "Failed to set install directory!"
diff --git a/net-im/toxic/toxic-0.11.3.ebuild b/net-im/toxic/toxic-0.11.3-r1.ebuild
index a436039ffa9e..4a42d75791c5 100644
--- a/net-im/toxic/toxic-0.11.3.ebuild
+++ b/net-im/toxic/toxic-0.11.3-r1.ebuild
@@ -101,7 +101,9 @@ src_configure() {
if ! use X; then
export DISABLE_X11=1
fi
- export USER_CFLAGS="${CFLAGS}"
+ #Including strings.h fixes undefined reference to strcasecmp()
+ #Defining _GNU_SOURCE fixes undefined reference to strcasestr()
+ export USER_CFLAGS="${CFLAGS} -include strings.h -D _GNU_SOURCE"
export USER_LDFLAGS="${LDFLAGS}"
#set install directory to /usr.
sed -i -e "s,/usr/local,${EPREFIX}/usr,g" cfg/global_vars.mk || die "Failed to set install directory!"