setup.sh 717 字节
Newer Older
Y
yangyaming 已提交
1 2 3 4 5 6 7
#!/bin/bash

# install python dependencies
if [ -f 'requirements.txt' ]; then
    pip install -r requirements.txt
fi
if [ $? != 0 ]; then
Y
yangyaming 已提交
8
    echo "Install python dependencies failed !!!"
Y
yangyaming 已提交
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
    exit 1
fi

# install scikits.samplerate
curl -O "http://www.mega-nerd.com/SRC/libsamplerate-0.1.9.tar.gz"
if [ $? != 0 ]; then
    echo "Download libsamplerate-0.1.9.tar.gz failed !!!"
    exit 1
fi
tar -xvf libsamplerate-0.1.9.tar.gz
cd libsamplerate-0.1.9
./configure && make && make install
cd -
rm -rf libsamplerate-0.1.9
rm libsamplerate-0.1.9.tar.gz
pip install scikits.samplerate==0.3.3
if [ $? != 0 ]; then
Y
yangyaming 已提交
26
    echo "Install scikits.samplerate failed !!!"
Y
yangyaming 已提交
27 28
    exit 1
fi
Y
yangyaming 已提交
29 30

echo "Install all dependencies successfully."