aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2014-01-31 13:31:06 +0200
committerSergey Poznyakoff <gray@gnu.org.ua>2014-01-31 13:31:06 +0200
commit4900a5e7be9ad90fda7c4743fd31613ceb0eda05 (patch)
treef8e38484828638d0d028086c91e4678089b0ae1c
parentd18e5794063e4ae4dcc5fac33293b63196af7e7b (diff)
downloadcpio-4900a5e7be9ad90fda7c4743fd31613ceb0eda05.tar.gz
cpio-4900a5e7be9ad90fda7c4743fd31613ceb0eda05.tar.bz2
Fix package name recognition in bootstrap.
The script logic failed if AC_INIT was split among two lines. Reported by Pavel. * bootstrap (extract_package_name): Rewrite as m4 script to allow for multiline AC_INIT.
-rwxr-xr-xbootstrap22
1 files changed, 4 insertions, 18 deletions
diff --git a/bootstrap b/bootstrap
index f7f6c56..aeb46e0 100755
--- a/bootstrap
+++ b/bootstrap
@@ -82,20 +82,6 @@ po_download_command_format=\
-extract_package_name='
- /^AC_INIT(/{
- /.*,.*,.*, */{
- s///
- s/[][]//g
- s/)$//
- p
- q
- }
- s/AC_INIT(\[*//
- s/]*,.*//
- s/^GNU //
- y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/
- s/[^A-Za-z0-9_]/-/g
- p
- }
-'
-package=`sed -n "$extract_package_name" configure.ac` || exit
+extract_package_name='divert(-1)[]changequote([,])[]define([AC_INIT],[divert(0)[]patsubst([$1],[GNU ],[])[]divert(-1)])'
+
+package=`echo $extract_package_name | m4 - configure.ac` || exit
+
gnulib_name=lib$package

Return to:

Send suggestions and report system problems to the System administrator.