update buildroot to 2017.02.11
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
Do not make symbols hidden on Blackfin
|
||||
|
||||
The libselinux logic to hide internal symbols from the DSO doesn't
|
||||
work properly on Blackfin due to the USER_LABEL_PREFIX not being
|
||||
handled properly. A real fix is not that simple, so this patch simply
|
||||
disables the internal symbol hiding mechanism. This means that those
|
||||
symbols are visible in the final DSO, which is not a problem for
|
||||
proper execution, it just isn't as clean.
|
||||
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
||||
Signed-off-by: Adam Duskett <Aduskett@gmail.com>
|
||||
|
||||
Index: b/src/dso.h
|
||||
===================================================================
|
||||
--- a/src/dso.h
|
||||
+++ b/src/dso.h
|
||||
@@ -1,7 +1,7 @@
|
||||
#ifndef _SEPOL_DSO_H
|
||||
#define _SEPOL_DSO_H 1
|
||||
|
||||
-#ifdef SHARED
|
||||
+#if defined(SHARED) && !defined(__bfin__)
|
||||
# define hidden __attribute__ ((visibility ("hidden")))
|
||||
# define hidden_proto(fct) __hidden_proto (fct, fct##_internal)
|
||||
# define __hidden_proto(fct, internal) \
|
||||
30
bsp/buildroot-2017.02.11/package/libsemanage/Config.in
Normal file
30
bsp/buildroot-2017.02.11/package/libsemanage/Config.in
Normal file
@@ -0,0 +1,30 @@
|
||||
config BR2_PACKAGE_LIBSEMANAGE
|
||||
bool "libsemanage"
|
||||
select BR2_PACKAGE_AUDIT
|
||||
select BR2_PACKAGE_LIBSELINUX
|
||||
select BR2_PACKAGE_USTR
|
||||
select BR2_PACKAGE_BZIP2
|
||||
depends on BR2_PACKAGE_AUDIT_ARCH_SUPPORTS
|
||||
depends on BR2_TOOLCHAIN_HAS_THREADS
|
||||
depends on !BR2_STATIC_LIBS
|
||||
# - libselinux needs fts.h (not available in uClibc/musl)
|
||||
# - libsemanage itself needs getpwent_r() not available in musl
|
||||
# - audit is not available on musl
|
||||
depends on BR2_TOOLCHAIN_USES_GLIBC
|
||||
depends on !BR2_arc
|
||||
help
|
||||
libsemanage is the policy management library. It uses
|
||||
libsepol for binary policy manipulation and libselinux for
|
||||
interacting with the SELinux system. It also exec's helper
|
||||
programs for loading policy and for checking whether the
|
||||
file_contexts configuration is valid (load_policy and
|
||||
setfiles from policycoreutils) presently, although this may
|
||||
change at least for the bootstrapping case (for rpm).
|
||||
|
||||
http://selinuxproject.org/page/Main_Page
|
||||
|
||||
comment "libsemanage needs a glibc toolchain w/ threads, dynamic library"
|
||||
depends on !BR2_arc
|
||||
depends on BR2_PACKAGE_AUDIT_ARCH_SUPPORTS
|
||||
depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS || \
|
||||
!BR2_TOOLCHAIN_USES_GLIBC
|
||||
@@ -0,0 +1,2 @@
|
||||
# Locally computed
|
||||
sha256 4f81541047290b751f2ffb926fcd381c186f22db18d9fe671b0b4a6a54e8cfce libsemanage-2.6.tar.gz
|
||||
62
bsp/buildroot-2017.02.11/package/libsemanage/libsemanage.mk
Normal file
62
bsp/buildroot-2017.02.11/package/libsemanage/libsemanage.mk
Normal file
@@ -0,0 +1,62 @@
|
||||
################################################################################
|
||||
#
|
||||
# libsemanage
|
||||
#
|
||||
################################################################################
|
||||
|
||||
LIBSEMANAGE_VERSION = 2.6
|
||||
LIBSEMANAGE_SITE = https://raw.githubusercontent.com/wiki/SELinuxProject/selinux/files/releases/20161014
|
||||
LIBSEMANAGE_LICENSE = LGPLv2.1+
|
||||
LIBSEMANAGE_LICENSE_FILES = COPYING
|
||||
LIBSEMANAGE_DEPENDENCIES = host-bison host-flex audit libselinux ustr bzip2
|
||||
LIBSEMANAGE_INSTALL_STAGING = YES
|
||||
|
||||
LIBSEMANAGE_MAKE_OPTS = $(TARGET_CONFIGURE_OPTS)
|
||||
|
||||
define LIBSEMANAGE_BUILD_CMDS
|
||||
# DESTDIR is needed during the compile to compute library and
|
||||
# header paths.
|
||||
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D) $(LIBSEMANAGE_MAKE_OPTS) DESTDIR=$(STAGING_DIR) all
|
||||
endef
|
||||
|
||||
define LIBSEMANAGE_INSTALL_STAGING_CMDS
|
||||
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D) $(LIBSEMANAGE_MAKE_OPTS) DESTDIR=$(STAGING_DIR) install
|
||||
endef
|
||||
|
||||
define LIBSEMANAGE_INSTALL_TARGET_CMDS
|
||||
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D) $(LIBSEMANAGE_MAKE_OPTS) DESTDIR=$(TARGET_DIR) install
|
||||
endef
|
||||
|
||||
HOST_LIBSEMANAGE_DEPENDENCIES = host-bison host-audit host-libsepol host-libselinux \
|
||||
host-ustr host-bzip2 host-swig
|
||||
HOST_LIBSEMANAGE_MAKE_OPTS += $(HOST_CONFIGURE_OPTS) \
|
||||
SWIG_LIB="$(HOST_DIR)/usr/share/swig/$(SWIG_VERSION)/"
|
||||
|
||||
ifeq ($(BR2_PACKAGE_PYTHON3),y)
|
||||
HOST_LIBSEMANAGE_DEPENDENCIES += host-python3
|
||||
HOST_LIBSEMANAGE_MAKE_OPTS += \
|
||||
PYINC="-I$(HOST_DIR)/usr/include/python$(PYTHON3_VERSION_MAJOR)m/" \
|
||||
PYTHONLIBDIR="-L$(HOST_DIR)/usr/lib/python$(PYTHON3_VERSION_MAJOR)/" \
|
||||
PYLIBVER="python$(PYTHON3_VERSION_MAJOR)"
|
||||
else
|
||||
HOST_LIBSEMANAGE_DEPENDENCIES += host-python
|
||||
HOST_LIBSEMANAGE_MAKE_OPTS += \
|
||||
PYINC="-I$(HOST_DIR)/usr/include/python$(PYTHON_VERSION_MAJOR)/" \
|
||||
PYTHONLIBDIR="-L$(HOST_DIR)/usr/lib/python$(PYTHON_VERSION_MAJOR)/" \
|
||||
PYLIBVER="python$(PYTHON_VERSION_MAJOR)"
|
||||
endif
|
||||
|
||||
define HOST_LIBSEMANAGE_BUILD_CMDS
|
||||
# DESTDIR is needed during the compile to compute library and
|
||||
# header paths.
|
||||
$(HOST_MAKE_ENV) $(MAKE) -C $(@D) $(HOST_CONFIGURE_OPTS) DESTDIR=$(HOST_DIR) all
|
||||
$(HOST_MAKE_ENV) $(MAKE) -C $(@D) $(HOST_LIBSEMANAGE_MAKE_OPTS) DESTDIR=$(HOST_DIR) swigify pywrap
|
||||
endef
|
||||
|
||||
define HOST_LIBSEMANAGE_INSTALL_CMDS
|
||||
$(HOST_MAKE_ENV) $(MAKE) -C $(@D) $(HOST_CONFIGURE_OPTS) DESTDIR=$(HOST_DIR) install
|
||||
$(HOST_MAKE_ENV) $(MAKE) -C $(@D) $(HOST_LIBSEMANAGE_MAKE_OPTS) DESTDIR=$(HOST_DIR) install-pywrap
|
||||
endef
|
||||
|
||||
$(eval $(generic-package))
|
||||
$(eval $(host-generic-package))
|
||||
Reference in New Issue
Block a user