[clang] [flang] [clang][driver] Special care for -l flags in config files (PR #117573)
Fangrui Song via cfe-commits
cfe-commits at lists.llvm.org
Fri Nov 29 19:14:42 PST 2024
================
@@ -82,3 +82,35 @@
// CHECK-TWO-CONFIGS: -isysroot
// CHECK-TWO-CONFIGS-SAME: /opt/data
// CHECK-TWO-CONFIGS-SAME: -Wall
+
+//--- The linker input flags should be moved to the end of input list and appear only when linking.
+// RUN: %clang --target=aarch64-unknown-linux-gnu --config %S/Inputs/config-l.cfg -o %s.out %s -### 2>&1 | FileCheck %s -check-prefix CHECK-LINKING
----------------
MaskRay wrote:
`-o %s.out` is strange. We typically use `-o %t` for output. That said, since we use -### and the output isn't useful, just omit it.
https://github.com/llvm/llvm-project/pull/117573
More information about the cfe-commits
mailing list