From: Hans-Christian Egtvedt Date: Mon, 8 Dec 2008 10:55:27 +0000 (+0100) Subject: alsa-utils check if __USE_BSD is defined before compiling "BSD functions" X-Git-Tag: v1.0.19~3 X-Git-Url: https://git.alsa-project.org/?a=commitdiff_plain;h=e3dfc7470e47f35127c07004beda94cb13f325ec;p=alsa-utils.git alsa-utils check if __USE_BSD is defined before compiling "BSD functions" Another bug/issue I tripped over when compiling alsa-utils in an environment using uClibc to supply the C library functions. Here I have enabled some old BSD style functions. The attached patch will honor them if they are enabled. Without this patch I get a redefined error during compile. Signed-off-by: Takashi Iwai --- diff --git a/alsactl/init_sysdeps.c b/alsactl/init_sysdeps.c index f263138..3aca1b4 100644 --- a/alsactl/init_sysdeps.c +++ b/alsactl/init_sysdeps.c @@ -17,7 +17,7 @@ * */ -#ifdef __GLIBC__ +#if defined(__GLIBC__) && !(defined(__UCLIBC__) && defined(__USE_BSD)) static size_t strlcpy(char *dst, const char *src, size_t size) { size_t bytes = 0;