+2003-01-08 Bruno Haible <bruno@clisp.org>
+
+ * project-id: Make it work with configure files that use
+ AM_INIT_AUTOMAKE from automake-1.7.2.
+
2002-12-04 Bruno Haible <bruno@clisp.org>
Fix handling of references to filenames starting with a digit.
#!/bin/sh
# Prints a package's identification PACKAGE VERSION or PACKAGE.
#
-# Copyright (C) 2001-2002 Free Software Foundation, Inc.
+# Copyright (C) 2001-2003 Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
want_version="$1"
while true; do
if test -f configure; then
- package=`(grep '^PACKAGE_NAME=' configure; grep '^PACKAGE=' configure) | grep -v '=[ ]*$' | sed -e '1q' | sed -e 's/^[^=]*=//' | sed -e "s/^'//" -e "s/'$//"`
+ package=`(grep '^PACKAGE_NAME=' configure; grep '^ *PACKAGE=' configure) | grep -v '=[ ]*$' | sed -e '1q' | sed -e 's/^[^=]*=//' | sed -e "s/^'//" -e "s/'$//"`
case "$package" in
*[\"\$\`\{\}]*)
# Some packages (gcal) retrieve the package name dynamically.
package="GNU $package"
fi
if test -n "$want_version"; then
- version=`(grep '^PACKAGE_VERSION=' configure; grep '^VERSION=' configure) | grep -v '=[ ]*$' | sed -e '1q' | sed -e 's/^[^=]*=//' | sed -e "s/^'//" -e "s/'$//"`
+ version=`(grep '^PACKAGE_VERSION=' configure; grep '^ *VERSION=' configure) | grep -v '=[ ]*$' | sed -e '1q' | sed -e 's/^[^=]*=//' | sed -e "s/^'//" -e "s/'$//"`
case "$version" in
*[\"\$\`\{\}]*)
# Some packages (gcal, gcc, clisp) retrieve the version dynamically.