zip file loading error on iphone

Problems building or running the engine, queries about how to use features etc.
Post Reply
TaeHyungKim
Kobold
Posts: 31
Joined: Thu Jun 03, 2010 4:03 pm
Location: Korea

zip file loading error on iphone

Post by TaeHyungKim »

hi
I was build samplebrowser and upload my iphone for test.
at 2-3weeks ago, test on the iphone is well done.
but now zip file loading error on loading "sdkTrays.zip" at iphone.
in recent , mac osX and iphone os is upgraded.
my osX version is 10.6.4 and iphone os is 3.1.3
is this problem related that update?
I don't know why zip file loading error is occured suddnely...
User avatar
masterfalcon
OGRE Team Member
OGRE Team Member
Posts: 4270
Joined: Sun Feb 25, 2007 4:56 am
Location: Bloomington, MN
x 126
Contact:

Re: zip file loading error on iphone

Post by masterfalcon »

What kind of error are you getting?
TaeHyungKim
Kobold
Posts: 31
Joined: Thu Jun 03, 2010 4:03 pm
Location: Korea

Re: zip file loading error on iphone

Post by TaeHyungKim »

i was using ogre source download page's ogre source for mac and iphonedependencies files

error is occured at OgreZip.cpp line 89
mZzipDir = zzip_dir_open(mName.c_str(), &zzipError);


-----error log-----------------------
...
Creating resource group Essential
Added resource location '/Users/taehyungkim/Documents/ogre_src_v1-7-1-2/Samples/Media/thumbnails' of type 'FileSystem' to resource group 'Essential'
Current language: auto; currently c++
(gdb) continue
An exception has occurred: OGRE EXCEPTION(7:InternalErrorException): /Users/taehyungkim/Documents/ogre_src_v1-7-1-2/Samples/Media/packs/SdkTrays.zip - error whilst opening archive: Unable to read zip file. in ZipArchive::checkZzipError at /Users/taehyungkim/Documents/ogre_src_v1-7-1-2/OgreMain/src/OgreZip.cpp (line 280)
User avatar
masterfalcon
OGRE Team Member
OGRE Team Member
Posts: 4270
Joined: Sun Feb 25, 2007 4:56 am
Location: Bloomington, MN
x 126
Contact:

Re: zip file loading error on iphone

Post by masterfalcon »

Looks like your app can't read the zip file. My guess is that your resources.cfg contains absolute paths to the resources and it's trying to load files that are outside the application bundle.

Change it to use absolute paths instead, like this:

Code: Select all

Zip=Media/packs/SdkTrays.zip
TaeHyungKim
Kobold
Posts: 31
Joined: Thu Jun 03, 2010 4:03 pm
Location: Korea

Re: zip file loading error on iphone

Post by TaeHyungKim »

thanks .. i modified resources.cfg mannualy
samplebrowser is well excuted on iphone

i have question .. i think build/bin/resources.cfg is copied to iphone app
and i think that file is generated by cmake
how change absolute path to relative path on generation process..
what file is modify for this??
User avatar
masterfalcon
OGRE Team Member
OGRE Team Member
Posts: 4270
Joined: Sun Feb 25, 2007 4:56 am
Location: Bloomington, MN
x 126
Contact:

Re: zip file loading error on iphone

Post by masterfalcon »

I can't remember exactly. It may be the CMakeLists.txt file in Samples/Browser.
Post Reply