link-warning: Add copyright notice.
authorBruno Haible <bruno@clisp.org>
Wed, 9 Dec 2009 11:41:19 +0000 (12:41 +0100)
committerBruno Haible <bruno@clisp.org>
Wed, 9 Dec 2009 11:41:44 +0000 (12:41 +0100)
26 files changed:
ChangeLog
NEWS
build-aux/link-warning.h
modules/arpa_inet
modules/dirent
modules/fcntl-h
modules/getopt-posix
modules/inttypes
modules/link-warning
modules/math
modules/search
modules/signal
modules/spawn
modules/stdio
modules/stdlib
modules/string
modules/strings
modules/sys_ioctl
modules/sys_select
modules/sys_socket
modules/sys_stat
modules/sys_times
modules/sys_utsname
modules/sys_wait
modules/unistd
modules/wchar

index 7bfe2cd45ac407b6c58099e051dad7497dc309a3..ecc461f05bdf57ae8d68dc3503c1229fc3e023c1 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,33 @@
+2009-12-09  Simon Josefsson <simon@josefsson.org>
+            Bruno Haible  <bruno@clisp.org>
+
+       * build-aux/link-warning.h: Add copyright notice.
+       * modules/link-warning (Makefile.am): Generate link-warning.h from
+       build-aux/link-warning.h. Update LINK_WARNING_H accordingly.
+       * NEWS: Mention change in link-warning module.
+       * modules/arpa_inet (Makefile.am): Add dependency to arpa/inet.h.
+       * modules/dirent (Makefile.am): Add dependency to dirent.h.
+       * modules/fcntl-h (Makefile.am): Add dependency to fcntl.h.
+       * modules/getopt-posix (Makefile.am): Add dependency to getopt.h.
+       * modules/inttypes (Makefile.am): Add dependency to inttypes.h.
+       * modules/math (Makefile.am): Add dependency to math.h.
+       * modules/search (Makefile.am): Add dependency to search.h.
+       * modules/signal (Makefile.am): Add dependency to signal.h.
+       * modules/spawn (Makefile.am): Add dependency to spawn.h.
+       * modules/stdio (Makefile.am): Add dependency to stdio.h.
+       * modules/stdlib (Makefile.am): Add dependency to stdlib.h.
+       * modules/string (Makefile.am): Add dependency to string.h.
+       * modules/strings (Makefile.am): Add dependency to strings.h.
+       * modules/sys_ioctl (Makefile.am): Add dependency to sys/ioctl.h.
+       * modules/sys_select (Makefile.am): Add dependency to sys/select.h.
+       * modules/sys_socket (Makefile.am): Add dependency to sys/socket.h.
+       * modules/sys_stat (Makefile.am): Add dependency to sys/stat.h.
+       * modules/sys_times (Makefile.am): Add dependency to sys/times.h.
+       * modules/sys_utsname (Makefile.am): Add dependency to sys/utsname.h.
+       * modules/sys_wait (Makefile.am): Add dependency to sys/wait.h.
+       * modules/unistd (Makefile.am): Add dependency to unistd.h.
+       * modules/wchar (Makefile.am): Add dependency to wchar.h.
+
 2009-12-09  Bruno Haible  <bruno@clisp.org>
 
        fchdir: Optimize away rpl_fstat when possible.
diff --git a/NEWS b/NEWS
index 2f364f74c4395f0e66689408ff846d46cbb9a9f8..cfa017c349bcf6e112609d78d2619a335e726b05 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -6,6 +6,10 @@ User visible incompatible changes
 
 Date        Modules         Changes
 
+2009-12-09  link-warning    The Makefile rules that use $(LINK_WARNING_H) now
+                            must contain an explicit dependency on
+                            $(LINK_WARNING_H).
+
 2009-11-12  getgroups       These functions now use a signature of gid_t,
             getugroups      rather than GETGROUPS_T.  This probably has no
                             effect except on very old platforms.
