aboutsummaryrefslogtreecommitdiffstats
path: root/meta-tpm/recipes-tpm2/tpm2-tcti-uefi/tpm2-tcti-uefi_0.9.9.bb
blob: 9c60e2b9d51feef8c41cec42b46c4775b8486bda (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
SUMMARY = "TCTI module for use with TSS2 libraries in UEFI environment"
SECTION = "security/tpm"
LICENSE = "BSD-2-Clause"
LIC_FILES_CHKSUM = "file://LICENSE;md5=500b2e742befc3da00684d8a1d5fd9da"
DEPENDS = "libtss2-dev libtss2-mu-dev gnu-efi-native gnu-efi pkgconfig autoconf-archive-native"

SRC_URI = "git://github.com/tpm2-software/tpm2-tcti-uefi.git;branch=master;protocol=https \
           file://configure_oe_fixup.patch \
           file://0001-configure.ac-stop-inserting-host-directories-into-co.patch \
           file://fix_header_file.patch \
"

SRCREV = "0241b08f069f0fdb3612f5c1b938144dbe9be811"

UPSTREAM_CHECK_URI = "https://github.com/tpm2-software/${BPN}/releases"

S = "${WORKDIR}/git"

inherit autotools pkgconfig

EFIDIR ?= "/EFI/BOOT"

EFI_ARCH:x86 = "ia32"
EFI_ARCH:x86-64 = "x86_64"

CFLAGS:append = " -I${STAGING_INCDIR}/efi -I${STAGING_INCDIR}/efi/${EFI_ARCH}"

EXTRA_OECONF:append = " \
    --with-efi-includedir=${STAGING_INCDIR} \
    --with-efi-crt0=${STAGING_LIBDIR}/crt0-efi-${EFI_ARCH}.o \
    --with-efi-lds=${STAGING_LIBDIR}/elf_${EFI_ARCH}_efi.lds \
"

do_compile:append() {
	oe_runmake example
}

do_install:append() {
	install -d "${D}${EFIDIR}"
	install -m 0755 "${B}"/example/*.efi "${D}${EFIDIR}"
}

COMPATIBLE_HOST = "(i.86|x86_64).*-linux"

FILES:${PN} += "${EFIDIR}"

RDEPENDS:${PN} = "gnu-efi libtss2-mu"