mirror of
https://github.com/rui314/mold.git
synced 2024-09-11 13:06:59 +03:00
Fix tests for musl libc-based systems
Fixes https://github.com/rui314/mold/issues/1221
This commit is contained in:
parent
b5f2a7b1ce
commit
11c9376a50
@ -69,13 +69,14 @@ test_cflags() {
|
||||
echo 'int main() {}' | $CC "$@" -o /dev/null -xc - >& /dev/null
|
||||
}
|
||||
|
||||
supports_ifunc() {
|
||||
echo 'void x() __attribute__((ifunc("y"))); void *y() { return 0; }' | \
|
||||
$CC -c -o /dev/null -xc - >& /dev/null
|
||||
is_musl() {
|
||||
ldd --version 2>&1 | grep -q musl
|
||||
}
|
||||
|
||||
is_musl() {
|
||||
ldd --help 2>&1 | grep -q musl
|
||||
supports_ifunc() {
|
||||
! is_musl && \
|
||||
echo 'void x() __attribute__((ifunc("y"))); void *y() { return 0; }' | \
|
||||
$CC -c -o /dev/null -xc - >& /dev/null
|
||||
}
|
||||
|
||||
supports_tlsdesc() {
|
||||
|
Loading…
Reference in New Issue
Block a user