diff options
author | Douglas Gregor <dgregor@apple.com> | 2013-01-22 23:49:45 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2013-01-22 23:49:45 +0000 |
commit | 01c7cfa2c058892d0c331711f912d24bbe63dde2 (patch) | |
tree | 7dd32b19ba5b5a3e82188433d4bdc5d55c46f9a9 | |
parent | 1a06479f4641995866b42b420ba9cc684c214c9a (diff) | |
download | bcm5719-llvm-01c7cfa2c058892d0c331711f912d24bbe63dde2.tar.gz bcm5719-llvm-01c7cfa2c058892d0c331711f912d24bbe63dde2.zip |
Fix compilation on Linux, which defines PATH_MAX in a weird place,
from Saleem Abdulrasool!
llvm-svn: 173208
-rw-r--r-- | clang/lib/Lex/HeaderSearch.cpp | 5 | ||||
-rw-r--r-- | clang/lib/Lex/ModuleMap.cpp | 5 |
2 files changed, 10 insertions, 0 deletions
diff --git a/clang/lib/Lex/HeaderSearch.cpp b/clang/lib/Lex/HeaderSearch.cpp index 4982ce4ac08..14d44cc3da2 100644 --- a/clang/lib/Lex/HeaderSearch.cpp +++ b/clang/lib/Lex/HeaderSearch.cpp @@ -23,6 +23,11 @@ #include "llvm/Support/FileSystem.h" #include "llvm/Support/Path.h" #include <cstdio> +#if defined(LLVM_ON_UNIX) +#if defined(__linux__) +#include <linux/limits.h> +#endif +#endif using namespace clang; const IdentifierInfo * diff --git a/clang/lib/Lex/ModuleMap.cpp b/clang/lib/Lex/ModuleMap.cpp index 72e79511eeb..25e5bee9ce3 100644 --- a/clang/lib/Lex/ModuleMap.cpp +++ b/clang/lib/Lex/ModuleMap.cpp @@ -28,6 +28,11 @@ #include "llvm/Support/PathV2.h" #include "llvm/Support/raw_ostream.h" #include <stdlib.h> +#if defined(LLVM_ON_UNIX) +#if defined(__linux__) +#include <linux/limits.h> +#endif +#endif using namespace clang; Module::ExportDecl |