progname=$0
package=gnulib
-cvsdatestamp='$Date: 2006-04-24 11:30:00 $'
+cvsdatestamp='$Date: 2006-06-23 19:27:17 $'
last_checkin_date=`echo "$cvsdatestamp" | sed -e 's,^\$[D]ate: ,,'`
version=`echo "$last_checkin_date" | sed -e 's/ .*$//' -e 's,/,-,g'`
# outputs to stdout the --version message.
func_version ()
{
+ year=`echo "$last_checkin_date" | sed -e 's,/.*$,,'`
echo "$progname (GNU $package) $version"
- echo "Copyright (C) 2002-2005 Free Software Foundation, Inc.
+ echo "Copyright (C) $year Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
echo "Written by" "Bruno Haible" "and" "Simon Josefsson"
}
+# func_emit_copyright_notice
+# outputs to stdout a header for a generated file.
+func_emit_copyright_notice ()
+{
+ echo "# Copyright (C) 2004-2006 Free Software Foundation, Inc."
+ echo "#"
+ echo "# This file is free software, distributed under the terms of the GNU"
+ echo "# General Public License. As a special exception to the GNU General"
+ echo "# Public License, this file may be distributed as part of a program"
+ echo "# that contains a configuration script generated by Autoconf, under"
+ echo "# the same distribution terms as the rest of that program."
+ echo "#"
+ echo "# Generated by gnulib-tool."
+}
+
# func_tmpdir
# creates a temporary directory.
# Sets variable
echo "you need to use 'gnulib --import' - at your own risk!" 1>&2
exit 1
fi
- if test -n "$libname" || test -n "$sourcebase" || test -n "$m4base" \
+ if test -n "$supplied_libname" || test -n "$sourcebase" || test -n "$m4base" \
|| test -n "$testsbase" || test -n "$auxdir" || test -n "$inctests" \
|| test -n "$avoidlist" || test -n "$lgpl" || test -n "$macro_prefix"; then
echo "gnulib-tool: invalid options for 'update' mode" 1>&2
perhapsLT=
fi
echo "## Process this file with automake to produce Makefile.in."
- echo "# Copyright (C) 2004 Free Software Foundation, Inc."
- echo "#"
- echo "# This file is free software, distributed under the terms of the GNU"
- echo "# General Public License. As a special exception to the GNU General"
- echo "# Public License, this file may be distributed as part of a program"
- echo "# that contains a configuration script generated by Automake, under"
- echo "# the same distribution terms as the rest of that program."
- echo "#"
- echo "# Generated by gnulib-tool."
+ func_emit_copyright_notice
if test -n "$actioncmd"; then
echo "# Reproduce by: $actioncmd"
fi
echo "BUILT_SOURCES ="
echo "SUFFIXES ="
echo "MOSTLYCLEANFILES ="
+ echo "MOSTLYCLEANDIRS ="
echo "CLEANFILES ="
echo "DISTCLEANFILES ="
echo "MAINTAINERCLEANFILES ="
echo
+ echo "AM_CPPFLAGS ="
+ echo
for module in $modules; do
func_verify_nontests_module
if test -n "$module"; then
fi
done
echo
+ echo "mostlyclean-local:"
+ echo " @test -z \"\$(MOSTLYCLEANDIRS)\" || \\"
+ echo " for dir in \$(MOSTLYCLEANDIRS); do \\"
+ echo " if test -d \$\$dir; then \\"
+ echo " echo \"rmdir \$\$dir\"; rmdir \$\$dir; \\"
+ echo " fi; \\"
+ echo " done"
+ echo
echo "# Makefile.am ends here"
}
fi
testsbase_inverse=`echo "$testsbase" | sed -e 's,/$,,' | sed -e 's,[^/][^/]*,..,g'`
echo "## Process this file with automake to produce Makefile.in."
- echo "# Copyright (C) 2004-2005 Free Software Foundation, Inc."
- echo "#"
- echo "# This file is free software, distributed under the terms of the GNU"
- echo "# General Public License. As a special exception to the GNU General"
- echo "# Public License, this file may be distributed as part of a program"
- echo "# that contains a configuration script generated by Automake, under"
- echo "# the same distribution terms as the rest of that program."
- echo "#"
- echo "# Generated by gnulib-tool."
+ func_emit_copyright_notice
echo
# Generate dependencies here, since it eases the debugging of test failures.
echo "AUTOMAKE_OPTIONS = 1.5 foreign"
echo "BUILT_SOURCES ="
echo "SUFFIXES ="
echo "MOSTLYCLEANFILES ="
+ echo "MOSTLYCLEANDIRS ="
echo "CLEANFILES ="
echo "DISTCLEANFILES ="
echo "MAINTAINERCLEANFILES ="
echo "clean-local:"
echo " rm -rf SunWS_cache"
echo
+ echo "mostlyclean-local:"
+ echo " @test -z \"\$(MOSTLYCLEANDIRS)\" || \\"
+ echo " for dir in \$(MOSTLYCLEANDIRS); do \\"
+ echo " if test -d \$\$dir; then \\"
+ echo " echo \"rmdir \$\$dir\"; rmdir \$\$dir; \\"
+ echo " fi; \\"
+ echo " done"
+ echo
echo "# Makefile.am ends here"
}
# Create m4/gnulib-cache.m4.
func_dest_tmpfilename $m4base/gnulib-cache.m4
(
- echo "# Copyright (C) 2004 Free Software Foundation, Inc."
- echo "# This file is free software, distributed under the terms of the GNU"
- echo "# General Public License. As a special exception to the GNU General"
- echo "# Public License, this file may be distributed as part of a program"
- echo "# that contains a configuration script generated by Autoconf, under"
- echo "# the same distribution terms as the rest of that program."
- echo "#"
- echo "# Generated by gnulib-tool."
+ func_emit_copyright_notice
echo "#"
echo "# This file represents the specification of how gnulib-tool is used."
echo "# It acts as a cache: It is written and read by gnulib-tool."
# Create m4/gnulib-comp.m4.
func_dest_tmpfilename $m4base/gnulib-comp.m4
(
- echo "# Copyright (C) 2004 Free Software Foundation, Inc."
- echo "# This file is free software, distributed under the terms of the GNU"
- echo "# General Public License. As a special exception to the GNU General"
- echo "# Public License, this file may be distributed as part of a program"
- echo "# that contains a configuration script generated by Autoconf, under"
- echo "# the same distribution terms as the rest of that program."
- echo "#"
- echo "# Generated by gnulib-tool."
+ func_emit_copyright_notice
echo "#"
echo "# This file represents the compiled summary of the specification in"
echo "# gnulib-cache.m4. It lists the computed macro invocations that need"
echo "Finished."
echo
echo "You may need to add #include directives for the following .h files."
- for module in $modules; do
- func_get_include_directive "$module"
- done | LC_ALL=C sort -u | sed -e '/^$/d;' -e 's/^/ /'
+ (
+ # First the #include <...> directives without #ifs, sorted for convenience.
+ for module in $modules; do
+ if func_get_include_directive "$module" | grep '^#if' >/dev/null; then
+ :
+ else
+ func_get_include_directive "$module" | grep -v 'include "'
+ fi
+ done | LC_ALL=C sort -u
+ # Then the #include "..." directives without #ifs, sorted for convenience.
+ for module in $modules; do
+ if func_get_include_directive "$module" | grep '^#if' >/dev/null; then
+ :
+ else
+ func_get_include_directive "$module" | grep 'include "'
+ fi
+ done | LC_ALL=C sort -u
+ # Then the #include directives that are surrounded by #ifs. Not sorted.
+ for module in $modules; do
+ if func_get_include_directive "$module" | grep '^#if' >/dev/null; then
+ func_get_include_directive "$module"
+ fi
+ done
+ ) | sed -e '/^$/d;' -e 's/^/ /'
echo
echo "Don't forget to"
echo " - add \"$sourcebase/Makefile\" to AC_CONFIG_FILES in $configure_ac,"