DPDK patches and discussions
 help / color / mirror / Atom feed
From: "De Lara Guarch, Pablo" <pablo.de.lara.guarch@intel.com>
To: Olivier Matz <olivier.matz@6wind.com>,
	"dev@dpdk.org" <dev@dpdk.org>,
	"Marohn, Byron" <byron.marohn@intel.com>
Subject: Re: [dpdk-dev] [PATCH] efd: fix compilation by removing dep to libmath
Date: Fri, 27 Jan 2017 14:45:04 +0000	[thread overview]
Message-ID: <E115CCD9D858EF4F90C690B0DCB4D897476D0980@IRSMSX108.ger.corp.intel.com> (raw)
In-Reply-To: <1485526997-31111-1-git-send-email-olivier.matz@6wind.com>



> -----Original Message-----
> From: Olivier Matz [mailto:olivier.matz@6wind.com]
> Sent: Friday, January 27, 2017 2:23 PM
> To: dev@dpdk.org; Marohn, Byron; De Lara Guarch, Pablo
> Subject: [PATCH] efd: fix compilation by removing dep to libmath
> 
> When we compile the dpdk with:
>   CONFIG_RTE_LIBRTE_EFD=y
>   CONFIG_RTE_LIBRTE_NFP_PMD=n
>   CONFIG_RTE_LIBRTE_THUNDERX_NICVF_PMD=n
>   CONFIG_RTE_LIBRTE_SCHED=n
>   CONFIG_RTE_LIBRTE_METER=n
> 
> The linker gives the following error:
>   lib/librte_efd.a(rte_efd.o): In function `rte_efd_create':
>   lib/librte_efd/rte_efd.c:560: undefined reference to `log2'
>   collect2: error: ld returned 1 exit status
> 
> This is because the '-lm' is missing in mk/rte.app.mk.
> 
> An alternative, which is proposed by this patch, is to use the compiler
> builtin rte_bsf32() to process log2 instead of the libmath log2() that
> requires to include math.h and link with -lm.
> 
> Signed-off-by: Olivier Matz <olivier.matz@6wind.com>

Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>

Nice catch, thanks!

  reply	other threads:[~2017-01-27 14:45 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-27 14:23 Olivier Matz
2017-01-27 14:45 ` De Lara Guarch, Pablo [this message]
2017-01-30  9:58   ` Thomas Monjalon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=E115CCD9D858EF4F90C690B0DCB4D897476D0980@IRSMSX108.ger.corp.intel.com \
    --to=pablo.de.lara.guarch@intel.com \
    --cc=byron.marohn@intel.com \
    --cc=dev@dpdk.org \
    --cc=olivier.matz@6wind.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).