index fda01941af51ca3920974ea79dc3b85761aa1440..9ff7c175ae00620108cbb2fcfbe7a78f8a19f8cd 100644 (file)
@@ -1,3 +1,20 @@
+/* A C macro for emitting link time warnings.
+   Copyright (C) 1995, 1997, 2000, 2002-2003, 2007, 2009 Free Software
+   Foundation, Inc.
+
+   This program is free software: you can redistribute it and/or modify it
+   under the terms of the GNU Lesser General Public License as published
+   by the Free Software Foundation; either version 2 of the License, or
+   (at your option) any later version.
+
+   This program is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public License
+   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
+
 /* GL_LINK_WARNING("literal string") arranges to emit the literal string as
    a linker warning on most glibc systems.
    We use a linker warning rather than a preprocessor warning, because
index 2105217b040af4fe1a27fdd78ac7d5cc57d99bcc..7eb9cc05671c018eb276ae942e9ab34eb5e44ac5 100644 (file)
@@ -19,7 +19,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
+arpa/inet.h: arpa_inet.in.h $(LINK_WARNING_H)
        $(AM_V_at)$(MKDIR_P) arpa
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
index d21cfafbda8eeabac8b899d2d1018962a007e96e..110ec4520a613f05807caf8c18b5038afa7c47fd 100644 (file)
@@ -18,7 +18,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
+dirent.h: dirent.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
          sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \
index ea76181b438df247df2b4d5f4df67a34f6a58661..eb5cce11ddd247548e1e856ccaece24eb21d6630 100644 (file)
@@ -19,7 +19,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
+fcntl.h: fcntl.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
          sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \
index 94932fcc00b21f15567d6958d7d50fe61d531098..0a6ee88b0c31213526eadb316522e5db00b333fe 100644 (file)
@@ -22,7 +22,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
+getopt.h: getopt.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
          sed -e 's|@''HAVE_GETOPT_H''@|$(HAVE_GETOPT_H)|g' \
index fc97cd613ac1131545573789b6eb4afe791c53dc..8c341f46d07ebe1296c54215dcb6931603a49d5b 100644 (file)
@@ -20,7 +20,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
+inttypes.h: inttypes.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
          sed -e 's/@''HAVE_INTTYPES_H''@/$(HAVE_INTTYPES_H)/g' \
index 5d702a7e82dea8a6435792258a3991731d9d34c3..33085b768fc35810fb62e0e7a022f9725d9a05f0 100644 (file)
@@ -9,7 +9,14 @@ Depends-on:
 configure.ac:
 
 Makefile.am:
-LINK_WARNING_H=$(top_srcdir)/build-aux/link-warning.h
+BUILT_SOURCES += link-warning.h
+link-warning.h: $(top_srcdir)/build-aux/link-warning.h
+       $(AM_V_GEN)rm -f $@-t $@ && \
+       sed 1,17d < $(top_srcdir)/build-aux/link-warning.h > $@-t && \
+       mv $@-t $@
+MOSTLYCLEANFILES += link-warning.h link-warning.h-t
+
+LINK_WARNING_H=link-warning.h
 
 Include:
 
index cdbe8105135a2262997f15727ad0142a1acc846a..37a544e5469ba536422eb083a7f2162ea10d92b3 100644 (file)
@@ -17,7 +17,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
+math.h: math.in.h $(LINK_WARNING_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' \
index ff1d9b541ac4b27cd897a92cdd8e0c0ac62be85d..f7a58ebf654ec92d22efdb7bf1a3858ec6f32d98 100644 (file)
@@ -17,7 +17,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
+search.h: search.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \
          sed -e 's|@''HAVE_SEARCH_H''@|$(HAVE_SEARCH_H)|g' \
index 6e37b150b8ed27ebab3cc4d7c290f46f0c30d792..42b543e3320f14919a14b9dfc7e049b6872a4092 100644 (file)
@@ -17,7 +17,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
+signal.h: signal.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \
          sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \
index 55c17f6e109f459b580692d720c7607fac7c4c6c..0fe7f836626c40e957c70ca067c93635f87b1d00 100644 (file)
@@ -18,7 +18,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
+spawn.h: spawn.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
          sed -e 's|@''HAVE_SPAWN_H''@|$(HAVE_SPAWN_H)|g' \
index 8b6e050e37b4142d5935cfd32f3b9593dd005e4b..06e7865ca5386de198889317665fa22e181ab007 100644 (file)
@@ -20,7 +20,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
+stdio.h: stdio.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \
          sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \
index ddf2b7ac306a3f778bf9ec566c4cc10a68a9546c..c272737706562622b3989d9fa494123cfedf5ebb 100644 (file)
@@ -20,7 +20,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
+stdlib.h: stdlib.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \
          sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \
index 652a88e741c6ba7f3fcb1e1aa2e76bcf4749189d..bd9505ec346c8d9c148a81fa23f85cdb73cd1808 100644 (file)
@@ -19,7 +19,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
+string.h: string.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \
          sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \
index f0375aeacfb0c4c3baa0730a1d19b19b1c9d23b1..673d75d34f6c1aabea072f7cb5981352102692ad 100644 (file)
@@ -17,7 +17,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
+strings.h: strings.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \
          sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \
index 170c67452e346a0fce4d96e66f590eda6f4f990a..5ae8c84369cd9c595b6be837c6afc231d2e091d9 100644 (file)
@@ -19,7 +19,7 @@ BUILT_SOURCES += $(SYS_IOCTL_H)
 
 # We need the following in order to create <sys/ioctl.h> when the system
 # does not have a complete one.
-sys/ioctl.h: sys_ioctl.in.h
+sys/ioctl.h: sys_ioctl.in.h $(LINK_WARNING_H)
        $(AM_V_at)$(MKDIR_P) sys
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
index 698de84847b02bd3c0832adf7e6e061577dbdb58..093e5e5e77ab3390f3235580cdd78c99a8deaea7 100644 (file)
@@ -20,7 +20,7 @@ BUILT_SOURCES += $(SYS_SELECT_H)
 
 # We need the following in order to create <sys/select.h> when the system
 # doesn't have one that works with the given compiler.
-sys/select.h: sys_select.in.h
+sys/select.h: sys_select.in.h $(LINK_WARNING_H)
        $(AM_V_at)$(MKDIR_P) sys
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
index 573ace7246c58bfd697e2c057fb3c7b2bfcfb7be..72d39596f344cfa79515549bea862f191485eb81 100644 (file)
@@ -21,7 +21,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
+sys/socket.h: sys_socket.in.h $(LINK_WARNING_H)
        $(AM_V_at)$(MKDIR_P) sys
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
index 20a8c83bf9aeb0fa3fbaff7ad7fad15423548a04..33ffe4a9a2982b20b76e8ff358549a1b33329dae 100644 (file)
@@ -20,7 +20,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
+sys/stat.h: sys_stat.in.h $(LINK_WARNING_H)
        $(AM_V_at)$(MKDIR_P) sys
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
index f91f6fcaacabf9283fb26d542dfab7daa9233b0f..b8b141d6f18578d33a981f7ef2ad7738d6c83a33 100644 (file)
@@ -17,7 +17,7 @@ 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
+sys/times.h: sys_times.in.h $(LINK_WARNING_H)
        $(AM_V_at)$(MKDIR_P) sys
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
index e5c4e8a1083bbbb3e8d7e43fe0ac79f99cfb656f..2bbeb7e0bdbf0e0db8bc0d2db548132a6f63e1d1 100644 (file)
@@ -17,7 +17,7 @@ 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
+sys/utsname.h: sys_utsname.in.h $(LINK_WARNING_H)
        $(AM_V_at)$(MKDIR_P) sys
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
index 9b74ea8a7e152c8ab1717d67f884b8f657ebe393..210b21638b496e675566f0ad51758b42d6eb738f 100644 (file)
@@ -18,7 +18,7 @@ BUILT_SOURCES += $(SYS_WAIT_H)
 
 # We need the following in order to create <sys/wait.h> when the system
 # has one that is incomplete.
-sys/wait.h: sys_wait.in.h
+sys/wait.h: sys_wait.in.h $(LINK_WARNING_H)
        $(AM_V_at)$(MKDIR_P) sys
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
index 7a5500101e7663b15f942a99291973ff1703d175..8e7382d2b4b76a2efbd5b94c27b0f88051627e52 100644 (file)
@@ -18,7 +18,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
+unistd.h: unistd.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
          sed -e 's|@''HAVE_UNISTD_H''@|$(HAVE_UNISTD_H)|g' \
index f6d02ec7651692d6203efcc7cd4ce4aa177f694e..d6dbfd5ef7bb50f8fd88f84a506c830130827afe 100644 (file)
@@ -19,7 +19,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
+wchar.h: wchar.in.h $(LINK_WARNING_H)
        $(AM_V_GEN)rm -f $@-t $@ && \
        { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
          sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \