xdp-tools: build static library

The problem with shared library is that generated object files are also
required additionally by libxdp. So build the static library instead of
installing .o files as well (which would need us to disable stripping
etc.)

Error log while building libxdp:
| libxdp: Couldn't find a BPF file with name xsk_def_xdp_prog.o
| xsk_configure(): Failed to create xsk socket

Enable production option too. Also see:

https://github.com/xdp-project/xdp-tools/issues/180

Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com>
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
This commit is contained in:
Naveen Saini 2023-02-07 09:39:40 +08:00 committed by Anuj Mittal
parent c995bda6b6
commit bd1b4f1026

View File

@ -21,14 +21,12 @@ S = "${WORKDIR}/git"
inherit pkgconfig inherit pkgconfig
EXTRA_OEMAKE += "PREFIX=${D}${prefix} LIBDIR=${D}${libdir}" EXTRA_OEMAKE += "PREFIX=${D}${prefix} LIBDIR=${D}${libdir} BUILD_STATIC_ONLY=1 PRODUCTION=1"
CFLAGS += "-fPIC"
export STAGING_INCDIR export STAGING_INCDIR
do_configure:prepend () {
export DYNAMIC_LIBXDP=1
}
do_install () { do_install () {
oe_runmake install oe_runmake install