Archived Forum Post

Index of archived forum posts


Errors when using Objective-C examples in Xcode

Jun 07 '14 at 11:19

Hello, I'm developing an IOS app, and i'm running it on an IOS simulator, and its working fine. But the moment i try using some of your Objective-C functions (ARC4 PRNG), i get a large amount of errors, i don't know why!!! Is it the static library i'm trying to link to Xcode, or is it the include file i'm importing into my code? By the way, I've followed your steps in "How To Link with Static Library in Xcode"

My question is: 1- I'm using a MacBook Pro laptop(intel Core i5), so which static library i should use (x86-64 or i386)? 2- what am i suppose to do with the bash shell script ( (your notes doesn't give much explanation). 3- do i need to move the Lib folder and include folder into my project directory, or what? 4- are we suppose to use your codes in Blocks?

These are the Errors i get:

Ld /Users/user/Library/Developer/Xcode/DerivedData/DGCH1-eyilvrcbfrxyoagqpcamtqkqakny/Build/Products/Debug-iphonesimulator/ normal i386
    cd /Users/user/Desktop/DGCH1
    export PATH="/Applications/"
    /Applications/ -arch i386 -isysroot /Applications/ -L/Users/user/Library/Developer/Xcode/DerivedData/DGCH1-eyilvrcbfrxyoagqpcamtqkqakny/Build/Products/Debug-iphonesimulator -L/Users/user/Documents/chilkat-9.5.0-ios/lib/i386 -L/Users/user/Documents/chilkat-9.5.0-ios/lib/x86_64 -F/Users/user/Library/Developer/Xcode/DerivedData/DGCH1-eyilvrcbfrxyoagqpcamtqkqakny/Build/Products/Debug-iphonesimulator -filelist /Users/user/Library/Developer/Xcode/DerivedData/DGCH1-eyilvrcbfrxyoagqpcamtqkqakny/Build/Intermediates/ -Xlinker -objc_abi_version -Xlinker 2 -fobjc-arc -fobjc-link-runtime -Xlinker -no_implicit_dylibs -mios-simulator-version-min=7.1 -lchilkatIos -framework CoreGraphics -framework UIKit -framework Foundation -Xlinker -dependency_info -Xlinker /Users/user/Library/Developer/Xcode/DerivedData/DGCH1-eyilvrcbfrxyoagqpcamtqkqakny/Build/Intermediates/ -o /Users/user/Library/Developer/Xcode/DerivedData/DGCH1-eyilvrcbfrxyoagqpcamtqkqakny/Build/Products/Debug-iphonesimulator/

Undefined symbols for architecture i386: "std::terminate()", referenced from: "vtable for cxxabiv1::class_type_info", referenced from: "vtable for cxxabiv1::si_class_type_info", referenced from: "vtable for cxxabiv1::vmi_class_type_info", referenced from: "operator delete", referenced from: "operator delete(void*)", referenced from: "operator new", referenced from: "operator new(unsigned long)", referenced from: "cxa_begin_catch", referenced from: "cxa_end_catch", referenced from: "___gxx_personality_v0", referenced from:

ld: symbol(s) not found for architecture i386 clang: error: linker command failed with exit code 1 (use -v to see invocation)

I don't even understand what are these error about!!!!

Sorry for asking too many questions, but i'm new to using Objective-C, and also new to Xcode. So, pleeeeeeeeeeease help me.

Best Regards.


Chilkat is written in C++ and therefore requires the C++ standard libs.

See this:

In a nutshell: create an empty file, name it "empty.cpp", and add it to your project.