app: fix plugin load on static builds
authorOlivier Matz <olivier.matz@6wind.com>
Tue, 17 Nov 2020 13:57:16 +0000 (14:57 +0100)
committerOlivier Matz <olivier.matz@6wind.com>
Thu, 26 Nov 2020 17:05:18 +0000 (18:05 +0100)
commit4a5f0f19b8b6f377fd0a536e2a4c3c92d2adae20
treee56f3035b05975b9d5a5e30173a1441126617062
parent4d4876744ada7b5fc660a97d33074b56a00dcf89
app: fix plugin load on static builds

When dpdk is compiled as static libraries, it is not possible
to load a plugin from an application. We get the following error:

  EAL: librte_pmd_xxxx.so: undefined symbol: per_lcore__rte_errno

This happens because the dpdk symbols are not exported. Add them to the
dynamic symbol table by using '-Wl,--export-dynamic'. This option was
previously present when compiled with Makefiles, it was introduced in
commit f9a08f650211 ("eal: add support for shared object drivers")

Fixes: 16ade738fd0d ("app/testpmd: build with meson")
Fixes: 89f0711f9ddf ("examples: build some samples with meson")
Cc: stable@dpdk.org
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
app/meson.build
examples/meson.build