diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 64f133e..ced7f0e 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,6 +2,7 @@ * CHANGELOG. */ +11022008 - iPhone support (thanks, Christian!) 04032008 - Fixed PHYSFS_openAppend() to work as documented on Unix. 03122008 - Fixed aliasing bug in Windows platform layer (thanks, Dennis!). 03102008 - Changed some text files from ISO-8859-1 to UTF-8. Replaced all the diff --git a/physfs_platforms.h b/physfs_platforms.h index 9f95a89..6079399 100644 --- a/physfs_platforms.h +++ b/physfs_platforms.h @@ -22,8 +22,16 @@ #elif (defined OS2) # define PHYSFS_PLATFORM_OS2 #elif ((defined __MACH__) && (defined __APPLE__)) -# define PHYSFS_PLATFORM_MACOSX -# define PHYSFS_PLATFORM_POSIX +/* To check if iphone or not, we need to inlcude this file */ +# include +# if (defined(TARGET_IPHONE_SIMULATOR) || (defined TARGET_OS_IPHONE)) +# define PHYSFS_PLATFORM_UNIX +# define PHYSFS_PLATFORM_POSIX +# define PHYSFS_NO_CDROM_SUPPORT +# else +# define PHYSFS_PLATFORM_MACOSX +# define PHYSFS_PLATFORM_POSIX +# endif #elif defined(macintosh) # error Classic Mac OS support was dropped from PhysicsFS 2.0. Move to OS X. #elif defined(unix)