gnulib-modules / bootstrap

a clean rewrite of gnulib bootstrap for scriptable extensibility and proper error reporting
Other
8 stars 6 forks source link

Problem with parsing prequisite names? #31

Closed rrthomas closed 9 months ago

rrthomas commented 9 months ago

[Previously filed against wrong project, I was using this version all along!]

I added the following line to my bootstrap.conf's buildreq section:

buildreq='
        pkg-config -       https://www.freedesktop.org/wiki/Software/pkg-config/
'

and get the error:

bootstrap:   error: Prerequisite 'CONFIG-pkg-config' not not found. Please install it, or
bootstrap:          'export PKG-CONFIG=/path/to/CONFIG-pkg-config'.

Looks like something has gone wrong with parsing pkg-config?

gvvaughan commented 9 months ago

Does this fix it for you?

diff --git a/bootstrap b/bootstrap
index 0c1062b..c881e04 100644
--- a/bootstrap
+++ b/bootstrap
@@ -5164,7 +5164,7 @@ delimited list of triples; 'program min-version url'."
       esac

       # Honor $APP variables ($TAR, $AUTOCONF, etc.)
-      _G_appvar=`echo $_G_app |tr '[a-z]' '[A-Z]'`
+      _G_appvar=`echo $_G_app |tr '[a-z-]' '[A-Z_]'`
       test TAR = "$_G_appvar" && _G_appvar=AMTAR
       eval "_G_app=\${$_G_appvar-$_G_app}"
rrthomas commented 9 months ago

That works fine, thanks! I tested both with no version specifier, and with a version that was newer than what I had (to get the error message).