diff options
author | Simon Josefsson <simon@josefsson.org> | 2006-03-08 13:22:23 +0000 |
---|---|---|
committer | Simon Josefsson <simon@josefsson.org> | 2006-03-08 13:22:23 +0000 |
commit | 652a7a36dacf900f089bdc9e7b6b3ed626c88d3f (patch) | |
tree | c60e991175a89579113041e8d4f71abec1bcda63 /gl | |
parent | 9471e2d45db98939ef9e823780df4a4a07ed4425 (diff) | |
download | libtasn1-652a7a36dacf900f089bdc9e7b6b3ed626c88d3f.tar.gz libtasn1-652a7a36dacf900f089bdc9e7b6b3ed626c88d3f.tar.bz2 libtasn1-652a7a36dacf900f089bdc9e7b6b3ed626c88d3f.zip |
Update.
Diffstat (limited to 'gl')
-rw-r--r-- | gl/Makefile.am | 12 | ||||
-rw-r--r-- | gl/getopt.c | 4 | ||||
-rw-r--r-- | gl/m4/gnulib-comp.m4 | 2 | ||||
-rw-r--r-- | gl/m4/unistd_h.m4 | 18 |
4 files changed, 33 insertions, 3 deletions
diff --git a/gl/Makefile.am b/gl/Makefile.am index 7cfd6b9..46f5c35 100644 --- a/gl/Makefile.am +++ b/gl/Makefile.am @@ -45,6 +45,18 @@ libgnu_la_SOURCES += gettext.h ## end gnulib module gettext-h +## begin gnulib module unistd + +BUILT_SOURCES += $(UNISTD_H) + +# We need the following in order to create an empty placeholder for +# <unistd.h> when the system doesn't have one. +unistd.h: + echo '/* Empty placeholder for $@. */' >$@ +MOSTLYCLEANFILES += unistd.h + +## end gnulib module unistd + ## begin gnulib module dummy libgnu_la_SOURCES += dummy.c diff --git a/gl/getopt.c b/gl/getopt.c index b74deef..d75f214 100644 --- a/gl/getopt.c +++ b/gl/getopt.c @@ -29,9 +29,7 @@ #include <stdio.h> #include <stdlib.h> #include <string.h> -#ifdef HAVE_UNISTD_H -# include <unistd.h> -#endif +#include <unistd.h> #ifdef VMS # include <unixlib.h> diff --git a/gl/m4/gnulib-comp.m4 b/gl/m4/gnulib-comp.m4 index faa6265..0b78d83 100644 --- a/gl/m4/gnulib-comp.m4 +++ b/gl/m4/gnulib-comp.m4 @@ -29,6 +29,7 @@ AC_DEFUN([gl_INIT], gl_GETOPT gl_FUNC_MEMMOVE gl_FUNC_STRDUP + gl_HEADER_UNISTD ]) # This macro records the list of files which have been installed by @@ -49,4 +50,5 @@ AC_DEFUN([gl_FILE_LIST], [ m4/memmove.m4 m4/onceonly_2_57.m4 m4/strdup.m4 + m4/unistd_h.m4 ]) diff --git a/gl/m4/unistd_h.m4 b/gl/m4/unistd_h.m4 new file mode 100644 index 0000000..9c77f9b --- /dev/null +++ b/gl/m4/unistd_h.m4 @@ -0,0 +1,18 @@ +# unistd_h.m4 serial 2 +dnl Copyright (C) 2006 Free Software Foundation, Inc. +dnl This file is free software; the Free Software Foundation +dnl gives unlimited permission to copy and/or distribute it, +dnl with or without modifications, as long as this notice is preserved. + +dnl Written by Simon Josefsson + +AC_DEFUN([gl_HEADER_UNISTD], +[ + dnl Prerequisites of lib/unistd.h. + AC_CHECK_HEADERS([unistd.h], [ + UNISTD_H='' + ], [ + UNISTD_H='unistd.h' + ]) + AC_SUBST(UNISTD_H) +]) |