diff options
author | Bruno Haible <bruno@clisp.org> | 2009-12-11 01:15:28 +0100 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2009-12-11 01:15:28 +0100 |
commit | 6948250861edce048d7bb3c6b47d13fa3649905e (patch) | |
tree | c3d1c4a2e42938d93a07095345cb18567fa44710 /modules | |
parent | 441aa3044f43e5572f58c354f01e6bc070acd5c7 (diff) | |
download | gnulib-6948250861edce048d7bb3c6b47d13fa3649905e.tar.gz |
New module 'arg-nonnull'. Declare which arguments expect non-NULL values.
Diffstat (limited to 'modules')
-rw-r--r-- | modules/arg-nonnull | 31 | ||||
-rw-r--r-- | modules/argv-iter | 1 | ||||
-rw-r--r-- | modules/arpa_inet | 4 | ||||
-rw-r--r-- | modules/dirent | 4 | ||||
-rw-r--r-- | modules/fcntl-h | 4 | ||||
-rw-r--r-- | modules/fnmatch | 6 | ||||
-rw-r--r-- | modules/getopt-posix | 4 | ||||
-rw-r--r-- | modules/glob | 4 | ||||
-rw-r--r-- | modules/iconv_open | 4 | ||||
-rw-r--r-- | modules/inttypes | 4 | ||||
-rw-r--r-- | modules/locale | 4 | ||||
-rw-r--r-- | modules/math | 4 | ||||
-rw-r--r-- | modules/netdb | 4 | ||||
-rw-r--r-- | modules/search | 4 | ||||
-rw-r--r-- | modules/signal | 4 | ||||
-rw-r--r-- | modules/spawn | 4 | ||||
-rw-r--r-- | modules/stdio | 4 | ||||
-rw-r--r-- | modules/stdlib | 4 | ||||
-rw-r--r-- | modules/string | 4 | ||||
-rw-r--r-- | modules/strings | 4 | ||||
-rw-r--r-- | modules/sys_socket | 4 | ||||
-rw-r--r-- | modules/sys_stat | 4 | ||||
-rw-r--r-- | modules/sys_time | 4 | ||||
-rw-r--r-- | modules/sys_times | 4 | ||||
-rw-r--r-- | modules/sys_utsname | 4 | ||||
-rw-r--r-- | modules/time | 4 | ||||
-rw-r--r-- | modules/unistd | 4 | ||||
-rw-r--r-- | modules/wchar | 4 |
28 files changed, 111 insertions, 27 deletions
diff --git a/modules/arg-nonnull b/modules/arg-nonnull new file mode 100644 index 0000000000..ed224bf7dc --- /dev/null +++ b/modules/arg-nonnull @@ -0,0 +1,31 @@ +Description: +A C macro for declaring that specific arguments must not be NULL. + +Files: +build-aux/arg-nonnull.h + +Depends-on: + +configure.ac: + +Makefile.am: +BUILT_SOURCES += arg-nonnull.h +# The arg-nonnull.h that gets inserted into generated .h files is the same as +# build-aux/arg-nonnull.h, except that it has the copyright header cut off. +arg-nonnull.h: $(top_srcdir)/build-aux/arg-nonnull.h + $(AM_V_GEN)rm -f $@-t $@ && \ + sed -n -e '/GL_ARG_NONNULL/,$$p' \ + < $(top_srcdir)/build-aux/arg-nonnull.h \ + > $@-t && \ + mv $@-t $@ +MOSTLYCLEANFILES += arg-nonnull.h arg-nonnull.h-t + +ARG_NONNULL_H=arg-nonnull.h + +Include: + +License: +LGPLv2+ + +Maintainer: +Bruno Haible diff --git a/modules/argv-iter b/modules/argv-iter index e9fc633915..3844b8a807 100644 --- a/modules/argv-iter +++ b/modules/argv-iter @@ -6,6 +6,7 @@ lib/argv-iter.c lib/argv-iter.h Depends-on: +arg-nonnull getdelim stdbool diff --git a/modules/arpa_inet b/modules/arpa_inet index 7eb9cc0567..e76c7e47fa 100644 --- a/modules/arpa_inet +++ b/modules/arpa_inet @@ -8,6 +8,7 @@ m4/arpa_inet_h.m4 Depends-on: include_next link-warning +arg-nonnull sys_socket configure.ac: @@ -19,7 +20,7 @@ BUILT_SOURCES += $(ARPA_INET_H) # We need the following in order to create <arpa/inet.h> when the system # doesn't have one. -arpa/inet.h: arpa_inet.in.h $(LINK_WARNING_H) +arpa/inet.h: arpa_inet.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_at)$(MKDIR_P) arpa $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ @@ -32,6 +33,7 @@ arpa/inet.h: arpa_inet.in.h $(LINK_WARNING_H) -e 's|@''HAVE_DECL_INET_NTOP''@|$(HAVE_DECL_INET_NTOP)|g' \ -e 's|@''HAVE_DECL_INET_PTON''@|$(HAVE_DECL_INET_PTON)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/arpa_inet.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/dirent b/modules/dirent index 110ec4520a..aed61e4ccd 100644 --- a/modules/dirent +++ b/modules/dirent @@ -9,6 +9,7 @@ m4/unistd_h.m4 Depends-on: include_next link-warning +arg-nonnull configure.ac: gl_DIRENT_H @@ -18,7 +19,7 @@ BUILT_SOURCES += $(DIRENT_H) # We need the following in order to create <dirent.h> when the system # doesn't have one that works with the given compiler. -dirent.h: dirent.in.h $(LINK_WARNING_H) +dirent.h: dirent.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ @@ -36,6 +37,7 @@ dirent.h: dirent.in.h $(LINK_WARNING_H) -e 's|@''REPLACE_FDOPENDIR''@|$(REPLACE_FDOPENDIR)|g' \ -e 's|@''REPLACE_OPENDIR''@|$(REPLACE_OPENDIR)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/dirent.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/fcntl-h b/modules/fcntl-h index eb5cce11dd..6eaec522b3 100644 --- a/modules/fcntl-h +++ b/modules/fcntl-h @@ -8,6 +8,7 @@ m4/fcntl_h.m4 Depends-on: include_next link-warning +arg-nonnull unistd extensions @@ -19,7 +20,7 @@ BUILT_SOURCES += $(FCNTL_H) # We need the following in order to create <fcntl.h> when the system # doesn't have one that works with the given compiler. -fcntl.h: fcntl.in.h $(LINK_WARNING_H) +fcntl.h: fcntl.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ @@ -31,6 +32,7 @@ fcntl.h: fcntl.in.h $(LINK_WARNING_H) -e 's|@''REPLACE_OPENAT''@|$(REPLACE_OPENAT)|g' \ -e 's|@''HAVE_OPENAT''@|$(HAVE_OPENAT)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/fcntl.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/fnmatch b/modules/fnmatch index 78344cae8b..6849b4d5e3 100644 --- a/modules/fnmatch +++ b/modules/fnmatch @@ -9,6 +9,7 @@ m4/mbstate_t.m4 m4/fnmatch.m4 Depends-on: +arg-nonnull extensions alloca stdbool @@ -27,10 +28,11 @@ BUILT_SOURCES += $(FNMATCH_H) # We need the following in order to create <fnmatch.h> when the system # doesn't have one that supports the required API. -fnmatch.h: fnmatch.in.h +fnmatch.h: fnmatch.in.h $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ - cat $(srcdir)/fnmatch.in.h; \ + sed -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ + < $(srcdir)/fnmatch.in.h; \ } > $@-t && \ mv -f $@-t $@ MOSTLYCLEANFILES += fnmatch.h fnmatch.h-t diff --git a/modules/getopt-posix b/modules/getopt-posix index 0a6ee88b0c..63bc6c4e25 100644 --- a/modules/getopt-posix +++ b/modules/getopt-posix @@ -13,6 +13,7 @@ gettext-h unistd extensions include_next +arg-nonnull configure.ac: gl_FUNC_GETOPT_POSIX @@ -22,7 +23,7 @@ BUILT_SOURCES += $(GETOPT_H) # We need the following in order to create <getopt.h> when the system # doesn't have one that works with the given compiler. -getopt.h: getopt.in.h $(LINK_WARNING_H) +getopt.h: getopt.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''HAVE_GETOPT_H''@|$(HAVE_GETOPT_H)|g' \ @@ -30,6 +31,7 @@ getopt.h: getopt.in.h $(LINK_WARNING_H) -e 's|@''PRAGMA_SYSTEM_HEADER''@|@PRAGMA_SYSTEM_HEADER@|g' \ -e 's|@''NEXT_GETOPT_H''@|$(NEXT_GETOPT_H)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/getopt.in.h; \ } > $@-t && \ mv -f $@-t $@ diff --git a/modules/glob b/modules/glob index c5fd73f470..204ba4886d 100644 --- a/modules/glob +++ b/modules/glob @@ -10,6 +10,7 @@ m4/glob.m4 Depends-on: alloca +arg-nonnull d-type dirfd extensions @@ -31,10 +32,11 @@ BUILT_SOURCES += $(GLOB_H) # We need the following in order to create <glob.h> when the system # doesn't have one that works with the given compiler. -glob.h: glob.in.h +glob.h: glob.in.h $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''HAVE_SYS_CDEFS_H''@|$(HAVE_SYS_CDEFS_H)|g' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/glob.in.h; \ } > $@-t && \ mv -f $@-t $@ diff --git a/modules/iconv_open b/modules/iconv_open index c85e660216..ab92f0c8b1 100644 --- a/modules/iconv_open +++ b/modules/iconv_open @@ -15,6 +15,7 @@ m4/iconv_open.m4 Depends-on: gperf include_next +arg-nonnull iconv c-ctype c-strcase @@ -28,7 +29,7 @@ BUILT_SOURCES += $(ICONV_H) # We need the following in order to create <iconv.h> when the system # doesn't have one that works with the given compiler. -iconv.h: iconv.in.h +iconv.h: iconv.in.h $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ @@ -38,6 +39,7 @@ iconv.h: iconv.in.h -e 's|@''REPLACE_ICONV''@|$(REPLACE_ICONV)|g' \ -e 's|@''REPLACE_ICONV_OPEN''@|$(REPLACE_ICONV_OPEN)|g' \ -e 's|@''REPLACE_ICONV_UTF''@|$(REPLACE_ICONV_UTF)|g' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/iconv.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/inttypes b/modules/inttypes index 8c341f46d0..7a49b77e63 100644 --- a/modules/inttypes +++ b/modules/inttypes @@ -9,6 +9,7 @@ m4/inttypes.m4 Depends-on: include_next link-warning +arg-nonnull multiarch stdint @@ -20,7 +21,7 @@ BUILT_SOURCES += $(INTTYPES_H) # We need the following in order to create <inttypes.h> when the system # doesn't have one that works with the given compiler. -inttypes.h: inttypes.in.h $(LINK_WARNING_H) +inttypes.h: inttypes.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's/@''HAVE_INTTYPES_H''@/$(HAVE_INTTYPES_H)/g' \ @@ -45,6 +46,7 @@ inttypes.h: inttypes.in.h $(LINK_WARNING_H) -e 's/@''UINT32_MAX_LT_UINTMAX_MAX''@/$(UINT32_MAX_LT_UINTMAX_MAX)/g' \ -e 's/@''UINT64_MAX_EQ_ULONG_MAX''@/$(UINT64_MAX_EQ_ULONG_MAX)/g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/inttypes.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/locale b/modules/locale index 8b4b3b6562..60d608192a 100644 --- a/modules/locale +++ b/modules/locale @@ -7,6 +7,7 @@ m4/locale_h.m4 Depends-on: include_next +arg-nonnull extensions stddef @@ -18,7 +19,7 @@ BUILT_SOURCES += $(LOCALE_H) # We need the following in order to create <locale.h> when the system # doesn't have one that provides all definitions. -locale.h: locale.in.h +locale.h: locale.in.h $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ @@ -27,6 +28,7 @@ locale.h: locale.in.h -e 's|@''GNULIB_DUPLOCALE''@|$(GNULIB_DUPLOCALE)|g' \ -e 's|@''HAVE_XLOCALE_H''@|$(HAVE_XLOCALE_H)|g' \ -e 's|@''REPLACE_DUPLOCALE''@|$(REPLACE_DUPLOCALE)|g' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/locale.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/math b/modules/math index 37a544e546..0e2bc0b27a 100644 --- a/modules/math +++ b/modules/math @@ -8,6 +8,7 @@ m4/math_h.m4 Depends-on: include_next link-warning +arg-nonnull configure.ac: gl_MATH_H @@ -17,7 +18,7 @@ BUILT_SOURCES += math.h # We need the following in order to create <math.h> when the system # doesn't have one that works with the given compiler. -math.h: math.in.h $(LINK_WARNING_H) +math.h: math.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''INCLUDE_NEXT_AS_FIRST_DIRECTIVE''@|$(INCLUDE_NEXT_AS_FIRST_DIRECTIVE)|g' \ @@ -79,6 +80,7 @@ math.h: math.in.h $(LINK_WARNING_H) -e 's|@''REPLACE_SIGNBIT_USING_GCC''@|$(REPLACE_SIGNBIT_USING_GCC)|g' \ -e 's|@''REPLACE_TRUNCL''@|$(REPLACE_TRUNCL)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/math.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/netdb b/modules/netdb index 5672867276..5d9c3758e6 100644 --- a/modules/netdb +++ b/modules/netdb @@ -7,6 +7,7 @@ m4/netdb_h.m4 Depends-on: include_next +arg-nonnull sys_socket configure.ac: @@ -17,7 +18,7 @@ BUILT_SOURCES += $(NETDB_H) # We need the following in order to create <netdb.h> when the system # doesn't have one that works with the given compiler. -netdb.h: netdb.in.h +netdb.h: netdb.in.h $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ @@ -30,6 +31,7 @@ netdb.h: netdb.in.h -e 's|@''HAVE_DECL_GAI_STRERROR''@|$(HAVE_DECL_GAI_STRERROR)|g' \ -e 's|@''HAVE_DECL_GETADDRINFO''@|$(HAVE_DECL_GETADDRINFO)|g' \ -e 's|@''HAVE_DECL_GETNAMEINFO''@|$(HAVE_DECL_GETNAMEINFO)|g' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/netdb.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/search b/modules/search index f7a58ebf65..9984c29113 100644 --- a/modules/search +++ b/modules/search @@ -8,6 +8,7 @@ m4/search_h.m4 Depends-on: include_next link-warning +arg-nonnull configure.ac: gl_SEARCH_H @@ -17,7 +18,7 @@ BUILT_SOURCES += search.h # We need the following in order to create <search.h> when the system # doesn't have one that works with the given compiler. -search.h: search.in.h $(LINK_WARNING_H) +search.h: search.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''HAVE_SEARCH_H''@|$(HAVE_SEARCH_H)|g' \ @@ -28,6 +29,7 @@ search.h: search.in.h $(LINK_WARNING_H) -e 's|@''HAVE_TSEARCH''@|$(HAVE_TSEARCH)|g' \ -e 's|@''REPLACE_TSEARCH''@|$(REPLACE_TSEARCH)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/search.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/signal b/modules/signal index 42b543e332..2c1917fa8f 100644 --- a/modules/signal +++ b/modules/signal @@ -8,6 +8,7 @@ m4/signal_h.m4 Depends-on: include_next link-warning +arg-nonnull configure.ac: gl_SIGNAL_H @@ -17,7 +18,7 @@ BUILT_SOURCES += signal.h # We need the following in order to create <signal.h> when the system # doesn't have a complete one. -signal.h: signal.in.h $(LINK_WARNING_H) +signal.h: signal.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ @@ -33,6 +34,7 @@ signal.h: signal.in.h $(LINK_WARNING_H) -e 's|@''HAVE_STRUCT_SIGACTION_SA_SIGACTION''@|$(HAVE_STRUCT_SIGACTION_SA_SIGACTION)|g' \ -e 's|@''HAVE_TYPE_VOLATILE_SIG_ATOMIC_T''@|$(HAVE_TYPE_VOLATILE_SIG_ATOMIC_T)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/signal.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/spawn b/modules/spawn index 0fe7f83662..616cc454f8 100644 --- a/modules/spawn +++ b/modules/spawn @@ -8,6 +8,7 @@ m4/spawn_h.m4 Depends-on: include_next link-warning +arg-nonnull sched configure.ac: @@ -18,7 +19,7 @@ BUILT_SOURCES += $(SPAWN_H) # We need the following in order to create a replacement for <spawn.h> when # the system doesn't have one. -spawn.h: spawn.in.h $(LINK_WARNING_H) +spawn.h: spawn.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''HAVE_SPAWN_H''@|$(HAVE_SPAWN_H)|g' \ @@ -49,6 +50,7 @@ spawn.h: spawn.in.h $(LINK_WARNING_H) -e 's|@''HAVE_POSIX_SPAWN''@|$(HAVE_POSIX_SPAWN)|g' \ -e 's|@''REPLACE_POSIX_SPAWN''@|$(REPLACE_POSIX_SPAWN)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/spawn.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/stdio b/modules/stdio index 06e7865ca5..eca35813c7 100644 --- a/modules/stdio +++ b/modules/stdio @@ -9,6 +9,7 @@ m4/stdio_h.m4 Depends-on: include_next link-warning +arg-nonnull raise stddef @@ -20,7 +21,7 @@ BUILT_SOURCES += stdio.h # We need the following in order to create <stdio.h> when the system # doesn't have one that works with the given compiler. -stdio.h: stdio.in.h $(LINK_WARNING_H) +stdio.h: stdio.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ @@ -105,6 +106,7 @@ stdio.h: stdio.in.h $(LINK_WARNING_H) -e 's|@''REPLACE_VSNPRINTF''@|$(REPLACE_VSNPRINTF)|g' \ -e 's|@''REPLACE_VSPRINTF''@|$(REPLACE_VSPRINTF)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/stdio.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/stdlib b/modules/stdlib index c272737706..19129cfec7 100644 --- a/modules/stdlib +++ b/modules/stdlib @@ -8,6 +8,7 @@ m4/stdlib_h.m4 Depends-on: include_next link-warning +arg-nonnull unistd stddef stdint @@ -20,7 +21,7 @@ BUILT_SOURCES += stdlib.h # We need the following in order to create <stdlib.h> when the system # doesn't have one that works with the given compiler. -stdlib.h: stdlib.in.h $(LINK_WARNING_H) +stdlib.h: stdlib.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ @@ -77,6 +78,7 @@ stdlib.h: stdlib.in.h $(LINK_WARNING_H) -e 's|@''REPLACE_STRTOD''@|$(REPLACE_STRTOD)|g' \ -e 's|@''REPLACE_UNSETENV''@|$(REPLACE_UNSETENV)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/stdlib.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/string b/modules/string index bd9505ec34..d445e3da60 100644 --- a/modules/string +++ b/modules/string @@ -9,6 +9,7 @@ Depends-on: extensions include_next link-warning +arg-nonnull stddef configure.ac: @@ -19,7 +20,7 @@ BUILT_SOURCES += string.h # We need the following in order to create <string.h> when the system # doesn't have one that works with the given compiler. -string.h: string.in.h $(LINK_WARNING_H) +string.h: string.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ @@ -86,6 +87,7 @@ string.h: string.in.h $(LINK_WARNING_H) -e 's|@''REPLACE_STRTOK_R''@|$(REPLACE_STRTOK_R)|g' \ -e 's|@''UNDEFINE_STRTOK_R''@|$(UNDEFINE_STRTOK_R)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/string.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/strings b/modules/strings index 673d75d34f..33c06088a2 100644 --- a/modules/strings +++ b/modules/strings @@ -8,6 +8,7 @@ m4/strings_h.m4 Depends-on: include_next link-warning +arg-nonnull configure.ac: gl_HEADER_STRINGS_H @@ -17,7 +18,7 @@ BUILT_SOURCES += strings.h # We need the following in order to create <strings.h> when the system # doesn't have one that works with the given compiler. -strings.h: strings.in.h $(LINK_WARNING_H) +strings.h: strings.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ @@ -26,6 +27,7 @@ strings.h: strings.in.h $(LINK_WARNING_H) -e 's|@''HAVE_STRCASECMP''@|$(HAVE_STRCASECMP)|g' \ -e 's|@''HAVE_DECL_STRNCASECMP''@|$(HAVE_DECL_STRNCASECMP)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/strings.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/sys_socket b/modules/sys_socket index 72d39596f3..b1b9ad27d7 100644 --- a/modules/sys_socket +++ b/modules/sys_socket @@ -9,6 +9,7 @@ m4/sockpfaf.m4 Depends-on: include_next link-warning +arg-nonnull errno alignof @@ -21,7 +22,7 @@ BUILT_SOURCES += $(SYS_SOCKET_H) # We need the following in order to create <sys/socket.h> when the system # doesn't have one that works with the given compiler. -sys/socket.h: sys_socket.in.h $(LINK_WARNING_H) +sys/socket.h: sys_socket.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_at)$(MKDIR_P) sys $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ @@ -51,6 +52,7 @@ sys/socket.h: sys_socket.in.h $(LINK_WARNING_H) -e 's|@''HAVE_SA_FAMILY_T''@|$(HAVE_SA_FAMILY_T)|g' \ -e 's|@''HAVE_ACCEPT4''@|$(HAVE_ACCEPT4)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/sys_socket.in.h; \ } > $@-t && \ mv -f $@-t $@ diff --git a/modules/sys_stat b/modules/sys_stat index 33ffe4a9a2..7421df67ac 100644 --- a/modules/sys_stat +++ b/modules/sys_stat @@ -9,6 +9,7 @@ m4/unistd_h.m4 Depends-on: include_next link-warning +arg-nonnull time configure.ac: @@ -20,7 +21,7 @@ BUILT_SOURCES += sys/stat.h # We need the following in order to create <sys/stat.h> when the system # has one that is incomplete. -sys/stat.h: sys_stat.in.h $(LINK_WARNING_H) +sys/stat.h: sys_stat.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_at)$(MKDIR_P) sys $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ @@ -60,6 +61,7 @@ sys/stat.h: sys_stat.in.h $(LINK_WARNING_H) -e 's|@''REPLACE_STAT''@|$(REPLACE_STAT)|g' \ -e 's|@''REPLACE_UTIMENSAT''@|$(REPLACE_UTIMENSAT)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/sys_stat.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/sys_time b/modules/sys_time index 460f046e1d..f0789e5890 100644 --- a/modules/sys_time +++ b/modules/sys_time @@ -7,6 +7,7 @@ m4/sys_time_h.m4 Depends-on: include_next +arg-nonnull configure.ac: gl_HEADER_SYS_TIME_H @@ -17,7 +18,7 @@ BUILT_SOURCES += $(SYS_TIME_H) # We need the following in order to create <sys/time.h> when the system # doesn't have one that works with the given compiler. -sys/time.h: sys_time.in.h +sys/time.h: sys_time.in.h $(ARG_NONNULL_H) $(AM_V_at)$(MKDIR_P) sys $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ @@ -27,6 +28,7 @@ sys/time.h: sys_time.in.h -e 's|@''NEXT_SYS_TIME_H''@|$(NEXT_SYS_TIME_H)|g' \ -e 's/@''REPLACE_GETTIMEOFDAY''@/$(REPLACE_GETTIMEOFDAY)/g' \ -e 's/@''HAVE_STRUCT_TIMEVAL''@/$(HAVE_STRUCT_TIMEVAL)/g' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/sys_time.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/sys_times b/modules/sys_times index b8b141d6f1..23af537414 100644 --- a/modules/sys_times +++ b/modules/sys_times @@ -7,6 +7,7 @@ m4/sys_times_h.m4 Depends-on: link-warning +arg-nonnull configure.ac: gl_SYS_TIMES_H @@ -17,12 +18,13 @@ BUILT_SOURCES += $(SYS_TIMES_H) # We need the following in order to create <sys/times.h> when the system # doesn't have one that works with the given compiler. -sys/times.h: sys_times.in.h $(LINK_WARNING_H) +sys/times.h: sys_times.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_at)$(MKDIR_P) sys $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GNULIB_TIMES''@|$(GNULIB_TIMES)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/sys_times.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/sys_utsname b/modules/sys_utsname index 2bbeb7e0bd..83e337d83f 100644 --- a/modules/sys_utsname +++ b/modules/sys_utsname @@ -7,6 +7,7 @@ m4/sys_utsname_h.m4 Depends-on: link-warning +arg-nonnull configure.ac: gl_SYS_UTSNAME_H @@ -17,13 +18,14 @@ BUILT_SOURCES += $(SYS_UTSNAME_H) # We need the following in order to create <sys/utsname.h> when the system # does not have one. -sys/utsname.h: sys_utsname.in.h $(LINK_WARNING_H) +sys/utsname.h: sys_utsname.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_at)$(MKDIR_P) sys $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GNULIB_UNAME''@|$(GNULIB_UNAME)|g' \ -e 's|@''HAVE_UNAME''@|$(HAVE_UNAME)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/sys_utsname.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/time b/modules/time index 46a85ec503..ed89cf9bd9 100644 --- a/modules/time +++ b/modules/time @@ -8,6 +8,7 @@ m4/time_h.m4 Depends-on: extensions include_next +arg-nonnull stddef configure.ac: @@ -18,7 +19,7 @@ BUILT_SOURCES += time.h # We need the following in order to create <time.h> when the system # doesn't have one that works with the given compiler. -time.h: time.in.h +time.h: time.in.h $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ @@ -31,6 +32,7 @@ time.h: time.in.h -e 's|@REPLACE_TIMEGM''@|$(REPLACE_TIMEGM)|g' \ -e 's|@SYS_TIME_H_DEFINES_STRUCT_TIMESPEC''@|$(SYS_TIME_H_DEFINES_STRUCT_TIMESPEC)|g' \ -e 's|@TIME_H_DEFINES_STRUCT_TIMESPEC''@|$(TIME_H_DEFINES_STRUCT_TIMESPEC)|g' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/time.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/unistd b/modules/unistd index 8e7382d2b4..3ee8f31449 100644 --- a/modules/unistd +++ b/modules/unistd @@ -8,6 +8,7 @@ lib/unistd.in.h Depends-on: include_next link-warning +arg-nonnull stddef configure.ac: @@ -18,7 +19,7 @@ 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: unistd.in.h $(LINK_WARNING_H) +unistd.h: unistd.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''HAVE_UNISTD_H''@|$(HAVE_UNISTD_H)|g' \ @@ -117,6 +118,7 @@ unistd.h: unistd.in.h $(LINK_WARNING_H) -e 's|@''UNISTD_H_HAVE_WINSOCK2_H''@|$(UNISTD_H_HAVE_WINSOCK2_H)|g' \ -e 's|@''UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS''@|$(UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/unistd.in.h; \ } > $@-t && \ mv $@-t $@ diff --git a/modules/wchar b/modules/wchar index d6dbfd5ef7..eb8615ca9c 100644 --- a/modules/wchar +++ b/modules/wchar @@ -9,6 +9,7 @@ m4/wint_t.m4 Depends-on: include_next link-warning +arg-nonnull stddef configure.ac: @@ -19,7 +20,7 @@ BUILT_SOURCES += $(WCHAR_H) # We need the following in order to create <wchar.h> when the system # version does not work standalone. -wchar.h: wchar.in.h $(LINK_WARNING_H) +wchar.h: wchar.in.h $(LINK_WARNING_H) $(ARG_NONNULL_H) $(AM_V_GEN)rm -f $@-t $@ && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ @@ -62,6 +63,7 @@ wchar.h: wchar.in.h $(LINK_WARNING_H) -e 's|@''REPLACE_WCSNRTOMBS''@|$(REPLACE_WCSNRTOMBS)|g' \ -e 's|@''REPLACE_WCWIDTH''@|$(REPLACE_WCWIDTH)|g' \ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \ + -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \ < $(srcdir)/wchar.in.h; \ } > $@-t && \ mv $@-t $@ |