diff --git a/.github/workflows/cpp-cross-linux-rpi.yml b/.github/workflows/cpp-cross-linux-rpi.yml new file mode 100644 index 00000000..fa18c6e6 --- /dev/null +++ b/.github/workflows/cpp-cross-linux-rpi.yml @@ -0,0 +1,60 @@ +name: C/C++ CI linux cross armv6 + +on: [push] + +jobs: + build: + strategy: + matrix: + buildtype: [Debug, Release] + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + + - name: pkg + run: | + sudo apt-get update + sudo apt-get install -y --no-install-recommends g++ autoconf automake libtool xz-utils libasound2-dev libpulse-dev libgtk-3-dev cmake p7zip-full + wget -qO- ${CROSSCOMPILER} | tar xz + echo "$(pwd)/cross-pi-gcc-*/bin" >> $GITHUB_PATH + env: + CROSSCOMPILER: https://sourceforge.net/projects/raspberry-pi-cross-compilers/files/Raspberry%20Pi%20GCC%20Cross-Compiler%20Toolchains/Buster/GCC%2010.2.0/Raspberry%20Pi%201%2C%20Zero/cross-gcc-10.2.0-pi_0-1.tar.gz + + - name: depot_tools + run: | + git clone --depth 1 https://chromium.googlesource.com/chromium/tools/depot_tools.git + echo "$(pwd)/depot_tools" >> $GITHUB_PATH + + - name: fetch webrtc + run: | + mkdir webrtc + pushd webrtc + fetch --no-history --nohooks webrtc + ./src/build/linux/sysroot_scripts/install-sysroot.py --arch=arm + sed -i -e "s|'src/resources'],|'src/resources'],'condition':'rtc_include_tests==true',|" src/DEPS + gclient sync + popd + + - name: build + run: | + cmake -DWEBRTCROOT=$(pwd)/webrtc -DCMAKE_BUILD_TYPE=${{ matrix.buildtype }} -DCMAKE_SYSTEM_PROCESSOR=armv6l -DCMAKE_LIBRARY_ARCHITECTURE=arm-linux-gnueabihf -DCMAKE_SYSTEM_NAME=Linux -DCMAKE_C_COMPILER=arm-linux-gnueabihf-gcc -DCMAKE_CXX_COMPILER=arm-linux-gnueabihf-g++ -DCMAKE_FIND_ROOT_PATH_MODE_PROGRAM=NEVER -DCMAKE_FIND_ROOT_PATH_MODE_INCLUDE=ONLY -DCMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY -DCMAKE_FIND_ROOT_PATH_MODE_PACKAGE=ONLY -DWEBRTCDESKTOPCAPTURE=OFF . + make + + - name: cpack + run: | + rm -f *.tar.gz + cpack + echo "artifactPath=$(ls *.tar.gz)" >> $GITHUB_ENV + + - uses: actions/upload-artifact@v3 + with: + name: ${{ env.artifactPath }} + path: ${{ env.artifactPath }} + + - name: Release + uses: softprops/action-gh-release@v2 + if: startsWith(github.ref, 'refs/tags/') + with: + files: ${{ env.artifactPath }} \ No newline at end of file diff --git a/Dockerfile.windows b/Dockerfile.windows index 91eb39a1..1a1caa90 100644 --- a/Dockerfile.windows +++ b/Dockerfile.windows @@ -8,12 +8,12 @@ SHELL ["cmd", "/S", "/C"] ENV DEPOT_TOOLS_WIN_TOOLCHAIN=0 \ CLANG_VERSION=ToT \ PYTHONIOENCODING=UTF-8 \ - MSVC_PATH="C:\Program Files (x86)\Microsoft Visual Studio\2022\Community" + MSVC_PATH="C:\Program Files\Microsoft Visual Studio\2022\Community" # Install Chocolatey & packages RUN powershell.exe -NoProfile -InputFormat None -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SETX PATH "%PATH%;%ALLUSERSPROFILE%\chocolatey\bin" -RUN choco install --no-progress -y 7zip git curl sed windows-sdk-11-version-22h2-all +RUN choco install --no-progress -y 7zip git curl sed RUN choco install --no-progress -y cmake --installargs 'ADD_CMAKE_TO_PATH=System' RUN choco install --ignoredetectedreboot --no-progress -y visualstudio2022buildtools --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --add Microsoft.VisualStudio.Workload.NativeDesktop --add Microsoft.VisualStudio.Component.VC.ATLMFC --includeRecommended --nocache --installPath %MSVC_PATH%" || IF "%ERRORLEVEL%"=="3010" EXIT 0