commit | 9895937618c776d629e97a8e2169f35dbfaf286f | [log] [tgz] |
---|---|---|
author | Chris Lattner <sabre@nondot.org> | Tue Oct 05 00:46:21 2004 +0000 |
committer | Chris Lattner <sabre@nondot.org> | Tue Oct 05 00:46:21 2004 +0000 |
tree | 4d7c98928daf0af43bfff0b11b2827e81b6f1a96 | |
parent | 2426ff991c54134bb018cfd3efea64bee8c8800c [diff] [blame] |
Solaris doesn't have MAP_FILE. llvm-svn: 16682
diff --git a/llvm/lib/System/Unix/MappedFile.cpp b/llvm/lib/System/Unix/MappedFile.cpp index d853ace..7682c23 100644 --- a/llvm/lib/System/Unix/MappedFile.cpp +++ b/llvm/lib/System/Unix/MappedFile.cpp
@@ -76,7 +76,10 @@ void* MappedFile::map() { if (!isMapped()) { int prot = PROT_NONE; - int flags = MAP_FILE; + int flags = 0; +#ifdef MAP_FILE + flags |= MAP_FILE; +#endif if (options_ == 0) { prot = PROT_READ; flags = MAP_PRIVATE;