[aur-general] PKGBUILD review

Justin Dray justin at dray.be
Fri Feb 5 06:30:32 UTC 2016


You've still got references to OS X and windows installs

Also instead of

if test _arch == '32'; then
    scons -j $cores platform=server target=release_debug tools=no bits=32
else
    scons -j $cores platform=server target=release_debug tools=no bits=64
fi

you can just do

scons -j $cores platform=server target=release_debug tools=no bits=$_arch

You're setting _arch in 3 places even though it can only have 2 values;
it's also in an array for no apparent reason, you can shorten it to
_arch=32
[[ $CARCH == x86_64 ]] && _arch=64

Or some such variation.

The same goes in the install, you have a bunch of 'if _arch == 32' and then
using 32 twice in a string; just substitute that with the variable.

Regards,
Justin


More information about the aur-general mailing list