meta: Build an empty libresolv to satisfy some programs

Signed-off-by: Dennis Bonke <admin@dennisbonke.com>
This commit is contained in:
Dennis Bonke 2021-01-14 20:48:51 +01:00
parent 3b26033129
commit 9170e68e19
No known key found for this signature in database
GPG key ID: F456F05FBF825330
2 changed files with 8 additions and 0 deletions

6
libresolv/src/dummy.cpp Normal file
View file

@ -0,0 +1,6 @@
// We build an empty libresolv because some programs always links with -lresolv
// The actual functions reside inside libc
extern "C" void __mlibc_libresolv_dummy(void) { }

View file

@ -265,6 +265,7 @@ if not headers_only
shared_library('util', 'libutil/src/dummy.cpp', install: true) shared_library('util', 'libutil/src/dummy.cpp', install: true)
shared_library('m', 'libm/src/dummy.cpp', install: true) shared_library('m', 'libm/src/dummy.cpp', install: true)
shared_library('crypt', 'libcrypt/src/dummy.cpp', install: true) shared_library('crypt', 'libcrypt/src/dummy.cpp', install: true)
shared_library('resolv', 'libresolv/src/dummy.cpp', install: true)
else else
ldso_lib = static_library('ld', rtdl_sources, ldso_lib = static_library('ld', rtdl_sources,
name_prefix: '', name_prefix: '',
@ -293,6 +294,7 @@ if not headers_only
static_library('util', 'libutil/src/dummy.cpp', install: true) static_library('util', 'libutil/src/dummy.cpp', install: true)
static_library('m', 'libm/src/dummy.cpp', install: true) static_library('m', 'libm/src/dummy.cpp', install: true)
static_library('crypt', 'libcrypt/src/dummy.cpp', install: true) static_library('crypt', 'libcrypt/src/dummy.cpp', install: true)
static_library('resolv', 'libresolv/src/dummy.cpp', install: true)
endif endif
endif endif