Index: clang/test/Driver/fuse-ld.c =================================================================== --- clang/test/Driver/fuse-ld.c +++ clang/test/Driver/fuse-ld.c @@ -40,6 +40,25 @@ // RUN: | FileCheck %s -check-prefix=CHECK-FREEBSD-PLIB // CHECK-FREEBSD-PLIB: error: invalid linker name +// RUN: %clang %s -### \ +// RUN: -target x86_64-unknown-netbsd 2>&1 \ +// RUN: | FileCheck %s --check-prefix=CHECK-NETBSD-LD +// CHECK-NETBSD-LD: ld + +// RUN: %clang %s -### -fuse-ld=bfd \ +// RUN: --sysroot=%S/Inputs/basic_netbsd_tree \ +// RUN: -target x86_64-unknown-netbsd \ +// RUN: -B%S/Inputs/basic_netbsd_tree/usr/bin 2>&1 \ +// RUN: | FileCheck %s -check-prefix=CHECK-NETBSD-BFD +// CHECK-NETBSD-BFD: Inputs/basic_netbsd_tree/usr/bin{{/|\\+}}ld.bfd + +// RUN: %clang %s -### -fuse-ld=gold \ +// RUN: --sysroot=%S/Inputs/basic_netbsd_tree \ +// RUN: -target x86_64-unknown-netbsd \ +// RUN: -B%S/Inputs/basic_netbsd_tree/usr/bin 2>&1 \ +// RUN: | FileCheck %s -check-prefix=CHECK-NETBSD-GOLD +// CHECK-NETBSD-GOLD: Inputs/basic_netbsd_tree/usr/bin{{/|\\+}}ld.gold + // RUN: %clang %s -### -fuse-ld=ld \ // RUN: -target arm-linux-androideabi \ // RUN: -B%S/Inputs/basic_android_tree/bin/arm-linux-androideabi- 2>&1 \