secilc: update to version 3.2
[openwrt/openwrt.git] / package / utils / secilc / Makefile
1 #
2 # This is free software, licensed under the GNU General Public License v2.
3 # See /LICENSE for more information.
4 #
5
6 include $(TOPDIR)/rules.mk
7
8 PKG_NAME:=secilc
9 PKG_VERSION:=3.2
10 PKG_RELEASE:=1
11
12 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
13 PKG_SOURCE_URL:=https://github.com/SELinuxProject/selinux/releases/download/3.2
14 PKG_HASH:=5f6e6528a281b29ac5e558babffc3d8aab682fd8df8977daff5f266a50292cc3
15 HOST_BUILD_DEPENDS:=libsepol/host
16
17 PKG_MAINTAINER:=Dominick Grift <dominick.grift@defensec.nl>
18 PKG_CPE_ID:=cpe:/a:selinuxproject:secilc
19 PKG_LICENSE:=BSD-2-Clause
20 PKG_LICENSE_FILES:=COPYING
21
22 include $(INCLUDE_DIR)/host-build.mk
23 include $(INCLUDE_DIR)/nls.mk
24 include $(INCLUDE_DIR)/package.mk
25
26 HOST_LDFLAGS+=-Wl,-rpath=$(STAGING_DIR_HOSTPKG)/lib
27 HOST_MAKE_FLAGS += \
28 DESTDIR=$(STAGING_DIR_HOSTPKG) \
29 PREFIX=
30
31 define Package/secilc
32 SECTION:=utils
33 CATEGORY:=Utilities
34 TITLE:=SELinux Common Intermediate Language (CIL) Compiler
35 URL:=http://selinuxproject.org/page/Main_Page
36 DEPENDS:=+libsepol
37 endef
38
39 define Package/secilc/description
40 The SELinux CIL Compiler is a compiler that converts the CIL language as
41 described on the CIL design wiki into a kernel binary policy file.
42 Please see the CIL Design Wiki at:
43 http://github.com/SELinuxProject/cil/wiki/
44 for more information about the goals and features on the CIL language.
45 endef
46
47 define Build/Compile
48 $(call Build/Compile/Default,secilc)
49 endef
50
51 define Host/Compile
52 $(call Host/Compile/Default,secilc)
53 endef
54
55 define Host/Install
56 $(INSTALL_DIR) $(STAGING_DIR_HOSTPKG)/bin
57 $(INSTALL_BIN) $(HOST_BUILD_DIR)/secilc $(STAGING_DIR_HOSTPKG)/bin
58 endef
59
60 define Package/secilc/install
61 $(INSTALL_DIR) $(1)/usr/bin
62 $(INSTALL_BIN) $(PKG_BUILD_DIR)/secilc $(1)/usr/bin
63 endef
64
65 $(eval $(call BuildPackage,secilc))
66 $(eval $(call HostBuild))