DPDK patches and discussions
 help / color / mirror / Atom feed
From: Bruce Richardson <bruce.richardson@intel.com>
To: Luca Boccassi <bluca@debian.org>
Cc: dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH 2/2] buildtools/test-meson-builds: workaround pkg-config issue
Date: Thu, 4 Jul 2019 10:47:38 +0100	[thread overview]
Message-ID: <20190704094738.GA426@bricha3-MOBL.ger.corp.intel.com> (raw)
In-Reply-To: <dfc28fbac177d017e3a4a2f57b24d322ff628deb.camel@debian.org>

On Thu, Jul 04, 2019 at 09:39:32AM +0100, Luca Boccassi wrote:
> On Wed, 2019-07-03 at 17:40 +0100, Bruce Richardson wrote:
> > With Debian and Ubuntu, the default installation path for the 64-bit
> > libraries is set to e.g. /usr/local/lib/x86_64-linux-gnu/, compared
> > to
> > /usr/local/lib64 on Fedora and Redhat distributions. This causes
> > issues
> > when using "pkg-config --define-prefix" since pkg-config assumes the
> > prefix
> > to be the grandparent of where the .pc file is. On Ubuntu we then get
> > the
> > cflags include path as being "/path/to/install-
> > root/usr/local/lib/include"
> > i.e. with an extra "lib" in the path.
> > 
> > This issue only applies for test installs on Ubuntu and similar
> > distros,
> > and is not a problem for regular installs since the --define-prefix
> > parameter would not be passed to pkg-config in those cases.
> > 
> > The workaround for this in our test build script is to explicitly
> > make
> > "lib" the "libdir" setting for the install, overriding the distro-
> > provided
> > default.
> > 
> > Fixes: 7f80a2102bbb ("devtools: test pkg-config file")
> > 
> > Signed-off-by: Bruce Richardson <
> > bruce.richardson@intel.com
> > >
> > ---
> >  devtools/test-meson-builds.sh | 4 +++-
> >  1 file changed, 3 insertions(+), 1 deletion(-)
> > 
> > diff --git a/devtools/test-meson-builds.sh b/devtools/test-meson-
> > builds.sh
> > index 57d1af47e..7efc590fe 100755
> > --- a/devtools/test-meson-builds.sh
> > +++ b/devtools/test-meson-builds.sh
> > @@ -76,12 +76,14 @@ for c in gcc clang ; do
> >  done
> >  
> >  # test compilation with minimal x86 instruction set
> > +# set the install path for libraries to "lib" explicitly to prevent
> > problems
> > +# with pkg-config prefixes if installed in "lib/x86_64-linux-gnu"
> > later.
> >  default_machine='nehalem'
> >  ok=$(cc -march=$default_machine -E - < /dev/null > /dev/null 2>&1 ||
> > echo false)
> >  if [ "$ok" = "false" ] ; then
> >  	default_machine='corei7'
> >  fi
> > -build build-x86-default -Dmachine=$default_machine $use_shared
> > +build build-x86-default -Dlibdir=lib -Dmachine=$default_machine
> > $use_shared
> >  
> >  # enable cross compilation if gcc cross-compiler is found
> >  c=aarch64-linux-gnu-gcc
> 
> I have sent a patch upstream to pkg-config to fix the issue, as it
> should really support the multiarch layout:
> 
> https://gitlab.freedesktop.org/pkg-config/pkg-config/merge_requests/4

Thanks, Luca, good to have that fixed at source. Either way the fix in DPDK
for our testing is harmless and ensures things pass generally.

/Bruce

  reply	other threads:[~2019-07-04  9:47 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-03 16:39 [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation Bruce Richardson
2019-07-03 16:40 ` [dpdk-dev] [PATCH 1/2] examples: fix pkg-config detection with older make Bruce Richardson
2019-07-03 16:40 ` [dpdk-dev] [PATCH 2/2] buildtools/test-meson-builds: workaround pkg-config issue Bruce Richardson
2019-07-04  8:39   ` Luca Boccassi
2019-07-04  9:47     ` Bruce Richardson [this message]
2019-07-03 16:49 ` [dpdk-dev] [PATCH 0/2] fix issues with Ubuntu 18.04 compilation Luca Boccassi
2019-07-03 21:11   ` 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=20190704094738.GA426@bricha3-MOBL.ger.corp.intel.com \
    --to=bruce.richardson@intel.com \
    --cc=bluca@debian.org \
    --cc=dev@dpdk.org \
    /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).