-1

I want to use objective-zip with an iOS 5 project under Xcode 4.3 but when I run my application in the simulator, this linker error appears to me:

Undefined symbols for architecture i386:
  "_OBJC_CLASS_$_ZipFile", referenced from:
      objc-class-ref in AddMeetingViewController.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)

This post has the same problem as me, but his solution doesn't solve my problem.

Any help about this will be appreciated. Thanks.

Community
  • 1
  • 1
chostDevil
  • 1,041
  • 5
  • 17
  • 24
  • 1
    And the Objective-Zip library is compiled for ARM6, ARM7 **and** i386? – trojanfoe May 04 '12 at 15:37
  • Is the library compiled for the correct architecture? You know that the iPhone is ARM but the iPhone Simulator is i386? – trojanfoe May 04 '12 at 15:44
  • i don't know that but i didn't receive any compiler errors, i just receive this linkage error on running my app, also i have a working objective-zip demo which works well on the simulator – chostDevil May 04 '12 at 15:46
  • OK, that sounds OK then. Can you show us the linker command line (available from within the Xcode Log Navigator). – trojanfoe May 04 '12 at 17:30

1 Answers1

1

i have resolved my problem as following:

1) objective-zip source files must be included inside the compile sources section in build phases.

2) objective-zip doesn't use ARC so you must add these command -fno-objc-arc to all the source files mentioned in step 1 to tell the compiler not to use ARC with these files.

3) to add these command to the source files , hold the cmd button and select all the source files then press enter and type this command in the text box that appears.

chostDevil
  • 1,041
  • 5
  • 17
  • 24