diff options
author | Yi Zhao <yi.zhao@windriver.com> | 2020-03-13 20:31:44 +0800 |
---|---|---|
committer | Jia Zhang <zhang.jia@linux.alibaba.com> | 2020-03-19 10:47:24 +0800 |
commit | e8e80fb7c4971bb05e14ec5e329c1435ba485b2b (patch) | |
tree | 3f0d762acd9df2b2da3437bebe06e4fa308eefa8 | |
parent | f2d06cda8d4de282a36d8922c69c6014d3ed715a (diff) | |
download | meta-secure-core-e8e80fb7c4971bb05e14ec5e329c1435ba485b2b.tar.gz |
cryptfs-tpm2: convert the script to python3
Convert the script to python3 to fix the do_compile failure.
Fixes:
/buildarea/poky/build/tmp/work/core2-64-poky-linux/cryptfs-tpm2/0.7.0+gitAUTOINC+888c46c827-r0/git/scripts/encrypt_secret.py -i "H31i05" > "primary_key.secret" || exit 1
/usr/bin/env: ‘python’: No such file or directory
Makefile:64: recipe for target 'primary_key.secret' failed
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
-rw-r--r-- | meta-encrypted-storage/recipes-tpm/cryptfs-tpm2/cryptfs-tpm2/0001-encrypt_secret.py-switch-to-python3.patch | 32 | ||||
-rw-r--r-- | meta-encrypted-storage/recipes-tpm/cryptfs-tpm2/cryptfs-tpm2_git.bb | 1 |
2 files changed, 33 insertions, 0 deletions
diff --git a/meta-encrypted-storage/recipes-tpm/cryptfs-tpm2/cryptfs-tpm2/0001-encrypt_secret.py-switch-to-python3.patch b/meta-encrypted-storage/recipes-tpm/cryptfs-tpm2/cryptfs-tpm2/0001-encrypt_secret.py-switch-to-python3.patch new file mode 100644 index 0000000..2ef8036 --- /dev/null +++ b/meta-encrypted-storage/recipes-tpm/cryptfs-tpm2/cryptfs-tpm2/0001-encrypt_secret.py-switch-to-python3.patch | |||
@@ -0,0 +1,32 @@ | |||
1 | From 480648bd9a516fc84b02d0b83ebccf40547e5dd0 Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Fri, 13 Mar 2020 20:17:46 +0800 | ||
4 | Subject: [PATCH] encrypt_secret.py: switch to python3 | ||
5 | |||
6 | Upstream-Status: Submitted [https://github.com/jiazhang0/cryptfs-tpm2/pull/7] | ||
7 | |||
8 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
9 | --- | ||
10 | scripts/encrypt_secret.py.in | 3 +-- | ||
11 | 1 file changed, 1 insertion(+), 2 deletions(-) | ||
12 | |||
13 | diff --git a/scripts/encrypt_secret.py.in b/scripts/encrypt_secret.py.in | ||
14 | index 1ddb76d..ffd3213 100755 | ||
15 | --- a/scripts/encrypt_secret.py.in | ||
16 | +++ b/scripts/encrypt_secret.py.in | ||
17 | @@ -1,11 +1,10 @@ | ||
18 | -#!/usr/bin/env python | ||
19 | +#!/usr/bin/env python3 | ||
20 | #coding: UTF-8 | ||
21 | |||
22 | ''' | ||
23 | The simple encryption/decryption for secret info | ||
24 | ''' | ||
25 | |||
26 | -from __future__ import print_function | ||
27 | import logging | ||
28 | import argparse | ||
29 | import struct | ||
30 | -- | ||
31 | 2.7.4 | ||
32 | |||
diff --git a/meta-encrypted-storage/recipes-tpm/cryptfs-tpm2/cryptfs-tpm2_git.bb b/meta-encrypted-storage/recipes-tpm/cryptfs-tpm2/cryptfs-tpm2_git.bb index 94b81aa..e36e2f2 100644 --- a/meta-encrypted-storage/recipes-tpm/cryptfs-tpm2/cryptfs-tpm2_git.bb +++ b/meta-encrypted-storage/recipes-tpm/cryptfs-tpm2/cryptfs-tpm2_git.bb | |||
@@ -22,6 +22,7 @@ PV = "0.7.0+git${SRCPV}" | |||
22 | SRC_URI = "\ | 22 | SRC_URI = "\ |
23 | git://github.com/jiazhang0/cryptfs-tpm2.git \ | 23 | git://github.com/jiazhang0/cryptfs-tpm2.git \ |
24 | file://0001-luks-setup.sh-Add-support-for-qemu-with-the-swtpm.patch \ | 24 | file://0001-luks-setup.sh-Add-support-for-qemu-with-the-swtpm.patch \ |
25 | file://0001-encrypt_secret.py-switch-to-python3.patch \ | ||
25 | " | 26 | " |
26 | SRCREV = "87c35c63090a33d4de437f518b8da9f2d1f1d828" | 27 | SRCREV = "87c35c63090a33d4de437f518b8da9f2d1f1d828" |
27 | 28 | ||