summaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorCalifornia Sullivan <california.l.sullivan@intel.com>2017-07-06 18:30:45 -0700
committerSaul Wold <sgw@linux.intel.com>2017-07-10 12:08:20 -0700
commit7fca20d924502510b4d57a28519a39b5f31ebb32 (patch)
tree2b1acc0c4a46fbce7d46d152e7d8e16049a76339 /common
parentfa6f2d28960ec7ac48117423bad9945b9b30265a (diff)
downloadmeta-intel-7fca20d924502510b4d57a28519a39b5f31ebb32.tar.gz
recipes: move sbsigntool from refkit to meta-intel
This is a tool that allows you to sign binaries. Either this or pesign is needed to support secure boot. Signed-off-by: California Sullivan <california.l.sullivan@intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
Diffstat (limited to 'common')
-rw-r--r--common/recipes-support/sbsigntool/sbsigntool-native_git.bb74
1 files changed, 74 insertions, 0 deletions
diff --git a/common/recipes-support/sbsigntool/sbsigntool-native_git.bb b/common/recipes-support/sbsigntool/sbsigntool-native_git.bb
new file mode 100644
index 00000000..a7dfe1d5
--- /dev/null
+++ b/common/recipes-support/sbsigntool/sbsigntool-native_git.bb
@@ -0,0 +1,74 @@
1DESCRIPTION = "Utility for signing and verifying files for UEFI Secure Boot"
2LICENSE = "GPLv3 & LGPL-2.1 & LGPL-3.0 & MIT"
3
4# sbsigntool statically links to libccan.a which is built with modules
5# passed to "create-ccan-tree" (and their dependencies). Therefore,
6# we also keep track of all the ccan module licenses.
7LIC_FILES_CHKSUM = "file://LICENSE.GPLv3;md5=9eef91148a9b14ec7f9df333daebc746 \
8 file://COPYING;md5=a7710ac18adec371b84a9594ed04fd20 \
9 file://lib/ccan.git/ccan/endian/LICENSE;md5=2d5025d4aa3495befef8f17206a5b0a1 \
10 file://lib/ccan.git/ccan/htable/LICENSE;md5=2d5025d4aa3495befef8f17206a5b0a1 \
11 file://lib/ccan.git/ccan/list/LICENSE;md5=2d5025d4aa3495befef8f17206a5b0a1 \
12 file://lib/ccan.git/ccan/read_write_all/LICENSE;md5=2d5025d4aa3495befef8f17206a5b0a1 \
13 file://lib/ccan.git/ccan/talloc/LICENSE;md5=2d5025d4aa3495befef8f17206a5b0a1 \
14 file://lib/ccan.git/ccan/typesafe_cb/LICENSE;md5=2d5025d4aa3495befef8f17206a5b0a1 \
15 file://lib/ccan.git/ccan/failtest/LICENSE;md5=6a6a8e020838b23406c81b19c1d46df6 \
16 file://lib/ccan.git/ccan/tlist/LICENSE;md5=6a6a8e020838b23406c81b19c1d46df6 \
17 file://lib/ccan.git/ccan/time/LICENSE;md5=838c366f69b72c5df05c96dff79b35f2 \
18"
19
20# The original upstream is git://kernel.ubuntu.com/jk/sbsigntool but it has
21# not been maintained and many patches have been backported in this repo.
22SRC_URI = "gitsm://git.kernel.org/pub/scm/linux/kernel/git/jejb/sbsigntools.git;protocol=git \
23 "
24
25SRCREV = "efbb550858e7bd3f43e64228d22aea440ef6a14d"
26
27DEPENDS = "binutils-native gnu-efi-native help2man-native openssl-native util-linux-native"
28
29PV = "0.8-git${SRCPV}"
30
31S = "${WORKDIR}/git"
32
33inherit native autotools pkgconfig
34
35do_configure_prepend() {
36 cd ${S}
37
38 if [ ! -e lib/ccan ]; then
39
40 # Use empty SCOREDIR because 'make scores' is not run.
41 # The default setting depends on (non-whitelisted) host tools.
42 sed -i -e 's#^\(SCOREDIR=\).*#\1#' lib/ccan.git/Makefile
43
44 lib/ccan.git/tools/create-ccan-tree \
45 --build-type=automake lib/ccan \
46 talloc read_write_all build_assert array_size endian
47 fi
48
49 # Create generatable docs from git
50 (
51 echo "Authors of sbsigntool:"
52 echo
53 git log --format='%an' | sort -u | sed 's,^,\t,'
54 ) > AUTHORS
55
56 # Generate simple ChangeLog
57 git log --date=short --format='%ad %t %an <%ae>%n%n * %s%n' > ChangeLog
58
59 cd ${B}
60}
61
62def efi_arch(d):
63 import re
64 harch = d.getVar("HOST_ARCH")
65 if re.match("i[3456789]86", harch):
66 return "ia32"
67 return harch
68
69EXTRA_OEMAKE = "\
70 INCLUDES+='-I${S}/lib/ccan.git/ \
71 -I${STAGING_INCDIR_NATIVE}/efi \
72 -I${STAGING_INCDIR_NATIVE} \
73 -I${STAGING_INCDIR_NATIVE}/efi/${@efi_arch(d)}' \
74 "