// RUN: FileCheck -input-file %t.log %s
// CHECK: clang{{.*}}" "-cc1" "-triple" "amd64-pc-dragonfly"
-// CHECK: as{{.*}}" "-o" "{{.*}}.o" "{{.*}}.s
// CHECK: ld{{.*}}" "-dynamic-linker" "{{.*}}ld-elf.{{.*}}" "-o" "a.out" "{{.*}}crt1.o" "{{.*}}crti.o" "{{.*}}crtbegin.o" "{{.*}}.o" "-L{{.*}}/gcc{{.*}}" {{.*}} "-lc" "-lgcc" "{{.*}}crtend.o" "{{.*}}crtn.o"
// RUN: FileCheck --check-prefix=CHECK-PPC < %t %s
//
// CHECK-PPC: clang{{.*}}" "-cc1" "-triple" "powerpc64-pc-freebsd8"
-// CHECK-PPC: as{{.*}}" "-o" "{{.*}}.o" "{{.*}}.s
// CHECK-PPC: ld{{.*}}" "--eh-frame-hdr" "-dynamic-linker" "{{.*}}ld-elf{{.*}}" "-o" "a.out" "{{.*}}crt1.o" "{{.*}}crti.o" "{{.*}}crtbegin.o" "{{.*}}.o" "-lgcc" "--as-needed" "-lgcc_s" "--no-as-needed" "-lc" "-lgcc" "--as-needed" "-lgcc_s" "--no-as-needed" "{{.*}}crtend.o" "{{.*}}crtn.o"
// RUN: FileCheck --check-prefix=CHECK-LIB32 < %t %s
//
// CHECK-LIB32: clang{{.*}}" "-cc1" "-triple" "i386-pc-freebsd8"
-// CHECK-LIB32: as{{.*}}" "--32"
// CHECK-LIB32: ld{{.*}}" {{.*}} "-m" "elf_i386_fbsd"
//
// RUN: %clang -ccc-host-triple x86_64-pc-freebsd8 -m32 -print-search-dirs %s > %t
// RUN: FileCheck -input-file %t.log %s
// CHECK: clang{{.*}}" "-cc1" "-triple" "i686-pc-openbsd"
-// CHECK: as{{.*}}" "-o" "{{.*}}.o" "{{.*}}.s
// CHECK: ld{{.*}}" "-e" "__start" "--eh-frame-hdr" "-Bdynamic" "-dynamic-linker" "{{.*}}ld.so" "-o" "a.out" "{{.*}}crt0.o" "{{.*}}crtbegin.o" "{{.*}}.o" "-lgcc" "-lc" "-lgcc" "{{.*}}crtend.o"