librem: Use default Build/Compile routine
Change from custom make call to using the default Build/Compile routine. This applies the standard memory corruption mitigation methods, e.g. FORTIFY_SOURCE and RELRO, to the package if they are enabled (default). Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>
This commit is contained in:
parent
7e1106ff83
commit
394e4bc773
1 changed files with 12 additions and 19 deletions
|
@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk
|
|||
|
||||
PKG_NAME:=rem
|
||||
PKG_VERSION:=0.5.2
|
||||
PKG_RELEASE:=1
|
||||
PKG_RELEASE:=2
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=http://www.creytiv.com/pub
|
||||
|
@ -20,6 +20,8 @@ PKG_LICENSE:=BSD-3-Clause
|
|||
PKG_LICENSE_FILES:=docs/COPYING
|
||||
PKG_MAINTAINER:=Jiri Slachta <jiri@slachta.eu>
|
||||
|
||||
PKG_INSTALL:=1
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/librem
|
||||
|
@ -31,24 +33,15 @@ define Package/librem
|
|||
URL:=http://www.creytiv.com/
|
||||
endef
|
||||
|
||||
TARGET_CFLAGS+=$(FPIC)
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR) \
|
||||
LIBRE_MK=$(STAGING_DIR)/usr/share/re/re.mk \
|
||||
LIBRE_INC=$(STAGING_DIR)/usr/include/re \
|
||||
LIBRE_SO=$(STAGING_DIR)/usr/lib \
|
||||
CC="$(TARGET_CC)" \
|
||||
EXTRA_CFLAGS="$(TARGET_CFLAGS) -DOPENWRT" \
|
||||
EXTRA_LFLAGS="-lm" \
|
||||
DESTDIR="$(PKG_INSTALL_DIR)" \
|
||||
SYSROOT="$$$$($(FIND) $(TOOLCHAIN_DIR) -path '*/include/pthread.h' | sed -ne '1s#/include/pthread.h##p')" \
|
||||
SYSROOT_ALT="$(STAGING_DIR)/usr" \
|
||||
RELEASE=1 \
|
||||
CROSS_COMPILE="$(TARGET_CROSS)" \
|
||||
OS=linux \
|
||||
all install
|
||||
endef
|
||||
MAKE_FLAGS+= \
|
||||
EXTRA_LFLAGS="$(TARGET_LDFLAGS)" \
|
||||
LIBRE_MK="$(STAGING_DIR)/usr/share/re/re.mk" \
|
||||
LIBRE_INC="$(STAGING_DIR)/usr/include/re" \
|
||||
LIBRE_SO="$(STAGING_DIR)/usr/lib" \
|
||||
SYSROOT="$(shell $(FIND) $(TOOLCHAIN_DIR) -path '*/include/pthread.h' | sed -ne '1s|/include/pthread.h||p')" \
|
||||
SYSROOT_ALT="$(STAGING_DIR)/usr" \
|
||||
RELEASE=1 \
|
||||
OS=linux
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/include
|
||||
|
|
Loading…
Reference in a new issue