diff options
-rw-r--r-- | meta-isg/common/recipes-extended/dpdk/dpdk_1.8.0.bb | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/meta-isg/common/recipes-extended/dpdk/dpdk_1.8.0.bb b/meta-isg/common/recipes-extended/dpdk/dpdk_1.8.0.bb new file mode 100644 index 00000000..7a278b60 --- /dev/null +++ b/meta-isg/common/recipes-extended/dpdk/dpdk_1.8.0.bb | |||
@@ -0,0 +1,61 @@ | |||
1 | include dpdk.inc | ||
2 | |||
3 | SRC_URI = "http://dpdk.org/browse/dpdk/snapshot/dpdk-${PV}.tar.gz;name=dpdk \ | ||
4 | file://dpdk-1.8.0-examples-add-config-variable-to-enable-disable-dpdk_.patch \ | ||
5 | file://dpdk-1.8.0-dpdk-enable-build-config-VHOST-in-common_linuxapp-config.patch \ | ||
6 | file://dpdk-1.8.0-add-RTE_KERNELDIR_OUT-to-split-kernel-bu.patch \ | ||
7 | file://dpdk-1.8.0-add-sysroot-option-within-app-makefile.patch \ | ||
8 | file://dpdk-1.8.0-dpdk-defconfig-select-RTE_MACHINE-type.patch \ | ||
9 | " | ||
10 | |||
11 | SRC_URI[dpdk.md5sum] = "11ad8785aaa869cc87265bcb8d828f22" | ||
12 | SRC_URI[dpdk.sha256sum] = "9f5386830bd999355182e20408f3fc2cfa0802a4497fdded8d43202feede1939" | ||
13 | |||
14 | export EXAMPLES_BUILD_DIR = "${RTE_TARGET}" | ||
15 | export ARCHDIR = "generic" | ||
16 | |||
17 | # dpdk example apps dpdk_qat and vhost have dependancy on fuse and qat. | ||
18 | # fuse is in meta-filesystems and qat is not yet upstreamed. | ||
19 | # So adding mechanism to explicitly disable the use of fuse and qat. | ||
20 | # To enable, uncomment the below line or include in .bbappend. | ||
21 | # PACKAGECONFIG ?= " dpdk_qat vhost libvirt" | ||
22 | |||
23 | PACKAGECONFIG[dpdk_qat] = ",,qat" | ||
24 | PACKAGECONFIG[vhost] = ",,fuse" | ||
25 | PACKAGECONFIG[libvirt] = ",,libvirt" | ||
26 | |||
27 | # The list of intel Comms platforms and their target machine | ||
28 | # process mapping. The supported target machine is listed under | ||
29 | # dpdk/mk/machine | ||
30 | def get_dpdk_target_mach(bb, d): | ||
31 | target_arch = d.getVar('MACHINE_ARCH', True) | ||
32 | multiarch_options = { | ||
33 | "mohonpeak64": "atm", | ||
34 | "mohonpeak32": "atm", | ||
35 | "crystalforest": "ivb", | ||
36 | "romley": "snd", | ||
37 | "romley-ivb": "ivb", | ||
38 | } | ||
39 | |||
40 | if target_arch in multiarch_options : | ||
41 | return multiarch_options[target_arch] | ||
42 | return "" | ||
43 | |||
44 | export CONFIG_EXAMPLE_DPDK_QAT = "${@base_contains('PACKAGECONFIG', 'dpdk_qat', 'y', 'n', d)}" | ||
45 | export CONFIG_EXAMPLE_VM_POWER_MANAGER = "${@base_contains('PACKAGECONFIG', 'libvirt', 'y', 'n', d)}" | ||
46 | export CONFIG_VHOST_ENABLED = "${@base_contains('PACKAGECONFIG', 'vhost', 'y', 'n', d)}" | ||
47 | export SYSROOTPATH = "--sysroot=${STAGING_DIR_HOST}" | ||
48 | export DPDK_TARGET_MACH = "${@get_dpdk_target_mach(bb,d)}" | ||
49 | |||
50 | do_compile_append () { | ||
51 | |||
52 | cd ${S}/examples/ | ||
53 | |||
54 | ############################################################### | ||
55 | # In order to make use of dpdk.inc for example app installation | ||
56 | # without failure, override the default build directory | ||
57 | ############################################################### | ||
58 | oe_runmake EXTRA_LDFLAGS="-L${STAGING_LIBDIR}" \ | ||
59 | EXTRA_CFLAGS="--sysroot=${STAGING_DIR_HOST} -I${STAGING_INCDIR}" \ | ||
60 | CROSS="${TARGET_PREFIX}" O="${S}/examples/$@/" | ||
61 | } | ||