From patchwork Sat Oct 31 06:39:49 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nick Connolly X-Patchwork-Id: 83167 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 2CEA7A04E6; Sat, 31 Oct 2020 07:40:45 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 82450CA0A; Sat, 31 Oct 2020 07:40:42 +0100 (CET) Received: from mail-wm1-f42.google.com (mail-wm1-f42.google.com [209.85.128.42]) by dpdk.org (Postfix) with ESMTP id 53E2ACA06 for ; Sat, 31 Oct 2020 07:40:41 +0100 (CET) Received: by mail-wm1-f42.google.com with SMTP id k18so4724854wmj.5 for ; Fri, 30 Oct 2020 23:40:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mayadata-io.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=mschp5JAeLM+mW+EGiXaxJwGzKPbw1AIkvTcka16F4I=; b=otMF7f+BLCq0U3t4BsZd4LyPyZHf+vucoMDXpl4kt7mJFFrmA5PmEUHBfSsE816j5Y bg0M9ci0/F4NiV8/8WC249NVLcWZWOC0vQ+6H2xc3kDBEnBoQYWT8ZUGVaJiO5NuAXHb WnQnG4C6BIUeV7aPJuCaRJQUcz4/cdQ8zHESG9Tul+YDnW93o44M1xTuQh5MGTQetYnv bNo8G1TBlxgpc9ZOy03LJw7hMik4vgqXDVYAZLte+4eJ9Q8dT7fALRVHXpdbRVXfQO/1 BYGvu0lfNCXGwmDxxTFG5SAX52kBIWADzuronWcTgcnD5iW4PCesTJA4r3yFzlQuGKXY bRFA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=mschp5JAeLM+mW+EGiXaxJwGzKPbw1AIkvTcka16F4I=; b=tVVrkJ6okGcGavX2/Wye/5dFWd0gz/LBRabBeDSPpzCSOqcN/pQ/kH0DWK5p4diJMp g0FF3XRKKNy6RmmMC0IocSeb+Qgld3GV43ZMOQ6juFzoFNUI5uWabQ97fVaFxi4DHBDn 6YcpSjwiFcj4G3p+6DKDzzUconSCCUGnuiulOgqNXzLvO1530ksDIsfnBFj2U0G7Mt4C X18M2+V1jIxwvE6AnaRTfAlTBG2omn7pJwnzLwmUNvLq8Ki7qV8wwzq6UJgLb6N819Wo 1zJHWhCZTOH+wFN1XYSU26s/NgatGvcEwDcEsBe4I3sDE4VYmd64FxClZupHhSie9Hmo 1NiA== X-Gm-Message-State: AOAM5306DwBl1szPuIgNgyQGUl98CyjeMPWrer8+v6bFd4YNupaN71FK hQei37jZ3uf2uRvH8RkYDOSry3XkWwylfGqW X-Google-Smtp-Source: ABdhPJz457jXyd3oUzsMrVSBrIomhcZVQkSlTk/6ZIWT+IHLEq0FN9iTBwhk/JevT6R/h8sEx79ZOg== X-Received: by 2002:a1c:9647:: with SMTP id y68mr6581726wmd.101.1604126439567; Fri, 30 Oct 2020 23:40:39 -0700 (PDT) Received: from FENIX.localdomain (cpc98320-croy25-2-0-cust77.19-2.cable.virginm.net. [80.235.134.78]) by smtp.gmail.com with ESMTPSA id v189sm7884830wmg.14.2020.10.30.23.40.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 Oct 2020 23:40:38 -0700 (PDT) From: Nick Connolly To: Cc: dev@dpdk.org, bruce.richardson@intel.com, Nick Connolly , Ranjit Menon Date: Sat, 31 Oct 2020 06:39:49 +0000 Message-Id: <20201031063949.829-1-nick.connolly@mayadata.io> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Subject: [dpdk-dev] [PATCH v2] windows: minor build fixes 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" Meson versions >= 0.54.0 include support for handling /implib with msvc link. Specifying it explicitly causes failures when linking against the dll. Tested using Link 14.27.29112.0 and Clang 11.0.0. There were a number of changes to the way that import libraries are handled between 0.47.1 and 0.54.0. Only make the change for >= 0.54.0, leaving the behaviour unchanged for earlier versions. Signed-off-by: Nick Connolly Tested-by: Ranjit Menon Acked-by: Ranjit Menon --- v2: * split out config/meson.build change drivers/meson.build | 6 ++++-- lib/meson.build | 6 ++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/drivers/meson.build b/drivers/meson.build index 4bb7e9218..6b50f7238 100644 --- a/drivers/meson.build +++ b/drivers/meson.build @@ -186,8 +186,10 @@ foreach subpath:subdirs lk_deps = [version_map, def_file, mingw_map] if is_windows if is_ms_linker - lk_args = ['-Wl,/def:' + def_file.full_path(), - '-Wl,/implib:drivers\\' + implib] + lk_args = ['-Wl,/def:' + def_file.full_path()] + if meson.version().version_compare('<0.54.0') + lk_args += ['-Wl,/implib:drivers\\' + implib] + endif else lk_args = ['-Wl,--version-script=' + mingw_map.full_path()] endif diff --git a/lib/meson.build b/lib/meson.build index 1bb019720..ed00f8914 100644 --- a/lib/meson.build +++ b/lib/meson.build @@ -157,8 +157,10 @@ foreach l:libraries output: '@0@_mingw.map'.format(libname)) if is_ms_linker - lk_args = ['-Wl,/def:' + def_file.full_path(), - '-Wl,/implib:lib\\' + implib] + lk_args = ['-Wl,/def:' + def_file.full_path()] + if meson.version().version_compare('<0.54.0') + lk_args += ['-Wl,/implib:lib\\' + implib] + endif else if is_windows lk_args = ['-Wl,--version-script=' + mingw_map.full_path()]