diff options
author | Misha Brukman <brukman+llvm@gmail.com> | 2003-11-24 05:28:39 +0000 |
---|---|---|
committer | Misha Brukman <brukman+llvm@gmail.com> | 2003-11-24 05:28:39 +0000 |
commit | a140b3c36759478d75618d63dc2b77592180dab8 (patch) | |
tree | 53d40fe3920df77c779e6f3ba012560a7954ef13 | |
parent | 17cca96735f3f7b4afeb44c67a0b191722ef6d20 (diff) | |
download | external_llvm-a140b3c36759478d75618d63dc2b77592180dab8.zip external_llvm-a140b3c36759478d75618d63dc2b77592180dab8.tar.gz external_llvm-a140b3c36759478d75618d63dc2b77592180dab8.tar.bz2 |
Expose functionality to query if a file is an ELF shared object.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10194 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | include/Support/FileUtilities.h | 5 | ||||
-rw-r--r-- | include/llvm/Support/FileUtilities.h | 5 |
2 files changed, 10 insertions, 0 deletions
diff --git a/include/Support/FileUtilities.h b/include/Support/FileUtilities.h index c276ec7..4c02605 100644 --- a/include/Support/FileUtilities.h +++ b/include/Support/FileUtilities.h @@ -34,6 +34,11 @@ bool IsArchive (const std::string &FN); /// bool IsBytecode (const std::string &FN); +/// IsSharedObject - Returns trus IFF the file named FN appears to be a shared +/// object with an ELF header. The file named FN must exist. +/// +bool IsSharedObject(const std::string &FN); + /// FileOpenable - Returns true IFF Filename names an existing regular file /// which we can successfully open. /// diff --git a/include/llvm/Support/FileUtilities.h b/include/llvm/Support/FileUtilities.h index c276ec7..4c02605 100644 --- a/include/llvm/Support/FileUtilities.h +++ b/include/llvm/Support/FileUtilities.h @@ -34,6 +34,11 @@ bool IsArchive (const std::string &FN); /// bool IsBytecode (const std::string &FN); +/// IsSharedObject - Returns trus IFF the file named FN appears to be a shared +/// object with an ELF header. The file named FN must exist. +/// +bool IsSharedObject(const std::string &FN); + /// FileOpenable - Returns true IFF Filename names an existing regular file /// which we can successfully open. /// |