From patchwork Wed Apr 6 17:10:10 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Kozlyuk X-Patchwork-Id: 109336 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 44CD8A0509; Wed, 6 Apr 2022 19:10:39 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B195F42852; Wed, 6 Apr 2022 19:10:33 +0200 (CEST) Received: from mail-lf1-f51.google.com (mail-lf1-f51.google.com [209.85.167.51]) by mails.dpdk.org (Postfix) with ESMTP id BEB6A4014F for ; Wed, 6 Apr 2022 19:10:31 +0200 (CEST) Received: by mail-lf1-f51.google.com with SMTP id t25so5212775lfg.7 for ; Wed, 06 Apr 2022 10:10:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=o36aRFEl77hR+F6pvDZpVJ5cRqKfmPSpnhDyp1iyr44=; b=JDtfOTyHgp1WoVSelxkyj7hH/6IwEDT6GQNVB3+Zcx48COJ9NmBbwVAD/VYbuRFP8v +odoFHXHddNmRlWjpCaMsO8AArl+c8F4cPaIdruqIX2lcinba8LixlJ9TAuI3+5QvTPy Q1jz06uRzUYt0EkIwvjjQLyCXMM8IkRKaizTIVAr6RNTZyRMrA6ePDGITdF2aY4CRjvK fJBunKhoS+S3xH79maOj25ejcauxSoamhj6eD5wyiFY6hgHvitQvlRcmzlIOnrmRGxDO h0SpEDLyE3UAnViQwHzuGok6YR8qUJGgDUQEv9Y54U1mRM6S7AMO1aP3Ho1kO7kKSr/6 NT1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=o36aRFEl77hR+F6pvDZpVJ5cRqKfmPSpnhDyp1iyr44=; b=RLCLqHiGPb92VXZGaTvdYwKX+r4pvRuJhgUDvGIQzfdPGmD8FOKN6J8SJrAbURbCgY 2AWANI86+myU2B565+9aI8JZ2KyAks1ng/k6KRVE4ZYZy5Fd6IaVDPxCeH6+clJc1pO7 9zuPV90nGP6fEt9jn79gTg9+npL4PvNMloUBODzPmRNoREdAHcgRLWirpMMeYJTfwE99 BkP/q0LDOvqhWkDcajLdr/78Tuhi/9JGCHIA2I4lQAAYpnBHM6jDD7+H8ob+/F8qnRuw yp3cd4pasX26P3XWBMg3I5jTcfGWXOTMxMZ2fV5UEnbnG3QWuq/NAWAESaXIxB23Yti7 MprA== X-Gm-Message-State: AOAM532jq5MREDSda1p51UB/zMzGTjnlqNqjhcMDZ01nfG5MJnr9bn9K LdtXBR6bxhYOV3BAdqIbS/16oAX5Hko= X-Google-Smtp-Source: ABdhPJwbVdAB35mBFdVH2rIO7ck+nGlOBjcOqXE2lLMBqzTlhg+cwVK0psk8Q3ICSwEbrVOE3Tzavw== X-Received: by 2002:a05:6512:3da1:b0:44a:2aeb:28e4 with SMTP id k33-20020a0565123da100b0044a2aeb28e4mr6410908lfv.579.1649265031007; Wed, 06 Apr 2022 10:10:31 -0700 (PDT) Received: from sovereign.. (broadband-37-110-65-23.ip.moscow.rt.ru. [37.110.65.23]) by smtp.gmail.com with ESMTPSA id e23-20020a196757000000b0044a27dced95sm1887769lfj.3.2022.04.06.10.10.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Apr 2022 10:10:30 -0700 (PDT) From: Dmitry Kozlyuk To: dev@dpdk.org Cc: Vipin Varghese , Dmitry Kozlyuk Subject: [PATCH v2 1/3] doc: simplify CSS customization for Doxygen Date: Wed, 6 Apr 2022 20:10:10 +0300 Message-Id: <20220406171012.87759-2-dmitry.kozliuk@gmail.com> X-Mailer: git-send-email 2.29.3 In-Reply-To: <20220406171012.87759-1-dmitry.kozliuk@gmail.com> References: <20220331212830.708912-1-dmitry.kozliuk@gmail.com> <20220406171012.87759-1-dmitry.kozliuk@gmail.com> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org CSS for API documentation was customized by a shell script modifying the file that Doxygen produces. This way CSS code is kept in a script and an extra build step is added. Move custom style to a plain CSS file. Use Doxygen capability to attach this extra stylesheet. Signed-off-by: Dmitry Kozlyuk --- doc/api/custom.css | 6 ++++++ doc/api/doxy-api.conf.in | 1 + doc/api/doxy-html-custom.sh | 8 -------- doc/api/generate_doxygen.sh | 3 --- doc/api/meson.build | 3 +-- 5 files changed, 8 insertions(+), 13 deletions(-) create mode 100644 doc/api/custom.css delete mode 100755 doc/api/doxy-html-custom.sh diff --git a/doc/api/custom.css b/doc/api/custom.css new file mode 100644 index 0000000000..66360f9b48 --- /dev/null +++ b/doc/api/custom.css @@ -0,0 +1,6 @@ +/* SPDX-License-Identifier: BSD-3-Clause + * Copyright 2013 6WIND S.A. + */ + +/* space between item and its comment */ +dd td:first-child { padding-right: 2em; } diff --git a/doc/api/doxy-api.conf.in b/doc/api/doxy-api.conf.in index db2ca9b6ed..8e961cbc8c 100644 --- a/doc/api/doxy-api.conf.in +++ b/doc/api/doxy-api.conf.in @@ -102,6 +102,7 @@ ALPHABETICAL_INDEX = NO HTML_TIMESTAMP = NO HTML_DYNAMIC_SECTIONS = YES +HTML_EXTRA_STYLESHEET = @TOPDIR@/doc/api/custom.css SEARCHENGINE = YES SORT_MEMBER_DOCS = NO SOURCE_BROWSER = YES diff --git a/doc/api/doxy-html-custom.sh b/doc/api/doxy-html-custom.sh deleted file mode 100755 index 3802007c8c..0000000000 --- a/doc/api/doxy-html-custom.sh +++ /dev/null @@ -1,8 +0,0 @@ -#! /bin/sh -e -# SPDX-License-Identifier: BSD-3-Clause -# Copyright 2013 6WIND S.A. - -CSS=$1 - -# space between item and its comment -echo 'dd td:first-child {padding-right: 2em;}' >> $CSS diff --git a/doc/api/generate_doxygen.sh b/doc/api/generate_doxygen.sh index 1350e50491..1940ea46e2 100755 --- a/doc/api/generate_doxygen.sh +++ b/doc/api/generate_doxygen.sh @@ -4,12 +4,9 @@ DOXYCONF=$1 OUTDIR=$2 -SCRIPTCSS=$3 OUT_FILE=$(dirname $OUTDIR)/doxygen.out # run doxygen, capturing all the header files it processed doxygen "${DOXYCONF}" > $OUT_FILE echo "$OUTDIR: $(awk '/Preprocessing/ {printf("%s ", substr($2, 1, length($2) - 3))}' $OUT_FILE)" > $OUTDIR.d - -"${SCRIPTCSS}" "${OUTDIR}"/doxygen.css diff --git a/doc/api/meson.build b/doc/api/meson.build index 5c25b92092..53338a02d6 100644 --- a/doc/api/meson.build +++ b/doc/api/meson.build @@ -13,7 +13,6 @@ endif # script to run the CSS modification afterwards generate_doxygen = find_program('generate_doxygen.sh') generate_examples = find_program('generate_examples.sh') -generate_css = find_program('doxy-html-custom.sh') htmldir = join_paths(get_option('datadir'), 'doc', 'dpdk') @@ -52,7 +51,7 @@ doxy_build = custom_target('doxygen', input: doxy_conf, output: 'html', depfile: 'html.d', - command: [generate_doxygen, '@INPUT@', '@OUTPUT@', generate_css], + command: [generate_doxygen, '@INPUT@', '@OUTPUT@'], install: get_option('enable_docs'), install_dir: htmldir, build_by_default: get_option('enable_docs')) From patchwork Wed Apr 6 17:10:11 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Kozlyuk X-Patchwork-Id: 109337 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 83A79A0509; Wed, 6 Apr 2022 19:10:45 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id CC40C42868; Wed, 6 Apr 2022 19:10:34 +0200 (CEST) Received: from mail-lf1-f47.google.com (mail-lf1-f47.google.com [209.85.167.47]) by mails.dpdk.org (Postfix) with ESMTP id 068C440E2D for ; Wed, 6 Apr 2022 19:10:33 +0200 (CEST) Received: by mail-lf1-f47.google.com with SMTP id b17so5250514lfv.3 for ; Wed, 06 Apr 2022 10:10:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=vTUwAId+UTWpaSAPDMe2dmH7BxaFlxv0JnyOIPscjJA=; b=WUhSqQ4RERfAfKkdezTG48kjwfmyQZ/Bh4xsE2i7nf9SUjYZhXOw8ZdClK2gzgKYOz SxtmZlojh9LBVTH98zokHx1zrA9ERKJm8bFxPvk/V9QzXmpKBwE3OKbyPBY2Bk7YQWGa nkepJxYems3PZ3RQjxaI49fPCAABuvCAd0nmMXNMldlW90X7wnCcA2qw4gzda+6CLL+O JBEFAF8qku8b3a31KWLUPuc8VW2cFmzNfMV3utE+0C3pmqFDcKVaaRj/NPAP41RpihDs dcH56eosOMSATo7Dhse6eLlfysIjGx/qpQvuQH8+Rv1GxsYJKCelxQ+bApCEpbQjOKbw 874w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=vTUwAId+UTWpaSAPDMe2dmH7BxaFlxv0JnyOIPscjJA=; b=QSHo8GmvtoHP55zCie3OosowU6uZhg5nJcZipwmYsH2/vUKVGs4c/VRPZo4uBTeJfS IAtb8Z3i+f6Yynnl3YbKCAKQ+dFFt+2i6Q6L+xD+2Ok2ky00kMJFfQOYoluhFuFJmPsW TvgyMciZdFKRzMlYWOgqwgl1Un1RpX2xw4Egn1mJGxjT82ml39JGh4LCqJMMG/6HrVpF uayMUOMzMjEwRpXBuzitSQBO59P6DxFXmTMBTqOmig8YeGo+LnK2wdp+unCi99kZ+zyA FVE3MVdVRQGCrFLY+sC+Jbehx9Rp/pvp+FGgj0naTuhYgphpOdHLyrfU/B0kqLp9dtVL EPvw== X-Gm-Message-State: AOAM533ZoNjJLXnbawtCWRvkGT+G1tLCc5iV5G5nbqHUa4PDy20/Tj/Z r2cw3bASONnKFPRk4kfmBllQ5dJwICQ= X-Google-Smtp-Source: ABdhPJxTiMbY/YhEGgyzCpNxPGYrBys73YngZ//ELdFZXSDlyAcNmrRLKnHXWMoR0rppeBROaNKKpw== X-Received: by 2002:a05:6512:1328:b0:445:cefe:f8b7 with SMTP id x40-20020a056512132800b00445cefef8b7mr6754016lfu.34.1649265032161; Wed, 06 Apr 2022 10:10:32 -0700 (PDT) Received: from sovereign.. (broadband-37-110-65-23.ip.moscow.rt.ru. [37.110.65.23]) by smtp.gmail.com with ESMTPSA id e23-20020a196757000000b0044a27dced95sm1887769lfj.3.2022.04.06.10.10.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Apr 2022 10:10:31 -0700 (PDT) From: Dmitry Kozlyuk To: dev@dpdk.org Cc: Vipin Varghese , Dmitry Kozlyuk , Thomas Monjalon , Olivier Matz , David Marchand Subject: [PATCH v2 2/3] doc: fix API index Markdown syntax Date: Wed, 6 Apr 2022 20:10:11 +0300 Message-Id: <20220406171012.87759-3-dmitry.kozliuk@gmail.com> X-Mailer: git-send-email 2.29.3 In-Reply-To: <20220406171012.87759-1-dmitry.kozliuk@gmail.com> References: <20220331212830.708912-1-dmitry.kozliuk@gmail.com> <20220406171012.87759-1-dmitry.kozliuk@gmail.com> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org API documentation index had spaces between link caption and URL, which may be unsupported by some Markdown implementations. That is, "[caption](URL)" is valid but "[caption] (URL)" is not. The problematic behavior is observed with Doxygen on Windows. Remove the spaces. Unfortunately, Markdown syntax is not formally specified. Fixes: 9bf486e606b0 ("doc: generate HTML for API with doxygen") Signed-off-by: Dmitry Kozlyuk --- doc/api/doxy-api-index.md | 366 +++++++++++++++++++------------------- 1 file changed, 183 insertions(+), 183 deletions(-) diff --git a/doc/api/doxy-api-index.md b/doc/api/doxy-api-index.md index 4245b9635c..baecb2e52e 100644 --- a/doc/api/doxy-api-index.md +++ b/doc/api/doxy-api-index.md @@ -9,222 +9,222 @@ API The public API headers are grouped by topics: - **device**: - [dev] (@ref rte_dev.h), - [ethdev] (@ref rte_ethdev.h), - [ethctrl] (@ref rte_eth_ctrl.h), - [rte_flow] (@ref rte_flow.h), - [rte_tm] (@ref rte_tm.h), - [rte_mtr] (@ref rte_mtr.h), - [bbdev] (@ref rte_bbdev.h), - [cryptodev] (@ref rte_cryptodev.h), - [security] (@ref rte_security.h), - [compressdev] (@ref rte_compressdev.h), - [compress] (@ref rte_comp.h), - [regexdev] (@ref rte_regexdev.h), - [dmadev] (@ref rte_dmadev.h), - [eventdev] (@ref rte_eventdev.h), - [event_eth_rx_adapter] (@ref rte_event_eth_rx_adapter.h), - [event_eth_tx_adapter] (@ref rte_event_eth_tx_adapter.h), - [event_timer_adapter] (@ref rte_event_timer_adapter.h), - [event_crypto_adapter] (@ref rte_event_crypto_adapter.h), - [rawdev] (@ref rte_rawdev.h), - [metrics] (@ref rte_metrics.h), - [bitrate] (@ref rte_bitrate.h), - [latency] (@ref rte_latencystats.h), - [devargs] (@ref rte_devargs.h), - [PCI] (@ref rte_pci.h), - [vdev] (@ref rte_bus_vdev.h), - [vfio] (@ref rte_vfio.h) + [dev](@ref rte_dev.h), + [ethdev](@ref rte_ethdev.h), + [ethctrl](@ref rte_eth_ctrl.h), + [rte_flow](@ref rte_flow.h), + [rte_tm](@ref rte_tm.h), + [rte_mtr](@ref rte_mtr.h), + [bbdev](@ref rte_bbdev.h), + [cryptodev](@ref rte_cryptodev.h), + [security](@ref rte_security.h), + [compressdev](@ref rte_compressdev.h), + [compress](@ref rte_comp.h), + [regexdev](@ref rte_regexdev.h), + [dmadev](@ref rte_dmadev.h), + [eventdev](@ref rte_eventdev.h), + [event_eth_rx_adapter](@ref rte_event_eth_rx_adapter.h), + [event_eth_tx_adapter](@ref rte_event_eth_tx_adapter.h), + [event_timer_adapter](@ref rte_event_timer_adapter.h), + [event_crypto_adapter](@ref rte_event_crypto_adapter.h), + [rawdev](@ref rte_rawdev.h), + [metrics](@ref rte_metrics.h), + [bitrate](@ref rte_bitrate.h), + [latency](@ref rte_latencystats.h), + [devargs](@ref rte_devargs.h), + [PCI](@ref rte_pci.h), + [vdev](@ref rte_bus_vdev.h), + [vfio](@ref rte_vfio.h) - **device specific**: - [softnic] (@ref rte_eth_softnic.h), - [bond] (@ref rte_eth_bond.h), - [vhost] (@ref rte_vhost.h), - [vdpa] (@ref rte_vdpa.h), - [KNI] (@ref rte_kni.h), - [ixgbe] (@ref rte_pmd_ixgbe.h), - [i40e] (@ref rte_pmd_i40e.h), - [ice] (@ref rte_pmd_ice.h), - [iavf] (@ref rte_pmd_iavf.h), - [ioat] (@ref rte_ioat_rawdev.h), - [bnxt] (@ref rte_pmd_bnxt.h), - [dpaa] (@ref rte_pmd_dpaa.h), - [dpaa2] (@ref rte_pmd_dpaa2.h), - [mlx5] (@ref rte_pmd_mlx5.h), - [dpaa2_mempool] (@ref rte_dpaa2_mempool.h), - [dpaa2_cmdif] (@ref rte_pmd_dpaa2_cmdif.h), - [dpaa2_qdma] (@ref rte_pmd_dpaa2_qdma.h), - [crypto_scheduler] (@ref rte_cryptodev_scheduler.h), - [dlb2] (@ref rte_pmd_dlb2.h), - [ifpga] (@ref rte_pmd_ifpga.h) + [softnic](@ref rte_eth_softnic.h), + [bond](@ref rte_eth_bond.h), + [vhost](@ref rte_vhost.h), + [vdpa](@ref rte_vdpa.h), + [KNI](@ref rte_kni.h), + [ixgbe](@ref rte_pmd_ixgbe.h), + [i40e](@ref rte_pmd_i40e.h), + [ice](@ref rte_pmd_ice.h), + [iavf](@ref rte_pmd_iavf.h), + [ioat](@ref rte_ioat_rawdev.h), + [bnxt](@ref rte_pmd_bnxt.h), + [dpaa](@ref rte_pmd_dpaa.h), + [dpaa2](@ref rte_pmd_dpaa2.h), + [mlx5](@ref rte_pmd_mlx5.h), + [dpaa2_mempool](@ref rte_dpaa2_mempool.h), + [dpaa2_cmdif](@ref rte_pmd_dpaa2_cmdif.h), + [dpaa2_qdma](@ref rte_pmd_dpaa2_qdma.h), + [crypto_scheduler](@ref rte_cryptodev_scheduler.h), + [dlb2](@ref rte_pmd_dlb2.h), + [ifpga](@ref rte_pmd_ifpga.h) - **memory**: - [memseg] (@ref rte_memory.h), - [memzone] (@ref rte_memzone.h), - [mempool] (@ref rte_mempool.h), - [malloc] (@ref rte_malloc.h), - [memcpy] (@ref rte_memcpy.h) + [memseg](@ref rte_memory.h), + [memzone](@ref rte_memzone.h), + [mempool](@ref rte_mempool.h), + [malloc](@ref rte_malloc.h), + [memcpy](@ref rte_memcpy.h) - **timers**: - [cycles] (@ref rte_cycles.h), - [timer] (@ref rte_timer.h), - [alarm] (@ref rte_alarm.h) + [cycles](@ref rte_cycles.h), + [timer](@ref rte_timer.h), + [alarm](@ref rte_alarm.h) - **locks**: - [atomic] (@ref rte_atomic.h), - [mcslock] (@ref rte_mcslock.h), - [pflock] (@ref rte_pflock.h), - [rwlock] (@ref rte_rwlock.h), - [spinlock] (@ref rte_spinlock.h), - [ticketlock] (@ref rte_ticketlock.h), - [RCU] (@ref rte_rcu_qsbr.h) + [atomic](@ref rte_atomic.h), + [mcslock](@ref rte_mcslock.h), + [pflock](@ref rte_pflock.h), + [rwlock](@ref rte_rwlock.h), + [spinlock](@ref rte_spinlock.h), + [ticketlock](@ref rte_ticketlock.h), + [RCU](@ref rte_rcu_qsbr.h) - **CPU arch**: - [branch prediction] (@ref rte_branch_prediction.h), - [cache prefetch] (@ref rte_prefetch.h), - [SIMD] (@ref rte_vect.h), - [byte order] (@ref rte_byteorder.h), - [CPU flags] (@ref rte_cpuflags.h), - [CPU pause] (@ref rte_pause.h), - [I/O access] (@ref rte_io.h), - [power management] (@ref rte_power_intrinsics.h) + [branch prediction](@ref rte_branch_prediction.h), + [cache prefetch](@ref rte_prefetch.h), + [SIMD](@ref rte_vect.h), + [byte order](@ref rte_byteorder.h), + [CPU flags](@ref rte_cpuflags.h), + [CPU pause](@ref rte_pause.h), + [I/O access](@ref rte_io.h), + [power management](@ref rte_power_intrinsics.h) - **CPU multicore**: - [interrupts] (@ref rte_interrupts.h), - [launch] (@ref rte_launch.h), - [lcore] (@ref rte_lcore.h), - [per-lcore] (@ref rte_per_lcore.h), - [service cores] (@ref rte_service.h), - [keepalive] (@ref rte_keepalive.h), - [power/freq] (@ref rte_power.h), - [PMD power] (@ref rte_power_pmd_mgmt.h) + [interrupts](@ref rte_interrupts.h), + [launch](@ref rte_launch.h), + [lcore](@ref rte_lcore.h), + [per-lcore](@ref rte_per_lcore.h), + [service cores](@ref rte_service.h), + [keepalive](@ref rte_keepalive.h), + [power/freq](@ref rte_power.h), + [PMD power](@ref rte_power_pmd_mgmt.h) - **layers**: - [ethernet] (@ref rte_ether.h), - [ARP] (@ref rte_arp.h), - [HIGIG] (@ref rte_higig.h), - [ICMP] (@ref rte_icmp.h), - [ESP] (@ref rte_esp.h), - [IPsec] (@ref rte_ipsec.h), - [IPsec group] (@ref rte_ipsec_group.h), - [IPsec SA] (@ref rte_ipsec_sa.h), - [IPsec SAD] (@ref rte_ipsec_sad.h), - [IP] (@ref rte_ip.h), - [frag/reass] (@ref rte_ip_frag.h), - [SCTP] (@ref rte_sctp.h), - [TCP] (@ref rte_tcp.h), - [UDP] (@ref rte_udp.h), - [GTP] (@ref rte_gtp.h), - [GRO] (@ref rte_gro.h), - [GSO] (@ref rte_gso.h), - [GRE] (@ref rte_gre.h), - [MPLS] (@ref rte_mpls.h), - [VXLAN] (@ref rte_vxlan.h), - [Geneve] (@ref rte_geneve.h), - [eCPRI] (@ref rte_ecpri.h), - [L2TPv2] (@ref rte_l2tpv2.h), - [PPP] (@ref rte_ppp.h) + [ethernet](@ref rte_ether.h), + [ARP](@ref rte_arp.h), + [HIGIG](@ref rte_higig.h), + [ICMP](@ref rte_icmp.h), + [ESP](@ref rte_esp.h), + [IPsec](@ref rte_ipsec.h), + [IPsec group](@ref rte_ipsec_group.h), + [IPsec SA](@ref rte_ipsec_sa.h), + [IPsec SAD](@ref rte_ipsec_sad.h), + [IP](@ref rte_ip.h), + [frag/reass](@ref rte_ip_frag.h), + [SCTP](@ref rte_sctp.h), + [TCP](@ref rte_tcp.h), + [UDP](@ref rte_udp.h), + [GTP](@ref rte_gtp.h), + [GRO](@ref rte_gro.h), + [GSO](@ref rte_gso.h), + [GRE](@ref rte_gre.h), + [MPLS](@ref rte_mpls.h), + [VXLAN](@ref rte_vxlan.h), + [Geneve](@ref rte_geneve.h), + [eCPRI](@ref rte_ecpri.h), + [L2TPv2](@ref rte_l2tpv2.h), + [PPP](@ref rte_ppp.h) - **QoS**: - [metering] (@ref rte_meter.h), - [scheduler] (@ref rte_sched.h), - [RED congestion] (@ref rte_red.h) + [metering](@ref rte_meter.h), + [scheduler](@ref rte_sched.h), + [RED congestion](@ref rte_red.h) - **routing**: - [LPM IPv4 route] (@ref rte_lpm.h), - [LPM IPv6 route] (@ref rte_lpm6.h), - [RIB IPv4] (@ref rte_rib.h), - [RIB IPv6] (@ref rte_rib6.h), - [FIB IPv4] (@ref rte_fib.h), - [FIB IPv6] (@ref rte_fib6.h) + [LPM IPv4 route](@ref rte_lpm.h), + [LPM IPv6 route](@ref rte_lpm6.h), + [RIB IPv4](@ref rte_rib.h), + [RIB IPv6](@ref rte_rib6.h), + [FIB IPv4](@ref rte_fib.h), + [FIB IPv6](@ref rte_fib6.h) - **hashes**: - [hash] (@ref rte_hash.h), - [jhash] (@ref rte_jhash.h), - [thash] (@ref rte_thash.h), - [thash_gfni] (@ref rte_thash_gfni.h), - [FBK hash] (@ref rte_fbk_hash.h), - [CRC hash] (@ref rte_hash_crc.h) + [hash](@ref rte_hash.h), + [jhash](@ref rte_jhash.h), + [thash](@ref rte_thash.h), + [thash_gfni](@ref rte_thash_gfni.h), + [FBK hash](@ref rte_fbk_hash.h), + [CRC hash](@ref rte_hash_crc.h) - **classification** - [reorder] (@ref rte_reorder.h), - [distributor] (@ref rte_distributor.h), - [EFD] (@ref rte_efd.h), - [ACL] (@ref rte_acl.h), - [member] (@ref rte_member.h), - [flow classify] (@ref rte_flow_classify.h), - [BPF] (@ref rte_bpf.h) + [reorder](@ref rte_reorder.h), + [distributor](@ref rte_distributor.h), + [EFD](@ref rte_efd.h), + [ACL](@ref rte_acl.h), + [member](@ref rte_member.h), + [flow classify](@ref rte_flow_classify.h), + [BPF](@ref rte_bpf.h) - **containers**: - [mbuf] (@ref rte_mbuf.h), - [mbuf pool ops] (@ref rte_mbuf_pool_ops.h), - [ring] (@ref rte_ring.h), - [stack] (@ref rte_stack.h), - [tailq] (@ref rte_tailq.h), - [bitmap] (@ref rte_bitmap.h) + [mbuf](@ref rte_mbuf.h), + [mbuf pool ops](@ref rte_mbuf_pool_ops.h), + [ring](@ref rte_ring.h), + [stack](@ref rte_stack.h), + [tailq](@ref rte_tailq.h), + [bitmap](@ref rte_bitmap.h) - **packet framework**: - * [port] (@ref rte_port.h): - [ethdev] (@ref rte_port_ethdev.h), - [ring] (@ref rte_port_ring.h), - [frag] (@ref rte_port_frag.h), - [reass] (@ref rte_port_ras.h), - [sched] (@ref rte_port_sched.h), - [kni] (@ref rte_port_kni.h), - [src/sink] (@ref rte_port_source_sink.h) - * [table] (@ref rte_table.h): - [lpm IPv4] (@ref rte_table_lpm.h), - [lpm IPv6] (@ref rte_table_lpm_ipv6.h), - [ACL] (@ref rte_table_acl.h), - [hash] (@ref rte_table_hash.h), - [array] (@ref rte_table_array.h), - [stub] (@ref rte_table_stub.h) - * [pipeline] (@ref rte_pipeline.h) - [port_in_action] (@ref rte_port_in_action.h) - [table_action] (@ref rte_table_action.h) + * [port](@ref rte_port.h): + [ethdev](@ref rte_port_ethdev.h), + [ring](@ref rte_port_ring.h), + [frag](@ref rte_port_frag.h), + [reass](@ref rte_port_ras.h), + [sched](@ref rte_port_sched.h), + [kni](@ref rte_port_kni.h), + [src/sink](@ref rte_port_source_sink.h) + * [table](@ref rte_table.h): + [lpm IPv4](@ref rte_table_lpm.h), + [lpm IPv6](@ref rte_table_lpm_ipv6.h), + [ACL](@ref rte_table_acl.h), + [hash](@ref rte_table_hash.h), + [array](@ref rte_table_array.h), + [stub](@ref rte_table_stub.h) + * [pipeline](@ref rte_pipeline.h) + [port_in_action](@ref rte_port_in_action.h) + [table_action](@ref rte_table_action.h) * SWX pipeline: - [control] (@ref rte_swx_ctl.h), - [extern] (@ref rte_swx_extern.h), - [pipeline] (@ref rte_swx_pipeline.h) + [control](@ref rte_swx_ctl.h), + [extern](@ref rte_swx_extern.h), + [pipeline](@ref rte_swx_pipeline.h) * SWX port: - [port] (@ref rte_swx_port.h), - [ethdev] (@ref rte_swx_port_ethdev.h), - [fd] (@ref rte_swx_port_fd.h), - [ring] (@ref rte_swx_port_ring.h), - [src/sink] (@ref rte_swx_port_source_sink.h) + [port](@ref rte_swx_port.h), + [ethdev](@ref rte_swx_port_ethdev.h), + [fd](@ref rte_swx_port_fd.h), + [ring](@ref rte_swx_port_ring.h), + [src/sink](@ref rte_swx_port_source_sink.h) * SWX table: - [table] (@ref rte_swx_table.h), - [table_em] (@ref rte_swx_table_em.h) - [table_wm] (@ref rte_swx_table_wm.h) - * [graph] (@ref rte_graph.h): - [graph_worker] (@ref rte_graph_worker.h) + [table](@ref rte_swx_table.h), + [table_em](@ref rte_swx_table_em.h) + [table_wm](@ref rte_swx_table_wm.h) + * [graph](@ref rte_graph.h): + [graph_worker](@ref rte_graph_worker.h) * graph_nodes: - [eth_node] (@ref rte_node_eth_api.h), - [ip4_node] (@ref rte_node_ip4_api.h) + [eth_node](@ref rte_node_eth_api.h), + [ip4_node](@ref rte_node_ip4_api.h) - **basic**: - [bitops] (@ref rte_bitops.h), - [approx fraction] (@ref rte_approx.h), - [random] (@ref rte_random.h), - [config file] (@ref rte_cfgfile.h), - [key/value args] (@ref rte_kvargs.h), - [string] (@ref rte_string_fns.h) + [bitops](@ref rte_bitops.h), + [approx fraction](@ref rte_approx.h), + [random](@ref rte_random.h), + [config file](@ref rte_cfgfile.h), + [key/value args](@ref rte_kvargs.h), + [string](@ref rte_string_fns.h) - **debug**: - [jobstats] (@ref rte_jobstats.h), - [telemetry] (@ref rte_telemetry.h), - [pcapng] (@ref rte_pcapng.h), - [pdump] (@ref rte_pdump.h), - [hexdump] (@ref rte_hexdump.h), - [debug] (@ref rte_debug.h), - [log] (@ref rte_log.h), - [errno] (@ref rte_errno.h), - [trace] (@ref rte_trace.h), - [trace_point] (@ref rte_trace_point.h) + [jobstats](@ref rte_jobstats.h), + [telemetry](@ref rte_telemetry.h), + [pcapng](@ref rte_pcapng.h), + [pdump](@ref rte_pdump.h), + [hexdump](@ref rte_hexdump.h), + [debug](@ref rte_debug.h), + [log](@ref rte_log.h), + [errno](@ref rte_errno.h), + [trace](@ref rte_trace.h), + [trace_point](@ref rte_trace_point.h) - **misc**: - [EAL config] (@ref rte_eal.h), - [common] (@ref rte_common.h), - [experimental APIs] (@ref rte_compat.h), - [ABI versioning] (@ref rte_function_versioning.h), - [version] (@ref rte_version.h) + [EAL config](@ref rte_eal.h), + [common](@ref rte_common.h), + [experimental APIs](@ref rte_compat.h), + [ABI versioning](@ref rte_function_versioning.h), + [version](@ref rte_version.h) From patchwork Wed Apr 6 17:10:12 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Kozlyuk X-Patchwork-Id: 109338 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 35384A0509; Wed, 6 Apr 2022 19:10:51 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id AB8F64286E; Wed, 6 Apr 2022 19:10:36 +0200 (CEST) Received: from mail-lj1-f172.google.com (mail-lj1-f172.google.com [209.85.208.172]) by mails.dpdk.org (Postfix) with ESMTP id 501454286E for ; Wed, 6 Apr 2022 19:10:35 +0200 (CEST) Received: by mail-lj1-f172.google.com with SMTP id m12so4108843ljp.8 for ; Wed, 06 Apr 2022 10:10:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=9k5RzIJZwwc4N98B7exJ7WTuOoaC0sDoGJjjho5TcS0=; b=B1/w/kzecjJOggsoH0nZllOmMDOcj/AyS8ACGIGJvAZt0N2ckUG5xQhh8CYaEJobBs paXsCxdR7T9DnqxTqFcg01SuWWoLorq8Gy7gWGzDURrM7QjobHT05QAKZHoE6uaFMHYm JhQ9YnID2hldvFS9sj7dEbRU88ZgrNYUErRxe+xwuDCnKg/3Zmq1E7WM0//i6UoTCE0Q 3XQ5EVMRvrWIDHF+YvTJLzC8l3krd0dlMoJIfdNW2mncD/4JWjOjRJVV2LrB8csjBoHm eVGVh0t0teJefzZIZaZlmprC5CIeh8VS9YdBW0X0vrstTSmtMOL7dSplYH5vewIj1Y4j Q3lg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=9k5RzIJZwwc4N98B7exJ7WTuOoaC0sDoGJjjho5TcS0=; b=aj05P3XyRrGuDZI5miVvei3FnD++WyZdcRwROXBhHC2UUQuhNUBiwsJb1+b5av/AXs 1wk4pjUDvNM1jLy8Jl+H/6hObkHps3bguosZstrojyUDsWbsZHLKvxCbfu8yB/CYo1QR /8L+sOn+ir0amyGN5FzroTPCkJcb6MdkfjpKFzKHncxr5SQCAVeSZKmdjWa6+fep98gT Qlz9kMp7/1V/MEpHTnrRXIcDNKmRF7DEU3q5/tOkkvKH8nsjCh6+VKh20DSKPfiR8sgr ifotY5xvmBy8XGIZIAn1c74+G5wEE3LngO1CHeFhDFI305dBS+AaOtZi4taNau8Jj9CJ MoLw== X-Gm-Message-State: AOAM530LCMnpXYwQ8y7ejjnU6F0d8RubWyh4IhCq/WdRijGxc5ZbShY3 0u1f/Vva3sIL07xVSkF+uBJ1Ga46oNQ= X-Google-Smtp-Source: ABdhPJyqr/FYFylpc+n6p4Ot5Ko/mF1w1SYZxEv0FMiOl2nX/8gMn9omp9XltBWA/dio7lWo6GUF8g== X-Received: by 2002:a2e:bc1e:0:b0:249:896f:6dbf with SMTP id b30-20020a2ebc1e000000b00249896f6dbfmr6022291ljf.180.1649265033203; Wed, 06 Apr 2022 10:10:33 -0700 (PDT) Received: from sovereign.. (broadband-37-110-65-23.ip.moscow.rt.ru. [37.110.65.23]) by smtp.gmail.com with ESMTPSA id e23-20020a196757000000b0044a27dced95sm1887769lfj.3.2022.04.06.10.10.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Apr 2022 10:10:32 -0700 (PDT) From: Dmitry Kozlyuk To: dev@dpdk.org Cc: Vipin Varghese , Dmitry Kozlyuk , Bruce Richardson Subject: [PATCH v2 3/3] doc: rewrite shell scripts in Python Date: Wed, 6 Apr 2022 20:10:12 +0300 Message-Id: <20220406171012.87759-4-dmitry.kozliuk@gmail.com> X-Mailer: git-send-email 2.29.3 In-Reply-To: <20220406171012.87759-1-dmitry.kozliuk@gmail.com> References: <20220331212830.708912-1-dmitry.kozliuk@gmail.com> <20220406171012.87759-1-dmitry.kozliuk@gmail.com> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Shell used in documentation generation could not run on Windows. Rewrite scripts in Python. New scripts use proper path separators and handle paths with spaces. Signed-off-by: Dmitry Kozlyuk Reviewed-by: Bruce Richardson --- doc/api/generate_doxygen.py | 19 +++++++++++++++++++ doc/api/generate_doxygen.sh | 12 ------------ doc/api/generate_examples.py | 31 +++++++++++++++++++++++++++++++ doc/api/generate_examples.sh | 20 -------------------- doc/api/meson.build | 6 +++--- 5 files changed, 53 insertions(+), 35 deletions(-) create mode 100644 doc/api/generate_doxygen.py delete mode 100755 doc/api/generate_doxygen.sh create mode 100644 doc/api/generate_examples.py delete mode 100755 doc/api/generate_examples.sh diff --git a/doc/api/generate_doxygen.py b/doc/api/generate_doxygen.py new file mode 100644 index 0000000000..2ccedf844e --- /dev/null +++ b/doc/api/generate_doxygen.py @@ -0,0 +1,19 @@ +#!/usr/bin/env python3 +# SPDX-License-Identifier: BSD-3-Clause +# (c) 2018 Luca Boccassi +# (c) 2022 Dmitry Kozlyuk + +import os, re, subprocess, sys + +pattern = re.compile('^Preprocessing (.*)...$') +out_dir, *doxygen_command = sys.argv[1:] +out_file = os.path.join(os.path.dirname(out_dir), 'doxygen.out') +dep_file = f'{out_dir}.d' +with open(out_file, 'w') as out: + subprocess.run(doxygen_command, check=True, stdout=out) +with open(out_file) as out, open(dep_file, 'w') as dep: + print(f'{out_dir}:', end=' ', file=dep) + for line in out: + match = re.match(pattern, line) + if match: + print(match.group(1), end=' ', file=dep) diff --git a/doc/api/generate_doxygen.sh b/doc/api/generate_doxygen.sh deleted file mode 100755 index 1940ea46e2..0000000000 --- a/doc/api/generate_doxygen.sh +++ /dev/null @@ -1,12 +0,0 @@ -#! /bin/sh -e -# SPDX-License-Identifier: BSD-3-Clause -# Copyright 2018 Luca Boccassi - -DOXYCONF=$1 -OUTDIR=$2 - -OUT_FILE=$(dirname $OUTDIR)/doxygen.out - -# run doxygen, capturing all the header files it processed -doxygen "${DOXYCONF}" > $OUT_FILE -echo "$OUTDIR: $(awk '/Preprocessing/ {printf("%s ", substr($2, 1, length($2) - 3))}' $OUT_FILE)" > $OUTDIR.d diff --git a/doc/api/generate_examples.py b/doc/api/generate_examples.py new file mode 100644 index 0000000000..c35e72f280 --- /dev/null +++ b/doc/api/generate_examples.py @@ -0,0 +1,31 @@ +#!/usr/bin/env python3 +# SPDX-License-Identifier: BSD-3-Clause +# (c) 2018 Luca Boccassi +# (c) 2022 Dmitry Kozlyuk + +import os, sys + +examples_dir, api_examples = sys.argv[1:] + +sources = [] +with open(f'{api_examples}.d', 'w') as dep: + print(f'{api_examples}:', end=' ', file=dep) + for root, _, files in os.walk(examples_dir): + for name in files: + is_source = name.endswith('.c') + if is_source or name == 'meson.build': + path = os.path.join(root, name) + if is_source: + sources.append(path) + print(path , end=' ', file=dep) + +with open(api_examples, 'w') as out: + print('''/** +@page examples DPDK Example Programs +''', file=out) + for path in sources: + # Produce consistent output with forward slashes on all systems. + # Every \ in paths within examples directory is a separator, not escape. + relpath = os.path.relpath(path, examples_dir).replace('\\', '/') + print(f'@example examples/{relpath}', file=out) + print('*/', file=out) diff --git a/doc/api/generate_examples.sh b/doc/api/generate_examples.sh deleted file mode 100755 index 48574563ca..0000000000 --- a/doc/api/generate_examples.sh +++ /dev/null @@ -1,20 +0,0 @@ -#! /bin/sh -e -# SPDX-License-Identifier: BSD-3-Clause -# Copyright 2018 Luca Boccassi - -EXAMPLES_DIR=$1 -API_EXAMPLES=$2 - -FIND=find - -# generate a .d file including both C files and also build files, so we can -# detect both file changes and file additions/deletions -echo "$API_EXAMPLES: $($FIND ${EXAMPLES_DIR} -type f \( -name '*.c' -o -name 'meson.build' \) | tr '\n' ' ' )" > ${API_EXAMPLES}.d - -exec > "${API_EXAMPLES}" -printf '/**\n' -printf '@page examples DPDK Example Programs\n\n' -$FIND "${EXAMPLES_DIR}" -type f -name '*.c' | - sed "s|${EXAMPLES_DIR}|@example examples|" | - LC_ALL=C sort -printf '*/\n' diff --git a/doc/api/meson.build b/doc/api/meson.build index 53338a02d6..2876a78a7e 100644 --- a/doc/api/meson.build +++ b/doc/api/meson.build @@ -11,8 +11,8 @@ endif # is in a subdirectory that is created at build time and thus it cannot # be an individual custom_target, we need to wrap the doxygen call in a # script to run the CSS modification afterwards -generate_doxygen = find_program('generate_doxygen.sh') -generate_examples = find_program('generate_examples.sh') +generate_doxygen = py3 + files('generate_doxygen.py') +generate_examples = py3 + files('generate_examples.py') htmldir = join_paths(get_option('datadir'), 'doc', 'dpdk') @@ -51,7 +51,7 @@ doxy_build = custom_target('doxygen', input: doxy_conf, output: 'html', depfile: 'html.d', - command: [generate_doxygen, '@INPUT@', '@OUTPUT@'], + command: [generate_doxygen, '@OUTPUT@', doxygen, '@INPUT@'], install: get_option('enable_docs'), install_dir: htmldir, build_by_default: get_option('enable_docs'))