Browse Source

Initial commit, works as of 03-29-2023

master
use 1 year ago
commit
0010452cbc
26 changed files with 846 additions and 0 deletions
  1. +1
    -0
      .gitignore
  2. +10
    -0
      README.md
  3. +63
    -0
      build.sh
  4. +50
    -0
      build_part.sh
  5. +39
    -0
      deps/01_fdk-aac/build.sh
  6. +32
    -0
      deps/02_intel-gmmlib/build.sh
  7. +29
    -0
      deps/03_mesa/build.sh
  8. +42
    -0
      deps/04_intel-libva/build.sh
  9. +42
    -0
      deps/04a_intel_libva_utils/build.sh
  10. +1
    -0
      deps/05_intel-sdk/MediaSDK
  11. +39
    -0
      deps/05_intel-sdk/build.sh
  12. +37
    -0
      deps/06_intel-media-driver/build.sh
  13. +32
    -0
      deps/07_libmemcached/build.sh
  14. +32
    -0
      deps/08_SDL/build.sh
  15. +39
    -0
      deps/09_libevent/build.sh
  16. +34
    -0
      deps/10_libjpeg/build.sh
  17. +39
    -0
      deps/11_libvorbis/build.sh
  18. +39
    -0
      deps/12_libwebp/build.sh
  19. +52
    -0
      deps/13_libvpx/build.sh
  20. +1
    -0
      deps/13_libvpx/libvpx
  21. +44
    -0
      deps/14_ImageMagick/build.sh
  22. +44
    -0
      deps/15_x264/build.sh
  23. +32
    -0
      deps/16_x265/build.sh
  24. +1
    -0
      deps/16_x265/x265_git
  25. +32
    -0
      deps/17_oneVPL/build.sh
  26. +40
    -0
      deps/18_zimg/build.sh

+ 1
- 0
.gitignore View File

