@@ -22,12 +22,12 @@ jobs:
2222 build :
2323 name : ${{ matrix.friendlyName }} ${{ matrix.arch }}
2424 runs-on : ${{ matrix.os }}
25+ container : ${{ matrix.image }}
2526 strategy :
2627 fail-fast : false
2728 matrix :
2829 os : [macos-11, windows-2019, ubuntu-20.04]
2930 arch : [x86, x64]
30- go : [1.16.3]
3131 include :
3232 - os : macos-11
3333 friendlyName : macOS
@@ -36,26 +36,44 @@ jobs:
3636 friendlyName : macOS
3737 targetPlatform : macOS
3838 arch : arm64
39- go : 1.16.3
4039 - os : windows-2019
4140 friendlyName : Windows
4241 targetPlatform : win32
4342 - os : ubuntu-20.04
4443 friendlyName : Linux
4544 targetPlatform : ubuntu
45+ image : ubuntu:18.04
4646 - os : ubuntu-20.04
4747 friendlyName : Linux
4848 targetPlatform : ubuntu
4949 arch : arm64
50+ image : ubuntu:18.04
5051 - os : ubuntu-20.04
5152 friendlyName : Linux
5253 targetPlatform : ubuntu
5354 arch : arm
55+ image : ubuntu:18.04
5456 exclude :
5557 - os : macos-11
5658 arch : x86
5759 timeout-minutes : 20
5860 steps :
61+ - name : Install dependencies into dockerfile on Ubuntu
62+ if : matrix.targetPlatform == 'ubuntu'
63+ run : |
64+ # ubuntu dockerfile is very minimal (only 122 packages are installed)
65+ # add dependencies expected by scripts
66+ apt update
67+ apt install -y software-properties-common lsb-release sudo wget curl build-essential jq autoconf automake pkg-config ca-certificates
68+ # install new enough git to run actions/checkout
69+ sudo add-apt-repository ppa:git-core/ppa -y
70+ sudo apt update
71+ sudo apt install -y git
72+ # install new enough npm/nodejs to build dugite-native
73+ curl -fsSL https://deb.nodesource.com/setup_16.x | sudo -E bash -
74+ sudo apt-get install -y nodejs
75+ # avoid "fatal: detected dubious ownership in repository at '/__w/dugite-native/dugite-native'" error
76+ git config --global --add safe.directory '*'
5977 # We need to use Xcode 11.7 for maximum compatibility with older macOS (x64)
6078 - name : Switch to Xcode 11.7
6179 if : matrix.targetPlatform == 'macOS' && matrix.arch == 'x64'
6987 submodules : recursive
7088 # Needed for script/package.sh to work
7189 fetch-depth : 0
72- - name : Use go ${{ matrix.go }}
90+ - name : Install go
91+ if : matrix.targetPlatform == 'macOS'
7392 uses : actions/setup-go@v2
74- with :
75- go-version : ${{ matrix.go }}
7693 - name : Install dependencies
7794 run : npm install
7895 - name : Check formatting
@@ -83,13 +100,13 @@ jobs:
83100 if : matrix.targetPlatform == 'ubuntu' && matrix.arch == 'x64'
84101 run : |
85102 sudo apt-get update
86- sudo apt-get install libcurl4-gnutls-dev libexpat1-dev gettext
103+ sudo apt-get install -y libcurl4-gnutls-dev libexpat1-dev zlib1g-dev gettext libssl-dev
87104 - name : Install extra dependencies for building Git on Ubuntu (x86)
88105 if : matrix.targetPlatform == 'ubuntu' && matrix.arch == 'x86'
89106 run : |
90107 sudo dpkg --add-architecture i386
91108 sudo apt-get update
92- sudo apt-get install gcc-i686-linux-gnu binutils-i686-gnu libcurl4-gnutls-dev:i386 zlib1g-dev:i386 gettext
109+ sudo apt-get install -y gcc-i686-linux-gnu binutils-i686-gnu libcurl4-gnutls-dev:i386 zlib1g-dev:i386 libssl -dev:i386 gettext
93110 - name : Install extra dependencies for building Git on Ubuntu (arm64)
94111 if : matrix.targetPlatform == 'ubuntu' && matrix.arch == 'arm64'
95112 run : |
98115 echo "deb [arch=arm64,armhf] http://azure.ports.ubuntu.com/ $(lsb_release -s -c)-updates main universe multiverse restricted" | sudo tee -a /etc/apt/sources.list
99116 sudo dpkg --add-architecture arm64
100117 sudo apt-get update
101- sudo apt-get install gcc-aarch64-linux-gnu binutils-aarch64-linux-gnu libcurl4-gnutls-dev:arm64 zlib1g-dev:arm64 gettext
118+ sudo apt-get install -y gcc-aarch64-linux-gnu binutils-aarch64-linux-gnu libcurl4-gnutls-dev:arm64 zlib1g-dev:arm64 libssl -dev:arm64 gettext
102119 - name : Install extra dependencies for building Git on Ubuntu (arm)
103120 if : matrix.targetPlatform == 'ubuntu' && matrix.arch == 'arm'
104121 run : |
@@ -107,7 +124,7 @@ jobs:
107124 echo "deb [arch=arm64,armhf] http://azure.ports.ubuntu.com/ $(lsb_release -s -c)-updates main universe multiverse restricted" | sudo tee -a /etc/apt/sources.list
108125 sudo dpkg --add-architecture armhf
109126 sudo apt-get update
110- sudo apt-get install gcc-arm-linux-gnueabihf binutils-arm-linux-gnueabihf libcurl4-gnutls-dev:armhf zlib1g-dev:armhf gettext
127+ sudo apt-get install -y gcc-arm-linux-gnueabihf binutils-arm-linux-gnueabihf libcurl4-gnutls-dev:armhf zlib1g-dev:armhf libssl -dev:armhf gettext
111128 - name : Build (except macOS arm64)
112129 if : matrix.targetPlatform != 'macOS' || matrix.arch != 'arm64'
113130 shell : bash
0 commit comments