From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id D5AC5A0A05; Tue, 19 Jan 2021 13:45:01 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7BC97140E11; Tue, 19 Jan 2021 13:45:01 +0100 (CET) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by mails.dpdk.org (Postfix) with ESMTP id 8E0C7140E0D for ; Tue, 19 Jan 2021 13:44:59 +0100 (CET) IronPort-SDR: BNr6AUBlX5GBDSOdYFCZfPMZjt7YYYpmNcTRxrr3+S4rTNhjKbTYv+OL37EzMVNJ2EBb/kTfR4 gxaBRhLxFuag== X-IronPort-AV: E=McAfee;i="6000,8403,9868"; a="158691452" X-IronPort-AV: E=Sophos;i="5.79,358,1602572400"; d="scan'208";a="158691452" Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Jan 2021 04:44:56 -0800 IronPort-SDR: O0AxzcSbcnH6e+uRB4Wz+0xHtwpeFnVTBjZvXSGAtbwRkIzLdb6jOm8r/8ooqIifXfhexiqksL +v5nrxNrmbpA== X-IronPort-AV: E=Sophos;i="5.79,358,1602572400"; d="scan'208";a="426452813" Received: from bricha3-mobl.ger.corp.intel.com ([10.252.18.163]) by orsmga001-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-SHA; 19 Jan 2021 04:44:55 -0800 Date: Tue, 19 Jan 2021 12:44:51 +0000 From: Bruce Richardson To: Truring Team Cc: dev@dpdk.org Message-ID: <20210119124451.GE1786@bricha3-MOBL.ger.corp.intel.com> References: <20210119104010.GC1786@bricha3-MOBL.ger.corp.intel.com> <20210119104204.GD1786@bricha3-MOBL.ger.corp.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Subject: Re: [dpdk-dev] DPDK 20.11 Static vs Dynamic Linking- l2fwd issue 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 Sender: "dev" On Tue, Jan 19, 2021 at 04:54:28PM +0530, Truring Team wrote: > export PKG_CONFIG_PATH=/usr/local/lib64/pkgconfig > pkg-config --static --libs libdpdk > -Wl,--whole-archive -Wl,--no-whole-archive -Wl,--as-needed -pthread This line is the source of the problem, since pkg-config is re-arranging the flags from the DPDK pkg-config file, and putting the whole-archive/no-whole-archive flags together rather than arround the list of drivers. It's a known issue, but is sadly outside of DPDK control. Can you perhaps upgrade your copy of pkg-config, or maybe put a newer copy of pkg-config or pkgconf in your home directory? The example makefile will take the path to an alternate pkg-config implementation via the "PKGCONF" env variable. Failing that, the only other option is to copy-paste the pkg-config output directly into the makefile and fix the ordering so that the --no-whole-archive flag comes after the list of drivers. The output from my system is shown below if you want to use that as a reference. (Using it directly is probably not advised as the dependencies and drivers available are likely different on your system) Regards, /Bruce -Wl,--whole-archive -L/usr/local/lib/x86_64-linux-gnu -l:librte_common_cpt.a -l:librte_common_dpaax.a -l:librte_common_iavf.a -l:librte_common_octeontx.a -l:librte_common_octeontx2.a -l:librte_common_sfc_efx.a -l:librte_bus_dpaa.a -l:librte_bus_fslmc.a -l:librte_bus_ifpga.a -l:librte_bus_pci.a -l:librte_bus_vdev.a -l:librte_bus_vmbus.a -l:librte_common_mlx5.a -l:librte_common_qat.a -l:librte_mempool_bucket.a -l:librte_mempool_dpaa.a -l:librte_mempool_dpaa2.a -l:librte_mempool_octeontx.a -l:librte_mempool_octeontx2.a -l:librte_mempool_ring.a -l:librte_mempool_stack.a -l:librte_net_af_packet.a -l:librte_net_af_xdp.a -l:librte_net_ark.a -l:librte_net_atlantic.a -l:librte_net_avp.a -l:librte_net_axgbe.a -l:librte_net_bond.a -l:librte_net_bnx2x.a -l:librte_net_bnxt.a -l:librte_net_cxgbe.a -l:librte_net_dpaa.a -l:librte_net_dpaa2.a -l:librte_net_e1000.a -l:librte_net_ena.a -l:librte_net_enetc.a -l:librte_net_enic.a -l:librte_net_failsafe.a -l:librte_net_fm10k.a -l:librte_net_i40e.a -l:librte_net_hinic.a -l:librte_net_hns3.a -l:librte_net_iavf.a -l:librte_net_ice.a -l:librte_net_igc.a -l:librte_net_ipn3ke.a -l:librte_net_ixgbe.a -l:librte_net_kni.a -l:librte_net_liquidio.a -l:librte_net_memif.a -l:librte_net_mlx4.a -l:librte_net_mlx5.a -l:librte_net_netvsc.a -l:librte_net_nfp.a -l:librte_net_null.a -l:librte_net_octeontx.a -l:librte_net_octeontx2.a -l:librte_net_pcap.a -l:librte_net_pfe.a -l:librte_net_qede.a -l:librte_net_ring.a -l:librte_net_sfc.a -l:librte_net_softnic.a -l:librte_net_tap.a -l:librte_net_thunderx.a -l:librte_net_txgbe.a -l:librte_net_vdev_netvsc.a -l:librte_net_vhost.a -l:librte_net_virtio.a -l:librte_net_vmxnet3.a -l:librte_raw_dpaa2_cmdif.a -l:librte_raw_dpaa2_qdma.a -l:librte_raw_ifpga.a -l:librte_raw_ioat.a -l:librte_raw_ntb.a -l:librte_raw_octeontx2_dma.a -l:librte_raw_octeontx2_ep.a -l:librte_raw_skeleton.a -l:librte_crypto_aesni_gcm.a -l:librte_crypto_aesni_mb.a -l:librte_crypto_bcmfs.a -l:librte_crypto_caam_jr.a -l:librte_crypto_ccp.a -l:librte_crypto_dpaa_sec.a -l:librte_crypto_dpaa2_sec.a -l:librte_crypto_kasumi.a -l:librte_crypto_nitrox.a -l:librte_crypto_null.a -l:librte_crypto_octeontx.a -l:librte_crypto_octeontx2.a -l:librte_crypto_openssl.a -l:librte_crypto_scheduler.a -l:librte_crypto_snow3g.a -l:librte_crypto_virtio.a -l:librte_crypto_zuc.a -l:librte_compress_isal.a -l:librte_compress_octeontx.a -l:librte_compress_zlib.a -l:librte_regex_mlx5.a -l:librte_regex_octeontx2.a -l:librte_vdpa_ifc.a -l:librte_vdpa_mlx5.a -l:librte_event_dlb.a -l:librte_event_dlb2.a -l:librte_event_dpaa.a -l:librte_event_dpaa2.a -l:librte_event_octeontx2.a -l:librte_event_opdl.a -l:librte_event_skeleton.a -l:librte_event_sw.a -l:librte_event_dsw.a -l:librte_event_octeontx.a -l:librte_baseband_null.a -l:librte_baseband_turbo_sw.a -l:librte_baseband_fpga_lte_fec.a -l:librte_baseband_fpga_5gnr_fec.a -l:librte_baseband_acc100.a -l:librte_node.a -l:librte_graph.a -l:librte_bpf.a -l:librte_flow_classify.a -l:librte_pipeline.a -l:librte_table.a -l:librte_port.a -l:librte_fib.a -l:librte_ipsec.a -l:librte_vhost.a -l:librte_stack.a -l:librte_security.a -l:librte_sched.a -l:librte_reorder.a -l:librte_rib.a -l:librte_regexdev.a -l:librte_rawdev.a -l:librte_pdump.a -l:librte_power.a -l:librte_member.a -l:librte_lpm.a -l:librte_latencystats.a -l:librte_kni.a -l:librte_jobstats.a -l:librte_ip_frag.a -l:librte_gso.a -l:librte_gro.a -l:librte_eventdev.a -l:librte_efd.a -l:librte_distributor.a -l:librte_cryptodev.a -l:librte_compressdev.a -l:librte_cfgfile.a -l:librte_bitratestats.a -l:librte_bbdev.a -l:librte_acl.a -l:librte_timer.a -l:librte_hash.a -l:librte_metrics.a -l:librte_cmdline.a -l:librte_pci.a -l:librte_ethdev.a -l:librte_meter.a -l:librte_net.a -l:librte_mbuf.a -l:librte_mempool.a -l:librte_rcu.a -l:librte_ring.a -l:librte_eal.a -l:librte_telemetry.a -l:librte_kvargs.a -Wl,--no-whole-archive -lIPSec_MB /usr/lib/gcc/x86_64-linux-gnu/10/../../../x86_64-linux-gnu/librt.so -Wl,--as-needed -lrte_node -lrte_graph -lrte_bpf -lrte_flow_classify -lrte_pipeline -lrte_table -lrte_port -lrte_fib -lrte_ipsec -lrte_vhost -lrte_stack -lrte_security -lrte_sched -lrte_reorder -lrte_rib -lrte_regexdev -lrte_rawdev -lrte_pdump -lrte_power -lrte_member -lrte_lpm -lrte_latencystats -lrte_kni -lrte_jobstats -lrte_ip_frag -lrte_gso -lrte_gro -lrte_eventdev -lrte_efd -lrte_distributor -lrte_cryptodev -lrte_compressdev -lrte_cfgfile -lrte_bitratestats -lrte_bbdev -lrte_acl -lrte_timer -lrte_hash -lrte_metrics -lrte_cmdline -lrte_pci -lrte_ethdev -lrte_meter -lrte_net -lrte_mbuf -lrte_mempool -lrte_rcu -lrte_ring -lrte_eal -lrte_telemetry -lrte_kvargs -pthread -lm -ldl -lnuma -lfdt -L/usr/lib/x86_64-linux-gnu -lbsd -L/usr/lib/x86_64-linux-gnu -lmlx5 -lpthread -L/usr/lib/x86_64-linux-gnu -libverbs -lbnxt_re-rdmav25 -lcxgb4-rdmav25 -lefa -lhns-rdmav25 -li40iw-rdmav25 -lmlx4 -lmlx5 -lmthca-rdmav25 -locrdma-rdmav25 -lqedr-rdmav25 -lvmw_pvrdma-rdmav25 -lhfi1verbs-rdmav25 -lipathverbs-rdmav25 -lrxe-rdmav25 -lsiw-rdmav25 -lpthread -L/usr/lib/x86_64-linux-gnu -lnl-3 -libverbs -lbnxt_re-rdmav25 -lcxgb4-rdmav25 -lefa -lhns-rdmav25 -li40iw-rdmav25 -lmlx5 -lmthca-rdmav25 -locrdma-rdmav25 -lqedr-rdmav25 -lvmw_pvrdma-rdmav25 -lhfi1verbs-rdmav25 -lipathverbs-rdmav25 -lrxe-rdmav25 -lsiw-rdmav25 -libverbs -lpthread -L/usr/lib/x86_64-linux-gnu -lnl-3 -lcrypto -ldl -pthread -L/usr/lib64 -lbpf -L/usr/lib/x86_64-linux-gnu -L/usr/lib/x86_64-linux-gnu -L/usr/lib/x86_64-linux-gnu -lz -lmlx4 -lpthread -L/usr/lib/x86_64-linux-gnu -libverbs -lbnxt_re-rdmav25 -lcxgb4-rdmav25 -lefa -lhns-rdmav25 -li40iw-rdmav25 -lmlx4 -lmlx5 -lmthca-rdmav25 -locrdma-rdmav25 -lqedr-rdmav25 -lvmw_pvrdma-rdmav25 -lhfi1verbs-rdmav25 -lipathverbs-rdmav25 -lrxe-rdmav25 -lsiw-rdmav25 -libverbs -lpthread -L/usr/lib/x86_64-linux-gnu -lnl-route-3 -lnl-3 -lpcap -ldbus-1 -lisal -lelf -L/usr/lib/x86_64-linux-gnu -L/usr/lib/x86_64-linux-gnu -lz -ljansson