libtool.m4: Avoid word splitting on untrusted inputs

If $multilib is set to more than one word, the following error can be
seen during configuration:

	test: too many arguments

* m4/libtool.m4: Wrap variable in quotes.
This commit is contained in:
Bruno Haible 2024-10-15 23:03:00 +02:00 committed by Ileana Dumitrescu
parent 4e96fb2a47
commit f91f7bc3ab
No known key found for this signature in database
GPG Key ID: 6570EA01146F7354

2
m4/libtool.m4 vendored
View File

@ -2584,7 +2584,7 @@ cygwin* | mingw* | windows* | pw32* | cegcc*)
# If user builds GCC with multilib enabled,
# it should just install on $(libdir)
# not on $(libdir)/../bin or 32 bits dlls would override 64 bit ones.
if test xyes = x$multilib; then
if test xyes = x"$multilib"; then
postinstall_cmds='base_file=`basename \$file`~
dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
dldir=$destdir/`dirname \$dlpath`~