Created
February 22, 2017 00:45
-
-
Save manureini/f4e3110539c4944d2349b0946b95cd5e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#modified from http://forum.ultra-star.de/viewtopic.php?f=13&t=11234 | |
apt-get update | |
apt-get upgrade | |
#rpi-update | |
aptitude -y remove libavutil54 | |
aptitude install -y git curl unzip autoconf automake build-essential texinfo zlib1g-dev yasm cmake mercurial checkinstall | |
aptitude install -y libtool libtool-bin libssl-dev pkg-config | |
aptitude install -y fpc fpc-source | |
aptitude install -y libsdl2-dev libsdl2-2.0-0 libsdl2-gfx-1.0-0 libsdl2-gfx-dev libsdl2-image-2.0-0 libsdl2-image-dev libsdl2-mixer-2.0-0 libsdl2-mixer-dev libsdl2-net-2.0-0 libsdl2-net-dev libsdl2-ttf-2.0-0 libsdl2-ttf-dev | |
aptitude install -y libsqlite3-0 libsqlite3-dev liblua5.2-0 liblua5.2-dev portaudio19-dev | |
aptitude install -y libomxil-bellagio-dev raspberrypi-kernel-headers | |
aptitude install -y libmp3lame-dev libopus-dev libfftw3-dev | |
aptitude install -y libass-dev libfreetype6-dev libtheora-dev libva-dev libvdpau-dev libvorbis-dev libxcb1-dev libxcb-shm0-dev libxcb-xfixes0-dev vdpauinfo | |
aptitude install -y libgl1-mesa-dri frei0r-plugins-dev libgsm1-dev libopenjpeg-dev librtmp-dev libspeex-dev libxvidcore-dev libcdio-dev cdparanoia libcdio-paranoia-dev | |
sudo apt-get install libdvbpsi-dev libavcodec-dev libavutil-dev libtool automake libswscale-dev | |
sudo apt-get install -t jessie libdvbpsi9 libdvbpsi-dev | |
apt-get install libasound2-plugins | |
#aptitude install -y libpng12-0 libpng12-dev | |
#libvdpau-va-gl gnutls-dev | |
## libdc1394-2 | |
cd /home/ | |
mkdir src | |
cd src | |
#git clone https://github.com/raspberrypi/userland.git | |
git clone git://git.videolan.org/x264 | |
hg clone https://bitbucket.org/multicoreware/x265 | |
git clone https://chromium.googlesource.com/webm/libvpx | |
#git clone git://git.ffmpeg.org/rtmpdump | |
##########git clone --depth 1 https://github.com/FFmpeg/FFmpeg.git | |
#wget http://ffmpeg.org/releases/ffmpeg-2.8.9.tar.gz | |
wget http://ffmpeg.org/releases/ffmpeg-3.2.tar.gz | |
#wget http://www.libsdl.org/projects/SDL_image/release/SDL2_image-2.0.1.tar.gz | |
#wget http://www.libsdl.org/projects/SDL_mixer/release/SDL2_mixer-2.0.1.tar.gz | |
#wget http://www.libsdl.org/projects/SDL_net/release/SDL2_net-2.0.1.zip | |
#wget http://www.libsdl.org/projects/SDL_ttf/release/SDL2_ttf-2.0.14.tar.gz | |
#wget http://www.libsdl.org/release/SDL2-2.0.5.tar.gz | |
#wget https://netcologne.dl.sourceforge.net/project/sdl2gfx/SDL2_gfx-1.0.1.zip | |
wget https://heanet.dl.sourceforge.net/project/freepascal/Source/3.0.0/fpcbuild-3.0.0.tar.gz | |
git clone https://github.com/UltraStar-Deluxe/USDX.git | |
git clone https://github.com/mstorsjo/fdk-aac.git | |
for f in *.tar.gz ; do tar -xvzf $f ; done | |
for f in *.tar.bz2 ; do tar -xvjf $f ; done | |
for f in *.zip ; do unzip $f ; done | |
# SUPPORT FOR LIBAACPLUS HAS BEEN REMOVED FROM FFMPEG | |
#wget http://tipok.org.ua/downloads/media/aacplus/libaacplus/libaacplus-2.0.2.tar.gz | |
#cd libaacplus-* | |
#./autogen.sh --with-parameter-expansion-string-replace-capable-shell=/bin/bash --host=arm-unknown-linux-gnueabi --enable-static | |
#make -j4 | |
#checkinstall | |
#cd .. | |
cd fdk-aac | |
./autogen.sh | |
./configure --enable-shared --enable-static | |
make -j4 | |
checkinstall --fstrans=no | |
cd .. | |
ldconfig | |
cd x264 | |
./configure --host=arm-unknown-linux-gnueabi --enable-shared --disable-opencl #-fPIC | |
make -j4 | |
checkinstall --fstrans=no | |
cd .. | |
cd x265 | |
PATH="$HOME/bin:$PATH" cmake -G "Unix Makefiles" -DENABLE_SHARED:bool=off ./source | |
make -j4 | |
checkinstall --fstrans=no | |
cd .. | |
cd libvpx | |
./configure --disable-examples --disable-unit-tests --enable-shared --disable-static | |
make -j4 | |
checkinstall --fstrans=no | |
cd .. | |
#cd rtmpdump | |
#make -j4 SYS=posix | |
#checkinstall | |
#cd .. | |
#ldconfig | |
# cd faac-* | |
# nano common/mp4v2/mpeg4ip.h | |
# | |
# | |
# #line 126 | |
# | |
# | |
# #ifdef __cplusplus | |
# extern "C" { | |
# #endif | |
# #ifndef _STRING_H | |
# char *strcasestr(const char *haystack, const char *needle); | |
# #endif | |
# #ifdef __cplusplus | |
# } | |
# #endif | |
# | |
# | |
# ./configure --host=arm-unknown-linux-gnueabi | |
# make -j4 | |
# checkinstall | |
# cd .. | |
# | |
# ldconfig | |
# | |
# cd mstorsjo-fdk-aac* | |
# autoreconf -fiv | |
# ./configure --enable-shared | |
# make -j4 | |
# checkinstall | |
# cd .. | |
# | |
# ldconfig | |
# | |
#./configure --prefix=/usr --disable-debug --disable-static --disable-stripping --enable-avisynth --enable-avresample --enable-fontconfig --enable-gnutls --enable-ladspa --enable-libbluray --enable-libfribidi --enable-libgsm --enable-libiec61883 --enable-libmodplug --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libpulse --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libssh --enable-libv4l2 --enable-libwebp --enable-libxvid --enable-netcdf --enable-shared --enable-version3 --enable-x11grab --host-cflags='"-fPIC"' | |
# --arch=arm --enable-pthreads --enable-runtime-cpudetect --extra-version='6:11.8-1~deb8u1+rpi1' --libdir=/usr/lib/arm-linux-gnueabihf --prefix=/usr --disable-yasm --disable-avserver --disable-protocol=concat --disable-armv6t2 --disable-neon --enable-bzlib --enable-libdc1394 --enable-libfreetype --enable-frei0r --enable-gnutls --enable-libgsm --enable-libmp3lame --enable-librtmp --enable-libopencv --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-vaapi --enable-vdpau --enable-libvorbis --enable-libvpx --enable-zlib --enable-gpl --enable-swscale --enable-libcdio --enable-x11grab --enable-libx264 --enable-libxvid --shlibdir=/usr/lib/arm-linux-gnueabihf/neon/vfp --cpu=armv7-a --extra-cflags='-mfpu=neon -fPIC -DPIC' --enable-shared --disable-static | |
################# TODO --enable-libx265 --enable-librtmp --enable-libfdk-aac --enable-omx --enable-omx-rpi | |
###### -enable-libass --disable-vdpau | |
cd ffmpeg-*/ | |
#working ffmpeg3 | |
./configure --arch=arm --enable-pthreads --enable-runtime-cpudetect --prefix=/usr --enable-neon --enable-bzlib --enable-libfreetype --enable-gpl --shlibdir=/usr/lib/arm-linux-gnueabihf/neon/vfp --cpu=armv7-a --extra-cflags='-mfpu=neon -fPIC -DPIC' --enable-shared --disable-static --enable-pic --enable-libx264 --enable-mmal --enable-hwaccel=h264_mmal --enable-omx-rpi --enable-omx --enable-opengl --enable-nonfree --enable-vdpau --enable-vaapi --enable-libtheora --enable-decoder=h264_mmal --enable-decoder=mpeg2_mmal --enable-decoder=mpeg4_mmal --enable-encoder=h264_omx --enable-encoder=h264_omx --enable-avresample --enable-libass --enable-libfdk-aac --enable-libmp3lame --enable-libvorbis --enable-libvpx --enable-libopus --disable-decoder=h264 --disable-decoder=mpeg4 --disable-encoder=libx264 --disable-encoder=mpeg4 | |
make -j4 | |
checkinstall --fstrans=no | |
ldconfig | |
cd fpcbuild-* | |
make NOGDB=1 OPT="-dFPC_ARMHF -CX -CfVFPV3_D16 -O- -XX -Xs" -j4 build | |
##make NOGDB=1 install | |
checkinstall --fstrans=no make NOGDB=1 install | |
unlink /usr/bin/ppcarm | |
ln -s /usr/local/lib/fpc/3.0.0 /usr/lib/fpc/3.0.0 | |
ln -s /usr/local/lib/fpc/3.0.0/ppcarm /usr/bin/ppcarm | |
cd .. | |
# cd SDL2-* | |
# ./configure; make; checkinstall | |
# cd .. | |
# | |
# cd SDL2_image-* | |
# ./autogen.sh && ./configure; make -j4; checkinstall | |
# cd .. | |
# | |
# cd SDL2_mixer-* | |
# ./autogen.sh && ./configure; make -j4; checkinstall | |
# cd .. | |
# | |
# cd SDL2_net-* | |
# ./autogen.sh && ./configure; make -j4; checkinstall | |
# cd .. | |
# | |
# cd SDL2_ttf-* | |
# ./autogen.sh && ./configure; make -j4; checkinstall | |
# cd .. | |
# | |
# cd SDL2_gfx-* | |
# ./autogen.sh && ./configure; make -j4; checkinstall | |
# cd .. | |
# | |
ln -s /lib/arm-linux-gnueabihf/libgcc_s.so.1 /lib/arm-linux-gnueabihf/libgcc_s.so | |
cd USDX | |
./autogen.sh | |
./configure --prefix=/usr | |
nano src/Makefile | |
# PFLAGS_RELEASE_DEFAULT := -Xs- -O2 ändern zu PFLAGS_RELEASE_DEFAULT := -Xs- -O1 | |
make -j4 | |
checkinstall --fstrans=no | |
cd .. | |
#dpkg -r fdk | |
#dpkg -r fpcbuild | |
#dpkg -r ffmpeg | |
#dpkg -r x264 | |
#dpkg -r x265 | |
#dpkg -r libvpx | |
#dpkg -r usdx | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi there,
i just tried to run your script, but I get an error when it tries to install the deb:
(Lese Datenbank ... 157262 Dateien und Verzeichnisse sind derzeit installiert.) Vorbereitung zum Entpacken von .../ffmpeg_3.2-1_armhf.deb ... Entpacken von ffmpeg (3.2-1) ... dpkg: Fehler beim Bearbeiten des Archivs /home/src/ffmpeg-3.2/ffmpeg_3.2-1_armhf.deb (--install): Versuch, »/usr/include/libavcodec/vdpau.h« zu überschreiben, welches auch in Paket libavcodec-dev 6:11.9-1~deb8u1+rpi1 ist dpkg-deb: Fehler: Unterprozess einfügen wurde durch Signal (Datenübergabe unterbrochen (broken pipe)) getötet Fehler traten auf beim Bearbeiten von: /home/src/ffmpeg-3.2/ffmpeg_3.2-1_armhf.deb
Any clues?