* Re: [dpdk-stable] [PATCH v2] build: skip detecting libpcap via pcap-config [not found] ` <20201009141914.205284-1-bruce.richardson@intel.com> @ 2020-10-12 12:48 ` Bruce Richardson [not found] ` <b72ca9072454c65075fe695597d65eb7e08fc7f6.camel@debian.org> 1 sibling, 0 replies; 2+ messages in thread From: Bruce Richardson @ 2020-10-12 12:48 UTC (permalink / raw) To: dev; +Cc: bluca, stable +CC stable for consideration On Fri, Oct 09, 2020 at 03:19:14PM +0100, Bruce Richardson wrote: > When compiling for a slightly different architecture, e.g. 32-bit on 64-bit > systems using CFLAGS rather than a cross-file, the pcap-config utility can > often return parameters that are unusable for the build in question, i.e. > providing the native 64-bit library paths rather than checking for 32-bit > equivalent. > > Since many distros now include a version of libpcap with a > pkg-config file, and for those that don't find-library should work ok as a > fallback, we can explicitly just use pkg-config in the dependency search, > causing meson to skip trying to use pcap-config. > CC: stable@dpdk.org > Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> > --- > config/meson.build | 8 +++----- > 1 file changed, 3 insertions(+), 5 deletions(-) > > diff --git a/config/meson.build b/config/meson.build > index 69f2aeb60..9fb903c9b 100644 > --- a/config/meson.build > +++ b/config/meson.build > @@ -163,11 +163,9 @@ if libbsd.found() > endif > > # check for pcap > -pcap_dep = dependency('pcap', required: false) > -if pcap_dep.found() > - # pcap got a pkg-config file only in 1.9.0 and before that meson uses > - # an internal pcap-config finder, which is not compatible with > - # cross-compilation, so try to fallback to find_library > +pcap_dep = dependency('libpcap', required: false, method: 'pkg-config') > +if not pcap_dep.found() > + # pcap got a pkg-config file only in 1.9.0 > pcap_dep = cc.find_library('pcap', required: false) > endif > if pcap_dep.found() and cc.has_header('pcap.h', dependencies: pcap_dep) > -- > 2.25.1 > ^ permalink raw reply [flat|nested] 2+ messages in thread
[parent not found: <b72ca9072454c65075fe695597d65eb7e08fc7f6.camel@debian.org>]
* Re: [dpdk-stable] [dpdk-dev] [PATCH v2] build: skip detecting libpcap via pcap-config [not found] ` <b72ca9072454c65075fe695597d65eb7e08fc7f6.camel@debian.org> @ 2020-10-12 15:12 ` David Marchand 0 siblings, 0 replies; 2+ messages in thread From: David Marchand @ 2020-10-12 15:12 UTC (permalink / raw) To: Bruce Richardson; +Cc: dev, Luca Boccassi, dpdk stable On Fri, Oct 9, 2020 at 4:54 PM Luca Boccassi <bluca@debian.org> wrote: > > On Fri, 2020-10-09 at 15:19 +0100, Bruce Richardson wrote: > > When compiling for a slightly different architecture, e.g. 32-bit on 64-bit > > systems using CFLAGS rather than a cross-file, the pcap-config utility can > > often return parameters that are unusable for the build in question, i.e. > > providing the native 64-bit library paths rather than checking for 32-bit > > equivalent. > > > > Since many distros now include a version of libpcap with a > > pkg-config file, and for those that don't find-library should work ok as a > > fallback, we can explicitly just use pkg-config in the dependency search, > > causing meson to skip trying to use pcap-config. > > CC: stable@dpdk.org > > Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> > Reviewed-by: Luca Boccassi <bluca@debian.org> Tested-by: David Marchand <david.marchand@redhat.com> Applied, thanks. -- David Marchand ^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-10-12 15:12 UTC | newest] Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <20201008170536.124111-1-bruce.richardson@intel.com> [not found] ` <20201009141914.205284-1-bruce.richardson@intel.com> 2020-10-12 12:48 ` [dpdk-stable] [PATCH v2] build: skip detecting libpcap via pcap-config Bruce Richardson [not found] ` <b72ca9072454c65075fe695597d65eb7e08fc7f6.camel@debian.org> 2020-10-12 15:12 ` [dpdk-stable] [dpdk-dev] " David Marchand
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).