pcre: pass -fPIC under host as well
authorRosen Penev <rosenp@gmail.com>
Sun, 27 Mar 2022 20:27:15 +0000 (13:27 -0700)
committerHauke Mehrtens <hauke@hauke-m.de>
Sat, 16 Apr 2022 12:02:11 +0000 (14:02 +0200)
static libraries need them as they are not PIC by default.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
package/libs/pcre/Makefile

index 43267562eaf2d1836f4d7cf480c56ebd45501e8b..894f39b7d15244d774c94a8a7fb5e47c85eda621 100644 (file)
@@ -67,9 +67,8 @@ HOST_CONFIGURE_ARGS += \
        --enable-unicode-properties \
        --enable-pcre16 \
        --with-match-limit-recursion=16000 \
-       --enable-cpp
-
-TARGET_CFLAGS += $(FPIC)
+       --enable-cpp \
+       --with-pic
 
 CONFIGURE_ARGS += \
        --enable-utf8 \
@@ -78,7 +77,8 @@ CONFIGURE_ARGS += \
        --enable-pcre32 \
        $(if $(CONFIG_PCRE_JIT_ENABLED),--enable-jit,--disable-jit) \
        --with-match-limit-recursion=16000 \
-       --$(if $(CONFIG_PACKAGE_libpcrecpp),en,dis)able-cpp
+       --$(if $(CONFIG_PACKAGE_libpcrecpp),en,dis)able-cpp \
+       --with-pic
 
 MAKE_FLAGS += \
        CFLAGS="$(TARGET_CFLAGS)"