2 # This is free software, licensed under the GNU General Public License v2.
3 # See /LICENSE for more information.
6 include $(TOPDIR
)/rules.mk
12 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
13 PKG_SOURCE_URL
:=https
://github.com
/SELinuxProject
/selinux
/releases
/download
/20200710
14 PKG_HASH
:=ae6778d01443fdd38cd30eeee846494e19f4d407b09872580372f4aa4bf8a3cc
16 PKG_MAINTAINER
:=Thomas Petazzoni
<thomas.petazzoni@bootlin.com
>
18 include $(INCLUDE_DIR
)/package.mk
19 include $(INCLUDE_DIR
)/host-build.mk
21 define Package
/libsepol
24 TITLE
:=SELinux binary policy manipulation library
25 URL
:=http
://selinuxproject.org
/page
/Main_Page
28 define Package
/libsepol
/description
29 Libsepol is the binary policy manipulation library. It doesn
't
30 depend upon or use any of the other SELinux components.
34 PREFIX=$(STAGING_DIR_HOSTPKG) \
35 SHLIBDIR=$(STAGING_DIR_HOSTPKG)/lib
42 $(call Build/Compile/Default,all)
46 $(call Build/Install/Default,install)
49 define Build/InstallDev
50 $(INSTALL_DIR) $(1)/usr/include
51 $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/
52 $(INSTALL_DIR) $(1)/usr/lib
53 $(CP) $(PKG_INSTALL_DIR)/usr/lib/* $(1)/usr/lib/
54 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
55 $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libsepol.pc $(1)/usr/lib/pkgconfig/
56 $(SED) 's
,/usr
/include,$$$${prefix}/include,g
' $(1)/usr/lib/pkgconfig/libsepol.pc
57 $(SED) 's
,/usr
/lib
,$$$${exec_prefix}/lib
,g
' $(1)/usr/lib/pkgconfig/libsepol.pc
60 define Package/libsepol/install
61 $(INSTALL_DIR) $(1)/usr/lib
62 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libsepol.so.* $(1)/usr/lib/
65 $(eval $(call HostBuild))
66 $(eval $(call BuildPackage,libsepol))