#!/bin/bash build_audacity2(){ HERE=`pwd` . ./ffmpeg-shared-sc.inc || exit 1 . ./lame-sc.inc || exit 1 . ./alsa-lib-sc.inc || exit 1 GIFLIBVER=4.1.6 # TIFFVER=4.0.0 LCMSVER=1.19 JACKVER="audio-connection-kit-0.121.3" SOUNDTOUCHVER=1.6.0 LIBSAMPLERATEVER=0.1.8 LIBMADVER=0.15.1b LIBSNDFILEFER=1.0.25 FLACVER=1.2.1 LIBOGGVER=1.3.0 LIBVORBISVER=1.3.2 LIBTHEORAVER=1.1.1 LIBID3TAGVER=0.15.1b wxGTKVER=2.8.12 BUILDDEPS="gettext.tcz perl5.tcz alsa-dev.tcz libasound.tcz Xorg-7.6-dev.tcz \ Xorg-7.6-bin.tcz \ libtool.tcz libtool-dev.tcz" DEPS="graphics-libs-1.tcz Xorg-7.6-lib.tcz alsa.tcz" for I in `echo "$BUILDDEPS"`; do DEPNAME=`basename "$I" .tcz` if [ ! -f /usr/local/tce.installed/"$DEPNAME" ]; then if [ -f "$TCEDIR"/"$I" ]; then if su tc -c "tce-load -i "$I""; then echo "${YELLOW}"$I" loaded locally${NORMAL}" else echo "${RED}"$I" failed to load, exiting..${NORMAL}" exit 1 fi else if su tc -c "tce-load -iw "$I""; then echo "${YELLOW}"$I" loaded from repo${NORMAL}" else echo "${RED}"$I" failed to load, exiting..${NORMAL}" exit 1 fi fi fi done PKGPATH=$1 export LDFLAGS="-L$PKGPATH/lib -L/apps/gtk2/lib $LDFLAGS" export CPPFLAGS="-I$PKGPATH/include -I/apps/gtk2/include" export PATH="$PKGPATH/bin:/apps/gtk2/bin:$PATH" export PKG_CONFIG_PATH="$PKGPATH/lib/pkgconfig:/apps/gtk2/lib/pkgconfig:$PKG_CONFIG_PATH" export LD_LIBRARY_PATH="$PKGPATH/lib:/apps/gtk2/lib" if [ ! -f "$TMPDIR"/ffmpeg-shared ]; then build_ffmpeg-shared "$PKGPATH" || exit 1 fi if [ ! -f "$TMPDIR"/lame ]; then build_lame "$PKGPATH" || exit 1 fi if [ ! -f "$TMPDIR"/libid3tag ]; then tar xvf libid3tag-$LIBID3TAGVER.tar.xz || exit 1 cd libid3tag-$LIBID3TAGVER || exit 1 ./configure --prefix="$PKGPATH" || exit 1 make || exit 1 make install || exit 1 cd "$HERE" touch "$TMPDIR"/libid3tag fi if [ ! -f "$TMPDIR"/libogg ]; then tar xvf libogg-$LIBOGGVER.tar.xz || exit 1 cd libogg-$LIBOGGVER || exit 1 ./configure --prefix="$PKGPATH" || exit 1 make || exit 1 make install || exit 1 cd "$HERE" touch "$TMPDIR"/libogg fi if [ ! -f "$TMPDIR"/libvorbis ]; then tar xvf libvorbis-$LIBVORBISVER.tar.xz || exit 1 cd libvorbis-$LIBVORBISVER || exit 1 ./configure --prefix="$PKGPATH" || exit 1 make || exit 1 make install || exit 1 cd "$HERE" touch "$TMPDIR"/libvorbis fi if [ ! -f "$TMPDIR"/libtheora ]; then tar xvf libtheora-1.1.1.tar.xz || exit 1 cd libtheora-1.1.1 || exit 1 ./configure --prefix="$PKGPATH" || exit 1 make || exit 1 make install || exit 1 cd "$HERE" touch "$TMPDIR"/libtheora fi if [ ! -f "$TMPDIR"/libsndfile ]; then tar xvf libsndfile-1.0.25.tar.xz || exit 1 cd libsndfile-1.0.25 ./configure --prefix="$PKGPATH" || exit 1 make || exit 1 make install || exit 1 cd "$HERE" touch "$TMPDIR"/libsndfile fi if [ ! -f "$TMPDIR"/flac ]; then tar xvf flac-1.2.1.tar.xz || exit 1 cd flac-1.2.1 || exit 1 patch -p1 < ../flac-1.2.1-gcc-4.3-includes.patch || exit 1 ./configure --prefix="$PKGPATH" --disable-xmms-plugin || exit 1 make || exit 1 make install || exit 1 cd "$HERE" touch "$TMPDIR"/flac fi if [ ! -f "$TMPDIR"/soundtouch ]; then tar xvf soundtouch-1.5.0.tar.xz || exit 1 cd soundtouch || exit 1 ln -s /usr/local/share/libtool/config/ltmain.sh /usr/share/libtool/config/ aclocal libtoolize --force autoheader autoconf automake ./configure --prefix="$PKGPATH" --enable-shared || exit 1 make || exit 1 make install || exit 1 cd "$HERE" touch "$TMPDIR"/soundtouch fi if [ ! -f "$TMPDIR"/wxgtk ]; then tar xvf wxGTK-$wxGTKVER.tar.xz || exit 1 cd wxGTK-$wxGTKVER || exit 1 ./configure --prefix="$PKGPATH" --with-gtk-prefix=/apps/gtk2 --enable-unicode || exit 1 make || exit 1 make install || exit 1 cd "$HERE" touch "$TMPDIR"/wxgtk fi if [ ! -f "$TMPDIR"/audacity2 ]; then tar xvf audacity-fullsrc-2.0.0.tar.xz || exit 1 cd audacity-src-2.0.0 ./configure --prefix="$PKGPATH" --with-portaudio --with-libsamplerate \ --without-libresample --with-libmad --with-ffmpeg --with-id3tag --with-libflac \ --with-vorbis --with-libexpat --with-libsndfile --with-soundtouch \ --enable-unicode --without-taglib || exit 1 make || exit 1 make install || exit 1 cd "$HERE" touch "$TMPDIR"/audacity2 fi if [ ! -f "$TMPDIR"/alsa-lib ]; then build_alsa-lib "$PKGPATH" || exit 1 fi }