Makefile 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. #
  2. # This is free software, licensed under the GNU General Public License v2.
  3. # See /LICENSE for more information.
  4. #
  5. include $(TOPDIR)/rules.mk
  6. PKG_NAME:=libsemanage
  7. PKG_VERSION:=3.1
  8. PKG_RELEASE:=1
  9. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  10. PKG_SOURCE_URL:=https://github.com/SELinuxProject/selinux/releases/download/20200710
  11. PKG_HASH:=22d6c75526e40d1781c30bcf29abf97171bdfe6780923f11c8e1c76a75a21ff8
  12. PKG_MAINTAINER:=Thomas Petazzoni <[email protected]>
  13. PKG_LICENSE:=LGPL-2.1
  14. PKG_LICENSE_FILES:=COPYING
  15. PKG_CPE_ID:=cpe:/a:selinuxproject:libsemanage
  16. HOST_BUILD_DEPENDS:=libaudit/host libselinux/host bzip2/host
  17. include $(INCLUDE_DIR)/package.mk
  18. include $(INCLUDE_DIR)/host-build.mk
  19. PKG_INSTALL:=1
  20. define Package/libsemanage
  21. SECTION:=libs
  22. DEPENDS:=+libaudit +libselinux +libbz2
  23. CATEGORY:=Libraries
  24. TITLE:=SELinux policy management library
  25. URL:=http://selinuxproject.org/page/Main_Page
  26. endef
  27. define Package/libsemanage/description
  28. libsemanage is the policy management library. It uses
  29. libsepol for binary policy manipulation and libselinux for
  30. interacting with the SELinux system. It also exec's helper
  31. programs for loading policy and for checking whether the
  32. file_contexts configuration is valid (load_policy and
  33. setfiles from policycoreutils) presently, although this may
  34. change at least for the bootstrapping case (for rpm).
  35. endef #'
  36. HOST_MAKE_FLAGS += \
  37. DESTDIR=$(STAGING_DIR_HOSTPKG) \
  38. PREFIX=""
  39. define Build/Configure
  40. endef
  41. define Build/InstallDev
  42. $(INSTALL_DIR) $(1)/usr/include
  43. $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/
  44. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  45. $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libsemanage.pc $(1)/usr/lib/pkgconfig/
  46. $(INSTALL_DIR) $(1)/usr/lib
  47. $(CP) $(PKG_INSTALL_DIR)/usr/lib/* $(1)/usr/lib/
  48. endef
  49. define Package/libsemanage/install
  50. $(INSTALL_DIR) $(1)/usr/lib
  51. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libsemanage.so.* $(1)/usr/lib/
  52. endef
  53. $(eval $(call HostBuild))
  54. $(eval $(call BuildPackage,libsemanage))