2013-05-01 14:35:30 +01:00
|
|
|
#!/bin/bash
|
|
|
|
|
2014-03-12 19:54:27 +00:00
|
|
|
set -e
|
|
|
|
|
2013-05-01 14:35:30 +01:00
|
|
|
PREFIX=`cat Makefile | grep '^prefix =' | awk '{print $3}'`
|
|
|
|
case $1 in
|
|
|
|
'')
|
|
|
|
echo '-- building...'
|
2014-01-22 15:57:47 +00:00
|
|
|
make -j5
|
2013-05-01 14:35:30 +01:00
|
|
|
echo '-- installing...'
|
|
|
|
make uninstall 1>/dev/null
|
|
|
|
make install 1>/dev/null
|
|
|
|
if [[ `basename \`pwd\`` == "latan" ]]
|
|
|
|
then
|
|
|
|
echo '-- creating debug symbols...'
|
|
|
|
dsymutil .libs/liblatan.0.dylib -o ${PREFIX}/lib/liblatan.0.dylib.dSYM
|
|
|
|
fi;;
|
|
|
|
'clean')
|
|
|
|
echo '-- cleaning...'
|
2014-01-22 15:57:47 +00:00
|
|
|
make -j5 clean;;
|
2013-05-01 14:35:30 +01:00
|
|
|
*)
|
|
|
|
echo 'error: unknown action' 1>&2
|
|
|
|
exit 1;;
|
|
|
|
esac
|