keyutils: Pass OpenWrt CFLAGS directly.
Needed for compilation with PKG_ASLR_PIE. Replaced Build/Compile with PKG_INSTALL. Adjusted install paths for consistency. Added license information. Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
parent
122426c651
commit
ccc3b6d44a
1 changed files with 19 additions and 8 deletions
|
@ -7,12 +7,15 @@ include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=keyutils
|
PKG_NAME:=keyutils
|
||||||
PKG_VERSION:=1.6
|
PKG_VERSION:=1.6
|
||||||
PKG_RELEASE:=2
|
PKG_RELEASE:=3
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
||||||
PKG_SOURCE_URL:=https://people.redhat.com/dhowells/keyutils/
|
PKG_SOURCE_URL:=https://people.redhat.com/dhowells/keyutils/
|
||||||
PKG_HASH:=d3aef20cec0005c0fa6b4be40079885567473185b1a57b629b030e67942c7115
|
PKG_HASH:=d3aef20cec0005c0fa6b4be40079885567473185b1a57b629b030e67942c7115
|
||||||
|
|
||||||
|
PKG_INSTALL:=1
|
||||||
|
PKG_BUILD_PARALLEL:=1
|
||||||
|
|
||||||
include $(INCLUDE_DIR)/package.mk
|
include $(INCLUDE_DIR)/package.mk
|
||||||
|
|
||||||
define Package/libkeyutils
|
define Package/libkeyutils
|
||||||
|
@ -20,6 +23,9 @@ define Package/libkeyutils
|
||||||
CATEGORY:=Libraries
|
CATEGORY:=Libraries
|
||||||
TITLE:=Key utilities library
|
TITLE:=Key utilities library
|
||||||
URL:=https://people.redhat.com/dhowells/keyutils/
|
URL:=https://people.redhat.com/dhowells/keyutils/
|
||||||
|
LICENSE:=LGPL-2.1-or-later
|
||||||
|
LICENSE_FILES:=LICENSE.LGPL
|
||||||
|
ABI_VERSION:=1
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/keyctl
|
define Package/keyctl
|
||||||
|
@ -28,31 +34,36 @@ define Package/keyctl
|
||||||
SUBMENU:=Encryption
|
SUBMENU:=Encryption
|
||||||
TITLE:=keyctl
|
TITLE:=keyctl
|
||||||
DEPENDS:=+libkeyutils
|
DEPENDS:=+libkeyutils
|
||||||
|
LICENSE:=GPL-2.0-or-later
|
||||||
|
LICENSE_FILES:=LICENSE.GPL
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/keyutils/description
|
define Package/keyutils/description
|
||||||
Key utilities
|
Key utilities
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Build/Install
|
MAKE_FLAGS += \
|
||||||
make -C $(PKG_BUILD_DIR) DESTDIR=$(PKG_INSTALL_DIR) LIBDIR=/usr/lib install
|
BINDIR=/usr/bin \
|
||||||
endef
|
LIBDIR=/usr/lib \
|
||||||
|
SBINDIR=/usr/sbin \
|
||||||
|
CFLAGS="$(TARGET_CFLAGS) $(FPIC)"
|
||||||
|
|
||||||
define Build/InstallDev
|
define Build/InstallDev
|
||||||
$(INSTALL_DIR) $(1)/usr/include
|
$(INSTALL_DIR) $(1)/usr/include
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/
|
||||||
$(INSTALL_DIR) $(1)/usr/lib/
|
$(INSTALL_DIR) $(1)/usr/lib/
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libkeyutils.{a,so*} $(1)/usr/lib/
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libkeyutils.a $(1)/usr/lib/
|
||||||
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libkeyutils.so.$(ABI_VERSION)* $(1)/usr/lib/
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/libkeyutils/install
|
define Package/libkeyutils/install
|
||||||
$(INSTALL_DIR) $(1)/usr/lib
|
$(INSTALL_DIR) $(1)/usr/lib
|
||||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libkeyutils.so* $(1)/usr/lib/
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libkeyutils.so.$(ABI_VERSION)* $(1)/usr/lib/
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/keyctl/install
|
define Package/keyctl/install
|
||||||
$(INSTALL_DIR) $(1)/bin
|
$(INSTALL_DIR) $(1)/usr/bin
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/bin/keyctl $(1)/bin
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/keyctl $(1)/usr/bin
|
||||||
endef
|
endef
|
||||||
|
|
||||||
$(eval $(call BuildPackage,libkeyutils))
|
$(eval $(call BuildPackage,libkeyutils))
|
||||||
|
|
Loading…
Reference in a new issue