From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 4EADFA04A5; Thu, 18 Jun 2020 02:42:38 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id E95FB4C90; Thu, 18 Jun 2020 02:42:33 +0200 (CEST) Received: from out2-smtp.messagingengine.com (out2-smtp.messagingengine.com [66.111.4.26]) by dpdk.org (Postfix) with ESMTP id 1D8692BF4 for ; Thu, 18 Jun 2020 02:42:32 +0200 (CEST) Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id C4D875C00B6; Wed, 17 Jun 2020 20:42:31 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute7.internal (MEProxy); Wed, 17 Jun 2020 20:42:31 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; s=fm1; bh=m3J4iFzPRc4eW 4Ed00qgBCx1AgThiGb9XS+tGeLUbZA=; b=EZp0wzl06VbIbPNGD0RZOa4M2QYH2 o2nWgyvzYl8XhgBFowJBmwpgL0G0FusUVFuIOvojx8SkL/7ZDckFtraTq/BaMSco DESdGyVE9HgmwkPPyswHaW2o2rTEona9+FY/TP+ITET/ZE2HvN15NJmTH0CO0pdK mZfEWLATO6WtAXlE2Cvv7mBQhdB4fiSGazEQwrKGDNRw41XvrwAKvGyweT/P4Yqx lddDA27xtfkqKbTeg4wJ6fyotfP8RFUhlUOEMeiS843llmnNiCCy3LUd1QH/xWSO ZA4dtEvbW0SQhxBgtdgMirN1cpLiYOPKyZKgXI45LbknZ0DN9Afhk/FTQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:date:from :in-reply-to:message-id:mime-version:references:subject:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; bh=m3J4iFzPRc4eW4Ed00qgBCx1AgThiGb9XS+tGeLUbZA=; b=kMRbP+eD xsGwJTehRu6axp/hhIMe6EVfmm0TLjjOAK0VlJTg2qtVjgC5SJTdr8jkJY6JCoF4 xghjFpvL/rEhdPZrfLZC8eyBRqqwouo7Bpit6/y3sYKxAKffJCf9XZ3b9AMn8hED Quchl6NNb1UyWhdAV/4n7xWJdn0LyFae6QXw3nz8hYQG4fae1x6LHzb9BEeQD/Hh tRYUEbjhmekbDBo4xg9IzgCuTNwPFZtTk1MOvLcCm0M5ZOJcnciwNdYOg1pyTK4+ YF2gUZBEJ6HXjZAMDVEPFVn+CbOEQz8WoH6ga56m2zqluJ8jvMfdD3DPgR5KoEXA BmxSCgjvoPHFZw== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedrudejfedgfeelucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufffkffojghfggfgsedtkeertdertddtnecuhfhrohhmpefvhhhomhgr shcuofhonhhjrghlohhnuceothhhohhmrghssehmohhnjhgrlhhonhdrnhgvtheqnecugg ftrfgrthhtvghrnhepvdehgfeivdejgedtveehfefhteelfefgieevgfffveefjeegtdfg uedthedtgeevnecukfhppeejjedrvddthedrudegvddruddtgeenucevlhhushhtvghruf hiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehthhhomhgrshesmhhonhhjrghl ohhnrdhnvght X-ME-Proxy: Received: from xps.monjalon.net (104.142.205.77.rev.sfr.net [77.205.142.104]) by mail.messagingengine.com (Postfix) with ESMTPA id 1C6783061856; Wed, 17 Jun 2020 20:42:29 -0400 (EDT) From: Thomas Monjalon To: dev@dpdk.org Cc: david.marchand@redhat.com, bruce.richardson@intel.com, John McNamara , Marko Kovacevic Date: Thu, 18 Jun 2020 02:42:15 +0200 Message-Id: <20200618004218.3730743-2-thomas@monjalon.net> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200618004218.3730743-1-thomas@monjalon.net> References: <20200618004218.3730743-1-thomas@monjalon.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH 1/4] doc: remove outdated guidelines for library addition X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" There was a doc about how to extend DPDK by adding a library. It could have been useful but was never updated, so it is lacking a lot of explanations about doxygen, meson, versioning, maintainership, etc. Anyway such guidelines should fit in the contributors guide. Better to completely remove this obsolete document. Signed-off-by: Thomas Monjalon --- doc/guides/prog_guide/extend_dpdk.rst | 109 -------------------------- 1 file changed, 109 deletions(-) delete mode 100644 doc/guides/prog_guide/extend_dpdk.rst diff --git a/doc/guides/prog_guide/extend_dpdk.rst b/doc/guides/prog_guide/extend_dpdk.rst deleted file mode 100644 index a3b3d300b0..0000000000 --- a/doc/guides/prog_guide/extend_dpdk.rst +++ /dev/null @@ -1,109 +0,0 @@ -.. SPDX-License-Identifier: BSD-3-Clause - Copyright(c) 2010-2014 Intel Corporation. - -Extending the DPDK -========================= - -This chapter describes how a developer can extend the DPDK to provide a new library, -a new target, or support a new target. - -Example: Adding a New Library libfoo ------------------------------------- - -To add a new library to the DPDK, proceed as follows: - -#. Add a new configuration option: - - .. code-block:: bash - - for f in config/\*; do \ - echo CONFIG_RTE_LIBFOO=y >> $f; done - -#. Create a new directory with sources: - - .. code-block:: console - - mkdir ${RTE_SDK}/lib/libfoo - touch ${RTE_SDK}/lib/libfoo/foo.c - touch ${RTE_SDK}/lib/libfoo/foo.h - -#. Add a foo() function in libfoo. - - Definition is in foo.c: - - .. code-block:: c - - void foo(void) - { - } - - Declaration is in foo.h: - - .. code-block:: c - - extern void foo(void); - - -#. Update lib/Makefile: - - .. code-block:: console - - vi ${RTE_SDK}/lib/Makefile - # add: - # DIRS-$(CONFIG_RTE_LIBFOO) += libfoo - -#. Create a new Makefile for this library, for example, derived from mempool Makefile: - - .. code-block:: console - - cp ${RTE_SDK}/lib/librte_mempool/Makefile ${RTE_SDK}/lib/libfoo/ - - vi ${RTE_SDK}/lib/libfoo/Makefile - # replace: - # librte_mempool -> libfoo - # rte_mempool -> foo - - -#. Update mk/DPDK.app.mk, and add -lfoo in LDLIBS variable when the option is enabled. - This will automatically add this flag when linking a DPDK application. - - -#. Build the DPDK with the new library (we only show a specific target here): - - .. code-block:: console - - cd ${RTE_SDK} - make config T=x86_64-native-linux-gcc - make - - -#. Check that the library is installed: - - .. code-block:: console - - ls build/lib - ls build/include - -Example: Using libfoo in the Test Application -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -The test application is used to validate all functionality of the DPDK. -Once you have added a library, a new test case should be added in the test application. - -* A new test_foo.c file should be added, that includes foo.h and calls the foo() function from test_foo(). - When the test passes, the test_foo() function should return 0. - -* Makefile, test.h and commands.c must be updated also, to handle the new test case. - -* Test report generation: autotest.py is a script that is used to generate the test report that is available in the - ${RTE_SDK}/doc/rst/test_report/autotests directory. This script must be updated also. - If libfoo is in a new test family, the links in ${RTE_SDK}/doc/rst/test_report/test_report.rst must be updated. - -* Build the DPDK with the updated test application (we only show a specific target here): - - - .. code-block:: console - - cd ${RTE_SDK} - make config T=x86_64-native-linux-gcc - make -- 2.26.2