build_mpg321() { HERE=`pwd` BUILDDEPS="compiletc.tcz" #DEPS= . ./libao-sc.inc || exit 1 . ./libmad-sc.inc || exit 1 . ./libid3tag-sc.inc || exit 1 for I in `echo "$BUILDDEPS"`; do su tc -c "tce-load -i "$I"" || su tc -c "tce-load -iw "$I"" done PKGPATH=$1 export LDFLAGS="-L$PKGPATH/lib" export CPPFLAGS="-I$PKGPATH/include" export PATH="$PKGPATH/bin:$PATH" export PKG_CONFIG_PATH="$PKGPATH/lib/pkgconfig:$PKG_CONFIG_PATH" export LD_LIBRARY_PATH="$PKGPATH/lib" if [ ! -f "$TMPDIR"/libid3tag ]; then build_libid3tag "$PKGPATH" || exit 1 fi if [ ! -f "$TMPDIR"/libao ]; then build_libao "$PKGPATH" || exit 1 fi if [ ! -f "$TMPDIR"/libmad ]; then build_libmad "$PKGPATH" || exit 1 fi tar xvf mpg321_0.3.2.orig.tar.gz || exit 1 cd mpg321-0.3.2-orig || exit 1 ./configure --prefix="$PKGPATH" --bindir="$PKGPATH"/localbin --with-default-audio=alsa --enable-ipv6 --disable-mpg123-symlink || exit 1 make || exit 1 make install || exit 1 cd "$HERE" touch "$TMPDIR"/mpg321 }