From f5998d524a19ea6e369b2f0ae50475577dfd28c1 Mon Sep 17 00:00:00 2001 From: KentuckyCompass Date: Wed, 26 Dec 2012 10:56:18 -0800 Subject: [PATCH] Add HOST_IS_CASE_SENSITIVE define --- Core/FileSystems/DirectoryFileSystem.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/Core/FileSystems/DirectoryFileSystem.h b/Core/FileSystems/DirectoryFileSystem.h index 6b87c3f784..c187db572c 100644 --- a/Core/FileSystems/DirectoryFileSystem.h +++ b/Core/FileSystems/DirectoryFileSystem.h @@ -28,6 +28,26 @@ typedef void * HANDLE; #endif +#if defined(__APPLE__) + +#if TARGET_OS_IPHONE +#define HOST_IS_CASE_SENSITIVE true +#elif TARGET_IPHONE_SIMULATOR +#define HOST_IS_CASE_SENSITIVE false +#else +// Mac OSX case sensitivity defaults off, but is user configurable (when +// creating a filesytem), so assume the worst: +#define HOST_IS_CASE_SENSITIVE true +#endif + +#elif defined(_WIN32) || defined(__SYMBIAN32__) +#define HOST_IS_CASE_SENSITIVE false + +#else // Android, Linux, BSD (and the rest?) +#define HOST_IS_CASE_SENSITIVE true + +#endif + class DirectoryFileSystem : public IFileSystem { public: DirectoryFileSystem(IHandleAllocator *_hAlloc, std::string _basePath);