summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-crypto
diff options
context:
space:
mode:
authorPeter Kjellerstedt <peter.kjellerstedt@axis.com>2022-06-08 20:26:54 +0200
committerKhem Raj <raj.khem@gmail.com>2022-06-30 07:01:38 -0400
commitfc578274215c81b0b263b9afe47144f9a6ed0ad3 (patch)
tree6bb1a328ce0336deaa99afa758666c69ba9b1c99 /meta-oe/recipes-crypto
parent63d620555073c4fca5e70737095b7700047ad5b2 (diff)
downloadmeta-openembedded-fc578274215c81b0b263b9afe47144f9a6ed0ad3.tar.gz
cryptsetup: Add support for building without SSH tokens
Cryptsetup SSH tokens is the only feature that has a dependency on libssh. Add a packageconfig to control this dependency. Change-Id: Iac4f91e099ad2e3a79aab183734108f8bfbff57f Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-oe/recipes-crypto')
-rw-r--r--meta-oe/recipes-crypto/cryptsetup/cryptsetup_2.4.3.bb12
1 files changed, 10 insertions, 2 deletions
diff --git a/meta-oe/recipes-crypto/cryptsetup/cryptsetup_2.4.3.bb b/meta-oe/recipes-crypto/cryptsetup/cryptsetup_2.4.3.bb
index 435b554777..652fd66614 100644
--- a/meta-oe/recipes-crypto/cryptsetup/cryptsetup_2.4.3.bb
+++ b/meta-oe/recipes-crypto/cryptsetup/cryptsetup_2.4.3.bb
@@ -14,7 +14,6 @@ DEPENDS = " \
14 libdevmapper \ 14 libdevmapper \
15 popt \ 15 popt \
16 util-linux-libuuid \ 16 util-linux-libuuid \
17 libssh \
18" 17"
19 18
20DEPENDS:append:libc-musl = " argp-standalone" 19DEPENDS:append:libc-musl = " argp-standalone"
@@ -39,6 +38,7 @@ PACKAGECONFIG ??= " \
39 blkid \ 38 blkid \
40 luks-adjust-xts-keysize \ 39 luks-adjust-xts-keysize \
41 openssl \ 40 openssl \
41 ssh-token \
42" 42"
43PACKAGECONFIG:append:class-target = " \ 43PACKAGECONFIG:append:class-target = " \
44 udev \ 44 udev \
@@ -69,7 +69,7 @@ PACKAGECONFIG[nss] = "--with-crypto_backend=nss,,nss"
69PACKAGECONFIG[kernel] = "--with-crypto_backend=kernel" 69PACKAGECONFIG[kernel] = "--with-crypto_backend=kernel"
70PACKAGECONFIG[nettle] = "--with-crypto_backend=nettle,,nettle" 70PACKAGECONFIG[nettle] = "--with-crypto_backend=nettle,,nettle"
71PACKAGECONFIG[luks2] = "--with-default-luks-format=LUKS2,--with-default-luks-format=LUKS1" 71PACKAGECONFIG[luks2] = "--with-default-luks-format=LUKS2,--with-default-luks-format=LUKS1"
72 72PACKAGECONFIG[ssh-token] = "--enable-ssh-token,--disable-ssh-token,libssh"
73 73
74EXTRA_OECONF = "--enable-static" 74EXTRA_OECONF = "--enable-static"
75# Building without largefile is not supported by upstream 75# Building without largefile is not supported by upstream
@@ -90,6 +90,14 @@ EXTRA_OECONF += "--with-luks2-pbkdf=${LUKS2_PBKDF} \
90 --with-luks2-parallel-threads=${LUKS2_PARALLEL_THREADS} \ 90 --with-luks2-parallel-threads=${LUKS2_PARALLEL_THREADS} \
91 --with-luks2-iter-time=${LUKS2_ITERTIME}" 91 --with-luks2-iter-time=${LUKS2_ITERTIME}"
92 92
93do_install:append() {
94 # The /usr/lib/cryptsetup directory is always created, even when ssh-token
95 # is disabled. In that case it is empty and causes a packaging error. Since
96 # there is no reason to distribute the empty directory, the easiest solution
97 # is to remove it if it is empty.
98 rmdir -p --ignore-fail-on-non-empty ${D}${libdir}/${BPN}
99}
100
93FILES:${PN} += "${@bb.utils.contains('DISTRO_FEATURES','systemd','${exec_prefix}/lib/tmpfiles.d/cryptsetup.conf', '', d)}" 101FILES:${PN} += "${@bb.utils.contains('DISTRO_FEATURES','systemd','${exec_prefix}/lib/tmpfiles.d/cryptsetup.conf', '', d)}"
94 102
95RDEPENDS:${PN} = " \ 103RDEPENDS:${PN} = " \