From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id C151EA00C5; Thu, 7 May 2020 12:13:57 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 54BD31DA0B; Thu, 7 May 2020 12:13:57 +0200 (CEST) Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by dpdk.org (Postfix) with ESMTP id A7C151D9EA for ; Thu, 7 May 2020 12:13:55 +0200 (CEST) IronPort-SDR: Eiwf1loI2+TVMA83ZPVRPnSYvn9izNyUJMPBr33gAsH7rhjkt4JSOLi33i1xZzRLv0E7Yfj6HP woYmSUB3qfPg== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 07 May 2020 03:13:54 -0700 IronPort-SDR: Syb1qGHxJxmrwLnVC8LRR46fR1kj/4vPGM9exOu2OR7SAOVh8aR3e9U+hTZ+56chwmlQCwd0Bu zRFkGqd1iqsQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,363,1583222400"; d="scan'208";a="370070184" Received: from ultraviolet.igk.intel.com (HELO localhost.localdomain) ([10.102.17.137]) by fmsmga001.fm.intel.com with ESMTP; 07 May 2020 03:13:53 -0700 From: Darek Stojaczyk To: dev@dpdk.org, Bruce Richardson Cc: Darek Stojaczyk Date: Thu, 7 May 2020 12:13:50 +0200 Message-Id: <20200507101350.123873-1-dariusz.stojaczyk@intel.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200326092259.33957-1-dariusz.stojaczyk@intel.com> References: <20200326092259.33957-1-dariusz.stojaczyk@intel.com> Subject: [dpdk-dev] [PATCH v2] build: don't parse build configs of explicitly disabled drivers X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Even when a PMD was disabled with meson's disable_drivers option its config file was still being parsed. Some of the PMD configs attempt to find a library they depend on and parse its header files with certain assumptions. If the library is found, but it's simply too old to contain the necessary header files, the meson build fails and it can only be fixed by either updating that library, or expanding the meson script for the faulty PMD. While the latter should be still done for the sake of DPDK quality, an intermediate solution would be to skip building the faulty PMD - there's a chance we don't need it. That's what this patch allows. Signed-off-by: Darek Stojaczyk Acked-by: Bruce Richardson --- v2: - simplified the code with if X.contains(), as Bruce suggested - removed the related comment from the code - it should be self-documented now drivers/meson.build | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/drivers/meson.build b/drivers/meson.build index 72eec46088..483226a789 100644 --- a/drivers/meson.build +++ b/drivers/meson.build @@ -57,17 +57,14 @@ foreach class:dpdk_driver_classes ext_deps = [] pkgconfig_extra_libs = [] - # pull in driver directory which should assign to each of the above - subdir(drv_path) - - # skip disabled drivers. For meson 0.49 change this to use - # "in" keyword - foreach disable_path: disabled_drivers - if drv_path == disable_path - build = false - reason = 'Explicitly disabled via build config' - endif - endforeach + if disabled_drivers.contains(drv_path) + build = false + reason = 'Explicitly disabled via build config' + else + # pull in driver directory which should update all the local variables + subdir(drv_path) + endif + if build # get dependency objs from strings shared_deps = ext_deps -- 2.17.1