Created
March 22, 2025 19:23
-
-
Save tabletseeker/f01da0b3709dbad64637a6ae4696ea15 to your computer and use it in GitHub Desktop.
Build FreeRDP with h264/ffmpeg support
This file contains hidden or 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 | |
BUILD_DIR=${PWD}/build | |
CUSTOM_VER="" | |
REPO="FreeRDP/FreeRDP" | |
GIT_URL="https://api.github.com/repos/${REPO}/tags" | |
BRANCH=$(curl -s ${GIT_URL} | jq '.[]' | jq -r '.name' | grep -Pm1 "${CUSTOM_VER}") | |
mkdir -p "$BUILD_DIR" | |
rm -rf "$BUILD_DIR/*" | |
sudo /bin/bash -c 'cat > /etc/apt/sources.list << EOF | |
deb https://deb.debian.org/debian bookworm main contrib non-free non-free-firmware | |
deb https://deb.debian.org/debian trixie main contrib non-free non-free-firmware | |
deb https://deb.debian.org/debian sid main contrib non-free non-free-firmware | |
deb https://deb.debian.org/debian experimental main contrib non-free non-free-firmware | |
EOF' | |
sudo apt-get update && sudo apt-get install -y -t trixie build-essential ccache cdbs clang clang-format \ | |
cmake cmake-curses-gui debhelper docbook-xsl dpkg-dev gcc git git-core libasound2-dev libavcodec-dev libavutil-dev \ | |
libcairo2-dev libcjson-dev libcups2-dev libfaac-dev libfaad-dev libfuse3-dev libfuse-dev libgsm1-dev libgstreamer1.0-dev \ | |
libicu-dev libjson-c-dev libkrb5-dev libmp3lame-dev libopenh264-dev libopus-dev libpam0g-dev libpcsclite-dev libpkcs11-helper1-dev \ | |
libpkcs11-helper-dev libpulse-dev libsdl2-dev libsdl2-image-dev libsdl2-ttf-dev libsdl3-dev libsdl3-ttf-dev libsoxr-dev libswresample-dev \ | |
libswscale-dev libsystemd-dev liburiparser-dev libusb-1.0-0-dev libusb-dev libwayland-dev libwebkit2gtk-4.0-dev libx11-dev libxcursor-dev libssl-dev \ | |
libxdamage-dev libxext-dev libxfixes-dev libxi-dev libxinerama-dev libxkbfile-dev libxml2-dev libxrandr-dev libxrender-dev libxtst-dev libxv-dev ninja-build \ | |
ocl-icd-opencl-dev opencl-c-headers pkg-config uuid-dev xmlto xsltproc llvm-dev | |
git clone --depth 1 https://github.com/freerdp/freerdp.git --branch ${BRANCH} "$BUILD_DIR/freerdp" | |
cd "$BUILD_DIR" | |
cmake -GNinja \ | |
-B freerdp-build \ | |
-S freerdp \ | |
-DCMAKE_BUILD_TYPE=Release \ | |
-DCMAKE_SKIP_INSTALL_ALL_DEPENDENCY=ON \ | |
-DCMAKE_INSTALL_PREFIX=/usr/local \ | |
-DWITH_SERVER=ON \ | |
-DWITH_SAMPLE=ON \ | |
-DWITH_PLATFORM_SERVER=OFF \ | |
-DUSE_UNWIND=OFF \ | |
-DWITH_FFMPEG=ON \ | |
-DWITH_OPENH264=ON \ | |
-DWITH_WEBVIEW=OFF \ | |
-DWITH_SWSCALE=ON \ | |
-DWITH_CAIRO=ON | |
cmake --build freerdp-build | |
#sudo cmake --install freerdp-build |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment