Skip to contentSkip to conversation

build DPDK libs and some drivers with meson/ninja

PATCH Superseded Bruce Richardson 6 participants 107 messages Sep 1, 2017 – Sep 20, 2017 Page 2 of 2

Subsystems (4)
lore
Share & tools
lore
#91 lore raw

PATCH v3 4/17 build: add DPDK libraries to build

In reply to Bruce Richardson

Add non-EAL libraries to DPDK build. The compat lib is a special case, along with the previously-added EAL, but all other libs can be build using the same set of commands, where the individual meson.build files only need to specify their dependencies, source files, header files and ABI versions.

---
 config/rte_config.h                 | 36 ++++++++++++++++++++
 lib/librte_acl/meson.build          | 59 ++++++++++++++++++++++++++++++++
 lib/librte_bitratestats/meson.build | 34 +++++++++++++++++++
 lib/librte_cfgfile/meson.build      | 34 +++++++++++++++++++
 lib/librte_cmdline/meson.build      | 55 ++++++++++++++++++++++++++++++
 lib/librte_compat/meson.build       | 36 ++++++++++++++++++++
 lib/librte_cryptodev/meson.build    | 40 ++++++++++++++++++++++
 lib/librte_distributor/meson.build  | 39 +++++++++++++++++++++
 lib/librte_efd/meson.build          | 34 +++++++++++++++++++
 lib/librte_ether/meson.build        | 45 +++++++++++++++++++++++++
 lib/librte_eventdev/meson.build     | 36 ++++++++++++++++++++
 lib/librte_gro/meson.build          | 34 +++++++++++++++++++
 lib/librte_hash/meson.build         | 45 +++++++++++++++++++++++++
 lib/librte_ip_frag/meson.build      | 39 +++++++++++++++++++++
 lib/librte_jobstats/meson.build     | 33 ++++++++++++++++++
 lib/librte_kni/meson.build          | 38 +++++++++++++++++++++
 lib/librte_kvargs/meson.build       | 34 +++++++++++++++++++
 lib/librte_latencystats/meson.build | 34 +++++++++++++++++++
 lib/librte_lpm/meson.build          | 35 +++++++++++++++++++
 lib/librte_mbuf/meson.build         | 35 +++++++++++++++++++
 lib/librte_mempool/meson.build      | 35 +++++++++++++++++++
 lib/librte_meter/meson.build        | 33 ++++++++++++++++++
 lib/librte_metrics/meson.build      | 33 ++++++++++++++++++
 lib/librte_net/meson.build          | 45 +++++++++++++++++++++++++
 lib/librte_pdump/meson.build        | 34 +++++++++++++++++++
 lib/librte_pipeline/meson.build     | 35 +++++++++++++++++++
 lib/librte_port/meson.build         | 58 ++++++++++++++++++++++++++++++++
 lib/librte_power/meson.build        | 37 ++++++++++++++++++++
 lib/librte_reorder/meson.build      | 34 +++++++++++++++++++
 lib/librte_ring/meson.build         | 33 ++++++++++++++++++
 lib/librte_sched/meson.build        | 36 ++++++++++++++++++++
 lib/librte_table/meson.build        | 52 ++++++++++++++++++++++++++++
 lib/librte_timer/meson.build        | 33 ++++++++++++++++++
 lib/librte_vhost/meson.build        | 39 +++++++++++++++++++++
 lib/meson.build                     | 67 +++++++++++++++++++++++++++++++++++++
 35 files changed, 1379 insertions(+)
 create mode 100644 lib/librte_acl/meson.build
 create mode 100644 lib/librte_bitratestats/meson.build
 create mode 100644 lib/librte_cfgfile/meson.build
 create mode 100644 lib/librte_cmdline/meson.build
 create mode 100644 lib/librte_compat/meson.build
 create mode 100644 lib/librte_cryptodev/meson.build
 create mode 100644 lib/librte_distributor/meson.build
 create mode 100644 lib/librte_efd/meson.build
 create mode 100644 lib/librte_ether/meson.build
 create mode 100644 lib/librte_eventdev/meson.build
 create mode 100644 lib/librte_gro/meson.build
 create mode 100644 lib/librte_hash/meson.build
 create mode 100644 lib/librte_ip_frag/meson.build
 create mode 100644 lib/librte_jobstats/meson.build
 create mode 100644 lib/librte_kni/meson.build
 create mode 100644 lib/librte_kvargs/meson.build
 create mode 100644 lib/librte_latencystats/meson.build
 create mode 100644 lib/librte_lpm/meson.build
 create mode 100644 lib/librte_mbuf/meson.build
 create mode 100644 lib/librte_mempool/meson.build
 create mode 100644 lib/librte_meter/meson.build
 create mode 100644 lib/librte_metrics/meson.build
 create mode 100644 lib/librte_net/meson.build
 create mode 100644 lib/librte_pdump/meson.build
 create mode 100644 lib/librte_pipeline/meson.build
 create mode 100644 lib/librte_port/meson.build
 create mode 100644 lib/librte_power/meson.build
 create mode 100644 lib/librte_reorder/meson.build
 create mode 100644 lib/librte_ring/meson.build
 create mode 100644 lib/librte_sched/meson.build
 create mode 100644 lib/librte_table/meson.build
 create mode 100644 lib/librte_timer/meson.build
 create mode 100644 lib/librte_vhost/meson.build
config/rte_config.h +36 -0
index c94704cfe..b47cfabae 100644
@@ -58,4 +58,40 @@
 #define RTE_BACKTRACE 1
 #define RTE_EAL_VFIO 1
 
+/* mempool defines */
+#define RTE_MEMPOOL_CACHE_MAX_SIZE 512
+
+/* mbuf defines */
+#define RTE_MBUF_DEFAULT_MEMPOOL_OPS "ring_mp_mc"
+#define RTE_MBUF_REFCNT_ATOMIC 1
+#define RTE_PKTMBUF_HEADROOM 128
+
+/* ether defines */
+#define RTE_MAX_ETHPORTS 32
+#define RTE_MAX_QUEUES_PER_PORT 1024
+#define RTE_ETHDEV_QUEUE_STAT_CNTRS 16
+#define RTE_ETHDEV_RXTX_CALLBACKS 1
+
+/* cryptodev defines */
+#define RTE_CRYPTO_MAX_DEVS 64
+#define RTE_CRYPTODEV_NAME_LEN 64
+
+/* eventdev defines */
+#define RTE_EVENT_MAX_DEVS 16
+#define RTE_EVENT_MAX_QUEUES_PER_DEV 64
+
+/* ip_fragmentation defines */
+#define RTE_LIBRTE_IP_FRAG_MAX_FRAG 4
+#undef RTE_LIBRTE_IP_FRAG_TBL_STAT
+
+/* rte_power defines */
+#define RTE_MAX_LCORE_FREQS 64
+
+/* rte_sched defines */
+#undef RTE_SCHED_RED
+#undef RTE_SCHED_COLLECT_STATS
+#undef RTE_SCHED_SUBPORT_TC_OV
+#define RTE_SCHED_PORT_N_GRINDERS 8
+#undef RTE_SCHED_VECTOR
+
 #endif /* _RTE_CONFIG_H_ */
lib/librte_acl/meson.build new file +59 -0

59 lines not on this page · raw message

lib/librte_bitratestats/meson.build new file +34 -0
new file mode 100644
index 000000000..dcf6070bf
@@ -0,0 +1,34 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_bitrate.c')
+headers = files('rte_bitrate.h')
+deps += ['ethdev', 'metrics']
lib/librte_cfgfile/meson.build new file +34 -0
new file mode 100644
index 000000000..1a4992ff3
@@ -0,0 +1,34 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+version = 2
+sources = files('rte_cfgfile.c')
+headers = files('rte_cfgfile.h')
lib/librte_cmdline/meson.build new file +55 -0

55 lines not on this page · raw message

lib/librte_compat/meson.build new file +36 -0
new file mode 100644
index 000000000..3b911dfff
@@ -0,0 +1,36 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+
+install_headers('rte_compat.h')
+
+set_variable('dep_rte_compat',
+	declare_dependency(include_directories: include_directories('.')))
lib/librte_cryptodev/meson.build new file +40 -0
new file mode 100644
index 000000000..e45e7098a
@@ -0,0 +1,40 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+version = 3
+sources = files('rte_cryptodev.c', 'rte_cryptodev_pmd.c')
+headers = files('rte_cryptodev.h',
+	'rte_cryptodev_pci.h',
+	'rte_cryptodev_pmd.h',
+	'rte_cryptodev_vdev.h',
+	'rte_crypto.h',
+	'rte_crypto_sym.h')
+deps += ['kvargs', 'mbuf']
lib/librte_distributor/meson.build new file +39 -0
new file mode 100644
index 000000000..6118c5f50
@@ -0,0 +1,39 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_distributor.c', 'rte_distributor_v20.c')
+if arch_subdir == 'x86'
+	sources += files('rte_distributor_match_sse.c')
+else
+	sources += files('rte_distributor_match_generic.c')
+endif
+headers = files('rte_distributor.h')
+deps += ['mbuf', 'compat']
lib/librte_efd/meson.build new file +34 -0
new file mode 100644
index 000000000..73c004e70
@@ -0,0 +1,34 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_efd.c')
+headers = files('rte_efd.h')
+deps += ['ring', 'hash']
lib/librte_ether/meson.build new file +45 -0

45 lines not on this page · raw message

lib/librte_eventdev/meson.build new file +36 -0
new file mode 100644
index 000000000..60d5f4e89
@@ -0,0 +1,36 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_eventdev.c', 'rte_event_ring.c')
+headers = files('rte_eventdev.h', 'rte_eventdev_pmd.h',
+		'rte_eventdev_pmd_pci.h', 'rte_eventdev_pmd_vdev.h',
+		'rte_event_ring.h')
+deps += ['ring']
lib/librte_gro/meson.build new file +34 -0
new file mode 100644
index 000000000..f6848c42b
@@ -0,0 +1,34 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_gro.c', 'gro_tcp4.c')
+headers = files('rte_gro.h')
+deps += ['ethdev']
lib/librte_hash/meson.build new file +45 -0

45 lines not on this page · raw message

lib/librte_ip_frag/meson.build new file +39 -0
new file mode 100644
index 000000000..11523badf
@@ -0,0 +1,39 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_ipv4_fragmentation.c',
+		'rte_ipv6_fragmentation.c',
+		'rte_ipv4_reassembly.c',
+		'rte_ipv6_reassembly.c',
+		'rte_ip_frag_common.c',
+		'ip_frag_internal.c')
+headers = files('rte_ip_frag.h')
+deps += ['ethdev', 'hash']
lib/librte_jobstats/meson.build new file +33 -0
new file mode 100644
index 000000000..97cf01cad
@@ -0,0 +1,33 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_jobstats.c')
+headers = files('rte_jobstats.h')
lib/librte_kni/meson.build new file +38 -0
new file mode 100644
index 000000000..25934a46d
@@ -0,0 +1,38 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+if host_machine.system() != 'linux'
+	build = false
+endif
+version = 2
+sources = files('rte_kni.c')
+headers = files('rte_kni.h')
+deps += ['ethdev']
lib/librte_kvargs/meson.build new file +34 -0
new file mode 100644
index 000000000..2962fc370
@@ -0,0 +1,34 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+version = 1
+sources = files('rte_kvargs.c')
+headers = files('rte_kvargs.h')
lib/librte_latencystats/meson.build new file +34 -0
new file mode 100644
index 000000000..10a778433
@@ -0,0 +1,34 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_latencystats.c')
+headers = files('rte_latencystats.h')
+deps += ['metrics', 'ethdev']
lib/librte_lpm/meson.build new file +35 -0
new file mode 100644
index 000000000..af88a97ec
@@ -0,0 +1,35 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+version = 2
+sources = files('rte_lpm.c', 'rte_lpm6.c')
+headers = files('rte_lpm.h', 'rte_lpm6.h')
+deps += ['compat']
lib/librte_mbuf/meson.build new file +35 -0
new file mode 100644
index 000000000..96856e231
@@ -0,0 +1,35 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+version = 3
+sources = files('rte_mbuf.c', 'rte_mbuf_ptype.c')
+headers = files('rte_mbuf.h', 'rte_mbuf_ptype.h')
+deps += ['mempool']
lib/librte_mempool/meson.build new file +35 -0
new file mode 100644
index 000000000..96e582deb
@@ -0,0 +1,35 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+version = 2
+sources = files('rte_mempool.c', 'rte_mempool_ops.c')
+headers = files('rte_mempool.h')
+deps += ['ring']
lib/librte_meter/meson.build new file +33 -0
new file mode 100644
index 000000000..debcebcc1
@@ -0,0 +1,33 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_meter.c')
+headers = files('rte_meter.h')
lib/librte_metrics/meson.build new file +33 -0
new file mode 100644
index 000000000..c820503f0
@@ -0,0 +1,33 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_metrics.c')
+headers = files('rte_metrics.h')
lib/librte_net/meson.build new file +45 -0

45 lines not on this page · raw message

lib/librte_pdump/meson.build new file +34 -0
new file mode 100644
index 000000000..94a92b677
@@ -0,0 +1,34 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_pdump.c')
+headers = files('rte_pdump.h')
+deps += ['ethdev']
lib/librte_pipeline/meson.build new file +35 -0
new file mode 100644
index 000000000..54e34fc62
@@ -0,0 +1,35 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+version = 3
+sources = files('rte_pipeline.c')
+headers = files('rte_pipeline.h')
+deps += ['port', 'table']
lib/librte_port/meson.build new file +58 -0

58 lines not on this page · raw message

lib/librte_power/meson.build new file +37 -0
new file mode 100644
index 000000000..541efa6a4
@@ -0,0 +1,37 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+if host_machine.system() != 'linux'
+	build = false
+endif
+sources = files('rte_power.c', 'rte_power_acpi_cpufreq.c',
+		'rte_power_kvm_vm.c', 'guest_channel.c')
+headers = files('rte_power.h')
lib/librte_reorder/meson.build new file +34 -0
new file mode 100644
index 000000000..456e83f02
@@ -0,0 +1,34 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_reorder.c')
+headers = files('rte_reorder.h')
+deps += ['mbuf']
lib/librte_ring/meson.build new file +33 -0
new file mode 100644
index 000000000..8c102fe6a
@@ -0,0 +1,33 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_ring.c')
+headers = files('rte_ring.h')
lib/librte_sched/meson.build new file +36 -0
new file mode 100644
index 000000000..c4badb211
@@ -0,0 +1,36 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_sched.c', 'rte_red.c', 'rte_approx.c',
+		'rte_reciprocal.c')
+headers = files('rte_sched.h', 'rte_bitmap.h', 'rte_sched_common.h',
+		'rte_red.h', 'rte_approx.h', 'rte_reciprocal.h')
+deps += ['mbuf', 'meter']
lib/librte_table/meson.build new file +52 -0

52 lines not on this page · raw message

lib/librte_timer/meson.build new file +33 -0
new file mode 100644
index 000000000..0edc45772
@@ -0,0 +1,33 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_timer.c')
+headers = files('rte_timer.h')
lib/librte_vhost/meson.build new file +39 -0
new file mode 100644
index 000000000..5482169ca
@@ -0,0 +1,39 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+if host_machine.system() != 'linux'
+	build = false
+endif
+version = 4
+sources = files('fd_man.c', 'socket.c', 'vhost.c', 'vhost_user.c',
+		'virtio_net.c')
+headers = files('rte_vhost.h')
+deps += ['ethdev']
lib/meson.build +67 -0

71 lines not on this page · raw message

Signature · 1 line
2.13.5
#92 lore raw

PATCH v3 5/17 build: add buildtools to meson build

In reply to Bruce Richardson

Add the buildtools folder, and more specifically the pmdinfogen binary to the meson and ninja build. This will be needed for building the PMDs in the driver folder later, as the pmd info output from the tool needs to be included in those libs.

---
 buildtools/gen-pmdinfo-cfile.sh   | 41 +++++++++++++++++++++++++++++++++++++++
 buildtools/meson.build            | 34 ++++++++++++++++++++++++++++++++
 buildtools/pmdinfogen/meson.build | 36 ++++++++++++++++++++++++++++++++++
 meson.build                       |  1 +
 4 files changed, 112 insertions(+)
 create mode 100755 buildtools/gen-pmdinfo-cfile.sh
 create mode 100644 buildtools/meson.build
 create mode 100644 buildtools/pmdinfogen/meson.build
buildtools/gen-pmdinfo-cfile.sh new file +41 -0
new file mode 100755
index 000000000..6441613ac
@@ -0,0 +1,41 @@
+#! /bin/sh
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+
+arfile=$1
+output=$2
+pmdinfogen=$3
+
+tmp_o=${output%.c.pmd.c}.tmp.o
+
+ar p $arfile > $tmp_o && \
+		$pmdinfogen $tmp_o $output
buildtools/meson.build new file +34 -0
new file mode 100644
index 000000000..4537e4d3b
@@ -0,0 +1,34 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+subdir('pmdinfogen')
+
+pmdinfo = find_program('gen-pmdinfo-cfile.sh')
buildtools/pmdinfogen/meson.build new file +36 -0
new file mode 100644
index 000000000..843afba7c
@@ -0,0 +1,36 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+pmdinfogen = executable('pmdinfogen',
+	'pmdinfogen.c',
+	include_directories: eal_inc,
+	native: true,
+	c_args: cflags)
meson.build +1 -0
index f62f64c31..db9c1631f 100644
@@ -59,6 +59,7 @@ subdir('config')
 
 # build libs and (TODO) drivers
 subdir('lib')
+subdir('buildtools')
 
 # TODO build binaries and installable tools
 
Signature · 1 line
2.13.5
#93 lore raw

PATCH v3 6/17 build: add infrastructure for building PMDs

In reply to Bruce Richardson

Add in the top-level drivers meson.build file to start adding in building of PMDs. Since all PMDs are built in pretty much the same way, the logic for building each PMD, including extracting the pmdinfo, is included in the top level build file. This means that each individual driver class only needs to specify its default dependencies and a few naming conventions, and each driver only needs to specify it's source files, headers, etc.

---
 drivers/meson.build | 121 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 meson.build         |   3 +-
 2 files changed, 123 insertions(+), 1 deletion(-)
 create mode 100644 drivers/meson.build
drivers/meson.build new file +121 -0
new file mode 100644
index 000000000..3e5046fe1
@@ -0,0 +1,121 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+driver_classes = []
+
+foreach class:driver_classes
+	drivers = []
+	std_deps = []
+	config_flag_fmt = '' # format string used to set the value in dpdk_conf
+	driver_name_fmt = '' # format string for driver name, used to name
+	                     # the library, the dependency and to find the
+	                     # version file for linking
+
+	subdir(class)
+
+	foreach drv:drivers
+		drv_path = join_paths(class, drv)
+
+		# set up empty variables used for build
+		build = true # set to false to disable, e.g. missing deps
+		version = 1
+		sources = []
+		objs = []
+		cflags = []
+		includes = [include_directories(drv_path)]
+		# set up internal deps. Drivers can append/override as necessary
+		deps = std_deps
+		# ext_deps: Stores external library dependency got
+		# using dependency() or cc.find_library(). For most cases, we
+		# probably also need to specify the "-l" flags in
+		# pkgconfig_extra_libs variable too, so that it can be reflected
+		# in the pkgconfig output for static builds
+		ext_deps = []
+		pkgconfig_extra_libs = []
+
+		# pull in driver directory which should assign to each of the above
+		subdir(drv_path)
+
+		if build
+			dpdk_conf.set(config_flag_fmt.format(drv.to_upper()),1)
+
+			# get dependency objs from strings
+			dep_objs = []
+			foreach d:deps
+				dep_objs += [get_variable('dep_rte_' + d)]
+			endforeach
+			dep_objs += ext_deps
+			dpdk_extra_ldflags += pkgconfig_extra_libs
+
+			# generate pmdinfo sources
+			pmdinfogen_srcs = run_command('grep', '--files-with-matches',
+				'RTE_PMD_REGISTER_.*(.*)', sources).stdout().strip().split()
+			foreach src: pmdinfogen_srcs
+				out_filename = '@[email protected]'.format(src.split('/')[-1])
+				tmp_lib = static_library('tmp_@0@'.format(src.underscorify()),
+					src, include_directories: includes,
+					dependencies: dep_objs,
+					c_args: cflags)
+				sources += custom_target(out_filename,
+						command: [pmdinfo, tmp_lib.full_path(),
+							'@OUTPUT@', pmdinfogen],
+						output: out_filename,
+						depends: [pmdinfogen, tmp_lib])
+			endforeach
+
+			# now build the driver itself, and add to the drivers list
+			drv_name = driver_name_fmt.format(drv)
+			version_map = '@0@/@1@/@2@_version.map'.format(
+					meson.current_source_dir(),
+					drv_path, drv_name)
+			lib = library(drv_name,
+				sources,
+				objects: objs,
+				include_directories: includes,
+				dependencies: dep_objs,
+				c_args: cflags,
+				link_args: '-Wl,--version-script=' + version_map,
+				link_depends: version_map,
+				version: '@[email protected]'.format(version),
+				install: true,
+				install_dir: driver_install_path)
+
+			dpdk_drivers += lib
+
+			# create a dependency object and add it to the global dictionary so
+			# testpmd or other built-in apps can find it if necessary
+			set_variable('dep_@0@'.format(drv_name),
+					declare_dependency(link_with: lib,
+					include_directories: includes,
+					dependencies: dep_objs))
+		endif # build
+	endforeach
+endforeach
meson.build +2 -1
index db9c1631f..ec4f1391a 100644
@@ -57,9 +57,10 @@ endif
 global_inc = include_directories('.', 'config')
 subdir('config')
 
-# build libs and (TODO) drivers
+# build libs and drivers
 subdir('lib')
 subdir('buildtools')
+subdir('drivers')
 
 # TODO build binaries and installable tools
 
Signature · 1 line
2.13.5
#94 lore raw

PATCH v3 7/17 drivers/mempool: add SW mempool drivers to meson build

In reply to Bruce Richardson

With build infrastructure in place, add in mempool drivers to the build.

---
 drivers/mempool/meson.build       | 35 +++++++++++++++++++++++++++++++++++
 drivers/mempool/ring/meson.build  | 32 ++++++++++++++++++++++++++++++++
 drivers/mempool/stack/meson.build | 32 ++++++++++++++++++++++++++++++++
 drivers/meson.build               |  2 +-
 4 files changed, 100 insertions(+), 1 deletion(-)
 create mode 100644 drivers/mempool/meson.build
 create mode 100644 drivers/mempool/ring/meson.build
 create mode 100644 drivers/mempool/stack/meson.build
drivers/mempool/meson.build new file +35 -0
new file mode 100644
index 000000000..c1bda9783
@@ -0,0 +1,35 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+drivers = ['ring', 'stack']
+std_deps = ['mempool']
+config_flag_fmt = 'RTE_LIBRTE_@0@_MEMPOOL'
+driver_name_fmt = 'rte_mempool_@0@'
drivers/mempool/ring/meson.build new file +32 -0
new file mode 100644
index 000000000..7a988f0a2
@@ -0,0 +1,32 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_mempool_ring.c')
drivers/mempool/stack/meson.build new file +32 -0
new file mode 100644
index 000000000..7b690b68d
@@ -0,0 +1,32 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_mempool_stack.c')
drivers/meson.build +1 -1
index 3e5046fe1..d8f11aa68 100644
@@ -29,7 +29,7 @@
 #   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 #   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
-driver_classes = []
+driver_classes = ['mempool']
 
 foreach class:driver_classes
 	drivers = []
Signature · 1 line
2.13.5
#95 lore raw

PATCH v3 8/17 drivers/crypto: add crypto drv class and null PMD to meson

In reply to Bruce Richardson

Add in a crypto driver class, and implement compiling the null crypto instance.

---
 drivers/crypto/meson.build      | 35 +++++++++++++++++++++++++++++++++++
 drivers/crypto/null/meson.build | 33 +++++++++++++++++++++++++++++++++
 drivers/meson.build             | 13 +++++++------
 3 files changed, 75 insertions(+), 6 deletions(-)
 create mode 100644 drivers/crypto/meson.build
 create mode 100644 drivers/crypto/null/meson.build
drivers/crypto/meson.build new file +35 -0
new file mode 100644
index 000000000..c84a9d522
@@ -0,0 +1,35 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+drivers = ['null']
+std_deps = ['cryptodev'] # cryptodev pulls in all other needed deps
+config_flag_fmt = 'RTE_LIBRTE_@0@_PMD'
+driver_name_fmt = 'rte_pmd_@0@'
drivers/crypto/null/meson.build new file +33 -0
new file mode 100644
index 000000000..ea08f783c
@@ -0,0 +1,33 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+name = 'null_crypto'
+sources = files('null_crypto_pmd.c', 'null_crypto_pmd_ops.c')
drivers/meson.build +7 -6
index d8f11aa68..be87918b2 100644
@@ -29,7 +29,7 @@
 #   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 #   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
-driver_classes = ['mempool']
+driver_classes = ['crypto', 'mempool']
 
 foreach class:driver_classes
 	drivers = []
@@ -46,6 +46,7 @@ foreach class:driver_classes
 
 		# set up empty variables used for build
 		build = true # set to false to disable, e.g. missing deps
+		name = drv
 		version = 1
 		sources = []
 		objs = []
@@ -65,7 +66,7 @@ foreach class:driver_classes
 		subdir(drv_path)
 
 		if build
-			dpdk_conf.set(config_flag_fmt.format(drv.to_upper()),1)
+			dpdk_conf.set(config_flag_fmt.format(name.to_upper()),1)
 
 			# get dependency objs from strings
 			dep_objs = []
@@ -92,11 +93,11 @@ foreach class:driver_classes
 			endforeach
 
 			# now build the driver itself, and add to the drivers list
