diff mbox series

[v2] buildtools: fix all drivers disabled on Windows

Message ID 20210416204852.15888-1-dmitry.kozliuk@gmail.com (mailing list archive)
State Accepted
Delegated to: Thomas Monjalon
Headers show
Series [v2] buildtools: fix all drivers disabled on Windows | expand

Checks

Context Check Description
ci/iol-testing success Testing PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-abi-testing success Testing PASS
ci/github-robot success github build: passed
ci/travis-robot success travis build: passed
ci/intel-Testing success Testing PASS
ci/Intel-compilation success Compilation OK
ci/checkpatch warning coding style issues

Commit Message

Dmitry Kozlyuk April 16, 2021, 8:48 p.m. UTC
buildtools/list-dir-globs.py printed paths with OS directory separator,
which is "/" on Unices and "\" on Windows, while Meson code always
expected "/". This resulted in all drivers being disabled on Windows.

Replace "\" with "/" in script output. Forward slash is a valid,
although non-default, separator on Windows, so no paths can be broken
by this substitution.

Fixes: ab9407c3addd ("build: allow using wildcards to disable drivers")
Cc: stable@dpdk.org

Signed-off-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
v2: Change fixes line, correct a typo (Juraj, Bruce).

Not sure if it's worth backporting: it wasn't an issue in 20.11
and the patch won't apply as-is.

 buildtools/list-dir-globs.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Thomas Monjalon April 17, 2021, 10:48 a.m. UTC | #1
16/04/2021 22:48, Dmitry Kozlyuk:
> buildtools/list-dir-globs.py printed paths with OS directory separator,
> which is "/" on Unices and "\" on Windows, while Meson code always
> expected "/". This resulted in all drivers being disabled on Windows.
> 
> Replace "\" with "/" in script output. Forward slash is a valid,
> although non-default, separator on Windows, so no paths can be broken
> by this substitution.
> 
> Fixes: ab9407c3addd ("build: allow using wildcards to disable drivers")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
> Acked-by: Bruce Richardson <bruce.richardson@intel.com>
> ---
> v2: Change fixes line, correct a typo (Juraj, Bruce).
> 
> Not sure if it's worth backporting: it wasn't an issue in 20.11
> and the patch won't apply as-is.

The commit you mention was introduced in 21.02.
No matter which release it is, it is good to suggest backporting
for those who need to maintain an old release even if not upstream.

Applied, thanks
diff mbox series

Patch

diff --git a/buildtools/list-dir-globs.py b/buildtools/list-dir-globs.py
index 911e267335..d824360d39 100755
--- a/buildtools/list-dir-globs.py
+++ b/buildtools/list-dir-globs.py
@@ -17,4 +17,4 @@ 
     if path:
         for p in iglob(os.path.join(root, path)):
             if os.path.isdir(p):
-                print(os.path.relpath(p))
+                print(os.path.relpath(p).replace('\\', '/'))