From fb1bd77bfbf68081666ef187e853732cae3f61d2 Mon Sep 17 00:00:00 2001 From: Martin Pulec Date: Wed, 2 Feb 2022 14:56:00 +0100 Subject: [PATCH] GitHub CI: download zfec/cineform directly from upstream + removed gpujpeg/cineform from monitored paths in workflow file --- .github/scripts/Linux/prepare.sh | 8 ++++---- .github/scripts/Windows/prepare_msys.sh | 7 +++---- .github/scripts/install-common-deps.sh | 8 +++++++- .github/scripts/macOS/prepare.sh | 8 ++++---- .github/workflows/ccpp.yml | 2 -- 5 files changed, 18 insertions(+), 15 deletions(-) diff --git a/.github/scripts/Linux/prepare.sh b/.github/scripts/Linux/prepare.sh index 8461d85b8..6c6c26cd4 100755 --- a/.github/scripts/Linux/prepare.sh +++ b/.github/scripts/Linux/prepare.sh @@ -52,8 +52,11 @@ sudo apt install libglib2.0-dev libcurl4-nss-dev sudo apt install libtool # gpujpeg sudo apt install i965-va-driver-shaders # instead of i965-va-driver +# Install cross-platform deps +$GITHUB_WORKSPACE/.github/scripts/install-common-deps.sh + ( ./bootstrap_gpujpeg.sh -d && mkdir ext-deps/gpujpeg/build && cd ext-deps/gpujpeg/build && CUDA_FLAGS=-D_FORCE_INLINES CXXFLAGS=-std=c++11 CC=$CUDA_HOST_COMPILER ../autogen.sh && make && sudo make install && sudo ldconfig || exit 1 ) -( sudo apt install uuid-dev && git submodule update --init cineform-sdk && cd cineform-sdk/ && cmake -DBUILD_TOOLS=OFF . && make CFHDCodecStatic || exit 1 ) +( sudo apt install uuid-dev && cd cineform-sdk/ && cmake -DBUILD_TOOLS=OFF . && make CFHDCodecStatic || exit 1 ) sudo apt install qtbase5-dev sudo chmod 777 /usr/local @@ -101,6 +104,3 @@ cd .. install_ndi -# Install cross-platform deps -$GITHUB_WORKSPACE/.github/scripts/install-common-deps.sh - diff --git a/.github/scripts/Windows/prepare_msys.sh b/.github/scripts/Windows/prepare_msys.sh index 4fd6c7287..0f28da5c2 100644 --- a/.github/scripts/Windows/prepare_msys.sh +++ b/.github/scripts/Windows/prepare_msys.sh @@ -77,7 +77,6 @@ fi build_cineform() { ( - git submodule update --init cineform-sdk cd cineform-sdk cmake -DBUILD_STATIC=false -DBUILD_TOOLS=false -A x64 . # assume "-G 'Visual Studio 16 2019'" cmake --build . --config Release --parallel @@ -85,6 +84,9 @@ build_cineform() { ) } +# Install cross-platform deps +$GITHUB_WORKSPACE/.github/scripts/install-common-deps.sh + $GITHUB_WORKSPACE/.github/scripts/Windows/install_natpmp.sh $GITHUB_WORKSPACE/.github/scripts/Windows/install_spout.sh @@ -96,6 +98,3 @@ wget --no-verbose https://www.gyan.dev/ffmpeg/builds/ffmpeg-release-full-shared. build_cineform -# Install cross-platform deps -$GITHUB_WORKSPACE/.github/scripts/install-common-deps.sh - diff --git a/.github/scripts/install-common-deps.sh b/.github/scripts/install-common-deps.sh index c637179e5..d651b81c7 100755 --- a/.github/scripts/install-common-deps.sh +++ b/.github/scripts/install-common-deps.sh @@ -10,6 +10,11 @@ case "$(uname -s)" in ;; esac +# only download here, compilation is handled per-platform +download_cineform() { + ( cd $GITHUB_WORKSPACE && git clone --depth 1 https://github.com/gopro/cineform-sdk || exit 1 ) +} + install_ews() { ${SUDO}curl -LS https://raw.githubusercontent.com/MartinPulec/EmbeddableWebServer/master/EmbeddableWebServer.h -o /usr/local/include/EmbeddableWebServer.h } @@ -38,9 +43,10 @@ install_pcp() { } install_zfec() { - ( cd $GITHUB_WORKSPACE && git submodule update --init ext-deps/zfec || exit 1 ) + ( cd $GITHUB_WORKSPACE && git clone --depth 1 https://github.com/tahoe-lafs/zfec ext-deps/zfec || exit 1 ) } +download_cineform install_ews install_juice install_pcp diff --git a/.github/scripts/macOS/prepare.sh b/.github/scripts/macOS/prepare.sh index 2532865e4..aaaccae98 100755 --- a/.github/scripts/macOS/prepare.sh +++ b/.github/scripts/macOS/prepare.sh @@ -18,7 +18,7 @@ brew install speexdsp brew install ffmpeg portaudio sdl2 sdl2_mixer sdl2_ttf brew install imagemagick jack libnatpmp opencv openssl brew install ossp-uuid # for cineform -( git submodule update --init cineform-sdk && cd cineform-sdk/ && cmake -DBUILD_TOOLS=OFF . && make -j $(sysctl -n hw.ncpu) CFHDCodecStatic || exit 1 ) +( cd cineform-sdk && cmake -DBUILD_TOOLS=OFF . && make -j $(sysctl -n hw.ncpu) CFHDCodecStatic || exit 1 ) brew install qt@5 sudo ln -s /usr/local/opt/qt@5 /usr/local/opt/qt @@ -81,6 +81,9 @@ install_ndi() { cd $TEMP_INST } +# Install cross-platform deps +$GITHUB_WORKSPACE/.github/scripts/install-common-deps.sh + # Install live555 git clone https://github.com/xanview/live555/ cd live555 @@ -97,9 +100,6 @@ sudo cp -R 'Syphon SDK 5/Syphon.framework' /Library/Frameworks install_ndi install_ximea -# Install cross-platform deps -$GITHUB_WORKSPACE/.github/scripts/install-common-deps.sh - # Remove installation files cd rm -rf $TEMP_INST diff --git a/.github/workflows/ccpp.yml b/.github/workflows/ccpp.yml index ea0b85742..47fb0ff7d 100644 --- a/.github/workflows/ccpp.yml +++ b/.github/workflows/ccpp.yml @@ -21,10 +21,8 @@ on: - '**.m' - '**.mm' - 'autogen.sh' - - 'cineform-sdk' - 'configure.ac' - 'data/scripts/**' - - 'gpujpeg' - 'Makefile.in' jobs: