2013-09-11 23:59:21 +02:00
|
|
|
################################################################################
|
|
|
|
#
|
|
|
|
# libsepol
|
|
|
|
#
|
|
|
|
################################################################################
|
|
|
|
|
2017-01-09 17:15:22 +01:00
|
|
|
LIBSEPOL_VERSION = 2.6
|
|
|
|
LIBSEPOL_SITE = https://raw.githubusercontent.com/wiki/SELinuxProject/selinux/files/releases/20161014
|
2013-09-11 23:59:21 +02:00
|
|
|
LIBSEPOL_LICENSE = LGPLv2.1+
|
|
|
|
LIBSEPOL_LICENSE_FILES = COPYING
|
|
|
|
|
|
|
|
LIBSEPOL_INSTALL_STAGING = YES
|
2016-07-02 00:24:55 +02:00
|
|
|
LIBSEPOL_DEPENDENCIES = host-flex
|
2016-07-03 00:20:53 +02:00
|
|
|
HOST_LIBSEPOL_DEPENDENCIES = host-flex
|
2013-09-11 23:59:21 +02:00
|
|
|
|
2014-02-20 22:42:36 +01:00
|
|
|
LIBSEPOL_MAKE_FLAGS = $(TARGET_CONFIGURE_OPTS)
|
|
|
|
|
2014-12-03 22:41:29 +01:00
|
|
|
ifeq ($(BR2_STATIC_LIBS),y)
|
2014-02-20 22:42:36 +01:00
|
|
|
LIBSEPOL_MAKE_FLAGS += STATIC=1
|
|
|
|
endif
|
|
|
|
|
2013-09-11 23:59:21 +02:00
|
|
|
define LIBSEPOL_BUILD_CMDS
|
|
|
|
# DESTDIR is needed during the compile to compute library and
|
|
|
|
# header paths.
|
2016-10-17 18:06:53 +02:00
|
|
|
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D) $(LIBSEPOL_MAKE_FLAGS) DESTDIR=$(STAGING_DIR)
|
2013-09-11 23:59:21 +02:00
|
|
|
endef
|
|
|
|
|
|
|
|
define LIBSEPOL_INSTALL_STAGING_CMDS
|
2016-10-17 18:06:53 +02:00
|
|
|
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D) install $(LIBSEPOL_MAKE_FLAGS) DESTDIR=$(STAGING_DIR)
|
2013-09-11 23:59:21 +02:00
|
|
|
endef
|
|
|
|
|
|
|
|
define LIBSEPOL_INSTALL_TARGET_CMDS
|
2016-10-17 18:06:53 +02:00
|
|
|
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D) install $(LIBSEPOL_MAKE_FLAGS) DESTDIR=$(TARGET_DIR)
|
2013-09-11 23:59:21 +02:00
|
|
|
endef
|
|
|
|
|
|
|
|
define HOST_LIBSEPOL_BUILD_CMDS
|
2016-10-17 18:06:54 +02:00
|
|
|
$(HOST_MAKE_ENV) $(MAKE) -C $(@D) $(HOST_CONFIGURE_OPTS) DESTDIR=$(HOST_DIR)
|
2013-09-11 23:59:21 +02:00
|
|
|
endef
|
|
|
|
|
|
|
|
define HOST_LIBSEPOL_INSTALL_CMDS
|
2016-10-17 18:06:54 +02:00
|
|
|
$(HOST_MAKE_ENV) $(MAKE) -C $(@D) install $(HOST_CONFIGURE_OPTS) DESTDIR=$(HOST_DIR)
|
2013-09-11 23:59:21 +02:00
|
|
|
mv $(HOST_DIR)/lib/libsepol.so.1 $(HOST_DIR)/usr/lib
|
|
|
|
(cd $(HOST_DIR)/usr/lib; rm -f libsepol.so; ln -s libsepol.so.1 libsepol.so)
|
|
|
|
-rmdir $(HOST_DIR)/lib
|
|
|
|
endef
|
|
|
|
|
|
|
|
$(eval $(generic-package))
|
|
|
|
$(eval $(host-generic-package))
|