From f512281d61c10cbd2dd9797457f5809648b0677b Mon Sep 17 00:00:00 2001 From: Matthijs Kooijman Date: Thu, 26 Jun 2008 10:36:58 +0000 Subject: Make LLVM compile on DragonFly BSD (PR2499). Patch by Hasso Tepper! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52781 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/System/Mutex.cpp | 2 +- lib/Target/CBackend/CBackend.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/System/Mutex.cpp b/lib/System/Mutex.cpp index 81dcd3b..f55dd3f 100644 --- a/lib/System/Mutex.cpp +++ b/lib/System/Mutex.cpp @@ -75,7 +75,7 @@ Mutex::Mutex( bool recursive) errorcode = pthread_mutexattr_settype(&attr, kind); assert(errorcode == 0); -#if !defined(__FreeBSD__) && !defined(__OpenBSD__) && !defined(__NetBSD__) +#if !defined(__FreeBSD__) && !defined(__OpenBSD__) && !defined(__NetBSD__) && !defined(__DragonFly__) // Make it a process local mutex errorcode = pthread_mutexattr_setpshared(&attr, PTHREAD_PROCESS_PRIVATE); #endif diff --git a/lib/Target/CBackend/CBackend.cpp b/lib/Target/CBackend/CBackend.cpp index 2e9902d..71895f4 100644 --- a/lib/Target/CBackend/CBackend.cpp +++ b/lib/Target/CBackend/CBackend.cpp @@ -1415,7 +1415,7 @@ static void generateCompilerSpecificCode(std::ostream& Out, << "extern void *__builtin_alloca(unsigned int);\n" << "#endif\n" << "#define alloca(x) __builtin_alloca(x)\n" - << "#elif defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__)\n" + << "#elif defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)\n" << "#define alloca(x) __builtin_alloca(x)\n" << "#elif defined(_MSC_VER)\n" << "#define inline _inline\n" -- cgit v1.1