summaryrefslogtreecommitdiffstats
path: root/recipes-devtools/qemu/qemu-xilinx-helper-native_1.0.bb
blob: f04be9602e2a91ae47c1dc12dacfd112012d74dd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
def get_filespath_extra(d, subpath):
	metaroot = next((p for p in d.getVar('BBPATH').split(':') if os.path.basename(p) == 'meta'), None)
	if metaroot:
		return os.path.join(metaroot, subpath) + ":"
	return ""

# TODO: improve this, since it is very hacky that this recipe need to build tunctl.
# include the existing qemu-helper-native
require recipes-devtools/qemu/qemu-helper-native_1.0.bb
# get the path to tunctl.c
FILESEXTRAPATHS_prepend := "${@get_filespath_extra(d, 'recipes-devtools/qemu/qemu-helper')}"

# provide it, to replace the existing
PROVIDES += "qemu-helper-native"

# replace qemu with qemu-xilinx
DEPENDS_remove = "qemu-native"
DEPENDS_append = " qemu-xilinx-native"