@ -0,0 +1 @@
install/*

+ 10
- 0
README.md View File

@ -0,0 +1,10 @@
A collection of scripts, presumes you don't have root access, and that the
directory /app/ffmpeg is available and writable (default install location for
all, will need to adjust the build.sh scripts if not).
Will pull the latest versions of the packages from github, install them to the
specified location, and then remove the source code (if successful).
Packages that are not included, but are required include (but are not limited
to) gcc > v.11; gnu binutils > v2.6; and clang. Good luck, and as usual you'll
want to send a prayer up to St. Isidore.

+ 63
- 0
build.sh View File

@ -0,0 +1,63 @@
#!/bin/bash
#build with hwaccell
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/:/usr/local:/usr/local/lib/pkgconfig:/usr/local/lib64/pkgconfig:/usr/lib64/pkgconfig
pkg=jellyfin-ffmpeg
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/jellyfin/jellyfin-ffmpeg.git
fi
cd "$pkg"
if ! [[ -f configure ]] && [[ -f autogen.sh ]]
then
bash autogen.sh
elif ! [[ -f configure ]]
then
echo "NO WAY TO CONFIGURE?, CMAKE?"
exit 1
fi
make clean
make distclean
./configure --prefix="/app/ffmpeg/install/" \
--pkg-config-flags="--static" \
--extra-cflags="-I/app/ffmpeg/install/include" \
--extra-ldflags="-L/app/ffmpeg/install/lib" \
--extra-libs="-lpthread -lm -lz -ldl" \
--enable-vaapi \
--enable-opengl \
--enable-opencl \
--enable-libmfx \
--enable-libvorbis \
--enable-libvpx \
--enable-libdrm \
--enable-libzimg \
--enable-gpl \
--enable-runtime-cpudetect \
--cpu=native \
--enable-libfdk-aac \
--enable-libx264 \
--enable-libx265 \
--enable-openssl \
--enable-libmp3lame \
--enable-pic \
--enable-nonfree
# --disable-debug \
# --enable-debug \
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 50
- 0
build_part.sh View File

@ -0,0 +1,50 @@
#!/bin/bash
#Build w/o hwaccell
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/:/usr/local:/usr/local/lib/pkgconfig:/usr/local/lib64/pkgconfig:/usr/lib64/pkgconfig
pkg=jellyfin-ffmpeg
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/jellyfin/jellyfin-ffmpeg.git
fi
cd "$pkg"
if ! [[ -f configure ]] && [[ -f autogen.sh ]]
then
bash autogen.sh
elif ! [[ -f configure ]]
then
echo "NO WAY TO CONFIGURE?, CMAKE?"
exit 1
fi
make clean
make distclean
./configure \
--prefix="/app/ffmpeg/install/" \
--extra-cflags="-I/app/ffmpeg/install/include" \
--extra-ldflags="-L/app/ffmpeg/install/lib" \
--extra-libs="-lpthread -lm -lz -ldl" \
--cpu=native \
--enable-gpl \
--enable-libx264 \
--enable-libx265
# --disable-debug \
# --enable-debug \
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "DONE"

+ 39
- 0
deps/01_fdk-aac/build.sh View File

@ -0,0 +1,39 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=fdk-aac
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/mstorsjo/fdk-aac.git
fi
cd "$pkg"
if ! [[ -f configure ]] && [[ -f autogen.sh ]]
then
bash autogen.sh
elif ! [[ -f configure ]]
then
echo "NO WAY TO CONFIGURE?, CMAKE?"
exit 1
fi
make clean
make distclean
./configure \
--prefix="/app/ffmpeg/install/"
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 32
- 0
deps/02_intel-gmmlib/build.sh View File

@ -0,0 +1,32 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=gmmlib
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/intel/gmmlib.git
fi
cd "$pkg"
mkdir -p build
cd build
make clean
cmake \
-DCMAKE_INSTALL_PREFIX="/app/ffmpeg/install/" \
../
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 29
- 0
deps/03_mesa/build.sh View File

@ -0,0 +1,29 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=mesa-drm
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/freedesktop/mesa-drm.git
fi
mkdir -p build
cd "$pkg"
meson ../build/
meson configure ../build/ -Dprefix=/app/ffmpeg/install/
cd ../
if ninja -C build/ install
then
make install
cd "$curDir"
rm -rf "$pkg" "build"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 42
- 0
deps/04_intel-libva/build.sh View File

@ -0,0 +1,42 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=libva
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/intel/libva.git
fi
cd "$pkg"
if ! [[ -f configure ]] && [[ -f autogen.sh ]]
then
bash autogen.sh
elif ! [[ -f configure ]]
then
echo "NO WAY TO CONFIGURE?, CMAKE?"
exit 1
fi
make clean
make distclean
./configure \
--enable-drm \
--enable-shared \
--enable-static \
--prefix="/app/ffmpeg/install/"
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 42
- 0
deps/04a_intel_libva_utils/build.sh View File

@ -0,0 +1,42 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=libva-utils
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/intel/libva-utils.git
fi
cd "$pkg"
if ! [[ -f configure ]] && [[ -f autogen.sh ]]
then
bash autogen.sh
elif ! [[ -f configure ]]
then
echo "NO WAY TO CONFIGURE?, CMAKE?"
exit 1
fi
make clean
make distclean
./configure \
--enable-drm \
--enable-shared \
--enable-static \
--prefix="/app/ffmpeg/install/"
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 1
- 0
deps/05_intel-sdk/MediaSDK

@ -0,0 +1 @@
Subproject commit 22dc85a376ebe8be9cc43fc48654ea159419db79

+ 39
- 0
deps/05_intel-sdk/build.sh View File

@ -0,0 +1,39 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=MediaSDK
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/Intel-Media-SDK/MediaSDK.git
fi
#Unsure if still needed:
echo "#include <stdint.h>" >>./MediaSDK/api/mfx_dispatch/linux/mfxparser.cpp
cd "$pkg"
mkdir -p build
cd build
make clean
cmake \
-DCMAKE_INSTALL_PREFIX="/app/ffmpeg/install/" \
-DENABLE_X11_DRI3=ON \
-DENABLE_WAYLAND=ON \
../
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 37
- 0
deps/06_intel-media-driver/build.sh View File

@ -0,0 +1,37 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=media-driver
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/intel/media-driver.git
fi
cd "$pkg"
mkdir -p build
cd build
make clean
cmake \
-DCMAKE_INSTALL_PREFIX="/app/ffmpeg/install/" \
-DMEDIA_BUILD_FATAL_WARNINGS=OFF \
../
# -DCMAKE_C_FLAGS="-O1 -Wno-error=overloaded-virtual" \
# -DCMAKE_CXX_FLAGS="-O1 -Wno-error=overloaded-virtual" \
# -DCMAKE_Fortran_FLAGS="-O1 -Wno-error=overloaded-virtual" \
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 32
- 0
deps/07_libmemcached/build.sh View File

@ -0,0 +1,32 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=libmemcached
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/awesomized/libmemcached.git
fi
cd "$pkg"
mkdir -p build
cd build
make clean
cmake \
-DCMAKE_INSTALL_PREFIX="/app/ffmpeg/install/" \
../
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 32
- 0
deps/08_SDL/build.sh View File

@ -0,0 +1,32 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=SDL
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/libsdl-org/SDL.git
fi
cd "$pkg"
mkdir -p build
cd build
make clean
cmake \
-DCMAKE_INSTALL_PREFIX="/app/ffmpeg/install/" \
../
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 39
- 0
deps/09_libevent/build.sh View File

@ -0,0 +1,39 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=libevent
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/libevent/libevent.git
fi
cd "$pkg"
if ! [[ -f configure ]] && [[ -f autogen.sh ]]
then
bash autogen.sh
elif ! [[ -f configure ]]
then
echo "NO WAY TO CONFIGURE?, CMAKE?"
exit 1
fi
make clean
make distclean
./configure \
--prefix="/app/ffmpeg/install/"
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 34
- 0
deps/10_libjpeg/build.sh View File

@ -0,0 +1,34 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=libjpeg-turbo
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/libjpeg-turbo/libjpeg-turbo.git
fi
cd "$pkg"
mkdir -p build
cd build
make clean
cmake \
-DCMAKE_INSTALL_PREFIX="/app/ffmpeg/install/" \
-DCMAKE_C_FLAGS="-fPIC" \
-DCMAKE_CXX_FLAGS="-fPIC" \
../
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 39
- 0
deps/11_libvorbis/build.sh View File

@ -0,0 +1,39 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=vorbis
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/xiph/vorbis.git
fi
cd "$pkg"
if ! [[ -f configure ]] && [[ -f autogen.sh ]]
then
bash autogen.sh
elif ! [[ -f configure ]]
then
echo "NO WAY TO CONFIGURE?, CMAKE?"
exit 1
fi
make clean
make distclean
./configure \
--prefix="/app/ffmpeg/install/"
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 39
- 0
deps/12_libwebp/build.sh View File

@ -0,0 +1,39 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=libwebp
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/webmproject/libwebp.git
fi
cd "$pkg"
if ! [[ -f configure ]] && [[ -f autogen.sh ]]
then
bash autogen.sh
elif ! [[ -f configure ]]
then
echo "NO WAY TO CONFIGURE?, CMAKE?"
exit 1
fi
make clean
make distclean
./configure \
--prefix="/app/ffmpeg/install/"
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 52
- 0
deps/13_libvpx/build.sh View File

@ -0,0 +1,52 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=libvpx
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/webmproject/libvpx/
fi
cd "$pkg"
if ! [[ -f configure ]] && [[ -f autogen.sh ]]
then
bash autogen.sh
elif ! [[ -f configure ]]
then
echo "NO WAY TO CONFIGURE?, CMAKE?"
exit 1
fi
make clean
make distclean
./configure \
--enable-runtime-cpu-detect \
--enable-vp9 \
--enable-vp8 \
--enable-postproc \
--enable-vp9-postproc \
--enable-multi-res-encoding \
--enable-webm-io \
--enable-vp9-highbitdepth \
--enable-onthefly-bitpacking \
--enable-realtime-only \
--enable-better-hw-compatibility \
--disable-unit-tests \
--as=nsam \
--prefix="/app/ffmpeg/install/"
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 1
- 0
deps/13_libvpx/libvpx

@ -0,0 +1 @@
Subproject commit 972149cafeb71d6f08df89e91a0130d6a38c4b15

+ 44
- 0
deps/14_ImageMagick/build.sh View File

@ -0,0 +1,44 @@
#!/bin/bash
#Depends on libtool
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=ImageMagick
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/ImageMagick/ImageMagick.git
fi
cd "$pkg"
if ! [[ -f configure ]] && [[ -f autogen.sh ]]
then
bash autogen.sh
elif ! [[ -f configure ]]
then
echo "NO WAY TO CONFIGURE?, CMAKE?"
exit 1
fi
make clean
make distclean
./configure \
--enable-opengl \
--enable-opencl \
--prefix="/app/ffmpeg/install/"
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 44
- 0
deps/15_x264/build.sh View File

@ -0,0 +1,44 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=x264
if ! [[ -d "$pkg" ]]
then
git clone https://code.videolan.org/videolan/x264.git
fi
cd "$pkg"
if ! [[ -f configure ]] && [[ -f autogen.sh ]]
then
bash autogen.sh
elif ! [[ -f configure ]]
then
echo "NO WAY TO CONFIGURE?, CMAKE?"
exit 1
fi
make clean
make distclean
./configure \
--prefix="/app/ffmpeg/install/"
# --disable-asm \
make -j8
if make
then
make install
make install-lib-dev
make install-lib-shared
make install-lib-static
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 32
- 0
deps/16_x265/build.sh View File

@ -0,0 +1,32 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=x265_git
if ! [[ -d "$pkg" ]]
then
git clone https://bitbucket.org/multicoreware/x265_git
fi
cd "$pkg"
mkdir -p build
cd build
make clean
cmake \
-DCMAKE_INSTALL_PREFIX="/app/ffmpeg/install/" \
../source/
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 1
- 0
deps/16_x265/x265_git

@ -0,0 +1 @@
Subproject commit c07d076cf20ab41d8077a804dda70fdbc3b97386

+ 32
- 0
deps/17_oneVPL/build.sh View File

@ -0,0 +1,32 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=oneVPL
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/oneapi-src/oneVPL.git
fi
cd "$pkg"
mkdir -p build
cd build
make clean
cmake \
-DCMAKE_INSTALL_PREFIX="/app/ffmpeg/install/" \
../
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

+ 40
- 0
deps/18_zimg/build.sh View File

@ -0,0 +1,40 @@
#!/bin/bash
export PKG_CONFIG_PATH=/app/ffmpeg/install/lib/pkgconfig:/app/ffmpeg/install/lib64/pkgconfig/
curDir="$PWD"
pkg=zimg
if ! [[ -d "$pkg" ]]
then
git clone https://github.com/sekrit-twc/zimg.git
fi
cd "$pkg"
git submodule update --init --recursive
if ! [[ -f configure ]] && [[ -f autogen.sh ]]
then
bash autogen.sh
elif ! [[ -f configure ]]
then
echo "NO WAY TO CONFIGURE?, CMAKE?"
exit 1
fi
make clean
make distclean
./configure \
--prefix="/app/ffmpeg/install/"
make -j8
if make
then
make install
cd "$curDir"
rm -rf "$pkg"
else
cd "$curDir"
echo "BUILD FAILED"
fi
echo "Done"

Loading…
Cancel
Save