Skip to content

[Driver,test] Remove -v from mkdir & ln -s from a test since it fails on AIX #72924

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 21, 2023
Merged

[Driver,test] Remove -v from mkdir & ln -s from a test since it fails on AIX #72924

merged 1 commit into from
Nov 21, 2023

Conversation

ilg-ul
Copy link
Contributor

@ilg-ul ilg-ul commented Nov 20, 2023

The PR #70817 introduced a small bug, the tests failed on ppc64-aix with:

RUN: at line 186: mkdir -pv /home/powerllvm/powerllvm_env/aix-ppc64/clang-ppc64-aix/build/tools/clang/test/Driver/Output/darwin-header-search-libcxx.cpp.tmp/install/bin
+ mkdir -pv /home/powerllvm/powerllvm_env/aix-ppc64/clang-ppc64-aix/build/tools/clang/test/Driver/Output/darwin-header-search-libcxx.cpp.tmp/install/bin
mkdir: illegal option -- v
Usage: mkdir [-p] [-e] [-m mode] Directory ... 

This PR removes the verbose flag from both mkdir and ln -s.

@llvmbot llvmbot added clang Clang issues not falling into any other category clang:driver 'clang' and 'clang++' user-facing binaries. Not 'clang-cl' labels Nov 20, 2023
@llvmbot
Copy link
Member

llvmbot commented Nov 20, 2023

@llvm/pr-subscribers-clang-driver

Author: Liviu Ionescu (ilg-ul)

Changes

The PR #70817 introduced a small bug, the tests failed on ppc64 with:

RUN: at line 186: mkdir -pv /home/powerllvm/powerllvm_env/aix-ppc64/clang-ppc64-aix/build/tools/clang/test/Driver/Output/darwin-header-search-libcxx.cpp.tmp/install/bin
+ mkdir -pv /home/powerllvm/powerllvm_env/aix-ppc64/clang-ppc64-aix/build/tools/clang/test/Driver/Output/darwin-header-search-libcxx.cpp.tmp/install/bin
mkdir: illegal option -- v
Usage: mkdir [-p] [-e] [-m mode] Directory ... 

This PR removes the verbose flag from both mkdir and ln -s.


Full diff: https://github.com/llvm/llvm-project/pull/72924.diff

1 Files Affected:

  • (modified) clang/test/Driver/darwin-header-search-libcxx.cpp (+7-7)
diff --git a/clang/test/Driver/darwin-header-search-libcxx.cpp b/clang/test/Driver/darwin-header-search-libcxx.cpp
index 8f530299d53c6d8..70cc06090a993d6 100644
--- a/clang/test/Driver/darwin-header-search-libcxx.cpp
+++ b/clang/test/Driver/darwin-header-search-libcxx.cpp
@@ -183,15 +183,15 @@
 // local folder hierarchy that meets this requirement.
 // Note: this might not work with weird RPATH configurations.
 // RUN: rm -rf %t/install
-// RUN: mkdir -pv %t/install/bin
+// RUN: mkdir -p %t/install/bin
 // RUN: cp %clang %t/install/bin/clang
-// RUN: mkdir -pv %t/install/include/c++/v1
+// RUN: mkdir -p %t/install/include/c++/v1
 
 // Headers in (1) and in (2) -> (1) is preferred over (2)
 // RUN: rm -rf %t/symlinked1
-// RUN: mkdir -pv %t/symlinked1/bin
-// RUN: ln -svf %t/install/bin/clang %t/symlinked1/bin/clang
-// RUN: mkdir -pv %t/symlinked1/include/c++/v1
+// RUN: mkdir -p %t/symlinked1/bin
+// RUN: ln -sf %t/install/bin/clang %t/symlinked1/bin/clang
+// RUN: mkdir -p %t/symlinked1/include/c++/v1
 
 // RUN: %t/symlinked1/bin/clang -### %s -fsyntax-only 2>&1 \
 // RUN:     --target=x86_64-apple-darwin \
@@ -207,8 +207,8 @@
 
 // Headers in (2) and in (3) -> (2) is preferred over (3)
 // RUN: rm -rf %t/symlinked2
-// RUN: mkdir -pv %t/symlinked2/bin
-// RUN: ln -svf %t/install/bin/clang %t/symlinked2/bin/clang
+// RUN: mkdir -p %t/symlinked2/bin
+// RUN: ln -sf %t/install/bin/clang %t/symlinked2/bin/clang
 
 // RUN: %t/symlinked2/bin/clang -### %s -fsyntax-only 2>&1 \
 // RUN:     --target=x86_64-apple-darwin \

@llvmbot
Copy link
Member

llvmbot commented Nov 20, 2023

@llvm/pr-subscribers-clang

Author: Liviu Ionescu (ilg-ul)

Changes

The PR #70817 introduced a small bug, the tests failed on ppc64 with:

