1
0
mirror of git://git.sv.gnu.org/coreutils.git synced 2026-02-23 07:35:35 +02:00
Files
coreutils/m4/gnu-source.m4

26 lines
665 B
Plaintext
Raw Normal View History

2000-07-10 08:26:36 +00:00
#serial 2
2000-07-09 17:24:41 +00:00
# Make sure _GNU_SOURCE is defined where necessary: as early as possible
# for configure-time tests, as well as for every source file that includes
# config.h.
# From Jim Meyering.
AC_DEFUN(AC__GNU_SOURCE,
[
# Make sure that _GNU_SOURCE is defined for all subsequent
# configure-time compile tests.
# This definition must be emitted (into confdefs.h) before any
# test that involves compilation.
2000-07-10 08:26:36 +00:00
cat >>confdefs.h <<\EOF
2000-07-09 17:24:41 +00:00
#ifndef _GNU_SOURCE
# define _GNU_SOURCE
2000-07-10 08:26:36 +00:00
#endif
EOF
2000-07-09 17:24:41 +00:00
# Emit this code into config.h.in.
# The ifndef is to avoid redefinition warnings.
AH_VERBATIM([_GNU_SOURCE], [#ifndef _GNU_SOURCE
# define _GNU_SOURCE
#endif])
])