From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 8D8C7A0350; Mon, 28 Feb 2022 18:33:35 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 19FDA4068C; Mon, 28 Feb 2022 18:33:35 +0100 (CET) Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mails.dpdk.org (Postfix) with ESMTP id 2B90740140 for ; Mon, 28 Feb 2022 18:33:32 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1646069613; x=1677605613; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=YYsvdjl0h4NAj+1zDFhDRUtOqosM+dIrQqDTG/0zhgs=; b=D7CQLAlZQVVJCgL/f+CBW9GOm2+3/lMJA/rC3mzs2MNM+O/R9vnWhSgt Omya7/M7JrtVs3NxyOeYaEDRjSZevHanRUJyoZ7/iOGrA25XLYuOw5r2F 3dJJkWz6MtLjxLjNnhpPfp5qkdCr9jSMItEbztRgwhAOnqBvlvlZttvp6 QMrATHvDU977e7n8BhdSYGvIT3kC1QIMDq4sgo5+cRHNe5Vg+O8bWGfzd sXwTA6BOmKpX6OvPox+Ol2O16hpugnfrsbpi4YxvZ6Hdv9MtIWYclWh+w kjQ8TQEJjo9w0jMjO0k8O3klxtI7hXhbrLV0LSDng+prfBrjeokgcpJyC A==; X-IronPort-AV: E=McAfee;i="6200,9189,10272"; a="250524830" X-IronPort-AV: E=Sophos;i="5.90,144,1643702400"; d="scan'208";a="250524830" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Feb 2022 09:33:32 -0800 X-IronPort-AV: E=Sophos;i="5.90,144,1643702400"; d="scan'208";a="534537649" Received: from bricha3-mobl.ger.corp.intel.com ([10.252.27.47]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-SHA; 28 Feb 2022 09:33:31 -0800 Date: Mon, 28 Feb 2022 17:33:28 +0000 From: Bruce Richardson To: aisha Cc: dev@dpdk.org Subject: Re: [patch] allow using standard ar from the build ini files instead of 'ar' string Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On Mon, Feb 28, 2022 at 10:54:28AM -0500, aisha wrote: > Hi, > > I've attached a patch, from Gentoo, which uses the *ar* binary passed to > meson when available, instead of 'ar', which may not be available, for > instance when cross compiling, or having multiple gcc versions present, like > in Gentoo. > > This should not have any regressions, as when the binary is not available it > uses the same logic as the original. > > Aisha > > diff --git a/buildtools/meson.build b/buildtools/meson.build > index 400b88f251..d886bfb1dc 100644 > --- a/buildtools/meson.build > +++ b/buildtools/meson.build > @@ -24,15 +24,20 @@ binutils_avx512_check = (py3 + files('binutils-avx512-check.py') + > # select library and object file format > pmdinfo = py3 + files('gen-pmdinfo-cfile.py') + [meson.current_build_dir()] > pmdinfogen = py3 + files('pmdinfogen.py') > +ar = '' > +if cc.get_id() == 'gcc' or host_machine.system() != 'windows' > + ar = 'ar' > +else > + ar = 'llvm-ar' > +endif > +ar_bin = find_program('ar', required: false) > +if ar_bin.found() > + ar = ar_bin.full_path() > +endif > +pmdinfo += ar > if host_machine.system() == 'windows' > - if cc.get_id() == 'gcc' > - pmdinfo += 'ar' > - else > - pmdinfo += 'llvm-ar' > - endif > pmdinfogen += 'coff' > else > - pmdinfo += 'ar' > pmdinfogen += 'elf' > endif > > diff --git a/meson.build b/meson.build > index 937f6110c0..35650ab20d 100644 > --- a/meson.build > +++ b/meson.build > @@ -12,7 +12,7 @@ project('DPDK', 'C', > 'default_library=static', > 'warning_level=2', > ], > - meson_version: '>= 0.49.2' > + meson_version: '>= 0.55.0' > ) I don't believe this should be part of this patch, as bumping the minimum meson version is not something we want to do just now. /Bruce