libredblack: Pass CFLAGS
authorRosen Penev <rosenp@gmail.com>
Tue, 27 Aug 2019 21:46:21 +0000 (14:46 -0700)
committerRosen Penev <rosenp@gmail.com>
Wed, 28 Aug 2019 21:45:24 +0000 (14:45 -0700)
CFLAGS were not being passed. This was breaking builds with ASLR.

Pass proper PIC command to gcc with $(fPIC).

Don't install static libraries. Keep those for InstallDev only.

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

index dcc527eb1c637b35b8bde2a1152df8766c19302e..40d32df4ddd3b471d7a437d7853a51484ae9b7bc 100644 (file)
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=libredblack
 PKG_VERSION:=1.3
-PKG_RELEASE:=1
+PKG_RELEASE:=2
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=@SF/libredblack
@@ -19,8 +19,9 @@ PKG_MAINTAINER:=Mislav Novakovic <mislav.novakovic@sartura.hr>
 PKG_LICENSE:=GPL-2.0-or-later
 PKG_LICENSE_FILES:=COPYING
 
-PKG_BUILD_PARALLEL:=1
+PKG_FIXUP:=autoreconf
 PKG_INSTALL:=1
+PKG_BUILD_PARALLEL:=1
 
 include $(INCLUDE_DIR)/package.mk
 include $(INCLUDE_DIR)/host-build.mk
@@ -37,6 +38,7 @@ define Package/libredblack/description
 endef
 
 CONFIGURE_ARGS += --without-rbgen
+CONFIGURE_VARS += lt_cv_prog_cc_pic=$(FPIC)
 
 define Build/InstallDev
        $(INSTALL_DIR) $(1)/usr/lib
@@ -48,7 +50,7 @@ endef
 
 define Package/libredblack/install
        $(INSTALL_DIR) $(1)/usr/lib
-       $(CP) $(PKG_INSTALL_DIR)/usr/lib/libredblack.{so*,a,la} $(1)/usr/lib/
+       $(CP) $(PKG_INSTALL_DIR)/usr/lib/libredblack.so* $(1)/usr/lib/
 
        $(INSTALL_DIR) $(1)/usr/include
        $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/include/redblack.h $(1)/usr/include