r215292 - Use the correct fallback directory for EABIHF targets on NetBSD/arm.

Joerg Sonnenberger joerg at bec.de
Sat Aug 9 12:01:53 PDT 2014


Author: joerg
Date: Sat Aug  9 14:01:52 2014
New Revision: 215292

URL: http://llvm.org/viewvc/llvm-project?rev=215292&view=rev
Log:
Use the correct fallback directory for EABIHF targets on NetBSD/arm.
>From Matt Thomas.

Added:
    cfe/trunk/test/Driver/Inputs/basic_netbsd_tree/usr/lib/eabihf/
Modified:
    cfe/trunk/lib/Driver/ToolChains.cpp
    cfe/trunk/test/Driver/netbsd.c

Modified: cfe/trunk/lib/Driver/ToolChains.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/ToolChains.cpp?rev=215292&r1=215291&r2=215292&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/ToolChains.cpp (original)
+++ cfe/trunk/lib/Driver/ToolChains.cpp Sat Aug  9 14:01:52 2014
@@ -2590,11 +2590,13 @@ NetBSD::NetBSD(const Driver &D, const ll
     case llvm::Triple::thumbeb:
       switch (Triple.getEnvironment()) {
       case llvm::Triple::EABI:
-      case llvm::Triple::EABIHF:
       case llvm::Triple::GNUEABI:
-      case llvm::Triple::GNUEABIHF:
         getFilePaths().push_back("=/usr/lib/eabi");
         break;
+      case llvm::Triple::EABIHF:
+      case llvm::Triple::GNUEABIHF:
+        getFilePaths().push_back("=/usr/lib/eabihf");
+        break;
       default:
         getFilePaths().push_back("=/usr/lib/oabi");
         break;

Modified: cfe/trunk/test/Driver/netbsd.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/netbsd.c?rev=215292&r1=215291&r2=215292&view=diff
==============================================================================
--- cfe/trunk/test/Driver/netbsd.c (original)
+++ cfe/trunk/test/Driver/netbsd.c Sat Aug  9 14:01:52 2014
@@ -19,6 +19,9 @@
 // RUN: %clang -no-canonical-prefixes -target arm--netbsd \
 // RUN: -no-integrated-as --sysroot=%S/Inputs/basic_netbsd_tree %s -### 2>&1 \
 // RUN: | FileCheck -check-prefix=ARM-APCS %s
+// RUN: %clang -no-canonical-prefixes -target arm--netbsd-eabihf \
+// RUN: -no-integrated-as --sysroot=%S/Inputs/basic_netbsd_tree %s -### 2>&1 \
+// RUN: | FileCheck -check-prefix=ARM-HF %s
 // RUN: %clang -no-canonical-prefixes -target thumb--netbsd-eabi \
 // RUN: -no-integrated-as --sysroot=%S/Inputs/basic_netbsd_tree %s -### 2>&1 \
 // RUN: | FileCheck -check-prefix=THUMB %s
@@ -28,9 +31,6 @@
 // RUN: %clang -no-canonical-prefixes -target arm--netbsd6.0.0-eabi \
 // RUN: --sysroot=%S/Inputs/basic_netbsd_tree %s -### 2>&1 \
 // RUN: | FileCheck -check-prefix=ARM-6 %s
-// RUN: %clang -no-canonical-prefixes -target arm--netbsd-eabihf \
-// RUN: -no-integrated-as --sysroot=%S/Inputs/basic_netbsd_tree %s -### 2>&1 \
-// RUN: | FileCheck -check-prefix=ARM-HF %s
 // RUN: %clang -no-canonical-prefixes -target sparc--netbsd \
 // RUN: -no-integrated-as --sysroot=%S/Inputs/basic_netbsd_tree %s -### 2>&1 \
 // RUN: | FileCheck -check-prefix=SPARC %s
@@ -123,6 +123,15 @@
 // ARM-APCS: "{{.*}}/usr/lib{{/|\\\\}}crtbegin.o" "{{.*}}.o" "-lc"
 // ARM-APCS: "{{.*}}/usr/lib{{/|\\\\}}crtend.o" "{{.*}}/usr/lib{{/|\\\\}}crtn.o"
 
+// ARM-HF: clang{{.*}}" "-cc1" "-triple" "armv5e--netbsd-eabihf"
+// ARM-HF: as{{.*}}" "-mcpu=arm926ej-s" "-o"
+// ARM-HF: ld{{.*}}" "--eh-frame-hdr" "-dynamic-linker" "/libexec/ld.elf_so"
+// ARM-HF: "-m" "armelf_nbsd_eabihf"
+// ARM-HF: "-o" "a.out" "{{.*}}/usr/lib{{/|\\\\}}crt0.o"
+// ARM-HF: "{{.*}}/usr/lib{{/|\\\\}}eabihf{{/|\\\\}}crti.o"
+// ARM-HF: "{{.*}}/usr/lib{{/|\\\\}}crtbegin.o" "{{.*}}.o" "-lc"
+// ARM-HF: "{{.*}}/usr/lib{{/|\\\\}}crtend.o" "{{.*}}/usr/lib{{/|\\\\}}crtn.o"
+
 // THUMB: clang{{.*}}" "-cc1" "-triple" "armv5e--netbsd-eabi"
 // THUMB: as{{.*}}" "-mcpu=arm926ej-s" "-o"
 // THUMB: ld{{.*}}" "--eh-frame-hdr" "-dynamic-linker" "/libexec/ld.elf_so"
@@ -148,9 +157,6 @@
 // ARM-6: "{{.*}}/usr/lib{{/|\\\\}}crtbegin.o" "{{.*}}.o" "-lc"
 // ARM-6: "{{.*}}/usr/lib{{/|\\\\}}crtend.o" "{{.*}}/usr/lib{{/|\\\\}}crtn.o"
 
-// ARM-HF: clang{{.*}}" "-cc1" "-triple" "armv5e--netbsd-eabihf"
-// ARM-HF: ld{{.*}}" "-m" "armelf_nbsd_eabihf"
-
 // SPARC: clang{{.*}}" "-cc1" "-triple" "sparc--netbsd"
 // SPARC: as{{.*}}" "-32" "-o"
 // SPARC: ld{{.*}}" "--eh-frame-hdr" "-dynamic-linker" "/libexec/ld.elf_so"





More information about the cfe-commits mailing list