File tree 2 files changed +5
-1
lines changed
2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -1513,7 +1513,8 @@ void ToolChain::getRuntimeLibraryPaths(SmallVectorImpl<std::string> &runtimeLibP
1513
1513
if (!scratchPath.empty ())
1514
1514
runtimeLibPaths.push_back (std::string (scratchPath.str ()));
1515
1515
1516
- if (!SDKPath.empty ()) {
1516
+ // Only Darwin places libraries directly in /sdk/usr/lib/swift/.
1517
+ if (Triple.isOSDarwin () && !SDKPath.empty ()) {
1517
1518
if (!scratchPath.empty ()) {
1518
1519
// If we added the secondary resource dir, we also need the iOSSupport
1519
1520
// directory.
Original file line number Diff line number Diff line change 58
58
// CHECK-COMPLEX-DAG: DYLD_FRAMEWORK_PATH=/foo/:/bar/:/abc/{{$| }}
59
59
// CHECK-COMPLEX-DAG: DYLD_LIBRARY_PATH={{/foo2/:/bar2/:[^:]+/lib/swift/macosx:/sdkroot/usr/lib/swift($| )}}
60
60
61
+ // RUN: %swift_driver_plain -sdk /sdk -### -target aarch64-unknown-linux-gnu %s | %FileCheck -check-prefix=CHECK-RUNTIME-LIBRARY-PATH %s
62
+ // CHECK-RUNTIME-LIBRARY-PATH-NOT: # LD_LIBRARY_PATH=/sdk/usr/lib/swift/linux:/sdk/usr/lib/swift
63
+
61
64
// RUN: %swift_driver_plain -sdk "" -### -target x86_64-unknown-linux-gnu -L/foo/ %s | %FileCheck -check-prefix=CHECK-L-LINUX${LD_LIBRARY_PATH+_LAX} %s
62
65
// CHECK-L-LINUX: # LD_LIBRARY_PATH={{/foo/:[^:]+/lib/swift/linux$}}
63
66
// CHECK-L-LINUX_LAX: # LD_LIBRARY_PATH={{/foo/:[^:]+/lib/swift/linux($|:)}}
You can’t perform that action at this time.
0 commit comments