diff options
| author | Reid Spencer <rspencer@reidspencer.com> | 2006-06-01 19:03:21 +0000 |
|---|---|---|
| committer | Reid Spencer <rspencer@reidspencer.com> | 2006-06-01 19:03:21 +0000 |
| commit | 187b4adcfe6c50feb015f1fc6680a01602acfab1 (patch) | |
| tree | ac30aa0fdee9078aab372443c8e2b29d2e315e9a /llvm/lib | |
| parent | 5cb722f320417a5a4032154ec30f9143af883a99 (diff) | |
| download | bcm5719-llvm-187b4adcfe6c50feb015f1fc6680a01602acfab1.tar.gz bcm5719-llvm-187b4adcfe6c50feb015f1fc6680a01602acfab1.zip | |
Provide configuration support and usage for MINGW32 platform
llvm-svn: 28639
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/System/Win32/DynamicLibrary.inc | 12 | ||||
| -rw-r--r-- | llvm/lib/System/Win32/Process.inc | 8 | ||||
| -rw-r--r-- | llvm/lib/System/Win32/Signals.inc | 14 |
3 files changed, 26 insertions, 8 deletions
diff --git a/llvm/lib/System/Win32/DynamicLibrary.inc b/llvm/lib/System/Win32/DynamicLibrary.inc index 310d3dc8359..d214ba0e727 100644 --- a/llvm/lib/System/Win32/DynamicLibrary.inc +++ b/llvm/lib/System/Win32/DynamicLibrary.inc @@ -14,12 +14,18 @@ #include "Win32.h" #ifdef __MINGW32__ -#include <imagehlp.h> + #include <imagehlp.h> #else -#include <dbghelp.h> + #include <dbghelp.h> #endif -#pragma comment(lib, "dbghelp.lib") +#ifdef __MINGW32__ + #if (HAVE_LIBIMAGEHLP != 1) + #error "libimagehlp.a should be present" + #endif +#else + #pragma comment(lib, "dbghelp.lib") +#endif namespace llvm { using namespace sys; diff --git a/llvm/lib/System/Win32/Process.inc b/llvm/lib/System/Win32/Process.inc index 5b090da3c2e..d5e80b4f19c 100644 --- a/llvm/lib/System/Win32/Process.inc +++ b/llvm/lib/System/Win32/Process.inc @@ -16,7 +16,13 @@ #include <malloc.h> #include <io.h> -#pragma comment(lib, "psapi.lib") +#ifdef __MINGW32__ + #if (HAVE_LIBPSAPI != 1) + #error "libpsapi.a should be present" + #endif +#else + #pragma comment(lib, "psapi.lib") +#endif //===----------------------------------------------------------------------===// //=== WARNING: Implementation here must contain only Win32 specific code diff --git a/llvm/lib/System/Win32/Signals.inc b/llvm/lib/System/Win32/Signals.inc index 333e387dea1..a44c034ba1d 100644 --- a/llvm/lib/System/Win32/Signals.inc +++ b/llvm/lib/System/Win32/Signals.inc @@ -16,14 +16,20 @@ #include <vector> #ifdef __MINGW32__ -#include <imagehlp.h> + #include <imagehlp.h> #else -#include <dbghelp.h> + #include <dbghelp.h> #endif #include <psapi.h> -#pragma comment(lib, "psapi.lib") -#pragma comment(lib, "dbghelp.lib") +#ifdef __MINGW32__ + #if ((HAVE_LIBIMAGEHLP != 1) || (HAVE_LIBPSAPI != 1)) + #error "libimagehlp.a & libpsapi.a should be present" + #endif +#else + #pragma comment(lib, "psapi.lib") + #pragma comment(lib, "dbghelp.lib") +#endif // Forward declare. static LONG WINAPI LLVMUnhandledExceptionFilter(LPEXCEPTION_POINTERS ep); |

