From: Thorben Roemer <thorben.roe...@secunet.com> In order to perform things like LTO more easily in our DPDK applications, we use DPDK as a meson subproject. Also export includes in order to be usable in this context.
Signed-off-by: Thorben Roemer <thorben.roe...@secunet.com> --- drivers/baseband/fpga_5gnr_fec/meson.build | 2 ++ drivers/dma/dpaa2/meson.build | 2 ++ drivers/event/dlb2/meson.build | 2 ++ drivers/mempool/dpaa2/meson.build | 2 ++ drivers/net/atlantic/meson.build | 2 ++ drivers/net/bnxt/meson.build | 2 ++ drivers/net/bonding/meson.build | 2 ++ drivers/net/cnxk/meson.build | 2 ++ drivers/net/dpaa/meson.build | 2 ++ drivers/net/dpaa2/meson.build | 2 ++ drivers/net/i40e/meson.build | 2 ++ drivers/net/iavf/meson.build | 2 ++ drivers/net/ixgbe/meson.build | 2 ++ drivers/net/memif/meson.build | 2 ++ drivers/net/mlx5/meson.build | 2 ++ drivers/net/ring/meson.build | 2 ++ drivers/net/softnic/meson.build | 2 ++ drivers/net/vhost/meson.build | 2 ++ drivers/raw/cnxk_bphy/meson.build | 2 ++ drivers/raw/cnxk_gpio/meson.build | 2 ++ drivers/raw/dpaa2_cmdif/meson.build | 2 ++ drivers/raw/ifpga/meson.build | 2 ++ drivers/raw/ntb/meson.build | 2 ++ lib/meson.build | 1 + meson.build | 1 + 25 files changed, 48 insertions(+) diff --git a/drivers/baseband/fpga_5gnr_fec/meson.build b/drivers/baseband/fpga_5gnr_fec/meson.build index 745cd271f2..b2b218e9f9 100644 --- a/drivers/baseband/fpga_5gnr_fec/meson.build +++ b/drivers/baseband/fpga_5gnr_fec/meson.build @@ -6,3 +6,5 @@ deps += ['bbdev', 'bus_vdev', 'ring', 'pci', 'bus_pci'] sources = files('rte_fpga_5gnr_fec.c') headers = files('rte_pmd_fpga_5gnr_fec.h') + +dpdk_includes += include_directories('.') diff --git a/drivers/dma/dpaa2/meson.build b/drivers/dma/dpaa2/meson.build index a99151e2a5..672f820f16 100644 --- a/drivers/dma/dpaa2/meson.build +++ b/drivers/dma/dpaa2/meson.build @@ -16,3 +16,5 @@ if cc.has_argument('-Wno-pointer-arith') endif headers = files('rte_pmd_dpaa2_qdma.h') + +dpdk_includes += include_directories('.') diff --git a/drivers/event/dlb2/meson.build b/drivers/event/dlb2/meson.build index 20ef159ab3..aeffc5d4da 100644 --- a/drivers/event/dlb2/meson.build +++ b/drivers/event/dlb2/meson.build @@ -65,3 +65,5 @@ endif headers = files('rte_pmd_dlb2.h') deps += ['mbuf', 'mempool', 'ring', 'pci', 'bus_pci'] + +dpdk_includes += include_directories('.') diff --git a/drivers/mempool/dpaa2/meson.build b/drivers/mempool/dpaa2/meson.build index 3d16d44158..559d36d9a8 100644 --- a/drivers/mempool/dpaa2/meson.build +++ b/drivers/mempool/dpaa2/meson.build @@ -10,3 +10,5 @@ deps += ['bus_fslmc'] sources = files('dpaa2_hw_mempool.c') headers = files('rte_dpaa2_mempool.h') + +dpdk_includes += include_directories('.') diff --git a/drivers/net/atlantic/meson.build b/drivers/net/atlantic/meson.build index bf5e47eaaf..6a6d176b45 100644 --- a/drivers/net/atlantic/meson.build +++ b/drivers/net/atlantic/meson.build @@ -17,3 +17,5 @@ sources = files( 'hw_atl/hw_atl_utils.c', 'rte_pmd_atlantic.c', ) + +dpdk_includes += include_directories('.') diff --git a/drivers/net/bnxt/meson.build b/drivers/net/bnxt/meson.build index 09d494e90f..af9a58ac9e 100644 --- a/drivers/net/bnxt/meson.build +++ b/drivers/net/bnxt/meson.build @@ -68,3 +68,5 @@ if arch_subdir == 'x86' elif arch_subdir == 'arm' and dpdk_conf.get('RTE_ARCH_64') sources += files('bnxt_rxtx_vec_neon.c') endif + +dpdk_includes += include_directories('.') diff --git a/drivers/net/bonding/meson.build b/drivers/net/bonding/meson.build index 29022712cb..41b0903374 100644 --- a/drivers/net/bonding/meson.build +++ b/drivers/net/bonding/meson.build @@ -23,3 +23,5 @@ deps += ['ip_frag'] headers = files('rte_eth_bond.h', 'rte_eth_bond_8023ad.h') pmd_supports_disable_iova_as_pa = true + +dpdk_includes += include_directories('.') diff --git a/drivers/net/cnxk/meson.build b/drivers/net/cnxk/meson.build index 5efb2000cf..d43f0b53d1 100644 --- a/drivers/net/cnxk/meson.build +++ b/drivers/net/cnxk/meson.build @@ -195,3 +195,5 @@ endforeach headers = files('rte_pmd_cnxk.h') pmd_supports_disable_iova_as_pa = true + +dpdk_includes += include_directories('.') diff --git a/drivers/net/dpaa/meson.build b/drivers/net/dpaa/meson.build index 42e1f8c2e2..6927c3644c 100644 --- a/drivers/net/dpaa/meson.build +++ b/drivers/net/dpaa/meson.build @@ -21,3 +21,5 @@ if cc.has_argument('-Wno-pointer-arith') endif headers = files('rte_pmd_dpaa.h') + +dpdk_includes += include_directories('.') diff --git a/drivers/net/dpaa2/meson.build b/drivers/net/dpaa2/meson.build index 51598c048c..d5f71deb29 100644 --- a/drivers/net/dpaa2/meson.build +++ b/drivers/net/dpaa2/meson.build @@ -27,3 +27,5 @@ sources = files( includes += include_directories('base', 'mc') headers = files('rte_pmd_dpaa2.h') + +dpdk_includes += include_directories('.') diff --git a/drivers/net/i40e/meson.build b/drivers/net/i40e/meson.build index e00c1a9ef9..1f64814608 100644 --- a/drivers/net/i40e/meson.build +++ b/drivers/net/i40e/meson.build @@ -92,3 +92,5 @@ elif arch_subdir == 'arm' endif headers = files('rte_pmd_i40e.h') + +dpdk_includes += include_directories('.') diff --git a/drivers/net/iavf/meson.build b/drivers/net/iavf/meson.build index 6df771f917..d27809059a 100644 --- a/drivers/net/iavf/meson.build +++ b/drivers/net/iavf/meson.build @@ -71,3 +71,5 @@ elif arch_subdir == 'arm' endif headers = files('rte_pmd_iavf.h') + +dpdk_includes += include_directories('.') diff --git a/drivers/net/ixgbe/meson.build b/drivers/net/ixgbe/meson.build index a18908ef7c..c2552276d5 100644 --- a/drivers/net/ixgbe/meson.build +++ b/drivers/net/ixgbe/meson.build @@ -36,3 +36,5 @@ endif includes += include_directories('base') headers = files('rte_pmd_ixgbe.h') + +dpdk_includes += include_directories('.') diff --git a/drivers/net/memif/meson.build b/drivers/net/memif/meson.build index 28416a982f..4cbe50fb2a 100644 --- a/drivers/net/memif/meson.build +++ b/drivers/net/memif/meson.build @@ -13,3 +13,5 @@ sources = files( deps += ['hash'] pmd_supports_disable_iova_as_pa = true + +dpdk_includes += include_directories('.') diff --git a/drivers/net/mlx5/meson.build b/drivers/net/mlx5/meson.build index 6a84d96380..9ecdcfda44 100644 --- a/drivers/net/mlx5/meson.build +++ b/drivers/net/mlx5/meson.build @@ -72,3 +72,5 @@ endif testpmd_sources += files('mlx5_testpmd.c') subdir(exec_env) + +dpdk_includes += include_directories('.') diff --git a/drivers/net/ring/meson.build b/drivers/net/ring/meson.build index 72792e26b0..567857dcd8 100644 --- a/drivers/net/ring/meson.build +++ b/drivers/net/ring/meson.build @@ -10,3 +10,5 @@ endif sources = files('rte_eth_ring.c') headers = files('rte_eth_ring.h') pmd_supports_disable_iova_as_pa = true + +dpdk_includes += include_directories('.') diff --git a/drivers/net/softnic/meson.build b/drivers/net/softnic/meson.build index 5dfbd16c77..451d70cddd 100644 --- a/drivers/net/softnic/meson.build +++ b/drivers/net/softnic/meson.build @@ -16,3 +16,5 @@ sources = files( 'rte_eth_softnic_thread.c', ) deps += ['pipeline', 'port', 'table'] + +dpdk_includes += include_directories('.') diff --git a/drivers/net/vhost/meson.build b/drivers/net/vhost/meson.build index f481a3a4b8..6023bcb179 100644 --- a/drivers/net/vhost/meson.build +++ b/drivers/net/vhost/meson.build @@ -10,3 +10,5 @@ endif deps += 'vhost' sources = files('rte_eth_vhost.c') headers = files('rte_eth_vhost.h') + +dpdk_includes += include_directories('.') diff --git a/drivers/raw/cnxk_bphy/meson.build b/drivers/raw/cnxk_bphy/meson.build index ffb0ee6b7e..591a24321b 100644 --- a/drivers/raw/cnxk_bphy/meson.build +++ b/drivers/raw/cnxk_bphy/meson.build @@ -11,3 +11,5 @@ sources = files( ) headers = files('rte_pmd_bphy.h') pmd_supports_disable_iova_as_pa = true + +dpdk_includes += include_directories('.') diff --git a/drivers/raw/cnxk_gpio/meson.build b/drivers/raw/cnxk_gpio/meson.build index f52a7be9eb..2139e21621 100644 --- a/drivers/raw/cnxk_gpio/meson.build +++ b/drivers/raw/cnxk_gpio/meson.build @@ -10,3 +10,5 @@ sources = files( ) headers = files('rte_pmd_cnxk_gpio.h') pmd_supports_disable_iova_as_pa = true + +dpdk_includes += include_directories('.') diff --git a/drivers/raw/dpaa2_cmdif/meson.build b/drivers/raw/dpaa2_cmdif/meson.build index 3b1d3371b2..c01f4ceefd 100644 --- a/drivers/raw/dpaa2_cmdif/meson.build +++ b/drivers/raw/dpaa2_cmdif/meson.build @@ -5,3 +5,5 @@ deps += ['rawdev', 'mempool_dpaa2', 'bus_vdev'] sources = files('dpaa2_cmdif.c') headers = files('rte_pmd_dpaa2_cmdif.h') + +dpdk_includes += include_directories('.') diff --git a/drivers/raw/ifpga/meson.build b/drivers/raw/ifpga/meson.build index cc30dc8be7..28ec996bba 100644 --- a/drivers/raw/ifpga/meson.build +++ b/drivers/raw/ifpga/meson.build @@ -22,3 +22,5 @@ includes += include_directories('../../net/ipn3ke') includes += include_directories('../../net/i40e') headers = files('rte_pmd_ifpga.h') + +dpdk_includes += include_directories('.') diff --git a/drivers/raw/ntb/meson.build b/drivers/raw/ntb/meson.build index 9096f2b25a..b5a7693f60 100644 --- a/drivers/raw/ntb/meson.build +++ b/drivers/raw/ntb/meson.build @@ -5,3 +5,5 @@ deps += ['rawdev', 'mbuf', 'mempool', 'pci', 'bus_pci'] sources = files('ntb.c', 'ntb_hw_intel.c') headers = files('rte_pmd_ntb.h') + +dpdk_includes += include_directories('.') diff --git a/lib/meson.build b/lib/meson.build index f858844fa2..85113d0b47 100644 --- a/lib/meson.build +++ b/lib/meson.build @@ -190,6 +190,7 @@ foreach l:libraries libname = 'rte_' + name includes += include_directories(l) + dpdk_includes += include_directories(l) if developer_mode and is_windows and use_function_versioning message('@0@: Function versioning is not supported by Windows.'.format(name)) diff --git a/meson.build b/meson.build index 1d35a255c3..d1cf039297 100644 --- a/meson.build +++ b/meson.build @@ -32,6 +32,7 @@ cc = meson.get_compiler('c') dpdk_source_root = meson.current_source_dir() dpdk_build_root = meson.current_build_dir() dpdk_conf = configuration_data() +dpdk_includes = [] dpdk_libraries = [] dpdk_static_libraries = [] dpdk_shared_lib_deps = [] -- 2.38.0