From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <dev-bounces@dpdk.org>
Received: from dpdk.org (dpdk.org [92.243.14.124])
	by inbox.dpdk.org (Postfix) with ESMTP id 8E20AA09EF;
	Mon, 21 Dec 2020 12:04:59 +0100 (CET)
Received: from [92.243.14.124] (localhost [127.0.0.1])
	by dpdk.org (Postfix) with ESMTP id 0312FCB79;
	Mon, 21 Dec 2020 12:04:58 +0100 (CET)
Received: from mga09.intel.com (mga09.intel.com [134.134.136.24])
 by dpdk.org (Postfix) with ESMTP id 7F122CAC7;
 Mon, 21 Dec 2020 12:04:54 +0100 (CET)
IronPort-SDR: z6arwQm5QoTSkMMZ0Pze1hsU9wxVs75PyXaxV1j8Vbx3M7fYlPHX2DvOrmohQDxX9bFJBz0ma7
 7EkTNO9dfXcg==
X-IronPort-AV: E=McAfee;i="6000,8403,9841"; a="175859124"
X-IronPort-AV: E=Sophos;i="5.78,436,1599548400"; d="scan'208";a="175859124"
Received: from fmsmga008.fm.intel.com ([10.253.24.58])
 by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;
 21 Dec 2020 03:04:51 -0800
IronPort-SDR: vpvt1IfEPSFcmN7nA8x3UFm4cQlvd/cO2Ge1HYj3E9vyPfK13q7H4O6b61LOlGTexsp3ImBZ0g
 w3nSu1A+LlCQ==
X-IronPort-AV: E=Sophos;i="5.78,436,1599548400"; d="scan'208";a="342597227"
Received: from bricha3-mobl.ger.corp.intel.com ([10.252.15.169])
 by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-SHA;
 21 Dec 2020 03:04:48 -0800
Date: Mon, 21 Dec 2020 11:04:44 +0000
From: Bruce Richardson <bruce.richardson@intel.com>
To: Olivier Matz <olivier.matz@6wind.com>
Cc: dev@dpdk.org, harry.van.haaren@intel.com, keith.wiles@intel.com,
 luca.boccassi@gmail.com, stable@dpdk.org, thomas@monjalon.net
Message-ID: <20201221110444.GA1753@bricha3-MOBL.ger.corp.intel.com>
References: <20201126142042.24741-1-olivier.matz@6wind.com>
 <20201218131422.15131-1-olivier.matz@6wind.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <20201218131422.15131-1-olivier.matz@6wind.com>
Subject: Re: [dpdk-dev] [PATCH v3] build: fix plugin load on static builds
X-BeenThere: dev@dpdk.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: DPDK patches and discussions <dev.dpdk.org>
List-Unsubscribe: <https://mails.dpdk.org/options/dev>,
 <mailto:dev-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://mails.dpdk.org/archives/dev/>
List-Post: <mailto:dev@dpdk.org>
List-Help: <mailto:dev-request@dpdk.org?subject=help>
List-Subscribe: <https://mails.dpdk.org/listinfo/dev>,
 <mailto:dev-request@dpdk.org?subject=subscribe>
Errors-To: dev-bounces@dpdk.org
Sender: "dev" <dev-bounces@dpdk.org>

On Fri, Dec 18, 2020 at 02:14:22PM +0100, Olivier Matz wrote:
> When dpdk is compiled as static libraries, it is not possible
> to load a plugin from an application. We get the following error:
> 
>   EAL: librte_pmd_xxxx.so: undefined symbol: per_lcore__rte_errno
> 
> This happens because the dpdk symbols are not exported. Add them to the
> dynamic symbol table by using '-Wl,--export-dynamic'. This option was
> previously present when compiled with Makefiles, it was introduced in
> commit f9a08f650211 ("eal: add support for shared object drivers")
> 
> Also add it to the pkg-config file.
> 
> Fixes: 16ade738fd0d ("app/testpmd: build with meson")
> Fixes: 89f0711f9ddf ("examples: build some samples with meson")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
> ---
Reviewed-by: Bruce Richardson <bruce.richardson@intel.com>