Skip to content

Instantly share code, notes, and snippets.

@blacksailer
Forked from jackersson/build-gstreamer.sh
Last active April 21, 2020 10:23
Show Gist options
  • Save blacksailer/fed978a43b6d83f996717de239a24be6 to your computer and use it in GitHub Desktop.
Save blacksailer/fed978a43b6d83f996717de239a24be6 to your computer and use it in GitHub Desktop.
Build gstreamer from source
#!/bin/bash
# Set your target branch
BRANCH="1.14.2"
exec > >(tee build-gstreamer.log)
exec 2>&1
[ ! -d orc ] && git clone git://anongit.freedesktop.org/git/gstreamer/orc
[ ! -d gstreamer ] && git clone git://anongit.freedesktop.org/git/gstreamer/gstreamer
[ ! -d gst-plugins-base ] && git clone git://anongit.freedesktop.org/git/gstreamer/gst-plugins-base
[ ! -d gst-plugins-good ] && git clone git://anongit.freedesktop.org/git/gstreamer/gst-plugins-good
[ ! -d gst-plugins-bad ] && git clone git://anongit.freedesktop.org/git/gstreamer/gst-plugins-bad
[ ! -d gst-libav ] && git clone git://anongit.freedesktop.org/git/gstreamer/gst-libav
[ ! -d gst-plugins-ugly ] && git clone git://anongit.freedesktop.org/git/gstreamer/gst-plugins-ugly
[ ! -d gst-python ] && git clone git://anongit.freedesktop.org/git/gstreamer/gst-python
export LD_LIBRARY_PATH=/usr/local/lib/
cd orc
mkdir build && cd build
meson ..
ninja
ninja install
cd ../..
sudo ldconfig
cd gstreamer
git checkout $BRANCH
./autogen.sh --disable-gtk-doc
make
sudo make install
cd ..
cd gst-plugins-base
git checkout $BRANCH
./autogen.sh --disable-gtk-doc
make
sudo make install
cd ..
cd gst-libav
git checkout $BRANCH
./autogen.sh --disable-gtk-doc --enable-orc
make
sudo make install
cd ..
cd gst-plugins-good
git checkout $BRANCH
./autogen.sh --disable-gtk-doc
make
sudo make install
cd ..
cd gst-plugins-bad
git checkout $BRANCH
./autogen.sh --disable-gtk-doc --enable-orc
make
sudo make install
cd ..
cd gst-plugins-ugly
git checkout $BRANCH
./autogen.sh --disable-gtk-doc --enable-orc
make
sudo make install
cd ..
# export PYTHON=/usr/bin/python3 (Specify required python version)
cd gst-python
git checkout $BRANCH
./autogen.sh --disable-gtk-doc --noconfigure
# with-libpython-dir -> location of libpython*.so
./configure --with-libpython-dir="/usr/lib/x86_64-linux-gnu"
make
sudo make install
cd ..
sudo ldconfig
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment