mpd/scripts/makerpm.sh
Avuton Olrich 0532c9ab4c Do a better job of trying to be able to run these
scripts from 'anywhere'

git-svn-id: https://svn.musicpd.org/mpd/trunk@4430 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2006-07-22 22:27:48 +00:00

30 lines
466 B
Bash
Executable File

#!/bin/bash
PWD=`pwd`
## If we're not in the scripts directory
## assume the base directory.
if test "`basename $PWD`" != "scripts"; then
MYOLDPWD=`pwd`
cd `dirname $0`
fi
./makedist.sh
rpmbuild -bb mpd.spec
if test $? -eq 0; then
echo 'Your RPM should be ready now'
else
echo 'Something went wrong when building your RPM'
fi
if test -f ../mpd-?.??.?.tar.gz;
then
rm ../mpd-?.??.?.tar.gz
fi
if test "`basename $PWD`" != "scripts"; then
cd $MYOLDPWD
fi