1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Fixes needed to compile with musl C library

Patch originally by Codarren Velvindron
This commit is contained in:
Monty
2016-02-07 15:00:30 +02:00
parent 07b8aefe90
commit d80b8442a6
7 changed files with 18 additions and 9 deletions

View File

@ -831,7 +831,7 @@ void my_strerror(char *buf, size_t len, int nr)
(defined _XOPEN_SOURCE && (_XOPEN_SOURCE >= 600))) && \
! defined _GNU_SOURCE
strerror_r(nr, buf, len); /* I can build with or without GNU */
#elif defined _GNU_SOURCE
#elif defined(__GLIBC__) && defined (_GNU_SOURCE)
char *r= strerror_r(nr, buf, len);
if (r != buf) /* Want to help, GNU? */
strmake(buf, r, len - 1); /* Then don't. */