]> git.ipfire.org Git - thirdparty/iproute2.git/commitdiff
configure: Add _GNU_SOURCE to strlcpy configure test
authorSam James <sam@gentoo.org>
Sat, 2 Dec 2023 02:47:04 +0000 (02:47 +0000)
committerDavid Ahern <dsahern@kernel.org>
Wed, 6 Dec 2023 17:02:28 +0000 (17:02 +0000)
>=glibc-2.38 adds strlcpy but it's guarded under a feature-test macro. Just
add _GNU_SOURCE to the configure test because we already pass _GNU_SOURCE unconditionally
in the Makefiles when building iproute2.

Signed-off-by: Sam James <sam@gentoo.org>
Signed-off-by: David Ahern <dsahern@kernel.org>
configure

index eb689341d17d0d053553f74aa1165c5f2bf499c2..78bc52c008f822f61479543c1b53136eb936a288 100755 (executable)
--- a/configure
+++ b/configure
@@ -445,6 +445,7 @@ EOF
 check_strlcpy()
 {
     cat >$TMPDIR/strtest.c <<EOF
+#define _GNU_SOURCE
 #include <string.h>
 int main(int argc, char **argv) {
        char dst[10];