miniupnpd: fix build error when ASLR enabled
authorKevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
Fri, 8 Jun 2018 10:46:55 +0000 (11:46 +0100)
committerKevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
Fri, 8 Jun 2018 14:25:09 +0000 (15:25 +0100)
Add -fPIC to TARGET_LD_FLAGS

ce9TpAS.ltrans0.ltrans.o: relocation R_MIPS16_26 against `syslog' can not
be used when making a shared object; recompile with -fPIC
cce9TpAS.ltrans0.ltrans.o: error adding symbols: Bad value

Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
net/miniupnpd/Makefile

index 02f95541c1fc57cc26c7dae9f7c7402e503872f3..faba7a2d918c2139c39da7fe435720453b51e802 100644 (file)
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=miniupnpd
 PKG_VERSION:=2.1
-PKG_RELEASE:=1
+PKG_RELEASE:=2
 
 PKG_SOURCE_URL:=http://miniupnp.free.fr/files
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
@@ -40,7 +40,7 @@ define Build/Prepare
 endef
 
 TARGET_CFLAGS += -flto -ffunction-sections -fdata-sections
-TARGET_LDFLAGS += -flto -Wl,--gc-sections
+TARGET_LDFLAGS += $(FPIC) -flto -Wl,--gc-sections
 MAKE_FLAGS += \
        TARGET_OPENWRT=1 TEST=0 LIBS="" \
        CC="$(TARGET_CC) -DIPTABLES_143 -lip4tc -luuid \