-			drv_name = driver_name_fmt.format(drv)
+			lib_name = driver_name_fmt.format(name)
 			version_map = '@0@/@1@/@2@_version.map'.format(
 					meson.current_source_dir(),
-					drv_path, drv_name)
-			lib = library(drv_name,
+					drv_path, lib_name)
+			lib = library(lib_name,
 				sources,
 				objects: objs,
 				include_directories: includes,
@@ -112,7 +113,7 @@ foreach class:driver_classes
 
 			# create a dependency object and add it to the global dictionary so
 			# testpmd or other built-in apps can find it if necessary
-			set_variable('dep_@0@'.format(drv_name),
+			set_variable('dep_@0@'.format(lib_name),
 					declare_dependency(link_with: lib,
 					include_directories: includes,
 					dependencies: dep_objs))
Signature · 1 line
2.13.5
#96 lore raw

PATCH v3 9/17 crypto/openssl: add driver to meson build

In reply to Bruce Richardson
---
 drivers/crypto/meson.build         |  2 +-
 drivers/crypto/openssl/meson.build | 38 ++++++++++++++++++++++++++++++++++++++
 2 files changed, 39 insertions(+), 1 deletion(-)
 create mode 100644 drivers/crypto/openssl/meson.build
drivers/crypto/meson.build +1 -1
index c84a9d522..b9488e761 100644
@@ -29,7 +29,7 @@
 #   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 #   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
-drivers = ['null']
+drivers = ['null', 'openssl']
 std_deps = ['cryptodev'] # cryptodev pulls in all other needed deps
 config_flag_fmt = 'RTE_LIBRTE_@0@_PMD'
 driver_name_fmt = 'rte_pmd_@0@'
drivers/crypto/openssl/meson.build new file +38 -0
new file mode 100644
index 000000000..677d16742
@@ -0,0 +1,38 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+dep = dependency('libcrypto', required: false)
+if not dep.found()
+	build = false
+endif
+sources = files('rte_openssl_pmd.c', 'rte_openssl_pmd_ops.c')
+ext_deps += dep
+pkgconfig_extra_libs += '-lcrypto'
Signature · 1 line
2.13.5
#97 lore raw

PATCH v3 10/17 crypto/qat: add driver to meson build

In reply to Bruce Richardson
---
 config/rte_config.h            |  8 ++++++++
 drivers/crypto/meson.build     |  2 +-
 drivers/crypto/qat/meson.build | 41 +++++++++++++++++++++++++++++++++++++++++
 3 files changed, 50 insertions(+), 1 deletion(-)
 create mode 100644 drivers/crypto/qat/meson.build
config/rte_config.h +8 -0
index b47cfabae..f2009ac79 100644
@@ -94,4 +94,12 @@
 #define RTE_SCHED_PORT_N_GRINDERS 8
 #undef RTE_SCHED_VECTOR
 
+/****** driver defines ********/
+
+/*
+ * Number of sessions to create in the session memory pool
+ * on a single QuickAssist device.
+ */
+#define RTE_QAT_PMD_MAX_NB_SESSIONS 2048
+
 #endif /* _RTE_CONFIG_H_ */
drivers/crypto/meson.build +1 -1
index b9488e761..cacef1c17 100644
@@ -29,7 +29,7 @@
 #   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 #   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
-drivers = ['null', 'openssl']
+drivers = ['qat', 'null', 'openssl']
 std_deps = ['cryptodev'] # cryptodev pulls in all other needed deps
 config_flag_fmt = 'RTE_LIBRTE_@0@_PMD'
 driver_name_fmt = 'rte_pmd_@0@'
drivers/crypto/qat/meson.build new file +41 -0

41 lines not on this page · raw message

Signature · 1 line
2.13.5
#98 lore raw

PATCH v3 11/17 drivers/net: add net driver support to meson build

In reply to Bruce Richardson
---
 drivers/meson.build     |  2 +-
 drivers/net/meson.build | 35 +++++++++++++++++++++++++++++++++++
 2 files changed, 36 insertions(+), 1 deletion(-)
 create mode 100644 drivers/net/meson.build
drivers/meson.build +1 -1
index be87918b2..f19da16fb 100644
@@ -29,7 +29,7 @@
 #   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 #   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
-driver_classes = ['crypto', 'mempool']
+driver_classes = ['crypto', 'mempool', 'net']
 
 foreach class:driver_classes
 	drivers = []
drivers/net/meson.build new file +35 -0
new file mode 100644
index 000000000..d760069fb
@@ -0,0 +1,35 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+drivers = []
+std_deps = ['ethdev', 'kvargs'] # 'ethdev' also pulls in mbuf, net, eal etc
+config_flag_fmt = 'RTE_LIBRTE_@0@_PMD'
+driver_name_fmt = 'rte_pmd_@0@'
Signature · 1 line
2.13.5
#99 lore raw

PATCH v3 12/17 drivers/net: add set of vdev PMDs to build

In reply to Bruce Richardson

Add the af_packet, null, pcap and ring PMDs to the meson build.

---
 config/rte_config.h               |  4 ++++
 drivers/net/af_packet/meson.build | 35 +++++++++++++++++++++++++++++++++
 drivers/net/meson.build           |  2 +-
 drivers/net/null/meson.build      | 32 ++++++++++++++++++++++++++++++
 drivers/net/pcap/meson.build      | 41 +++++++++++++++++++++++++++++++++++++++
 drivers/net/ring/meson.build      | 33 +++++++++++++++++++++++++++++++
 6 files changed, 146 insertions(+), 1 deletion(-)
 create mode 100644 drivers/net/af_packet/meson.build
 create mode 100644 drivers/net/null/meson.build
 create mode 100644 drivers/net/pcap/meson.build
 create mode 100644 drivers/net/ring/meson.build
config/rte_config.h +4 -0
index f2009ac79..79d7e26d9 100644
@@ -102,4 +102,8 @@
  */
 #define RTE_QAT_PMD_MAX_NB_SESSIONS 2048
 
+/* Ring net PMD settings */
+#define RTE_PMD_RING_MAX_RX_RINGS 16
+#define RTE_PMD_RING_MAX_TX_RINGS 16
+
 #endif /* _RTE_CONFIG_H_ */
drivers/net/af_packet/meson.build new file +35 -0
new file mode 100644
index 000000000..f3607d768
@@ -0,0 +1,35 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+if host_machine.system() != 'linux'
+	build = false
+endif
+sources = files('rte_eth_af_packet.c')
drivers/net/meson.build +1 -1
index d760069fb..9a24bae43 100644
@@ -29,7 +29,7 @@
 #   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 #   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
-drivers = []
+drivers = ['af_packet', 'null', 'pcap', 'ring']
 std_deps = ['ethdev', 'kvargs'] # 'ethdev' also pulls in mbuf, net, eal etc
 config_flag_fmt = 'RTE_LIBRTE_@0@_PMD'
 driver_name_fmt = 'rte_pmd_@0@'
drivers/net/null/meson.build new file +32 -0
new file mode 100644
index 000000000..e90b5c5c7
@@ -0,0 +1,32 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_eth_null.c')
drivers/net/pcap/meson.build new file +41 -0

41 lines not on this page · raw message

drivers/net/ring/meson.build new file +33 -0
new file mode 100644
index 000000000..1ac2c90e7
@@ -0,0 +1,33 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+sources = files('rte_eth_ring.c')
+install_headers('rte_eth_ring.h')
Signature · 1 line
2.13.5
#100 lore raw

PATCH v3 13/17 drivers/net: add drivers for Intel NICs to meson build

In reply to Bruce Richardson

Add the e1000, fm10k, i40e and ixgbe drivers to the meson & ninja build.

---
 config/rte_config.h                | 12 +++++++
 drivers/net/e1000/base/meson.build | 65 ++++++++++++++++++++++++++++++++++++++
 drivers/net/e1000/meson.build      | 44 ++++++++++++++++++++++++++
 drivers/net/fm10k/base/meson.build | 55 ++++++++++++++++++++++++++++++++
 drivers/net/fm10k/meson.build      | 44 ++++++++++++++++++++++++++
 drivers/net/i40e/base/meson.build  | 56 ++++++++++++++++++++++++++++++++
 drivers/net/i40e/meson.build       | 60 +++++++++++++++++++++++++++++++++++
 drivers/net/ixgbe/base/meson.build | 60 +++++++++++++++++++++++++++++++++++
 drivers/net/ixgbe/meson.build      | 58 ++++++++++++++++++++++++++++++++++
 drivers/net/meson.build            |  3 +-
 10 files changed, 456 insertions(+), 1 deletion(-)
 create mode 100644 drivers/net/e1000/base/meson.build
 create mode 100644 drivers/net/e1000/meson.build
 create mode 100644 drivers/net/fm10k/base/meson.build
 create mode 100644 drivers/net/fm10k/meson.build
 create mode 100644 drivers/net/i40e/base/meson.build
 create mode 100644 drivers/net/i40e/meson.build
 create mode 100644 drivers/net/ixgbe/base/meson.build
 create mode 100644 drivers/net/ixgbe/meson.build
config/rte_config.h +12 -0
index 79d7e26d9..3e26d5118 100644
@@ -102,6 +102,18 @@
  */
 #define RTE_QAT_PMD_MAX_NB_SESSIONS 2048
 
+/* fm10k defines */
+#define RTE_LIBRTE_FM10K_RX_OLFLAGS_ENABLE 1
+
+/* i40e defines */
+#define RTE_LIBRTE_I40E_RX_ALLOW_BULK_ALLOC 1
+#undef RTE_LIBRTE_I40E_16BYTE_RX_DESC
+#define RTE_LIBRTE_I40E_QUEUE_NUM_PER_PF 64
+#define RTE_LIBRTE_I40E_QUEUE_NUM_PER_VF 4
+#define RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM 4
+/* interval up to 8160 us, aligned to 2 (or default value) */
+#define RTE_LIBRTE_I40E_ITR_INTERVAL -1
+
 /* Ring net PMD settings */
 #define RTE_PMD_RING_MAX_RX_RINGS 16
 #define RTE_PMD_RING_MAX_TX_RINGS 16
drivers/net/e1000/base/meson.build new file +65 -0

65 lines not on this page · raw message

drivers/net/e1000/meson.build new file +44 -0

44 lines not on this page · raw message

drivers/net/fm10k/base/meson.build new file +55 -0

55 lines not on this page · raw message

drivers/net/fm10k/meson.build new file +44 -0

44 lines not on this page · raw message

drivers/net/i40e/base/meson.build new file +56 -0

56 lines not on this page · raw message

drivers/net/i40e/meson.build new file +60 -0

60 lines not on this page · raw message

drivers/net/ixgbe/base/meson.build new file +60 -0

60 lines not on this page · raw message

drivers/net/ixgbe/meson.build new file +58 -0

58 lines not on this page · raw message

drivers/net/meson.build +2 -1
index 9a24bae43..d07b38b19 100644
@@ -29,7 +29,8 @@
 #   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 #   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
-drivers = ['af_packet', 'null', 'pcap', 'ring']
+drivers = ['af_packet', 'e1000', 'fm10k', 'i40e', 'ixgbe',
+	'null', 'pcap', 'ring']
 std_deps = ['ethdev', 'kvargs'] # 'ethdev' also pulls in mbuf, net, eal etc
 config_flag_fmt = 'RTE_LIBRTE_@0@_PMD'
 driver_name_fmt = 'rte_pmd_@0@'
Signature · 1 line
2.13.5
#101 lore raw

PATCH v3 14/17 app/test-pmd: add test-pmd to meson build

In reply to Bruce Richardson
---
 app/meson.build          | 32 +++++++++++++++++++++
 app/test-pmd/meson.build | 74 ++++++++++++++++++++++++++++++++++++++++++++++++
 meson.build              |  3 +-
 3 files changed, 108 insertions(+), 1 deletion(-)
 create mode 100644 app/meson.build
 create mode 100644 app/test-pmd/meson.build
app/meson.build new file +32 -0
new file mode 100644
index 000000000..da8b631f4
@@ -0,0 +1,32 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+subdir('test-pmd')
app/test-pmd/meson.build new file +74 -0

74 lines not on this page · raw message

meson.build +2 -1
index ec4f1391a..0476c4711 100644
@@ -62,7 +62,8 @@ subdir('lib')
 subdir('buildtools')
 subdir('drivers')
 
-# TODO build binaries and installable tools
+# build binaries and (TODO) installable tools
+subdir('app')
 
 # write the build config
 build_cfg = 'rte_build_config.h'
Signature · 1 line
2.13.5
#102 lore raw

PATCH v3 15/17 usertools: add usertools installation to meson build

In reply to Bruce Richardson

Have the "usertools" scripts installed when doing a DPDK install using ninja. They will be copies to $prefix/bin, generally /usr/local/bin, alongside testpmd.

---
 meson.build           |  3 ++-
 usertools/meson.build | 32 ++++++++++++++++++++++++++++++++
 2 files changed, 34 insertions(+), 1 deletion(-)
 create mode 100644 usertools/meson.build
meson.build +2 -1
index 0476c4711..6ad3e8053 100644
@@ -62,7 +62,8 @@ subdir('lib')
 subdir('buildtools')
 subdir('drivers')
 
-# build binaries and (TODO) installable tools
+# build binaries and installable tools
+subdir('usertools')
 subdir('app')
 
 # write the build config
usertools/meson.build new file +32 -0
new file mode 100644
index 000000000..c5452e3fc
@@ -0,0 +1,32 @@
+#   BSD LICENSE
+#
+#   Copyright(c) 2017 Intel Corporation.
+#   All rights reserved.
+#
+#   Redistribution and use in source and binary forms, with or without
+#   modification, are permitted provided that the following conditions
+#   are met:
+#
+#     * Redistributions of source code must retain the above copyright
+#       notice, this list of conditions and the following disclaimer.
+#     * Redistributions in binary form must reproduce the above copyright
+#       notice, this list of conditions and the following disclaimer in
+#       the documentation and/or other materials provided with the
+#       distribution.
+#     * Neither the name of Intel Corporation nor the names of its
+#       contributors may be used to endorse or promote products derived
+#       from this software without specific prior written permission.
+#
+#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+install_data(['dpdk-devbind.py', 'dpdk-pmdinfo.py'], install_dir: 'bin')
Signature · 1 line
2.13.5
#103 lore raw

PATCH v3 16/17 build: add option to version libs using DPDK version

In reply to Bruce Richardson

Normally, each library has it's own version number based on the ABI. Add an option to have all libs just use the DPDK version number as the .so version.

---
 drivers/meson.build                     | 13 ++++++++++++-
 lib/librte_eal/bsdapp/eal/meson.build   | 12 +++++++++++-
 lib/librte_eal/linuxapp/eal/meson.build | 12 +++++++++++-
 lib/meson.build                         | 12 +++++++++++-
 meson_options.txt                       |  1 +
 5 files changed, 46 insertions(+), 4 deletions(-)
drivers/meson.build +12 -1
index f19da16fb..3ea42b04b 100644
@@ -92,6 +92,16 @@ foreach class:driver_classes
 						depends: [pmdinfogen, tmp_lib])
 			endforeach
 
+			if get_option('per_library_versions')
+				lib_version = '@[email protected]'.format(version)
+				so_version = '@0@'.format(version)
+			else
+				pver = meson.project_version().split('.')
+				lib_version = '@0@.@1@'.format(pver.get(0),
+						pver.get(1))
+				so_version = lib_version
+			endif
+
 			# now build the driver itself, and add to the drivers list
 			lib_name = driver_name_fmt.format(name)
 			version_map = '@0@/@1@/@2@_version.map'.format(
@@ -105,7 +115,8 @@ foreach class:driver_classes
 				c_args: cflags,
 				link_args: '-Wl,--version-script=' + version_map,
 				link_depends: version_map,
-				version: '@[email protected]'.format(version),
+				version: lib_version,
+				soversion: so_version,
 				install: true,
 				install_dir: driver_install_path)
 
lib/librte_eal/bsdapp/eal/meson.build +11 -1
index 00973122a..f6c43fd44 100644
@@ -46,11 +46,21 @@ sources = ['eal_alarm.c',
 
 eal_extra_link_arg = '-lexecinfo'
 
+if get_option('per_library_versions')
+	lib_version = '@[email protected]'.format(version)
+	so_version = '@0@'.format(version)
+else
+	pver = meson.project_version().split('.')
+	lib_version = '@0@.@1@'.format(pver.get(0), pver.get(1))
+	so_version = lib_version
+endif
+
 version_map = join_paths(meson.current_source_dir(), 'rte_eal_version.map')
 eal_lib = library('rte_eal', sources, eal_common_sources, eal_common_arch_sources,
 			dependencies: dependency('threads'),
 			include_directories : eal_inc,
-			version: '@[email protected]'.format(version),
+			version: lib_version,
+			soversion: so_version,
 			c_args: '-D_GNU_SOURCE',
 			link_depends: version_map,
 			link_args: [eal_extra_link_arg,
lib/librte_eal/linuxapp/eal/meson.build +11 -1
index e7daed499..bffbd7e66 100644
@@ -51,11 +51,21 @@ sources = ['eal_alarm.c',
 
 eal_extra_link_arg = '-ldl'
 
+if get_option('per_library_versions')
+	lib_version = '@[email protected]'.format(version)
+	so_version = '@0@'.format(version)
+else
+	pver = meson.project_version().split('.')
+	lib_version = '@0@.@1@'.format(pver.get(0), pver.get(1))
+	so_version = lib_version
+endif
+
 version_map = join_paths(meson.current_source_dir(), 'rte_eal_version.map')
 eal_lib = library('rte_eal', sources, eal_common_sources, eal_common_arch_sources,
 			dependencies: dependency('threads'),
 			include_directories : eal_inc,
-			version: '@[email protected]'.format(version),
+			version: lib_version,
+			soversion: so_version,
 			c_args: '-D_GNU_SOURCE',
 			link_depends: version_map,
 			link_args: [eal_extra_link_arg,
lib/meson.build +11 -1
index d814721de..5244fe4a5 100644
@@ -76,6 +76,15 @@ foreach l:libraries
 			dep_objs += [get_variable('dep_rte_' + d)]
 		endforeach
 
+		if get_option('per_library_versions')
+			lib_version = '@[email protected]'.format(version)
+			so_version = '@0@'.format(version)
+		else
+			pver = meson.project_version().split('.')
+			lib_version = '@0@.@1@'.format(pver.get(0), pver.get(1))
+			so_version = lib_version
+		endif
+
 		version_map = '@0@/@1@/rte_@2@_version.map'.format(
 				meson.current_source_dir(), dir_name, name)
 		libname = 'rte_' + name
@@ -87,7 +96,8 @@ foreach l:libraries
 				include_directories: include_directories(dir_name),
 				link_args: '-Wl,--version-script=' + version_map,
 				link_depends: version_map,
-				version: '@[email protected]'.format(version),
+				version: lib_version,
+				soversion: so_version,
 				install: true)
 		dep = declare_dependency(link_with: lib,
 				include_directories: include_directories(dir_name),
meson_options.txt +1 -0
index 9c45b8159..636226ce8 100644
@@ -6,3 +6,4 @@ option('allow_invalid_socket_id', type: 'boolean', value: false,
 	description: 'allow out-of-range NUMA socket id\'s for platforms that don\'t report the value correctly')
 option('enable_kmods', type: 'boolean', value: true, description: 'build kernel modules')
 option('kernel_dir', type: 'string', value: '', description: 'path to the kernel for building kernel modules')
+option('per_library_versions', type: 'boolean', value: true, description: 'true: each lib gets its own version number, false: DPDK version used for each lib')
Signature · 1 line
2.13.5
#104 lore raw

PATCH v3 17/17 doc: add documentation on how to add new components to DPDK

In reply to Bruce Richardson

Add to the contributors guide details on how to add libraries and drivers and integrate them with the DPDK build system(s).

---
 doc/guides/contributing/coding_style.rst | 214 +++++++++++++++++++++++++++++++
 1 file changed, 214 insertions(+)
doc/guides/contributing/coding_style.rst +214 -0
index d8e4a0f9c..3c59cbca5 100644
@@ -702,3 +702,217 @@ All Python code should work with Python 2.7+ and 3.2+ and be compliant with
 `PEP8 (Style Guide for Python Code) <https://www.python.org/dev/peps/pep-0008/>`_.
 
 The ``pep8`` tool can be used for testing compliance with the guidelines.
+
+Integrating with the Build System
+---------------------------------
+
+DPDK supports being built in two different ways:
+
+* using ``make`` - or more specifically "GNU make", i.e. ``gmake`` on FreeBSD
+* using the tools ``meson`` and ``ninja``
+
+Any new library or driver to be integrated into DPDK should support being
+built with both systems. While building using ``make`` is a legacy approach, and
+most build-system enhancements are being done using ``meson`` and ``ninja``
+there are no plans at this time to deprecate the legacy ``make`` build system.
+
+Therefore all new component additions should include both a ``Makefile`` and a
+``meson.build`` file, and should be added to the component lists in both the
+``Makefile`` and ``meson.build`` files in the relevant top-level directory:
+either ``lib`` directory or a ``driver`` subdirectory.
+
+Makefile Contents
+~~~~~~~~~~~~~~~~~
+
+The ``Makefile`` for the component should be of the following format, where
+``<name>`` corresponds to the name of the library in question, e.g. hash,
+lpm, etc. For drivers, the same format of Makefile is used.
+
+.. code-block:: makefile
+
+	# pull in basic DPDK definitions, including whether library is to be
+	# built or not
+	include $(RTE_SDK)/mk/rte.vars.mk
+
+	# library name
+	LIB = librte_<name>.a
+
+	# any library cflags needed. Generally add "-O3 $(WERROR_FLAGS)"
+	CFLAGS += -O3
+	CFLAGS += $(WERROR_FLAGS)
+
+	# the symbol version information for the library, and .so version
+	EXPORT_MAP := rte_<name>_version.map
+	LIBABIVER := 1
+
+	# all source filenames are stored in SRCS-y
+	SRCS-$(CONFIG_RTE_LIBRTE_<NAME>) += rte_<name>.c
+
+	# install includes
+	SYMLINK-$(CONFIG_RTE_LIBRTE_<NAME>)-include += rte_<name>.h
+
+	# pull in rules to build the library
+	include $(RTE_SDK)/mk/rte.lib.mk
+
+Meson Build File Contents - Libraries
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+The ``meson.build`` file for a new DPDK library should be of the following basic
+format.
+
+.. code-block:: python
+
+	sources = files('file1.c', ...)
+	headers = files('file1.c', ...)
+
+
+The will build based on a number of conventions and assumptions within the DPDK
+itself, for example, that the library name is the same as the directory name in
+which the files are stored.
+
+For a library ``meson.build`` file, there are number of variables which can be
+set, some mandatory, others optional. The mandatory fields are:
+
+sources
+	**Default Value = []**.
+	This variable should list out the files to be compiled up to create the
+	library. Files must be specified using the meson ``files()`` function.
+
+
+The optional fields are:
+
+build
+	**Default Value = true.**
+	Used to optionally compile a library, based on its dependencies or
+	environment. A simple example of use would be:
+
+.. code-block:: python
+
+	if host_machine.system() != 'linux'
+	        build = false
+	endif
+
+
+cflags
+	**Default Value = []**.
+	Used to specify any additional cflags that need to be passed to compile
+	the sources in the library.
+
+deps
+	**Default Value = ['eal']**.
+	Used to list the internal library dependencies of the library. It should
+	be assigned to using ``+=`` rather than overwriting using ``=``.  The
+	dependencies should be specified as strings, each one giving the name of
+	a DPDK library, without the ``librte_`` prefix. Dependencies are handled
+	recursively, so specifying e.g. ``mempool``, will automatically also
+	make the library depend upon the mempool library's dependencies too -
+	``ring`` and ``eal``. For libraries that only depend upon EAL, this
+	variable may be omitted from the ``meson.build`` file.  For example:
+
+.. code-block:: python
+
+	deps += ['ethdev']
+
+
+ext_deps
+	**Default Value = []**.
+	Used to specify external dependencies of this library. They should be
+	returned as dependency objects, as returned from the meson
+	``dependency()`` or ``find_library()`` functions. Before returning
+	these, they should be checked to ensure the dependencies have been
+	found, and, if not, the ``build`` variable should be set to ``false``.
+	For example:
+
+.. code-block:: python
+
+	my_dep = dependency('libX', required: 'false')
+	if my_dep.found()
+		ext_deps += my_dep
+	else
+		build = false
+	endif
+
+
+headers
+	**Default Value = []**.
+	Used to return the list of header files for the library that should be
+	installed to $PREFIX/include when ``ninja install`` is run. As with
+	source files, these should be specified using the meson ``files()``
+	function.
+
+name
+	**Default Value = library name derived from the directory name**.
+	If a library's .so or .a file differs from that given in the directory
+	name, the name should be specified using this variable. In practice,
+	since the convention is that for a library called ``librte_xyz.so``, the
+	sources are stored in a directory ``lib/librte_xyz``, this value should
+	never be needed for new libraries.
+
+.. note::
+
+	The name value also provides the name used to find the function version
+	map file, as part of the build process, so if the directory name and
+	library names differ, the ``version.map`` file should be named
+	consistently with the library, not the directory
+
+objs
+	**Default Value = []**.
+	This variable can be used to pass to the library build some pre-built
+	objects that were compiled up as part of another target given in the
+	included library ``meson.build`` file.
+
+version
+	**Default Value = 1**.
+	Specifies the ABI version of the library, and is used as the major
+	version number of the resulting ``.so`` library.
+
+Meson Build File Contents - Drivers
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+For drivers, the values are largely the same as for libraries. The variables
+supported are:
+
+build
+	As above.
+
+cflags
+	As above.
+
+deps
+	As above.
+
+ext_deps
+	As above.
+
+includes
+	**Default Value = <driver directory>** Some drivers include a base
+	directory for additional source files and headers, so we have this
+	variable to allow the headers from that base directory to be found when
+	compiling driver sources. Should be appended to using ``+=`` rather than
+	overwritten using ``=``.  The values appended should be meson include
+	objects got using the ``include_directories()`` function. For example:
+
+.. code-block:: python
+
+	includes += include_directories('base')
+
+name
+	As above, though note that each driver class can define it's own naming
+	scheme for the resulting ``.so`` files.
+
+objs
+	As above, generally used for the contents of the ``base`` directory.
+
+pkgconfig_extra_libs
+	**Default Value = []**
+	This variable is used to pass additional library link flags through to
+	the DPDK pkgconfig file generated, for example, to track any additional
+	libraries that may need to be linked into the build - especially when
+	using static libraries. Anything added here will be appended to the end
+	of the ``pkgconfig --libs`` output.
+
+sources [mandatory]
+	As above
+
+version
+	As above
Signature · 1 line
2.13.5
Acked-by on the v3 series
#105 lore raw
In reply to Bruce Richardson
Quoted 270 lines · Bruce Richardson

V3 changes:
* used two-digit version numbers when globally versioning libs+drivers
* removed symlinks with single-digit version numbers in same case
* moved driver install location from $prefix/dpdk to $prefix/share/dpdk

V2 changes:
* fixed copyright notices, updated 2016 to 2017
* removed dependency on kconfig file in kernel build tree
* marked pmdinfogen as a "native" binary, in preparation for future cross-
  compilation work
* added in additional warning flags for compatibility with existing system
---

Following on from the two previous RFCs [1] [2], here is a cleaned up patchset to serve as a start-point for getting all of DPDK building with
meson and ninja.

What's covered:
* Basic infrastructure for feature detection and DPDK compilation
* Building of all DPDK libraries - as either static or shared
* Compilation of igb_uio driver for Linux
* Building a number of mempool, crypto and net drivers.
* Installation of compiled libraries and headers
* Installation of usertools scripts
* Compilation of testpmd as dpdk-testpmd and install of same
* Generation and installation of pkgconfig file for DPDK
* Contributors guide document addition describing how to add build scripts

What's not implemented:
* Just about everything else :-), including
* Support for non-x86 architectures, including cross-compilation
* Lots of PMDs
* Support for building and running the unit tests

Some key differences from RFC2:
* Removed duplication between the different driver meson files by moving
  the build logic up one level to the driver/meson.build file.
* Added a build option to allow versioning the libraries using the DPDK
  version number, rather than individual .so versions.
* Made EAL a default dependency for libs, to simplify meson.build files for
  a number of them.
* Made the build variables used for libraries and drivers more consistent.
* Moved responsibility for determining if a given driver or library should
  be built to the driver/library's own build file, giving a single place
  where all details about that component are placed, and saving having lots
  of environment detection logic in higher-level build files.
* Begun adding in developer documentation to make it easier for driver
  authors/maintainers to contribute.

Meson 0.41 and ninja are needed, and ideally meson 0.42 is recommended.
Ninja is available in most distributions, and meson - if an updated version
is not available on your distro of choice - can be easily got using
"pip3 install meson"

To build and install then use:

meson build # use default compiler and shared libs cd build
ninja
sudo ninja install

Thereafter to use DPDK in other build systems one can use:

	pkg-config --cflags DPDK
	pkt-config --libs DPDK

to query the needed DPDK build parameters.

Once reviewed and tested a bit, I hope to apply this set - or a new revision of it - to the build-next tree, to serve as a baseline for others
to use and to add the missing functionality to.

Regards,
/Bruce

[1] http://dpdk.org/ml/archives/dev/2017-June/067429.html
[2] http://dpdk.org/ml/archives/dev/2017-August/072818.html

Bruce Richardson (17):
  build: add initial infrastructure for meson & ninja builds
  eal: add eal library to meson build
  igb_uio: add igb_uio kmod to meson build
  build: add DPDK libraries to build
  build: add buildtools to meson build
  build: add infrastructure for building PMDs drivers/mempool: add SW mempool drivers to meson build drivers/crypto: add crypto drv class and null PMD to meson crypto/openssl: add driver to meson build crypto/qat: add driver to meson build drivers/net: add net driver support to meson build drivers/net: add set of vdev PMDs to build drivers/net: add drivers for Intel NICs to meson build app/test-pmd: add test-pmd to meson build
  usertools: add usertools installation to meson build
  build: add option to version libs using DPDK version
  doc: add documentation on how to add new components to DPDK

 app/meson.build                                    |  32 +++ app/test-pmd/meson.build                           |  74 +++++++ buildtools/gen-pmdinfo-cfile.sh                    |  41 ++++ buildtools/meson.build                             |  34 ++++ buildtools/pmdinfogen/meson.build                  |  36 ++++ config/meson.build                                 |  72 +++++++ config/rte_config.h                                | 121
++++++++++++
 config/x86/meson.build                             |  70 +++++++ doc/guides/contributing/coding_style.rst           | 214
+++++++++++++++++++++
 drivers/crypto/meson.build                         |  35 ++++ drivers/crypto/null/meson.build                    |  33 ++++ drivers/crypto/openssl/meson.build                 |  38 ++++ drivers/crypto/qat/meson.build                     |  41 ++++ drivers/mempool/meson.build                        |  35 ++++ drivers/mempool/ring/meson.build                   |  32 +++ drivers/mempool/stack/meson.build                  |  32 +++ drivers/meson.build                                | 133
+++++++++++++
 drivers/net/af_packet/meson.build                  |  35 ++++ drivers/net/e1000/base/meson.build                 |  65 +++++++ drivers/net/e1000/meson.build                      |  44 +++++ drivers/net/fm10k/base/meson.build                 |  55 ++++++ drivers/net/fm10k/meson.build                      |  44 +++++ drivers/net/i40e/base/meson.build                  |  56 ++++++ drivers/net/i40e/meson.build                       |  60 ++++++ drivers/net/ixgbe/base/meson.build                 |  60 ++++++ drivers/net/ixgbe/meson.build                      |  58 ++++++ drivers/net/meson.build                            |  36 ++++

 drivers/net/null/meson.build                       |  32 +++
 drivers/net/pcap/meson.build                       |  41 ++++
 drivers/net/ring/meson.build                       |  33 ++++

 lib/librte_acl/meson.build                         |  59 ++++++ lib/librte_bitratestats/meson.build                |  34 ++++ lib/librte_cfgfile/meson.build                     |  34 ++++ lib/librte_cmdline/meson.build                     |  55 ++++++ lib/librte_compat/meson.build                      |  36 ++++ lib/librte_cryptodev/meson.build                   |  40 ++++ lib/librte_distributor/meson.build                 |  39 ++++ lib/librte_eal/bsdapp/eal/meson.build              |  77 ++++++++ lib/librte_eal/bsdapp/meson.build                  |  32 +++ lib/librte_eal/common/arch/meson.build             |  33 ++++ lib/librte_eal/common/arch/x86/meson.build         |  32 +++ lib/librte_eal/common/include/arch/meson.build     |  33 ++++ lib/librte_eal/common/include/arch/x86/meson.build |  48 +++++ lib/librte_eal/common/include/meson.build          |  71 +++++++ lib/librte_eal/common/meson.build                  |  71 +++++++ lib/librte_eal/linuxapp/eal/meson.build            |  82 ++++++++ lib/librte_eal/linuxapp/igb_uio/Kbuild             |   1 + lib/librte_eal/linuxapp/igb_uio/meson.build        |  46 +++++ lib/librte_eal/linuxapp/meson.build                |  42 ++++ lib/librte_eal/meson.build                         |  44 +++++ lib/librte_efd/meson.build                         |  34 ++++ lib/librte_ether/meson.build                       |  45 +++++ lib/librte_eventdev/meson.build                    |  36 ++++ lib/librte_gro/meson.build                         |  34 ++++ lib/librte_hash/meson.build                        |  45 +++++ lib/librte_ip_frag/meson.build                     |  39 ++++ lib/librte_jobstats/meson.build                    |  33 ++++ lib/librte_kni/meson.build                         |  38 ++++ lib/librte_kvargs/meson.build                      |  34 ++++ lib/librte_latencystats/meson.build                |  34 ++++ lib/librte_lpm/meson.build                         |  35 ++++ lib/librte_mbuf/meson.build                        |  35 ++++ lib/librte_mempool/meson.build                     |  35 ++++ lib/librte_meter/meson.build                       |  33 ++++ lib/librte_metrics/meson.build                     |  33 ++++ lib/librte_net/meson.build                         |  45 +++++ lib/librte_pdump/meson.build                       |  34 ++++ lib/librte_pipeline/meson.build                    |  35 ++++ lib/librte_port/meson.build                        |  58 ++++++ lib/librte_power/meson.build                       |  37 ++++ lib/librte_reorder/meson.build                     |  34 ++++ lib/librte_ring/meson.build                        |  33 ++++

 lib/librte_sched/meson.build                       |  36 ++++
 lib/librte_table/meson.build                       |  52 +++++
 lib/librte_timer/meson.build                       |  33 ++++
 lib/librte_vhost/meson.build                       |  39 ++++

 lib/meson.build                                    | 109 +++++++++++ meson.build                                        |  88 +++++++++ meson_options.txt                                  |   9 + usertools/meson.build                              |  32 +++

 80 files changed, 3818 insertions(+)

 create mode 100644 app/meson.build
 create mode 100644 app/test-pmd/meson.build
 create mode 100755 buildtools/gen-pmdinfo-cfile.sh create mode 100644 buildtools/meson.build
 create mode 100644 buildtools/pmdinfogen/meson.build create mode 100644 config/meson.build
 create mode 100644 config/rte_config.h
 create mode 100644 config/x86/meson.build
 create mode 100644 drivers/crypto/meson.build
 create mode 100644 drivers/crypto/null/meson.build create mode 100644 drivers/crypto/openssl/meson.build create mode 100644 drivers/crypto/qat/meson.build create mode 100644 drivers/mempool/meson.build
 create mode 100644 drivers/mempool/ring/meson.build create mode 100644 drivers/mempool/stack/meson.build create mode 100644 drivers/meson.build
 create mode 100644 drivers/net/af_packet/meson.build create mode 100644 drivers/net/e1000/base/meson.build create mode 100644 drivers/net/e1000/meson.build create mode 100644 drivers/net/fm10k/base/meson.build create mode 100644 drivers/net/fm10k/meson.build create mode 100644 drivers/net/i40e/base/meson.build create mode 100644 drivers/net/i40e/meson.build
 create mode 100644 drivers/net/ixgbe/base/meson.build create mode 100644 drivers/net/ixgbe/meson.build create mode 100644 drivers/net/meson.build
 create mode 100644 drivers/net/null/meson.build
 create mode 100644 drivers/net/pcap/meson.build
 create mode 100644 drivers/net/ring/meson.build
 create mode 100644 lib/librte_acl/meson.build
 create mode 100644 lib/librte_bitratestats/meson.build create mode 100644 lib/librte_cfgfile/meson.build create mode 100644 lib/librte_cmdline/meson.build create mode 100644 lib/librte_compat/meson.build create mode 100644 lib/librte_cryptodev/meson.build create mode 100644 lib/librte_distributor/meson.build create mode 100644 lib/librte_eal/bsdapp/eal/meson.build create mode 100644 lib/librte_eal/bsdapp/meson.build create mode 100644 lib/librte_eal/common/arch/meson.build create mode 100644 lib/librte_eal/common/arch/x86/meson.build create mode 100644 lib/librte_eal/common/include/arch/meson.build create mode 100644 lib/librte_eal/common/include/arch/x86/meson.build create mode 100644 lib/librte_eal/common/include/meson.build create mode 100644 lib/librte_eal/common/meson.build create mode 100644 lib/librte_eal/linuxapp/eal/meson.build create mode 100644 lib/librte_eal/linuxapp/igb_uio/Kbuild create mode 100644 lib/librte_eal/linuxapp/igb_uio/meson.build create mode 100644 lib/librte_eal/linuxapp/meson.build create mode 100644 lib/librte_eal/meson.build
 create mode 100644 lib/librte_efd/meson.build
 create mode 100644 lib/librte_ether/meson.build
 create mode 100644 lib/librte_eventdev/meson.build create mode 100644 lib/librte_gro/meson.build
 create mode 100644 lib/librte_hash/meson.build
 create mode 100644 lib/librte_ip_frag/meson.build create mode 100644 lib/librte_jobstats/meson.build create mode 100644 lib/librte_kni/meson.build
 create mode 100644 lib/librte_kvargs/meson.build create mode 100644 lib/librte_latencystats/meson.build create mode 100644 lib/librte_lpm/meson.build
 create mode 100644 lib/librte_mbuf/meson.build
 create mode 100644 lib/librte_mempool/meson.build create mode 100644 lib/librte_meter/meson.build
 create mode 100644 lib/librte_metrics/meson.build create mode 100644 lib/librte_net/meson.build
 create mode 100644 lib/librte_pdump/meson.build
 create mode 100644 lib/librte_pipeline/meson.build create mode 100644 lib/librte_port/meson.build
 create mode 100644 lib/librte_power/meson.build
 create mode 100644 lib/librte_reorder/meson.build create mode 100644 lib/librte_ring/meson.build

Quoted 8 lines

 create mode 100644 lib/librte_sched/meson.build
 create mode 100644 lib/librte_table/meson.build
 create mode 100644 lib/librte_timer/meson.build
 create mode 100644 lib/librte_vhost/meson.build
 create mode 100644 lib/meson.build
 create mode 100644 meson.build
 create mode 100644 meson_options.txt
 create mode 100644 usertools/meson.build

Signature · 2 lines
Kind regards,
Luca Boccassi
#106 lore raw
Quoted 116 lines · Luca Boccassi
Quoted 105 lines · Bruce Richardson

V3 changes:
* used two-digit version numbers when globally versioning libs+drivers
* removed symlinks with single-digit version numbers in same case
* moved driver install location from $prefix/dpdk to $prefix/share/dpdk

V2 changes:
* fixed copyright notices, updated 2016 to 2017
* removed dependency on kconfig file in kernel build tree
* marked pmdinfogen as a "native" binary, in preparation for future cross-
  compilation work
* added in additional warning flags for compatibility with existing system
---

Following on from the two previous RFCs [1] [2], here is a cleaned up patchset to serve as a start-point for getting all of DPDK building with
meson and ninja.

What's covered:
* Basic infrastructure for feature detection and DPDK compilation
* Building of all DPDK libraries - as either static or shared
* Compilation of igb_uio driver for Linux
* Building a number of mempool, crypto and net drivers.
* Installation of compiled libraries and headers
* Installation of usertools scripts
* Compilation of testpmd as dpdk-testpmd and install of same
* Generation and installation of pkgconfig file for DPDK
* Contributors guide document addition describing how to add build scripts

What's not implemented:
* Just about everything else :-), including
* Support for non-x86 architectures, including cross-compilation
* Lots of PMDs
* Support for building and running the unit tests

Some key differences from RFC2:
* Removed duplication between the different driver meson files by moving
  the build logic up one level to the driver/meson.build file.
* Added a build option to allow versioning the libraries using the DPDK
  version number, rather than individual .so versions.
* Made EAL a default dependency for libs, to simplify meson.build files for
  a number of them.
* Made the build variables used for libraries and drivers more consistent.
* Moved responsibility for determining if a given driver or library should
  be built to the driver/library's own build file, giving a single place
  where all details about that component are placed, and saving having lots
  of environment detection logic in higher-level build files.
* Begun adding in developer documentation to make it easier for driver
  authors/maintainers to contribute.

Meson 0.41 and ninja are needed, and ideally meson 0.42 is recommended.
Ninja is available in most distributions, and meson - if an updated version
is not available on your distro of choice - can be easily got using
"pip3 install meson"

To build and install then use:

meson build # use default compiler and shared libs cd build
ninja
sudo ninja install

Thereafter to use DPDK in other build systems one can use:

	pkg-config --cflags DPDK
	pkt-config --libs DPDK

to query the needed DPDK build parameters.

Once reviewed and tested a bit, I hope to apply this set - or a new revision of it - to the build-next tree, to serve as a baseline for others
to use and to add the missing functionality to.

Regards,
/Bruce

[1] http://dpdk.org/ml/archives/dev/2017-June/067429.html
[2] http://dpdk.org/ml/archives/dev/2017-August/072818.html

Bruce Richardson (17):
  build: add initial infrastructure for meson & ninja builds
  eal: add eal library to meson build
  igb_uio: add igb_uio kmod to meson build
  build: add DPDK libraries to build
  build: add buildtools to meson build
  build: add infrastructure for building PMDs drivers/mempool: add SW mempool drivers to meson build drivers/crypto: add crypto drv class and null PMD to meson crypto/openssl: add driver to meson build

Quoted 9 lines

  crypto/qat: add driver to meson build drivers/net: add net driver support to meson build drivers/net: add set of vdev PMDs to build drivers/net: add drivers for Intel NICs to meson build app/test-pmd: add test-pmd to meson build
  usertools: add usertools installation to meson build
  build: add option to version libs using DPDK version
  doc: add documentation on how to add new components to DPDK

Quoted 2 lines

Pushed to dpdk-next-build.

Thanks to all for the reviews and acks.

/Bruce