tools/elfutils: add -fPIC to fix linker errors (#13841)
authorFelix Fietkau <nbd@nbd.name>
Wed, 1 Nov 2023 16:44:43 +0000 (17:44 +0100)
committerFelix Fietkau <nbd@nbd.name>
Wed, 1 Nov 2023 16:45:25 +0000 (17:45 +0100)
Resolves issues with building PIE binaries that link against libdw or libelf

Signed-off-by: Felix Fietkau <nbd@nbd.name>
tools/elfutils/Makefile

index 2605bc61cb7e61834108a38817c42b559af747c7..92eabc14ddfc0414ace0c388f05add6211daf1fe 100644 (file)
@@ -23,7 +23,7 @@ ifeq ($(HOST_OS),Darwin)
   HOST_CFLAGS += -I/opt/homebrew/include
 endif
 
-HOST_CFLAGS += -Wno-error
+HOST_CFLAGS += -Wno-error -fPIC
 
 HOST_CONFIGURE_ARGS += \
        --without-libintl-prefix \