Skip to content
This repository was archived by the owner on Nov 25, 2019. It is now read-only.

Problems on linking iActiveRecord to my App #35

Closed
paulocoutinhox opened this issue Jun 19, 2013 · 6 comments
Closed

Problems on linking iActiveRecord to my App #35

paulocoutinhox opened this issue Jun 19, 2013 · 6 comments

Comments

@paulocoutinhox
Copy link
Contributor

Hi,

I have downloaded the ZIP from github with source and i try install it to my project, but i get the error above:


Ld /Users/paulo/Library/Developer/Xcode/DerivedData/uBook-chcabrasmyhbfccdfgginmrzdgqw/Build/Products/Debug-iphonesimulator/uBook.app/uBook normal i386
cd /Users/paulo/Documents/workspaces/xcode/ubook
setenv IPHONEOS_DEPLOYMENT_TARGET 5.0
setenv PATH "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch i386 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator6.1.sdk -L/Users/paulo/Library/Developer/Xcode/DerivedData/uBook-chcabrasmyhbfccdfgginmrzdgqw/Build/Products/Debug-iphonesimulator -F/Users/paulo/Library/Developer/Xcode/DerivedData/uBook-chcabrasmyhbfccdfgginmrzdgqw/Build/Products/Debug-iphonesimulator -F/Users/paulo/Documents/workspaces/xcode/ubook/libs -filelist /Users/paulo/Library/Developer/Xcode/DerivedData/uBook-chcabrasmyhbfccdfgginmrzdgqw/Build/Intermediates/uBook.build/Debug-iphonesimulator/uBook.build/Objects-normal/i386/uBook.LinkFileList -Xlinker -objc_abi_version -Xlinker 2 -fobjc-arc -fobjc-link-runtime -Xlinker -no_implicit_dylibs -mios-simulator-version-min=5.0 -framework ActiveRecord -lsqlite3 -framework AVFoundation -framework QuartzCore -framework UIKit -framework Foundation -framework CoreGraphics -o /Users/paulo/Library/Developer/Xcode/DerivedData/uBook-chcabrasmyhbfccdfgginmrzdgqw/Build/Products/Debug-iphonesimulator/uBook.app/uBook

Undefined symbols for architecture i386:
"OBJC_CLASS$_ARConfiguration", referenced from:
objc-class-ref in ActiveRecord
ld: symbol(s) not found for architecture i386

clang: error: linker command failed with exit code 1 (use -v to see invocation)

The steps:

1 - Download zip from github
2 - Extract the zip
3 - Open the project into xcode (osx 10.8 and xcode 4.6.2)
4 - Build the project "Build_Framework" for iPhone Device
5 - Open Finder and go to extracted path (step #2) + "Products"
6 - Copy "ActiveRecord.framework" to my project path + "libs" (project/libs/ActiveRecord.framework)
7 - Open my project on xcode
8 - Add framework: my project path + "libs" (project/libs/ActiveRecord.framework)
9 - I already have sqlite3.dylib into my project and it is working, dont need add again
10 - Compile my project for iPhone Device
11 - Got the error ^^

:::SCREENSHOT:::

screen shot 2013-06-19 at 2 41 11 pm

@paulocoutinhox
Copy link
Contributor Author

I forgot say that my project use ARC and DEPLOY TARGET is 5.0

@AlexDenisov
Copy link
Owner

Hi @PRSolucoes, thank you for contributing.
I've fixed this issue, now it should works fine.
Note that some paragraphs on wiki is deprecated due to new AR features.
You may look at ActiveTwitter target/sources for clarification.

If you still have problems (or they will be in the future) - please, feel free to open issue or ask me directly via email (or even skype).

@paulocoutinhox
Copy link
Contributor Author

I build the ActiveRecord without the ARC, but on my project i use ARC, have any problems?

@paulocoutinhox
Copy link
Contributor Author

With the current version of github the method on wiki:

[ActiveRecord registerDatabaseName:@"ubook" useDirectory:ARStorageDocuments];

Dont work. Whats the new version of it?

@AlexDenisov
Copy link
Owner

  1. ARC - if you use AR as a library, then you should not have any problems. Otherwise my understanding of ARC is totally wrong 😄
  2. Here is the new API

@AlexDenisov
Copy link
Owner

Solved by #36

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants