ci/run.sh: Avoid deprecated Makefiles (#15832)

* ci/run.sh: Avoid deprecated Makefiles

* ci/run.sh: Streamline OS_NAME from `darwin` to `osx` on macOS

As DMD uses `osx` as OS in most other places, including the
`generated/osx/release/64` output dir, which is currently wrong
in run.sh's `build_path` and leads to CI failures on macOS.

* GHA: Disable `-debug` for DMD unittests with old host compilers

* GHA: Work around linker errors with -g on macOS 13

See https://issues.dlang.org/show_bug.cgi?id=23517.

compiler/src/posix.mak sets it to 10.9, compiler/test/Makefile to 11.
This commit is contained in:
Martin Kinkelin 2023-11-22 10:41:16 +01:00 committed by GitHub
parent f6802dd63f
commit ed22f5c28f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 23 additions and 15 deletions

View file

@ -27,6 +27,7 @@ jobs:
- job_name: Ubuntu 22.04 x64, DMD (bootstrap)
os: ubuntu-22.04
host_dmd: dmd-2.079.0
disable_debug_for_dmd_unittests: true # no `-debug` - host frontend too old
- job_name: Ubuntu 22.04 x86, DMD (latest)
os: ubuntu-22.04
model: 32
@ -46,6 +47,7 @@ jobs:
- job_name: Ubuntu 22.04 x64, GDC
os: ubuntu-22.04
host_dmd: gdmd-9
disable_debug_for_dmd_unittests: true # no `-debug` - host frontend too old
# macOS
- job_name: macOS 13 x64, DMD (latest)
os: macos-13
@ -64,13 +66,15 @@ jobs:
timeout-minutes: 40
env:
# for ci/run.sh:
OS_NAME: ${{ startsWith(matrix.os, 'ubuntu') && 'linux' || (startsWith(matrix.os, 'macos') && 'darwin' || '') }}
OS_NAME: ${{ startsWith(matrix.os, 'ubuntu') && 'linux' || (startsWith(matrix.os, 'macos') && 'osx' || '') }}
MODEL: ${{ matrix.model || '64' }}
HOST_DMD: ${{ matrix.host_dmd }}
N: ${{ startsWith(matrix.os, 'macos') && '3' || '2' }}
FULL_BUILD: true
# for coverage:
DMD_TEST_COVERAGE: ${{ matrix.coverage && '1' || '0' }}
# work around https://issues.dlang.org/show_bug.cgi?id=23517
MACOSX_DEPLOYMENT_TARGET: '11'
steps:
- uses: actions/checkout@v4
with:
@ -99,10 +103,10 @@ jobs:
ci/run.sh setup_repos "$REPO_BRANCH"
- name: Build
run: ci/run.sh build
run: ${{ matrix.disable_debug_for_dmd_unittests && 'ENABLE_DEBUG=0' || '' }} ci/run.sh build
- name: Rebuild dmd (with enabled coverage)
if: matrix.coverage
run: ENABLE_RELEASE=0 ENABLE_DEBUG=1 ENABLE_COVERAGE=1 ${{ runner.os == 'macOS' && 'OS_NAME=osx' || '' }} ci/run.sh rebuild
run: ENABLE_RELEASE=0 ENABLE_DEBUG=1 ENABLE_COVERAGE=1 ci/run.sh rebuild
- name: Test dmd
run: ci/run.sh test_dmd
- name: Test druntime