[pacman-dev] [PATCH] Fix command line argument parsing in makepkg

Sebastian Nowicki sebnow at gmail.com
Wed May 21 12:21:14 EDT 2008

It's definitely not a good patch, I just needed to get it fixed quickly so I
could use makepkg, and thought I might as well submit it to provoke some
discussion. It seems -p does brake, and I assume --forcever does as well. I
didn't have enough knowledge of makepkg, nor the time, to tackle the problem
properly. I suppose filing a bug report would have been better ;).

I narrowed down the problem to the eval command. It appears eval changes $@
for some reason, as the following shell scripts shows:
$ cat test-eval.sh
echo "\$@ before eval: "
echo $@
eval set -- "-p test abcd"
echo "\$@ after eval:"
echo $@

$ ./test-eval.sh this is a test
$@ before eval:
this is a test
$@ after eval:
-p test abcd

Sebastian Nowicki
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://archlinux.org/pipermail/pacman-dev/attachments/20080522/9920993a/attachment.htm>

More information about the pacman-dev mailing list