blob: 5c9d9e52a81ad73a147bc976bf09bb1f792b0849 (
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
48
49
50
51
52
53
54
55
|
# Common settings for all Zephyr recipes
ZEPHYR_INHERIT_CLASSES += "zephyr cmake"
inherit ${ZEPHYR_INHERIT_CLASSES}
# There shouldn't be a manifest for zephyr kernels since there is no root
# filesystem.
IMAGE_NO_MANIFEST = "1"
ZEPHYR_TOOLCHAIN_VARIANT ?= "yocto"
require zephyr-toolchain-${ZEPHYR_TOOLCHAIN_VARIANT}.inc
ZEPHYR_MAKE_OUTPUT = "zephyr.elf"
ZEPHYR_MAKE_BIN_OUTPUT = "zephyr.bin"
ZEPHYR_MAKE_EFI_OUTPUT = "zephyr.efi"
EXTRA_OECMAKE = "\
-DZEPHYR_BASE=${ZEPHYR_BASE} \
-DBOARD=${BOARD} \
-DARCH=${ARCH} \
-DZEPHYR_TOOLCHAIN_VARIANT=${ZEPHYR_TOOLCHAIN_VARIANT} \
-DZEPHYR_MODULES=${ZEPHYR_MODULES} \
"
ZEPHYR_EXTRA_MODULES = ""
EXTRA_OECMAKE:append = " -DZEPHYR_EXTRA_MODULES=${ZEPHYR_EXTRA_MODULES}"
export ZEPHYR_BASE="${S}/zephyr"
DEPENDS += "gperf-native"
DEPENDS:append:qemuall = " qemu-native qemu-helper-native"
# The makefiles are explicit about the flags they want, so don't unset
# them so zephyr flags actually get used.
# This is done here rather than in the task so that things still work
# in devshell.
python () {
d.delVar('CFLAGS')
d.delVar('CXXFLAGS')
d.delVar('LDFLAGS')
}
OE_TERMINAL_EXPORTS += "BOARD"
OE_TERMINAL_EXPORTS += "ZEPHYR_SRC_DIR"
OE_TERMINAL_EXPORTS += "ZEPHYR_BASE"
IMAGE_FSTYPES = "elf bin"
do_configure:prepend() {
# Zephyr expects CPPFLAGS as cmake argument as and ignores env variables.
unset CPPFLAGS
}
|