RUN: at line 186: mkdir -pv /home/powerllvm/powerllvm_env/aix-ppc64/clang-ppc64-aix/build/tools/clang/test/Driver/Output/darwin-header-search-libcxx.cpp.tmp/install/bin
+ mkdir -pv /home/powerllvm/powerllvm_env/aix-ppc64/clang-ppc64-aix/build/tools/clang/test/Driver/Output/darwin-header-search-libcxx.cpp.tmp/install/bin
mkdir: illegal option -- v
Usage: mkdir [-p] [-e] [-m mode] Directory ... 

This PR removes the verbose flag from both mkdir and ln -s.


Full diff: https://github.com/llvm/llvm-project/pull/72924.diff

1 Files Affected:

  • (modified) clang/test/Driver/darwin-header-search-libcxx.cpp (+7-7)
diff --git a/clang/test/Driver/darwin-header-search-libcxx.cpp b/clang/test/Driver/darwin-header-search-libcxx.cpp
index 8f530299d53c6d8..70cc06090a993d6 100644
--- a/clang/test/Driver/darwin-header-search-libcxx.cpp
+++ b/clang/test/Driver/darwin-header-search-libcxx.cpp
@@ -183,15 +183,15 @@
 // local folder hierarchy that meets this requirement.
 // Note: this might not work with weird RPATH configurations.
 // RUN: rm -rf %t/install
-// RUN: mkdir -pv %t/install/bin
+// RUN: mkdir -p %t/install/bin
 // RUN: cp %clang %t/install/bin/clang
-// RUN: mkdir -pv %t/install/include/c++/v1
+// RUN: mkdir -p %t/install/include/c++/v1
 
 // Headers in (1) and in (2) -> (1) is preferred over (2)
 // RUN: rm -rf %t/symlinked1
-// RUN: mkdir -pv %t/symlinked1/bin
-// RUN: ln -svf %t/install/bin/clang %t/symlinked1/bin/clang
-// RUN: mkdir -pv %t/symlinked1/include/c++/v1
+// RUN: mkdir -p %t/symlinked1/bin
+// RUN: ln -sf %t/install/bin/clang %t/symlinked1/bin/clang
+// RUN: mkdir -p %t/symlinked1/include/c++/v1
 
 // RUN: %t/symlinked1/bin/clang -### %s -fsyntax-only 2>&1 \
 // RUN:     --target=x86_64-apple-darwin \
@@ -207,8 +207,8 @@
 
 // Headers in (2) and in (3) -> (2) is preferred over (3)
 // RUN: rm -rf %t/symlinked2
-// RUN: mkdir -pv %t/symlinked2/bin
-// RUN: ln -svf %t/install/bin/clang %t/symlinked2/bin/clang
+// RUN: mkdir -p %t/symlinked2/bin
+// RUN: ln -sf %t/install/bin/clang %t/symlinked2/bin/clang
 
 // RUN: %t/symlinked2/bin/clang -### %s -fsyntax-only 2>&1 \
 // RUN:     --target=x86_64-apple-darwin \

@ilg-ul
Copy link
Contributor Author

ilg-ul commented Nov 20, 2023

@ldionne, could you take a look? This should fix the bug introduced by the previous PR.

@MaskRay
Copy link
Member

MaskRay commented Nov 21, 2023

since it fails on ppc64

Change ppc64 to AIX. This is OS-specific instead of arch-specific. AIX mkdir doesn't provide -v, but other ppc64 OSes (e.g. Linux/FreeBSD) may provide -v even if https://pubs.opengroup.org/onlinepubs/9699919799/ does not require it.

@MaskRay MaskRay changed the title [clang][driver] Remove -v from mkdir & ln -s from a test since it fails on ppc64 [clang][driver] Remove -v from mkdir & ln -s from a test since it fails on AIX Nov 21, 2023
@MaskRay MaskRay changed the title [clang][driver] Remove -v from mkdir & ln -s from a test since it fails on AIX [Driver,test] Remove -v from mkdir & ln -s from a test since it fails on AIX Nov 21, 2023
@ilg-ul
Copy link
Contributor Author

ilg-ul commented Nov 21, 2023

Thank you @MaskRay for correcting the title and for the approval.

Please also merge it when possible.

@MaskRay MaskRay merged commit e4151cc into llvm:main Nov 21, 2023
@ilg-ul
Copy link
Contributor Author

ilg-ul commented Nov 21, 2023

Great! Thank you!

@MaskRay
Copy link
Member

MaskRay commented Nov 21, 2023

Thank you for the patch and open for my idea changing the title :)

I think [test] as a tag is more common a patch that only deals with tests (more common than trailing . NFC or [NFC]), so I used it.

@ilg-ul
Copy link
Contributor Author

ilg-ul commented Nov 21, 2023

Is there a page documenting these tags?

@MaskRay
Copy link
Member

MaskRay commented Nov 21, 2023

Is there a page documenting these tags?

There is no AFAIK, but as I have done git log a lot and I have figured out the convention...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clang:driver 'clang' and 'clang++' user-facing binaries. Not 'clang-cl' clang Clang issues not falling into any other category
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants