From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 8A8D96D45 for ; Wed, 27 Sep 2017 14:01:08 +0200 (CEST) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 27 Sep 2017 05:01:07 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,445,1500966000"; d="scan'208";a="1199585824" Received: from bricha3-mobl3.ger.corp.intel.com ([10.252.14.171]) by fmsmga001.fm.intel.com with SMTP; 27 Sep 2017 05:01:04 -0700 Received: by (sSMTP sendmail emulation); Wed, 27 Sep 2017 13:01:03 +0100 Date: Wed, 27 Sep 2017 13:01:02 +0100 From: Bruce Richardson To: Tomasz Duszynski Cc: dev@dpdk.org, mw@semihalf.com, dima@marvell.com, nsamsono@marvell.com, Jacek Siuda Message-ID: <20170927120102.GA27076@bricha3-MOBL3.ger.corp.intel.com> References: <1506418805-12117-1-git-send-email-tdu@semihalf.com> <1506418805-12117-2-git-send-email-tdu@semihalf.com> <20170926143117.GA24952@bricha3-MOBL3.ger.corp.intel.com> <20170927073603.GA30028@tdu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170927073603.GA30028@tdu> Organization: Intel Research and Development Ireland Ltd. User-Agent: Mutt/1.8.3 (2017-05-23) Subject: Re: [dpdk-dev] [PATCH 1/8] app: link the whole rte_cfgfile library 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: , X-List-Received-Date: Wed, 27 Sep 2017 12:01:08 -0000 On Wed, Sep 27, 2017 at 09:36:03AM +0200, Tomasz Duszynski wrote: > On Tue, Sep 26, 2017 at 03:31:18PM +0100, Bruce Richardson wrote: > > On Tue, Sep 26, 2017 at 11:39:58AM +0200, Tomasz Duszynski wrote: > > > Since MRVL NET PMD needs librte_cfgfile to parse QoS configuration file > > > link it as the whole library. > > > > > > Signed-off-by: Jacek Siuda > > > Signed-off-by: Tomasz Duszynski > > > --- > > > > Can you clarify a bit more why this is needed? For a static build, the > > cfgfile should be linked in to the after the PMDs, so the dependencies > > in the driver should be satisfied in the link. For a dynamic build, the > > PMD should depend upon the cfgfile directly, and use it at runtime > > appropriately. > > Am I missing something? > > > > /Bruce > Hi Bruce, > > You are correct, all dependencies in the driver will be satisfied. > The reason this change was introduced is that, librte_pmd_mrvl.a > contains undefined symbols from librte_cfgfile.a thus linking > applications under app/ directory will fail as librte_cfgfile.a comes > before librte_pmd_mrvl.a during the linking stage. > > Linking librte_cfgfile.a with --whole-archive solves the issue. > > -- Thanks for the explanation. I believe the proper fix in this case is to ensure that when linking apps that cfgfile comes after librte_pmd_mrvl. The drivers should always come first when linking, then the DPDK libs. /Bruce