contribs.sh 2.04 KB
Newer Older
1 2
#! /bin/sh

3 4
QT4_FILE="qt4-4.8-win32-bin.tar.bz2"
QT4_URL="http://rohityadav.in/files/contribs/qt4-4.8-win32-bin.tar.bz2"
5
VLC_VERSION_PREFIX="vlc-2.0.4"
6
VLC_FILE="${VLC_VERSION_PREFIX}-win32.7z"
7
VLC_URL="http://download.videolan.org/vlc/2.0.4/win32/${VLC_FILE}"
8 9
FREI0R_FILE="frei0r-plugins-1.2.1.tar.gz"
FREI0R_URL="http://www.piksel.no/frei0r/releases/frei0r-plugins-1.2.1.tar.gz"
10 11
FREI0R_EFFECTS_FILE="effects.7z"
FREI0R_EFFECTS_URL="http://people.videolan.org/~jb/vlmc/effects.7z"
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32

ROOT_FOLDER=`pwd`

# Get the dependencies, aka VLC+Qt
mkdir -p src-dl/
cd src-dl/
if [ ! -f $QT4_FILE ]; then
    wget $QT4_URL ;
else
    echo "Qt4 OK";
fi
if [ ! -f $VLC_FILE ]; then
    wget $VLC_URL ;
else
    echo "VLC OK";
fi
if [ ! -f $FREI0R_FILE ]; then
    wget $FREI0R_URL ;
else
    echo "FREI0R OK";
fi
33 34 35
if [ ! -f $FREI0R_EFFECTS_FILE ]; then
    wget $FREI0R_EFFECTS_URL ;
else
36
    echo "FREI0R EFFECTS OK";
37
fi
38

39
cd $ROOT_FOLDER
40 41 42 43 44 45

# bin and dlls
mkdir bin && mkdir include && mkdir temp

7z e src-dl/$VLC_FILE "$VLC_VERSION_PREFIX/libvlc.dll" -otemp
7z e src-dl/$VLC_FILE "$VLC_VERSION_PREFIX/libvlccore.dll" -otemp
46
7z e src-dl/$VLC_FILE "$VLC_VERSION_PREFIX/plugins/*" -otemp/plugins
47 48 49 50 51 52
cd temp
  for i in libvlc.dll libvlccore.dll; do
    cp -v $i $ROOT_FOLDER/bin/
  done
  cd plugins
    for i in libqt4_plugin.dll libskins2_plugin.dll libstream_out_raop_plugin.dll libvout_sdl_plugin.dll libaout_sdl_plugin.dll; do
53
        rm -f $i
54 55 56
    done
  cd ..
cd ..
57
cp -r $ROOT_FOLDER/temp/plugins/ $ROOT_FOLDER/bin/
58 59 60 61 62

cd $ROOT_FOLDER

#VLC sdk
7z x src-dl/$VLC_FILE "$VLC_VERSION_PREFIX/sdk"
63 64
mv -fv $VLC_VERSION_PREFIX/sdk/include/vlc $ROOT_FOLDER/include/vlc
mv -fv $VLC_VERSION_PREFIX/sdk/lib/ $ROOT_FOLDER/
65
rm -frv $VLC_VERSION_PREFIX
66 67 68

# Qt
tar xvf src-dl/$QT4_FILE -C . --strip-components=1
69
lrelease -compress -silent -nounfinished ts/*.ts
70 71 72
cd include && ln -sf qt4/src && cd ..

#frei0r
73 74
tar xvf src-dl/$FREI0R_FILE -C $ROOT_FOLDER/temp/
mv `find $ROOT_FOLDER/temp | grep frei0r.h$ | head -1` $ROOT_FOLDER/include
75
7z x src-dl/$FREI0R_EFFECTS_FILE "effects"
76
mv -fv effects/ bin/
77 78
#Clean up
rm -rf temp