wangqr / Aegisub

Win64 nightly builds available at GHA artifact, also at following link:
https://ftp.wangqr.tk/aegisub/
Other
794 stars 49 forks source link

configure.ac: Fix error when using dash as /bin/sh #89

Closed TheGreatMcPain closed 3 years ago

TheGreatMcPain commented 3 years ago

Apparently passing arguments to a script while also sourcing doesn't work in a POSIX shell like dash. For example:

this doesn't work.

dash -c ". build/version.sh ."

To get it to work I had to use set -- to modify the current script arguments before sourcing version.sh. Like this:

dash -c "set -- '.'; . build/version.sh"

I also make sure to save the old ./configure arguments before running set -- "$srcdir" and then restoring them after sourcing version.sh

wangqr commented 3 years ago

Issue fixed with alternative approach in c2f64bb7bb1198273779dcd501c66fe16c5e342c. Thanks for the PR.