From e9f31d49b10c066ba225815cc9e4be2fa804b543 Mon Sep 17 00:00:00 2001 From: John Toomey Date: Fri, 21 Jul 2023 16:40:21 +0100 Subject: libmcdi: Add new recipe Build and install the mcdi library components independently from DPDK and remmove these components from the original dpdk recipe. Signed-off-by: John Toomey Signed-off-by: Mark Hatle --- meta-dpdk/recipes-extended/dpdk/dpdk_22.11.0.bb | 5 ++-- meta-dpdk/recipes-extended/dpdk/libmcdi_0.1.0.bb | 33 ++++++++++++++++++++++++ 2 files changed, 35 insertions(+), 3 deletions(-) create mode 100644 meta-dpdk/recipes-extended/dpdk/libmcdi_0.1.0.bb diff --git a/meta-dpdk/recipes-extended/dpdk/dpdk_22.11.0.bb b/meta-dpdk/recipes-extended/dpdk/dpdk_22.11.0.bb index a79b0511..48034085 100644 --- a/meta-dpdk/recipes-extended/dpdk/dpdk_22.11.0.bb +++ b/meta-dpdk/recipes-extended/dpdk/dpdk_22.11.0.bb @@ -1,7 +1,6 @@ include dpdk.inc -SRC_URI = "git://github.com/Xilinx-CNS/cns-dpdk-next-sfc;branch=${BRANCH};protocol=https \ -" +SRC_URI = "git://github.com/Xilinx-CNS/cns-dpdk-next-sfc.git;branch=${BRANCH};protocol=https" BRANCH = "cdx_22.11" SRCREV = "e0cfb566341221dd08a5a0d7fdefce5432b41735" @@ -10,7 +9,7 @@ S = "${WORKDIR}/git" # kernel module is provide by dpdk-module recipe, so disable here EXTRA_OEMESON = " \ -Denable_kmods=false \ - -Dexamples=cdma_demo,cdx_test,mcdi/mcdi_test,mcdi/mcdi_init \ + -Dexamples=cdma_demo,cdx_test \ " COMPATIBLE_MACHINE = "null" diff --git a/meta-dpdk/recipes-extended/dpdk/libmcdi_0.1.0.bb b/meta-dpdk/recipes-extended/dpdk/libmcdi_0.1.0.bb new file mode 100644 index 00000000..a154664f --- /dev/null +++ b/meta-dpdk/recipes-extended/dpdk/libmcdi_0.1.0.bb @@ -0,0 +1,33 @@ +DESCRIPTION = "Management Controller Driver Interface library" + +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://COPYING.MIT;md5=838c366f69b72c5df05c96dff79b35f2" + +SRC_URI = "git://github.com/Xilinx-CNS/mcdi-lib.git;branch=${BRANCH};protocol=https" +BRANCH = "master" +SRCREV = "00e8422cbfc62c90b3a925b734b6c0caa2481540" + +S = "${WORKDIR}/git" + +COMPATIBLE_MACHINE = "^$" +COMPATIBLE_MACHINE:versal-net = "${MACHINE}" + +INSTALL_PATH = "${prefix}/share/${PN}/examples" + +TARGET_CC_ARCH += "${LDFLAGS}" + +do_compile() { + oe_runmake all CC="${CC}" CROSS_COMPILE="${TARGET_PREFIX}" +} + +do_install() { + install -d ${D}/${libdir}/ + install -m 0644 ${B}/lib/libmcdi.so.${PV} ${D}/${libdir}/ + ln -sf ${PN}.so ${D}/${libdir}/${PN}.so.${PV} + + install -d ${D}/${INSTALL_PATH} + install -m 0755 ${B}/example/mcdi_example_app ${D}/${INSTALL_PATH} + install -m 0755 ${B}/init/init_app ${D}/${INSTALL_PATH} +} + +FILES:${PN} = "${INSTALL_PATH}/* ${libdir}/*" -- cgit v1.2.3-54-g00ecf