From 2f51b4c0bc28238a03d5239cac591e1acf3b0dce Mon Sep 17 00:00:00 2001 From: Juan RP Date: Fri, 27 Dec 2019 16:19:37 +0100 Subject: [PATCH] xbps_init: fix warning on glibc. --- lib/initend.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/initend.c b/lib/initend.c index 5efb21e2..acba0c1c 100644 --- a/lib/initend.c +++ b/lib/initend.c @@ -107,7 +107,10 @@ xbps_init(struct xbps_handle *xhp) if ((native_arch = getenv("XBPS_ARCH")) != NULL) { xbps_strlcpy(xhp->native_arch, native_arch, sizeof (xhp->native_arch)); } else { +#if defined(__linux__) && !defined(__GLIBC__) + /* musl libc on linux */ char *s = NULL; +#endif struct utsname un; if (uname(&un) == -1) return ENOTSUP;