1# RUN: not ld64.lld.darwinold -test_file_usage -v \
2# RUN:        -path_exists /usr/lib \
3# RUN:        -path_exists /Applications/MySDK/usr/local/lib \
4# RUN:        -path_exists /Applications/MySDK/usr/lib \
5# RUN:        -path_exists /Applications/MySDK/usr/lib/libSystem.dylib \
6# RUN:        -syslibroot /Applications/MySDK \
7# RUN:        -syslibroot / \
8# RUN:        -lSystem \
9# RUN: 2>&1 | FileCheck %s
10
11# When the last -syslibroot is simply "/", all of them get discarded. So in this
12# case, only /usr/lib should show up.
13
14# CHECK: Library search paths:
15# CHECK:     /usr/lib
16# CHECK-NOT:     /usr/local/lib
17# CHECK: Unable to find library for -lSystem
18