treewide: refactor to use PKG_BUILD_FLAGS:=gc-sections
[feed/packages.git] / libs / libdcwsocket / Makefile
index 28176a8ecf35a489a09d7172f97f5ad4adec0f3e..dc3bf3f1eb0115ad0d6e6ce0624cb814c1e07104 100644 (file)
@@ -22,6 +22,7 @@ PKG_LICENSE_FILES:=COPYING
 
 PKG_INSTALL:=1
 PKG_BUILD_PARALLEL:=1
+PKG_BUILD_FLAGS:=gc-sections
 
 include $(INCLUDE_DIR)/package.mk
 
@@ -37,8 +38,8 @@ define Package/libdcwsocket/description
   User-land C library for sending and receiving DCW "EtherType"d messages
 endef
 
-TARGET_CFLAGS += -std=c89 -ffunction-sections -fdata-sections -flto
-TARGET_LDFLAGS += -Wl,--gc-sections,--as-needed
+TARGET_CFLAGS += -std=c89 -flto
+TARGET_LDFLAGS += -Wl,--as-needed
 
 define Build/InstallDev
        $(INSTALL_DIR) $(1)/usr/include