[pacman-dev] makepkg: unsetting variables

Alexander Baldeck kth5 at archlinuxppc.org
Wed Dec 6 08:47:14 EST 2006


Hey again,

sorry for being such a nagger today.

Then again, I have a problem with this change - see attachment - to makepkg.

Imagine you want to build glibc from Archlinux ABS. I have two cases for 
you in which it starts messing things up:

1) comparisons in if-clauses make makepkg freak out

The following example:

if [ "${CARCH}" = "i686" ]; then
     # Hack to fix NPTL issues with Xen, only required on 32bit platforms
     export CFLAGS="${CFLAGS} -mno-tls-direct-seg-refs"
fi


causes:

/usr/bin/makepkg: line 415: unset: `[': not a valid identifier
/usr/bin/makepkg: line 415: unset: `"${CARCH}"': not a valid identifier
/usr/bin/makepkg: line 415: unset: `=': not a valid identifier
/usr/bin/makepkg: line 415: unset: `"i686"': not a valid identifier


2) appending strings in bash-style does not work anymore

After getting rid of the if-clauses in the PKGBUILD for the sake of 
testing, a line like this:

$ CFLAGS="-O2"
$ export CFLAGS="${CFLAGS} -mno-tls-direct-seg-refs"

will result in:

$ echo $CFLAGS
$ -mno-tls-direct-seg-refs


This can't be right... sorry. Since the commit message shows that frugal 
changes were merged at that time plus that they may still be incomplete, 
I understand the fact that it might not be ready for general use but at 
least import something that doesn't fail so obviously. :)

BTW, is there no bug tracker for pacman?


Cheers,

-O
-------------- next part --------------
A non-text attachment was scrubbed...
Name: revert.patch
Type: text/x-patch
Size: 404 bytes
Desc: not available
URL: <http://archlinux.org/pipermail/pacman-dev/attachments/20061206/1d22b53e/attachment.bin>


More information about the pacman-dev mailing list