Mark generated files as "DO NOT EDIT".
[gnulib.git] / modules / getopt
index 149146c..bf1da55 100644 (file)
@@ -2,24 +2,37 @@ Description:
 Process command line arguments.
 
 Files:
-lib/getopt.h
+lib/getopt_.h
 lib/getopt.c
 lib/getopt1.c
 lib/getopt_int.h
 m4/getopt.m4
 
 Depends-on:
-gettext
+gettext-h
+unistd
 
 configure.ac:
 gl_GETOPT
 
 Makefile.am:
-lib_SOURCES += getopt.h getopt.c getopt1.c getopt_int.h
+BUILT_SOURCES += $(GETOPT_H)
+EXTRA_DIST += getopt_.h getopt_int.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_.h
+       { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
+         cat $(srcdir)/getopt_.h; \
+       } > $@-t
+       mv -f $@-t $@
+MOSTLYCLEANFILES += getopt.h getopt.h-t
 
 Include:
-"getopt.h"
+<getopt.h>
+
+License:
+LGPL
 
 Maintainer:
 all, glibc
-