define _GNU_SOURCE via autoconf

This commit is contained in:
john30
2017-03-04 14:00:39 +01:00
parent d168dd31e0
commit 3b26cf1f38
3 changed files with 4 additions and 5 deletions
+1
View File
@@ -3,6 +3,7 @@ m4_ifndef([m4_esyscmd_s], [m4_define([m4_chomp_all], [m4_format([[%.*s]], m4_bre
m4_ifndef([m4_esyscmd_s], [m4_define([m4_esyscmd_s], [m4_chomp_all(m4_esyscmd([$1]))])]) m4_ifndef([m4_esyscmd_s], [m4_define([m4_esyscmd_s], [m4_chomp_all(m4_esyscmd([$1]))])])
AC_PREREQ([2.63]) AC_PREREQ([2.63])
AC_INIT([ebusd], m4_esyscmd_s([cat VERSION]), [ebusd@ebusd.eu], [ebusd], [https://github.com/john30/ebusd]) AC_INIT([ebusd], m4_esyscmd_s([cat VERSION]), [ebusd@ebusd.eu], [ebusd], [https://github.com/john30/ebusd])
AC_GNU_SOURCE
AC_CONFIG_AUX_DIR([build]) AC_CONFIG_AUX_DIR([build])
AC_CONFIG_MACRO_DIR([m4]) AC_CONFIG_MACRO_DIR([m4])
+3 -1
View File
@@ -16,7 +16,9 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>. * along with this program. If not, see <http://www.gnu.org/licenses/>.
*/ */
#define _GNU_SOURCE #ifdef HAVE_CONFIG_H
# include <config.h>
#endif
#include "lib/utils/log.h" #include "lib/utils/log.h"
#include <stdlib.h> #include <stdlib.h>
-4
View File
@@ -20,10 +20,6 @@
# include <config.h> # include <config.h>
#endif #endif
#ifdef HAVE_PTHREAD_SETNAME_NP
# define _GNU_SOURCE
#endif
#include "lib/utils/thread.h" #include "lib/utils/thread.h"
#include "lib/utils/clock.h" #include "lib/utils/clock.h"