Genericize implementation of GetDLLSuffix now that we have LTDL_SHLIB_EXT
authorReid Spencer <rspencer@reidspencer.com>
Mon, 13 Dec 2004 18:41:28 +0000 (18:41 +0000)
committerReid Spencer <rspencer@reidspencer.com>
Mon, 13 Dec 2004 18:41:28 +0000 (18:41 +0000)
available.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18904 91177308-0d34-0410-b5e6-96231b3b80d8

lib/System/AIX/Path.cpp
lib/System/Cygwin/Path.cpp
lib/System/Darwin/Path.cpp
lib/System/FreeBSD/Path.cpp
lib/System/Interix/Path.cpp
lib/System/Linux/Path.cpp
lib/System/Path.cpp
lib/System/SunOS/Path.cpp
lib/System/Win32/Path.cpp
lib/System/Win32/Path.inc

index 8eddb967bd355ab5086081e0564ca155a7b97760..56a006dbad9a60850256007bb9d880771d13dc4a 100644 (file)
@@ -48,11 +48,6 @@ Path::GetTemporaryDirectory() {
   return result;
 }
 
-std::string
-Path::GetDLLSuffix() {
-  return "so";
-}
-
 }
 
 // vim: sw=2 smartindent smarttab tw=80 autoindent expandtab
index 01a40da4e7cb5d33e7a30d360f3d1da50d89b50e..43dae2f982bb4c655a760a576234d84e302007f8 100644 (file)
@@ -47,11 +47,6 @@ Path::GetTemporaryDirectory() {
   return result;
 }
 
-std::string
-Path::GetDLLSuffix() {
-  return "dll.a";
-}
-
 }
 
 // vim: sw=2 smartindent smarttab tw=80 autoindent expandtab
index ed391079487c9cfff8e87a965ff8e9e34e3e085a..d34ad80ef22c31156ca6a3ab1fcae960bdffc5ba 100644 (file)
@@ -43,11 +43,6 @@ Path::GetTemporaryDirectory() {
   return result;
 }
 
-std::string
-Path::GetDLLSuffix() {
-  return "dylib";
-}
-
 }
 
 // vim: sw=2 smartindent smarttab tw=80 autoindent expandtab
index 7dac6fd5e98c676b3376860522d8498ee31aafbd..837f830c4fe3abff89ffd04ea4f8a015465a672f 100644 (file)
@@ -45,11 +45,6 @@ Path::GetTemporaryDirectory() {
   return result;
 }
 
-std::string
-Path::GetDLLSuffix() {
-  return "so";
-}
-
 }
 
 // vim: sw=2 smartindent smarttab tw=80 autoindent expandtab
index 45ab13a6dc683a07edcc80c0268382cdc8017a7e..4fb38cb1f5ade9e7b171a40cf097b87be274f5bb 100644 (file)
@@ -45,11 +45,6 @@ Path::GetTemporaryDirectory() {
   return result;
 }
 
-std::string
-Path::GetDLLSuffix() {
-  return "dll";
-}
-
 }
 
 // vim: sw=2 smartindent smarttab tw=80 autoindent expandtab
index 5238c1f329b8585cbcca346ec1b942add8a73da6..d0eccb783f1c604fd877ec60fc277d93ab84b3f4 100644 (file)
@@ -45,11 +45,6 @@ Path::GetTemporaryDirectory() {
   return result;
 }
 
-std::string
-Path::GetDLLSuffix() {
-  return "so";
-}
-
 }
 
 // vim: sw=2 smartindent smarttab tw=80 autoindent expandtab
index 1a6d030f89679af4a313c72f4211b6a186257ca0..d0ee1a3ae89acfd957b79b870ec68ac1a2f14156 100644 (file)
@@ -12,6 +12,7 @@
 //===----------------------------------------------------------------------===//
 
 #include "llvm/System/Path.h"
+#include "llvm/Config/config.h"
 #include <cassert>
 
 namespace llvm {
@@ -80,6 +81,11 @@ Path::FindLibrary(std::string& name) {
   return sys::Path();
 }
 
+std::string
+Path::GetDLLSuffix() {
+  return LTDL_SHLIB_EXT;
+}
+
 }
 
 // Include the truly platform-specific parts of this class.
index db6db19c38bfb433c9a15f929f71b45ef4d40928..346615d55c221bacfe8644cf07282f7fa242e07d 100644 (file)
@@ -47,11 +47,6 @@ Path::GetTemporaryDirectory() {
   return result;
 }
 
-std::string
-Path::GetDLLSuffix() {
-  return "so";
-}
-
 }
 
 // vim: sw=2 smartindent smarttab tw=80 autoindent expandtab
index 8201dd4ab22d66c7f6e972081cce6a1c563f9ec5..e847154e583623226ba8ccdb1a49ef677724f61b 100644 (file)
@@ -118,11 +118,6 @@ Path::GetRootDirectory() {
   return result;
 }
 
-std::string
-Path::GetDLLSuffix() {
-  return "dll";
-}
-
 static void getPathList(const char*path, std::vector<sys::Path>& Paths) {
   const char* at = path;
   const char* delim = strchr(at, ';');
index 8201dd4ab22d66c7f6e972081cce6a1c563f9ec5..e847154e583623226ba8ccdb1a49ef677724f61b 100644 (file)
@@ -118,11 +118,6 @@ Path::GetRootDirectory() {
   return result;
 }
 
-std::string
-Path::GetDLLSuffix() {
-  return "dll";
-}
-
 static void getPathList(const char*path, std::vector<sys::Path>& Paths) {
   const char* at = path;
   const char* delim = strchr(at, ';');