GHA/mac: simplify detecting SDK version bound to GCC
Previous method extracted this information from the "hack layer" headers' copyright comments. It turns out that the same information can be obtained by querying the default SDK root via a GCC option. According to this test run, they do match: https://github.com/curl/curl/actions/runs/11264283159/job/31323963221?pr=15193 Closes #15241
This commit is contained in:
parent
d3725f2bc4
commit
5b2d6448bb
9
.github/workflows/macos.yml
vendored
9
.github/workflows/macos.yml
vendored
@ -159,8 +159,7 @@ jobs:
|
||||
- name: 'toolchain versions'
|
||||
run: |
|
||||
[[ '${{ matrix.compiler }}' = 'llvm'* ]] && CC="$(brew --prefix ${{ matrix.compiler }})/bin/clang"
|
||||
[[ '${{ matrix.compiler }}' = 'gcc'* ]] && \
|
||||
grep -h -r -E -o '.+[0-9.]+\.sdk/' "$(dirname "$("${CC}" -print-libgcc-file-name)")/include-fixed" | sed -E 's/^\t+//g' | tr -d '"' | sort -u || true
|
||||
[[ '${{ matrix.compiler }}' = 'gcc'* ]] && "${CC}" --print-sysroot
|
||||
which "${CC}"; "${CC}" --version || true
|
||||
xcodebuild -version || true
|
||||
xcrun --sdk macosx --show-sdk-path 2>/dev/null || true
|
||||
@ -326,8 +325,7 @@ jobs:
|
||||
- name: 'toolchain versions'
|
||||
run: |
|
||||
[[ '${{ matrix.compiler }}' = 'llvm'* ]] && CC="$(brew --prefix ${{ matrix.compiler }})/bin/clang"
|
||||
[[ '${{ matrix.compiler }}' = 'gcc'* ]] && \
|
||||
grep -h -r -E -o '.+[0-9.]+\.sdk/' "$(dirname "$("${CC}" -print-libgcc-file-name)")/include-fixed" | sed -E 's/^\t+//g' | tr -d '"' | sort -u || true
|
||||
[[ '${{ matrix.compiler }}' = 'gcc'* ]] && "${CC}" --print-sysroot
|
||||
which "${CC}"; "${CC}" --version || true
|
||||
xcodebuild -version || true
|
||||
xcrun --sdk macosx --show-sdk-path 2>/dev/null || true
|
||||
@ -488,8 +486,7 @@ jobs:
|
||||
- name: 'toolchain versions'
|
||||
run: |
|
||||
[[ '${{ matrix.compiler }}' = 'llvm'* ]] && CC="$(brew --prefix ${{ matrix.compiler }})/bin/clang"
|
||||
[[ '${{ matrix.compiler }}' = 'gcc'* ]] && \
|
||||
grep -h -r -E -o '.+[0-9.]+\.sdk/' "$(dirname "$("${CC}" -print-libgcc-file-name)")/include-fixed" | sed -E 's/^\t+//g' | tr -d '"' | sort -u || true
|
||||
[[ '${{ matrix.compiler }}' = 'gcc'* ]] && "${CC}" --print-sysroot
|
||||
which "${CC}"; "${CC}" --version || true
|
||||
xcodebuild -version || true
|
||||
xcrun --sdk macosx --show-sdk-path 2>/dev/null || true
|
||||
|
||||
Loading…
Reference in New Issue
Block a user