From: Thomas Monjalon <thomas@monjalon.net>
To: Bruce Richardson <bruce.richardson@intel.com>,
Luca Boccassi <bluca@debian.org>
Cc: dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH v8 6/6] build: use dependency for pcap and fallback to find_library
Date: Fri, 01 Mar 2019 14:13:49 +0100 [thread overview]
Message-ID: <8361830.nL5yRZOfUf@xps> (raw)
In-Reply-To: <20190228174026.GA207688@bricha3-MOBL.ger.corp.intel.com>
28/02/2019 18:40, Bruce Richardson:
> On Wed, Feb 27, 2019 at 01:53:32PM +0000, Bruce Richardson wrote:
> > On Wed, Feb 27, 2019 at 12:03:48PM +0000, Luca Boccassi wrote:
> > > On Wed, 2019-02-27 at 11:56 +0100, Thomas Monjalon wrote:
> > > > 27/02/2019 11:50, Luca Boccassi:
> > > > > On Wed, 2019-02-27 at 09:47 +0000, Bruce Richardson wrote:
> > > > > > On Wed, Feb 27, 2019 at 09:33:12AM +0100, Thomas Monjalon wrote:
> > > > > > > 26/02/2019 18:49, Luca Boccassi:
> > > > > > > > On Tue, 2019-02-26 at 17:46 +0000, luca.boccassi@gmail.com
> > > > > > > > wrote:
> > > > > > > > > From: Luca Boccassi <luca.boccassi@microsoft.com>
> > > > > > > > >
> > > > > > > > > pcap has historically shipped a custom pcap-config binary
> > > > > > > > > tool
> > > > > > > > > which
> > > > > > > > > does the job of pkg-config. It was never compatible with
> > > > > > > > > cross
> > > > > > > > > compilation.
> > > > > > > > > Meson uses it when using dependency(), which then means
> > > > > > > > > cross
> > > > > > > > > compilation fails.
> > > > > > > > > Set pcap-config to empty in the meson cross compilation
> > > > > > > > > files
> > > > > > > > > so
> > > > > > > > > that Meson will not use it, and add a fallback in case
> > > > > > > > > dependency() fails.
> > > > > > > > > libpcap 1.9.0 finally ships a pkg-config file so everything
> > > > > > > > > will
> > > > > > > > > work out of the box in the future.
> > > > > > > > >
> > > > > > > > > Signed-off-by: Luca Boccassi <luca.boccassi@microsoft.com>
> > > > > > > > > ---
> > > > > > > > > v8: added back pcap change separately. Tested with bootlin
> > > > > > > > > cross-compilation toolchain, everything seems to work.
> > > > > > > >
> > > > > > > > I had some time to invest so I added back this change, in a
> > > > > > > > way
> > > > > > > > that
> > > > > > > > works with cross compilation too. Given the series wasn't
> > > > > > > > merged
> > > > > > > > yet
> > > > > > > > and there was a conflict I've done a v8 rather than a single
> > > > > > > > separate
> > > > > > > > patch, but it's independent from the rest.
> > > > > > > >
> > > > > > > > More testing is of course welcome!
> > > > > > >
> > > > > > > I still see the same error when cross-compiling:
> > > > > > >
> > > > > > > /usr/include/stdint.h:109: error: "__INT64_C" redefined
> > > > > > >
> > > > > > Can patches 1-5 be merged anyway, leaving 6 for later?
> > > > > >
> > > > > > /Bruce
> > > > >
> > > > > Yes please...
> > > >
> > > > Yes, sure. I am checking other patches to push them.
> > >
> > > Thanks!
> > >
> > > > > Thomas, could you please give me detailed instructions on how to
> > > > > repro?
> > > > > I used the bootlin toolchain you linked me last time, and passed --
> > > > > cross-file config/arm/arm64_armv8_linuxapp_gcc to Meson, and
> > > > > everything
> > > > > built fine both with and without an arm64 build of libpcap in the
> > > > > sysroot. With the previous version that I removed it would fail.
> > > > > Not
> > > > > sure what I'm missing!
> > > >
> > > > I'm running devtools/test-meson-builds.sh on my ArchLinux which has
> > > > aarch64-linux-gnu-gcc 8.2.0 but no arm pcap I guess.
> > >
> > > The script is working fine too - I have the toolchain in /tmp so I
> > > simply run it with PATH=/tmp/toolchain/bin:$PATH and everything built
> > > fine including the arm targets.
> > >
> > > The key part in the patch was adding pcap-config = '' to the various
> > > arm configs, could you please double check that it was applied
> > > correctly? Without that, Meson finds and calls the native pcap-config
> > > which gives wrong (native) flags and causes the errors you are seeing.
> > > Otherwise I'm a bit lost, I can't understand why it's all working here
> > > and not there.
> > >
> > > meson --werror -Dexamples=all --default-library=shared --cross-file config/arm/arm64_armv8_linuxapp_gcc /home/bluca/git/dpdk/devtools/.. build-arm64-armv8
> > > The Meson build system
> > > Version: 0.49.2
> > > Source dir: /home/bluca/git/dpdk
> > > Build dir: /home/bluca/git/dpdk/build-arm64-armv8
> > > Build type: cross build
> > > Project name: DPDK
> > > Project version: 19.05.0-rc0
> > > Native C compiler: ccache gcc (gcc 8.2.0 "gcc (Debian 8.2.0-21) 8.2.0")
> > > Cross C compiler: aarch64-linux-gnu-gcc (gcc 7.3.0)
> > > Host machine cpu family: aarch64
> > > Host machine cpu: armv8-a
> > > Target machine cpu family: aarch64
> > > Target machine cpu: armv8-a
> > > <...>
> > > $ file build-arm64-armv8/lib/librte_eal.so.9.1
> > > build-arm64-armv8/lib/librte_eal.so.9.1: ELF 64-bit LSB pie executable, ARM aarch64, version 1 (SYSV), dynamically linked, not stripped
> > >
> >
> > I'm testing on Fedora 29 and this patch works fine with the cross-builds
> > too. Maybe it's something special in Arch Linux again. I'll trying testing
> > it out in an Arch VM - though sadly Arch linux is failing to update for me,
> > so I won't have exactly Thomas' setup.
>
> I've also run this on Arch with the cross compiler installed and see no
> issues. Thomas, can you look at the log below and see what differs from
> your setup?
I'm sorry for the noise.
It compiles fine after cleaning the build directory :/
next prev parent reply other threads:[~2019-03-01 13:13 UTC|newest]
Thread overview: 88+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-03 17:57 [dpdk-dev] [PATCH 1/2] build: use static deps of libs for pkg-config libs.private Luca Boccassi
2019-01-03 17:57 ` [dpdk-dev] [PATCH 2/2] build: use dependency() instead of find_library() Luca Boccassi
2019-01-07 14:28 ` Bruce Richardson
2019-01-07 16:39 ` [dpdk-dev] [dpdk-stable] " Luca Boccassi
2019-01-07 16:55 ` Bruce Richardson
2019-01-07 17:03 ` [dpdk-dev] [dpdk-techboard] " Thomas Monjalon
2019-01-07 17:45 ` [dpdk-dev] [dpdk-stable] [dpdk-techboard] " Thomas Monjalon
2019-01-07 21:09 ` Luca Boccassi
2019-01-07 22:03 ` Luca Boccassi
2019-01-11 11:10 ` [dpdk-dev] [dpdk-stable] " Luca Boccassi
2019-01-11 11:52 ` Bruce Richardson
2019-01-11 12:39 ` Luca Boccassi
2019-01-11 14:24 ` Bruce Richardson
2019-01-11 14:56 ` Luca Boccassi
2019-01-11 15:49 ` Bruce Richardson
2019-01-11 16:27 ` Luca Boccassi
2019-01-11 12:38 ` [dpdk-dev] [PATCH v2 1/3] build: use static deps of libs for pkg-config libs.private Luca Boccassi
2019-01-11 12:38 ` [dpdk-dev] [PATCH v2 2/3] build: use dependency() instead of find_library() Luca Boccassi
2019-01-11 12:38 ` [dpdk-dev] [PATCH v2 3/3] build: bump minimum Meson to 0.47.1 and use dependency() for libbsd Luca Boccassi
2019-01-11 14:27 ` Bruce Richardson
2019-01-11 14:30 ` Bruce Richardson
2019-01-11 15:04 ` Luca Boccassi
2019-01-11 15:50 ` Bruce Richardson
2019-01-11 16:14 ` Luca Boccassi
2019-01-11 16:26 ` [dpdk-dev] [PATCH v3 1/4] build: bump minimum Meson version to 0.47.1 Luca Boccassi
2019-01-11 16:26 ` [dpdk-dev] [PATCH v3 2/4] build: use dependency() instead of find_library() Luca Boccassi
2019-01-11 17:21 ` Bruce Richardson
2019-01-11 18:16 ` Luca Boccassi
2019-01-11 21:49 ` Bruce Richardson
2019-01-11 16:26 ` [dpdk-dev] [PATCH v3 3/4] build: reorder libraries and build eal before cmdline Luca Boccassi
2019-01-11 17:22 ` Bruce Richardson
2019-01-11 16:26 ` [dpdk-dev] [PATCH v3 4/4] build: use dependency() for libbsd instead of manual append to ldflags Luca Boccassi
2019-01-11 17:24 ` Bruce Richardson
2019-01-11 17:17 ` [dpdk-dev] [PATCH v3 1/4] build: bump minimum Meson version to 0.47.1 Bruce Richardson
2019-01-11 18:22 ` [dpdk-dev] [PATCH v4 " Luca Boccassi
2019-01-11 18:22 ` [dpdk-dev] [PATCH v4 2/4] build: use dependency() instead of find_library() Luca Boccassi
2019-01-11 18:22 ` [dpdk-dev] [PATCH v4 3/4] build: reorder libraries and build eal before cmdline Luca Boccassi
2019-01-11 18:22 ` [dpdk-dev] [PATCH v4 4/4] build: use dependency() for libbsd instead of manual append to ldflags Luca Boccassi
2019-01-22 13:10 ` [dpdk-dev] [PATCH v5 1/4] build: bump minimum Meson version to 0.47.1 Luca Boccassi
2019-01-22 13:10 ` [dpdk-dev] [PATCH v5 2/4] build: use dependency() instead of find_library() Luca Boccassi
2019-01-22 13:46 ` Bruce Richardson
2019-01-22 14:09 ` Luca Boccassi
2019-01-22 14:24 ` Bruce Richardson
2019-01-22 14:25 ` Bruce Richardson
2019-01-22 13:10 ` [dpdk-dev] [PATCH v5 3/4] build: reorder libraries and build eal before cmdline Luca Boccassi
2019-01-22 13:10 ` [dpdk-dev] [PATCH v5 4/4] build: use dependency() for libbsd instead of manual append to ldflags Luca Boccassi
2019-01-22 13:42 ` [dpdk-dev] [PATCH v5 1/4] build: bump minimum Meson version to 0.47.1 Bruce Richardson
2019-02-06 17:08 ` [dpdk-dev] [PATCH v6 1/5] " Luca Boccassi
2019-02-06 17:08 ` [dpdk-dev] [PATCH v6 2/5] build: use dependency() instead of find_library() Luca Boccassi
2019-02-12 11:15 ` Thomas Monjalon
2019-02-12 11:31 ` Bruce Richardson
2019-02-12 11:36 ` Thomas Monjalon
2019-02-12 11:43 ` Bruce Richardson
2019-02-12 14:47 ` Thomas Monjalon
2019-02-12 15:03 ` Bruce Richardson
2019-02-12 16:21 ` Thomas Monjalon
2019-02-13 10:49 ` Luca Boccassi
2019-02-13 11:10 ` Thomas Monjalon
2019-02-13 13:45 ` Luca Boccassi
2019-02-13 11:48 ` Luca Boccassi
2019-02-06 17:08 ` [dpdk-dev] [PATCH v6 3/5] build: reorder libraries and build eal before cmdline Luca Boccassi
2019-02-06 17:08 ` [dpdk-dev] [PATCH v6 4/5] build: use dependency() for libbsd instead of manual append to ldflags Luca Boccassi
2019-02-06 17:08 ` [dpdk-dev] [PATCH v6 5/5] build: use integers for numerical options Luca Boccassi
2019-02-08 14:44 ` Bruce Richardson
2019-02-13 11:54 ` [dpdk-dev] [PATCH v7 1/5] build: bump minimum Meson version to 0.47.1 Luca Boccassi
2019-02-13 11:54 ` [dpdk-dev] [PATCH v7 2/5] build: use dependency() instead of find_library() Luca Boccassi
2019-02-13 15:35 ` Bruce Richardson
2019-02-13 11:54 ` [dpdk-dev] [PATCH v7 3/5] build: reorder libraries and build eal before cmdline Luca Boccassi
2019-02-13 11:54 ` [dpdk-dev] [PATCH v7 4/5] build: use dependency() for libbsd instead of manual append to ldflags Luca Boccassi
2019-02-13 11:54 ` [dpdk-dev] [PATCH v7 5/5] build: use integers for numerical options Luca Boccassi
2019-02-26 17:46 ` [dpdk-dev] [PATCH v8 1/6] build: bump minimum Meson version to 0.47.1 luca.boccassi
2019-02-26 17:46 ` [dpdk-dev] [PATCH v8 2/6] build: use dependency() instead of find_library() luca.boccassi
2019-02-26 17:46 ` [dpdk-dev] [PATCH v8 3/6] build: reorder libraries and build eal before cmdline luca.boccassi
2019-02-26 17:46 ` [dpdk-dev] [PATCH v8 4/6] build: use dependency() for libbsd instead of manual append to ldflags luca.boccassi
2019-02-26 17:46 ` [dpdk-dev] [PATCH v8 5/6] build: use integers for numerical options luca.boccassi
2019-02-26 17:46 ` [dpdk-dev] [PATCH v8 6/6] build: use dependency for pcap and fallback to find_library luca.boccassi
2019-02-26 17:49 ` Luca Boccassi
2019-02-27 8:33 ` Thomas Monjalon
2019-02-27 9:47 ` Bruce Richardson
2019-02-27 10:50 ` Luca Boccassi
2019-02-27 10:56 ` Thomas Monjalon
2019-02-27 12:03 ` Luca Boccassi
2019-02-27 13:53 ` Bruce Richardson
2019-02-28 17:40 ` Bruce Richardson
2019-03-01 13:13 ` Thomas Monjalon [this message]
2019-03-01 15:13 ` Luca Boccassi
2019-03-01 13:22 ` Thomas Monjalon
2019-02-27 11:29 ` [dpdk-dev] [PATCH v8 1/6] build: bump minimum Meson version to 0.47.1 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=8361830.nL5yRZOfUf@xps \
--to=thomas@monjalon.net \
--cc=bluca@debian.org \
--cc=bruce.richardson@intel.com \
--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).