Mercurial > sdl-ios-xcode
diff test/testfile.c @ 2432:daf3baf72a45 gsoc2008_iphone
Added lines to change path when run on iPhone. Reason: iPhone operates in sandbox and so cannot write files just anywhere ... I use the documents folder in this test.
author | Holmes Futrell <hfutrell@umail.ucsb.edu> |
---|---|
date | Fri, 15 Aug 2008 00:57:58 +0000 |
parents | 891ed60fcaa9 |
children |
line wrap: on
line diff
--- a/test/testfile.c Fri Aug 15 00:56:43 2008 +0000 +++ b/test/testfile.c Fri Aug 15 00:57:58 2008 +0000 @@ -14,9 +14,14 @@ #include <stdio.h> /* WARNING ! those 2 files will be destroyed by this test program */ -#define FBASENAME1 "sdldata1" /* this file will be created during tests */ -#define FBASENAME2 "sdldata2" /* this file should not exists before starting test */ +#ifdef __IPHONEOS__ + #define FBASENAME1 "../Documents/sdldata1" /* this file will be created during tests */ + #define FBASENAME2 "../Documents/sdldata2" /* this file should not exist before starting test */ +#else + #define FBASENAME1 "sdldata1" /* this file will be created during tests */ + #define FBASENAME2 "sdldata2" /* this file should not exist before starting test */ +#endif #ifndef NULL #define NULL ((void *)0)