GHA: replace make with ninja in Cygwin, MSYS2 and mingw-w64 cmake jobs
Speed-ups: - cygwin build: 47s -> 29s - cygwin build tests: 3m12 -> 2m32 - MSYS2 native build: 29s -> 16s - MSYS2 native build tests: 2m24 -> 1m52 - MSYS2/mingw-w64: already had ninja installed and used implicitly. - linux-mingw-w64-cross: 31s -> 25s before: cygwin: https://github.com/curl/curl/actions/runs/10866939355/job/30155134299 windows: https://github.com/curl/curl/actions/runs/10866939361 after: cygwin: https://github.com/curl/curl/actions/runs/10867861215/job/30157121784 windows: https://github.com/curl/curl/actions/runs/10867861208?pr=14914 Closes #14914
This commit is contained in:
parent
2e76e1f7fc
commit
5f93cad086
4
.github/workflows/cygwin.yml
vendored
4
.github/workflows/cygwin.yml
vendored
@ -61,7 +61,7 @@ jobs:
|
||||
with:
|
||||
platform: ${{ matrix.platform }}
|
||||
# https://cygwin.com/cgi-bin2/package-grep.cgi
|
||||
packages: autoconf libtool ${{ matrix.build }} gcc-core gcc-g++ binutils make libssl-devel zlib-devel libbrotli-devel libnghttp2-devel libpsl-devel libssh2-devel
|
||||
packages: autoconf libtool ${{ matrix.build }} gcc-core gcc-g++ binutils make ninja libssl-devel zlib-devel libbrotli-devel libnghttp2-devel libpsl-devel libssh2-devel
|
||||
site: https://mirrors.kernel.org/sourceware/cygwin/
|
||||
|
||||
- name: 'autotools autoreconf'
|
||||
@ -131,7 +131,7 @@ jobs:
|
||||
timeout-minutes: 5
|
||||
run: |
|
||||
PATH="/usr/bin:$(cygpath "${SYSTEMROOT}")/System32"
|
||||
cmake -B bld ${options} \
|
||||
cmake -B bld -G Ninja ${options} \
|
||||
-DCMAKE_UNITY_BUILD=ON \
|
||||
-DCURL_WERROR=ON \
|
||||
-DBUILD_EXAMPLES=ON \
|
||||
|
||||
10
.github/workflows/windows.yml
vendored
10
.github/workflows/windows.yml
vendored
@ -69,14 +69,14 @@ jobs:
|
||||
with:
|
||||
msystem: ${{ matrix.sys }}
|
||||
# https://packages.msys2.org/search
|
||||
install: gcc ${{ matrix.build }} make openssl-devel zlib-devel brotli-devel libnghttp2-devel libpsl-devel libssh2-devel
|
||||
install: gcc ${{ matrix.build }} ${{ matrix.build == 'autotools' && 'make' || 'ninja' }} openssl-devel zlib-devel brotli-devel libnghttp2-devel libpsl-devel libssh2-devel
|
||||
- uses: msys2/setup-msys2@ddf331adaebd714795f1042345e6ca57bd66cea8 # v2
|
||||
if: ${{ matrix.sys != 'msys' }}
|
||||
with:
|
||||
msystem: ${{ matrix.sys }}
|
||||
install: >-
|
||||
mingw-w64-${{ matrix.env }}-cc
|
||||
mingw-w64-${{ matrix.env }}-${{ matrix.build }} make
|
||||
mingw-w64-${{ matrix.env }}-${{ matrix.build }} ${{ matrix.build == 'autotools' && 'make' || '' }}
|
||||
mingw-w64-${{ matrix.env }}-openssl
|
||||
mingw-w64-${{ matrix.env }}-libssh2
|
||||
mingw-w64-${{ matrix.env }}-libpsl
|
||||
@ -171,7 +171,7 @@ jobs:
|
||||
fi
|
||||
[ '${{ matrix.type }}' = 'Debug' ] && options+=' -DCMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG='
|
||||
[ '${{ matrix.type }}' = 'Release' ] && options+=' -DCMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE='
|
||||
cmake -B bld ${options} \
|
||||
cmake -B bld -G Ninja ${options} \
|
||||
"-DCMAKE_C_FLAGS=${cflags}" \
|
||||
"-DCMAKE_RC_COMPILE_OBJECT=${rcopts}" \
|
||||
'-DCMAKE_BUILD_TYPE=${{ matrix.type }}' \
|
||||
@ -358,7 +358,7 @@ jobs:
|
||||
TRIPLET: 'x86_64-w64-mingw32'
|
||||
steps:
|
||||
- name: 'install packages'
|
||||
run: sudo apt-get --quiet 2 --option Dpkg::Use-Pty=0 install mingw-w64
|
||||
run: sudo apt-get --quiet 2 --option Dpkg::Use-Pty=0 install mingw-w64 ${{ matrix.build == 'cmake' && 'ninja-build' || '' }}
|
||||
|
||||
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
|
||||
|
||||
@ -388,7 +388,7 @@ jobs:
|
||||
- name: 'cmake configure'
|
||||
if: ${{ matrix.build == 'cmake' }}
|
||||
run: |
|
||||
cmake -B bld \
|
||||
cmake -B bld -G Ninja \
|
||||
-DCMAKE_SYSTEM_NAME=Windows \
|
||||
-DCMAKE_C_COMPILER_TARGET=${TRIPLET} \
|
||||
-DCMAKE_C_COMPILER=${TRIPLET}-gcc \
|
||||
|
||||
Loading…
Reference in New Issue
Block a user