From patchwork Sat Jun 20 22:35:42 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Kozlyuk X-Patchwork-Id: 71830 X-Patchwork-Delegate: thomas@monjalon.net 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 83904A0518; Sun, 21 Jun 2020 00:36:03 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 1B34C1BFC8; Sun, 21 Jun 2020 00:35:56 +0200 (CEST) Received: from mail-lf1-f65.google.com (mail-lf1-f65.google.com [209.85.167.65]) by dpdk.org (Postfix) with ESMTP id 2B4BB1BFBD for ; Sun, 21 Jun 2020 00:35:53 +0200 (CEST) Received: by mail-lf1-f65.google.com with SMTP id d7so7546315lfi.12 for ; Sat, 20 Jun 2020 15:35:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=dwK0w4XEJbWGjpM+1vfoFREAFfyjXah6z1x3aKCdvhU=; b=uisVRUJfPtK9IuvTtgDKUdobYpTG3sgylE7by8QmcP9ndZOp04hLuis4VE+O2cSlVE QG7RDDWaoCUR/uzCbfxOyih0a78mzH4+C++6WX+RZZlO9TJDxewunklCMdA5ORWj8G00 39BOstkfBZr7ncDfV2Yu7qjEB4NPHoVZV7k+OtYeyIB661Bn9Czu/7zHeB+QHGgtkoJ7 51lZbWhFT4GEZSZW7J+wDSn0XdOZD4GXoz1NbYOMCjs/T6flTRlCWVmImxUH0ffdp+5x t4Y37ckWO6fvA9nnMvLwn8tORKOiThhTVyOjtetus7V3pWZnsfhjG7ksNc1XhEPnNAKg FT2g== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=dwK0w4XEJbWGjpM+1vfoFREAFfyjXah6z1x3aKCdvhU=; b=QImShTA2GCC36tfoYWgXucE+kZV0+2TYw0BKuIExcKn/q2+WkaCN5qeafvERctnjka O27jiBV/E2CuZq1EI9IEK6a+nLVN5xBva1ZGYgDbfhQNaq2UTxznwzjh37Vp8ClK2Gvb 02qebxta1ugY1W2C/zD+HaehNf4egcyvM6bG19r/CyROeqJajKe2uhzVVYZVAW3UZckP kNTKcR1jFf1kWTryTH5whGTprXE4nvjRXxbMfm4nL3lliLLkjxOA470m/5OGGUOtWJ8d 3Bb5U/EUv85fz8fxyu05pVByaTmXBDBnnETqYrcPJGM7QdEReQhGqNlZQhyTSZhPRa04 2+VA== X-Gm-Message-State: AOAM532uUZzFPBH/eKdoQ48lkm7kVj3aE4L0dbZY0wlB3AEXGVyKEjhi 44yT1ODoaqXlK7ofMC8tEZe9vdTCrIFRXg== X-Google-Smtp-Source: ABdhPJzyizNhdIH10np6n9l3w7lqKzXgRN1cnDMeFXXO0oFhYx6EUVpufN1k3ABxrMCEmNGGlXO5dw== X-Received: by 2002:a05:6512:3089:: with SMTP id z9mr5540788lfd.83.1592692552443; Sat, 20 Jun 2020 15:35:52 -0700 (PDT) Received: from localhost.localdomain (broadband-37-110-65-23.ip.moscow.rt.ru. [37.110.65.23]) by smtp.gmail.com with ESMTPSA id q14sm1877015ljj.110.2020.06.20.15.35.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 20 Jun 2020 15:35:51 -0700 (PDT) From: Dmitry Kozlyuk To: dev@dpdk.org Cc: Thomas Monjalon , Tal Shnaiderman , Dmitry Kozlyuk , Bruce Richardson Date: Sun, 21 Jun 2020 01:35:42 +0300 Message-Id: <20200620223544.24070-2-dmitry.kozliuk@gmail.com> X-Mailer: git-send-email 2.25.4 In-Reply-To: <20200620223544.24070-1-dmitry.kozliuk@gmail.com> References: <20200620223544.24070-1-dmitry.kozliuk@gmail.com> MIME-Version: 1.0 Subject: [dpdk-dev] [PATCH 1/3] config: never link with pthread on Windows 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 if pthread is provided by the toolchain, it is not needed for DPDK on Windows, because internal shim is used. As a side-effect, this enables cross-build with MinGW configured with non-POSIX thread library, e.g. mcfgthread, which is the default on some distributions. Signed-off-by: Dmitry Kozlyuk --- config/meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/meson.build b/config/meson.build index d3f05f878..bb64c3bd4 100644 --- a/config/meson.build +++ b/config/meson.build @@ -117,7 +117,7 @@ if not is_windows endif # use pthreads if available for the platform -if not is_ms_linker +if not is_windows add_project_link_arguments('-pthread', language: 'c') dpdk_extra_ldflags += '-pthread' endif From patchwork Sat Jun 20 22:35:43 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Kozlyuk X-Patchwork-Id: 71831 X-Patchwork-Delegate: thomas@monjalon.net 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 B47B1A0518; Sun, 21 Jun 2020 00:36:10 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 77E1B1BFD3; Sun, 21 Jun 2020 00:35:57 +0200 (CEST) Received: from mail-lf1-f65.google.com (mail-lf1-f65.google.com [209.85.167.65]) by dpdk.org (Postfix) with ESMTP id 8C3E01BFBD for ; Sun, 21 Jun 2020 00:35:53 +0200 (CEST) Received: by mail-lf1-f65.google.com with SMTP id c21so7561515lfb.3 for ; Sat, 20 Jun 2020 15:35:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=lbyH2PkOfUzzCnqpPX1GHDdOQATv2MmiBHtoTvBfFg0=; b=PdwCZE/6QtjskbvfO4frn61C/aY2HkEBgD5+HIGzmSUn4J6WEPdDZ/SqbjpmINZyDF dWdYr2wOzDslxiGfJFyIHKN51o19ley1t4+pjfnXLSM/ZIe2M2K9fyD8JYHHflF4x3Yn VtUJ7VENElENp5ORH/pFzxdruJ3jpGQvp0Ipq800mVXncLwdXN0dneQZhVYGg1ladcSN Bctkq/ztjo85UQIzRf5a7O9yQePRMVaxajHjM6eInMD4SNjbjQD6GHIHv24hX7ace5JV XsR0QeurNDvbLs3YuXWmrFYU2tGQeKU/L5EwVmWc0KmqPauyC0Bhz0z3BnDukh4QlKCv Vzkg== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=lbyH2PkOfUzzCnqpPX1GHDdOQATv2MmiBHtoTvBfFg0=; b=SbiBEnMBeZABiaTaoVD8RJwZWxJJHdR9HB1igQcD6n3s9b2oXq+y9f8e7590I5HkmF UpFcR5ZMjrKoJ2nv7gnFJzzCVKQqCn5QdrVuJ4F4j//4Y9AG1Z9CzafAsuhmN6Tc5DRR 0tSAgHeTgHUMCJp3ClAKqJ1WlrCsvL4hwYtxDwHNfMDE8R2fV7xgwyzSRyAKoVO9e9VZ YIHZeeMdMRVNygBMqWVDHCEyy3tLLc88E3efCqComqG0BqFmNxwh05NooKMRpf+ngjNK 6n3Jte8f3tFrhEreMmb5WI/yfAHTcwKDJIEYnxFWa6HTlMZjkAgf8zA4ChmZg7tl4ss9 amtQ== X-Gm-Message-State: AOAM531S/TxAexxvT8suX+41+/kZws6BoO9vrVcFRZfierlTLPlOqQXJ fqmOaeGt+gdpFAzsLhwzd70cVbANvYxhyA== X-Google-Smtp-Source: ABdhPJx0oUKODiTvteT0coBAW9umhBGapdO9QvD748ctmzfEiiqW2H97WMx8jD9TOm7R1ii0JHS1LA== X-Received: by 2002:a05:6512:31d1:: with SMTP id j17mr5260884lfe.148.1592692553100; Sat, 20 Jun 2020 15:35:53 -0700 (PDT) Received: from localhost.localdomain (broadband-37-110-65-23.ip.moscow.rt.ru. [37.110.65.23]) by smtp.gmail.com with ESMTPSA id q14sm1877015ljj.110.2020.06.20.15.35.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 20 Jun 2020 15:35:52 -0700 (PDT) From: Dmitry Kozlyuk To: dev@dpdk.org Cc: Thomas Monjalon , Tal Shnaiderman , Dmitry Kozlyuk , Bruce Richardson Date: Sun, 21 Jun 2020 01:35:43 +0300 Message-Id: <20200620223544.24070-3-dmitry.kozliuk@gmail.com> X-Mailer: git-send-email 2.25.4 In-Reply-To: <20200620223544.24070-1-dmitry.kozliuk@gmail.com> References: <20200620223544.24070-1-dmitry.kozliuk@gmail.com> MIME-Version: 1.0 Subject: [dpdk-dev] [PATCH 2/3] config/x86: don't use absolute paths for MinGW-w64 cross toolchain 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" Absolute paths in Meson cross-file impose unnecessary limitation on build environment, remove them. Signed-off-by: Dmitry Kozlyuk --- config/x86/meson_mingw.txt | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/config/x86/meson_mingw.txt b/config/x86/meson_mingw.txt index fac33cfcd..4c15a7fa2 100644 --- a/config/x86/meson_mingw.txt +++ b/config/x86/meson_mingw.txt @@ -1,10 +1,10 @@ [binaries] -c = '/usr/bin/x86_64-w64-mingw32-gcc' -cpp = '/usr/bin/x86_64-w64-mingw32-g++' -ld = '/usr/bin/x86_64-w64-mingw32-ld' -ar = '/usr/bin/x86_64-w64-mingw32-ar' -strip = '/usr/bin/x86_64-w64-mingw32-strip' -pkgconfig = '/usr/bin/x86_64-w64-mingw32-pkg-config' +c = 'x86_64-w64-mingw32-gcc' +cpp = 'x86_64-w64-mingw32-g++' +ld = 'x86_64-w64-mingw32-ld' +ar = 'x86_64-w64-mingw32-ar' +strip = 'x86_64-w64-mingw32-strip' +pkgconfig = 'x86_64-w64-mingw32-pkg-config' [host_machine] system = 'windows' From patchwork Sat Jun 20 22:35:44 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Kozlyuk X-Patchwork-Id: 71832 X-Patchwork-Delegate: thomas@monjalon.net 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 0E4C4A0518; Sun, 21 Jun 2020 00:36:18 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id A84D01BFE8; Sun, 21 Jun 2020 00:35:58 +0200 (CEST) Received: from mail-lj1-f196.google.com (mail-lj1-f196.google.com [209.85.208.196]) by dpdk.org (Postfix) with ESMTP id 781811BFC1 for ; Sun, 21 Jun 2020 00:35:54 +0200 (CEST) Received: by mail-lj1-f196.google.com with SMTP id s1so15410639ljo.0 for ; Sat, 20 Jun 2020 15:35:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=MRLVSjUPRqK+yPZy/1Ij3but2s9fEePJC2BgtuEM5nk=; b=ifUo35XBv3aYb2TleUsMf9/ylEw2Nh3W3NgHURJPf+5sXnT9jM5zJYuzwB1KD7zu6i JuoRqqg7qWZszrvyn/uuEMrld3oZYZ+8/Koi82zejvCpGdic+0k0v99wSq5nsuuuvohq wVVDQRK1IoDmPqYXoFs1BgUPjs18WvdOGv/dElkvMhEFskOejxHHN+VVYAajqp741JSO otsiPAxqcCDjffQCTw0k4MsueomXJm00qNO7S6I8Nassveu65i3l4+pbYnzXmdJcNR4O K5L3sui/C4lTQ1nV0Fz3gZerR9sRcwXAxwjk5T82uqDTyTCeVoXxQFK4IWlWz/m6G+9/ Ujsg== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=MRLVSjUPRqK+yPZy/1Ij3but2s9fEePJC2BgtuEM5nk=; b=Ys3B7Slhpl2KEYJysxOO5uyUiUzF1wWhDwkbEycs3Cn3CkFFXJRANbqLK8rDuziVM4 pRruXZfiFr29KSK6hztJAaiGe/Olfh0pi9dmoFvBvjY9Guxw/2edOxLUiEwsVFWMV6WW Pi3As62H8YiddZGQr/hhLS1RAsktylPVuVXtKePS7GNZ4S89j/9A4HRmTc4IhrH+Baqq UqittCHYw4oSDVingWZzMS2fBkJyOmuRPGH5vfYU8G63hSDI+ZpxEAkDN+qJvAuJUujH GixYc2PQpt6KWmoolFLp03LSDpyNcJjUHhQH1ll3wG++a4yO9cxAiWx9zOg1qn2NyLTG GZGw== X-Gm-Message-State: AOAM530UB2iTLeAQAenn/jMIQBiIsFudnc3hgd6i2EyZZ8YUdueKxPuk 7GrIe7WkJMborg5/OAEb3JQ84A3zlW8EPA== X-Google-Smtp-Source: ABdhPJxlx/ir6LvCet3UYfipt93J6VJcf+qYLjb//gQSanRlxZ+80VXl8mKmRIiJPEEXkvCB8PcLvg== X-Received: by 2002:a2e:87da:: with SMTP id v26mr4744729ljj.14.1592692553833; Sat, 20 Jun 2020 15:35:53 -0700 (PDT) Received: from localhost.localdomain (broadband-37-110-65-23.ip.moscow.rt.ru. [37.110.65.23]) by smtp.gmail.com with ESMTPSA id q14sm1877015ljj.110.2020.06.20.15.35.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 20 Jun 2020 15:35:53 -0700 (PDT) From: Dmitry Kozlyuk To: dev@dpdk.org Cc: Thomas Monjalon , Tal Shnaiderman , Dmitry Kozlyuk Date: Sun, 21 Jun 2020 01:35:44 +0300 Message-Id: <20200620223544.24070-4-dmitry.kozliuk@gmail.com> X-Mailer: git-send-email 2.25.4 In-Reply-To: <20200620223544.24070-1-dmitry.kozliuk@gmail.com> References: <20200620223544.24070-1-dmitry.kozliuk@gmail.com> MIME-Version: 1.0 Subject: [dpdk-dev] [PATCH 3/3] doc/windows: clarify installation for MinGW-w64 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" Provide a more direct link for installer download and clarify thread model choice during installation. As pthread is not a requirement, remove notice about its possible runtime dependency. Signed-off-by: Dmitry Kozlyuk --- doc/guides/windows_gsg/build_dpdk.rst | 12 +++++++----- doc/guides/windows_gsg/run_apps.rst | 7 +------ 2 files changed, 8 insertions(+), 11 deletions(-) diff --git a/doc/guides/windows_gsg/build_dpdk.rst b/doc/guides/windows_gsg/build_dpdk.rst index 650483e3b..5757446cc 100644 --- a/doc/guides/windows_gsg/build_dpdk.rst +++ b/doc/guides/windows_gsg/build_dpdk.rst @@ -44,14 +44,16 @@ and ensure the Windows SDK is selected. Option 2. MinGW-w64 Toolchain ----------------------------- -Obtain the latest version from -`MinGW-w64 website `_. -On Windows, install to a folder without spaces in its name, like ``C:\MinGW``. -This path is assumed for the rest of this guide. - +On Linux, i.e. for cross-compilation, install MinGW-w64 via a package manager. Version 4.0.4 for Ubuntu 16.04 cannot be used due to a `MinGW-w64 bug `_. +On Windows, obtain the latest version installer from +`MinGW-w64 repository `_. +Any thread model (POSIX or Win32) can be chosen, DPDK does not rely on it. +Install to a folder without spaces in its name, like ``C:\MinGW``. +This path is assumed for the rest of this guide. + Install the Build System ------------------------ diff --git a/doc/guides/windows_gsg/run_apps.rst b/doc/guides/windows_gsg/run_apps.rst index 78e5a614f..abaecc379 100644 --- a/doc/guides/windows_gsg/run_apps.rst +++ b/doc/guides/windows_gsg/run_apps.rst @@ -83,13 +83,8 @@ Navigate to the examples in the build directory and run `dpdk-helloworld.exe`. .. code-block:: console cd C:\Users\me\dpdk\build\examples - dpdk-helloworld.exe + dpdk-helloworld.exe -l 0-3 hello from core 1 hello from core 3 hello from core 0 hello from core 2 - -Note for MinGW-w64: applications are linked to ``libwinpthread-1.dll`` -by default. To run the example, either add toolchain executables directory -to the PATH or copy the library to the working directory. -Alternatively, static linking may be used (mind the LGPLv2.1 license).