diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 0eb263b9..b3a22a15 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -62,12 +62,22 @@ jobs: if: ${{ matrix.os == 'ubuntu-20.04' && matrix.target == 'armv7-unknown-linux-gnueabihf' }} run: | cat /etc/apt/sources.list{,.d/*.list} - sudo sed -i'' -E 's/^deb http:\/\/(azure.archive|security).ubuntu.com/deb [arch=amd64,i386] http:\/\/\1.ubuntu.com/' /etc/apt/sources.list - sudo sed -i'' -E 's/^deb http:\/\/(azure.archive|security).ubuntu.com/deb [arch=amd64,i386] http:\/\/\1.ubuntu.com/' /etc/apt/sources.list.d/*.list + # Patch azure sources to amd64/armhf + sudo sed -i'' -E 's/^(deb|deb-src) http:\/\/(azure.archive|security).ubuntu.com/\1 [arch=amd64,i386] http:\/\/\2.ubuntu.com/' /etc/apt/sources.list + # Add architecture / enable multiarch sudo dpkg --add-architecture armhf - cat /etc/apt/sources.list{,.d/*.list} + + # Manually add an apt source with armhf support + echo "deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports/ focal main restricted universe"| sudo tee /etc/apt/sources.list.d/armhf.list + echo "deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports/ focal-updates main restricted universe"| sudo tee /etc/apt/sources.list.d/armhf.list + echo "deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports/ focal-backports main restricted universe"| sudo tee /etc/apt/sources.list.d/armhf.list + echo "deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports/ focal-security main restricted universe"| sudo tee /etc/apt/sources.list.d/armhf.list + + # Run apt update sudo apt-get update - sudo apt-get install -y libssl-dev:armhf libssl1.1:armgf zlib1g-dev:armhf zlib1g:armhf libc-dev:armhf + # Install deps + sudo apt-get install -y libssl-dev:armhf libssl1.1:armhf zlib1g-dev:armhf zlib1g:armhf libc-dev:armhf + # Allow cross compilation echo "PKG_CONFIG_ALLOW_CROSS=1" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf-8 -Append - name: Install openssl (vcpkg)