diff options
author | Lans Zhang <jia.zhang@windriver.com> | 2017-07-20 10:30:41 +0800 |
---|---|---|
committer | Lans Zhang <jia.zhang@windriver.com> | 2017-07-20 10:30:41 +0800 |
commit | 6f7bf76d94519cc390737468e6508c1704f27311 (patch) | |
tree | 629090c13d029a4894c9f7c6bbce14c742198cc7 | |
parent | dffeaacd06aa190ca99ff6c382cdcb1238376761 (diff) | |
download | meta-secure-core-6f7bf76d94519cc390737468e6508c1704f27311.tar.gz |
meta-secure-core: define new image type secure-core-minimal-image
Signed-off-by: Lans Zhang <jia.zhang@windriver.com>
-rw-r--r-- | meta/recipes-core/images/secure-core-image.bb | 32 | ||||
-rw-r--r-- | meta/recipes-core/images/secure-core-image.inc | 32 | ||||
-rw-r--r-- | meta/recipes-core/images/secure-core-minimal-image.bb | 1 |
3 files changed, 35 insertions, 30 deletions
diff --git a/meta/recipes-core/images/secure-core-image.bb b/meta/recipes-core/images/secure-core-image.bb index 35ea93b..0a8adc8 100644 --- a/meta/recipes-core/images/secure-core-image.bb +++ b/meta/recipes-core/images/secure-core-image.bb | |||
@@ -1,33 +1,5 @@ | |||
1 | SUMMARY = "The root image of SecureCore." | 1 | require secure-core-image.inc |
2 | LICENSE = "MIT" | ||
3 | 2 | ||
4 | SECURE_CORE_IMAGE_EXTRA_INSTALL_append += "\ | 3 | IMAGE_INSTALL += "\ |
5 | ${@bb.utils.contains("DISTRO_FEATURES", "efi-secure-boot", \ | ||
6 | "packagegroup-efi-secure-boot", "", d)} \ | ||
7 | ${@bb.utils.contains("DISTRO_FEATURES", "tpm", \ | ||
8 | "packagegroup-tpm", "", d)} \ | ||
9 | ${@bb.utils.contains("DISTRO_FEATURES", "tpm2", \ | ||
10 | "packagegroup-tpm2", "", d)} \ | ||
11 | ${@bb.utils.contains("DISTRO_FEATURES", "ima", \ | ||
12 | "packagegroup-ima", "", d)} \ | ||
13 | ${@bb.utils.contains("DISTRO_FEATURES", "encrypted-storage", \ | ||
14 | "packagegroup-encrypted-storage", "", d)} \ | ||
15 | " | ||
16 | |||
17 | IMAGE_INSTALL = "\ | ||
18 | packagegroup-core-boot \ | ||
19 | packagegroup-core-lsb \ | 4 | packagegroup-core-lsb \ |
20 | kernel-initramfs \ | ||
21 | ${SECURE_CORE_IMAGE_EXTRA_INSTALL} \ | ||
22 | " | ||
23 | |||
24 | IMAGE_LINGUAS = " " | ||
25 | |||
26 | INITRAMFS_IMAGE = "secure-core-image-initramfs" | ||
27 | |||
28 | inherit core-image | ||
29 | |||
30 | IMAGE_ROOTFS_SIZE ?= "8192" | ||
31 | IMAGE_ROOTFS_EXTRA_SPACE_append = "\ | ||
32 | ${@bb.utils.contains("DISTRO_FEATURES", "systemd", " + 4096", "" ,d)} \ | ||
33 | " | 5 | " |
diff --git a/meta/recipes-core/images/secure-core-image.inc b/meta/recipes-core/images/secure-core-image.inc new file mode 100644 index 0000000..e08b84a --- /dev/null +++ b/meta/recipes-core/images/secure-core-image.inc | |||
@@ -0,0 +1,32 @@ | |||
1 | SUMMARY = "The root image of SecureCore." | ||
2 | LICENSE = "MIT" | ||
3 | |||
4 | SECURE_CORE_IMAGE_EXTRA_INSTALL_append += "\ | ||
5 | ${@bb.utils.contains("DISTRO_FEATURES", "efi-secure-boot", \ | ||
6 | "packagegroup-efi-secure-boot", "", d)} \ | ||
7 | ${@bb.utils.contains("DISTRO_FEATURES", "tpm", \ | ||
8 | "packagegroup-tpm", "", d)} \ | ||
9 | ${@bb.utils.contains("DISTRO_FEATURES", "tpm2", \ | ||
10 | "packagegroup-tpm2", "", d)} \ | ||
11 | ${@bb.utils.contains("DISTRO_FEATURES", "ima", \ | ||
12 | "packagegroup-ima", "", d)} \ | ||
13 | ${@bb.utils.contains("DISTRO_FEATURES", "encrypted-storage", \ | ||
14 | "packagegroup-encrypted-storage", "", d)} \ | ||
15 | " | ||
16 | |||
17 | IMAGE_INSTALL = "\ | ||
18 | packagegroup-core-boot \ | ||
19 | kernel-initramfs \ | ||
20 | ${SECURE_CORE_IMAGE_EXTRA_INSTALL} \ | ||
21 | " | ||
22 | |||
23 | IMAGE_LINGUAS = " " | ||
24 | |||
25 | INITRAMFS_IMAGE = "secure-core-image-initramfs" | ||
26 | |||
27 | inherit core-image | ||
28 | |||
29 | IMAGE_ROOTFS_SIZE ?= "8192" | ||
30 | IMAGE_ROOTFS_EXTRA_SPACE_append = "\ | ||
31 | ${@bb.utils.contains("DISTRO_FEATURES", "systemd", " + 4096", "" ,d)} \ | ||
32 | " | ||
diff --git a/meta/recipes-core/images/secure-core-minimal-image.bb b/meta/recipes-core/images/secure-core-minimal-image.bb new file mode 100644 index 0000000..63ddf34 --- /dev/null +++ b/meta/recipes-core/images/secure-core-minimal-image.bb | |||
@@ -0,0 +1 @@ | |||
require secure-core-image.inc | |||