#5400 closed defect (fixed)
GHA ci is failing on PG15-clang-geos311-gdal35 C compiler works... no
Reported by: | robe | Owned by: | robe |
---|---|---|---|
Priority: | blocker | Milestone: | Website Management, Bots |
Component: | management | Version: | 3.3.x |
Keywords: | Cc: |
Description
https://github.com/postgis/postgis/actions/runs/5242404014/jobs/9465763896
====================================== Now you are ready to run './configure' ====================================== checking for a BSD-compatible install... /usr/bin/install -c checking build system type... x86_64-pc-linux-gnu checking host system type... x86_64-pc-linux-gnu checking how to print strings... printf checking for gcc... clang checking whether the C compiler works... no configure: error: in `/src/postgis': configure: error: C compiler cannot create executables See `config.log' for more details Error: Process completed with exit code 77.
This started failing last week, so guessing it's most likely something wrong with the ci docker build than anything wrong with our code
Change History (5)
comment:1 by , 18 months ago
Component: | postgis → management |
---|
comment:2 by , 18 months ago
comment:3 by , 18 months ago
Confirmed the new one failing is bookworm
PRETTY_NAME="Debian GNU/Linux 12 (bookworm)" NAME="Debian GNU/Linux" VERSION_ID="12" VERSION="12 (bookworm)" VERSION_CODENAME=bookworm ID=debian
The old one working is bullseye
PRETTY_NAME="Debian GNU/Linux 11 (bullseye)" NAME="Debian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=debian
However it's not just the LD_LOAD at fault. There are some of these flags that the new clang doesn't like:
# Enable undefined behaviour sanitizer using traps CFLAGS_USAN="-g3 -O0 -mtune=generic -fno-omit-frame-pointer -fsanitize=undefined,implicit-conversion -fsanitize-undefined-trap-on-error -fno-sanitize-recover=implicit-conversion" LDFLAGS_STD="-Wl,-Bsymbolic-functions -Wl,-z,relro" # Sanitizer options to continue avoid stopping the runs on leaks (expected on postgres binaries) export ASAN_OPTIONS=halt_on_error=false,leak_check_at_exit=false,exitcode=0 export MSAN_OPTIONS=halt_on_error=false,leak_check_at_exit=false,exitcode=0 ./configure CC=clang CFLAGS="${CFLAGS_USAN}" LDFLAGS="${LDFLAGS_STD}"
Note:
See TracTickets
for help on using tickets.
Okay looked at this closer, putting in an echo on clang —version
It looks like our scripts in github/run_usan_clang.sh are hard-coded to work with clang 11. I suspect this broken when debian-slim (I'm guessing it's based on bookworm but haven't looked) started shipping with clang 14.
I discovered this by having the script output clang —version.
https://github.com/robe2/postgis/actions/runs/5295165329/jobs/9585211344
The PG13 clang that still works was built a while ago and shows:
While the new one pg15-clang-geos311-gdal35-proj90
shows:
and errors out in the usan_clang script:
I'm going to confirm that by hardcoding 14 and if that works try to make it conditional based on clang version