How to Install and use FANN with Xcode - iphone

i want to use FANN (fast artificial neural network) with Xcode
i googled for a way how to get the FANN and install it in Xcode but i did not find a result
please guys does anyone know from where can i download FANN library and use it with Xcode
thanks

Go to http://leenissen.dk. Here you will find the source code you can download from sourceforge.com and install instructions for Cmake on the command line. Just follow the instructions and you will see several static libraries were included. Now all you will have to do is add the library you want to use and the include (.h) files to your Xcode project. From here the example code from the FANN website should work.
Note that when you reference the FANN .h files to your projects files you must use include and not import. I ran into this problem myself.
There was a issue with exporting a code signed application using Xcode. I was able to find a solution after playing around with code signing.
I decided to try manually code signing my app with instructions from http://www.digicert.com/code-signing/mac-os-codesign-tool.htm. This did not work. However the code signing tool pointed me to a problem with libfann.2.2.0.dylib. So I checked if libfann.2.2.0.dylib was code signed and it was not. When I saw this I thought I would try code signing libfann.2.2.0.dylib with my developer ID and re-importing it into my project. This strategy worked and I was able to export a developer ID signed version of my application.

Related

Can't link XlsxReaderWriter in Xcode 10

I need to create an iOS app that reads and writes Excel .xlsx formatted files. Using XlsxReaderWriter I have tried countless times to link following instructions in the README.md file, but have never succeeded. It says that older systems can use libz.dylib instead of libz.tbd, but I can only find libz.tbd and newer versions up to libz.1.2.8.tbd when compiling on Xcode 10. Perhaps there are issues with newer versions of libz that are undocumented.
I've run out of ways to link, install, and run an app with XlsxReaderWriter and wonder if anyone could share a simple app in Objective-C that would show what a successful installation looks like. Endless thanks will follow. Thank you.

Xcode upgrade: PBXContainerItemProxy missing containerPortal key

I just upgraded my Xcode, now when I try to open my project, I get this error:
Project /Users/xxx/xxxx/xxxxx/xxxxxx/xxxxxxxx.xcodeproj cannot be opened: PBXContainerItemProxy (xxxxxxxxxxxxxxxxx) is missing a containerPortal key
I have searched the web and stackoverflow, but cannot get anything relevent to come up at all regarding this.
I do have Three20 as part of my project, I don't know if that matters. I just upgraded to xcode 4.4.1
Thanks for any insight.
-D
the project icon which we see i.e projectname.xcodeproj, is actually a directory, you do this
1. in terminal do cd yourproject.xcodeproj
2.ls
3.vi project.pbxproj
4. scroll down till /* Begin PBXContainerItemProxy section */
5.there you will see all sections check for the section which is missing a portal key edit it and save it :wq it will work
in image if you see the first section is missing container portal key.just pic it from other section and replace it..
it will work :D see this link
Now I should start with that I do not know the actual error, never seen it before, but I did find a reference to a "PBXContainerProxy"-error in this post (As soon as I add a project to XCode 4.0.2 it crashes) and thought you might try the solutions from there?
"Apparently this is due to the new version of XCodeProjects. I found a
work around by pre-compiling the library that was causing the issue
and then using the linker to link to the .a file. I also had to copy
the .a library into the DerivedData path.
The real solution was to remove the project and replace it with an
updated project for the new version of XCode."
Hope that helps somewhat :)
Never saw that error either, but if you're upgrading directly from XCode 3.X I'd suggest you to go to https://developer.apple.com/downloads/index.action?name=Xcode
and download/install a previous version of Xcode somewhere else. (You can have several different copies installed on your machine, just google it if you don't know how but just remember to use xcode-select to pick the one you want to use). Repeat with all the versions back to 4.0.1 until (hopefully) it works. I know it's tedious but it might help.
If it does, validate the project settings and try to open it with 4.4.1. That should work.
Good luck

How do you Create a single-bundle App/Archive using static libraries like Core-Plot?

I struggled a bit before I found an answer and so I'm posting it here.
Problem: Building archive with Core-Plot resulted in an Organizer error that said something about building a single-bundle archive. Issue seemed to be problem with headers located in /usr of Install_Root.
See below for the solution.
There may be other ways. This one worked for me. Create run script in Build Phase of target App.
Then run Archive. Wha-la!

Core-plot configuration error

I am trying to use core-plot and I followed the instruction from the following project page to use it.
http://code.google.com/p/core-plot/wiki/UsingCorePlotInApplications, which is
You can install the SDK with a standard Mac installer package, or by hand. Here is how you install by hand.
Copy the CorePlotSDK directory to ~/Library/SDKs/
Add to your project's .PCH file:
#import < CorePlot/CorePlot.h >
Open Project -> Edit Project Settings and for All Configurations:
3a. Add to Additional SDKS:
$HOME/Library/SDKs/CorePlotSDK/${PLATFORM_NAME}.sdk
3b. Add to Other Linker Flags:
-ObjC -all_load -lCorePlot
Add the QuartzCore framework to the project.
Add a CPGraph to your application.
I went with the SDK install options: I installed it with Mac installer Package, it got installed in the following location /Library/SDKs/iphoneos.sdk and /Library/SDKs/iphonesimulator.sdk
Then i did step 2 as mentioned.
For 3a i added /Library/SDKs/iphonesimulator.sdk
Then i did 3b and then 4.
After that I tried to do a build and see how does it works and i get the following errors:
:1:0 :1:1: warning: "__IPHONE_OS_VERSION_MIN_REQUIRED" redefined
:1:0 :1:1: warning: this is the location of the previous definition
/var/folders/+r/+rBG+BziF1OqK12XNyw1ak+++TM/-Caches-/com.apple.Xcode.502/CompositeSDKs/iphonesimulator-iPhoneSimulator4.1-cztutytisanvsqaptkdkpoyyctln/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:250:0 /var/folders/+r/+rBG+BziF1OqK12XNyw1ak+++TM/-Caches-/com.apple.Xcode.502/CompositeSDKs/iphonesimulator-iPhoneSimulator4.1-cztutytisanvsqaptkdkpoyyctln/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:250: error: syntax error before '^' token
/var/folders/+r/+rBG+BziF1OqK12XNyw1ak+++TM/-Caches-/com.apple.Xcode.502/CompositeSDKs/iphonesimulator-iPhoneSimulator4.1-cztutytisanvsqaptkdkpoyyctln/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:250:0 /var/folders/+r/+rBG+BziF1OqK12XNyw1ak+++TM/-Caches-/com.apple.Xcode.502/CompositeSDKs/iphonesimulator-iPhoneSimulator4.1-cztutytisanvsqaptkdkpoyyctln/System/Library/Frameworks/UIKit.framework/Headers/UIView.h:250: error: 'type name' declared as function returning a function
This appears 20 times. and it points all to UIView.h
There are same question in the stackoverflow and people suggested to change the compiler to 4.2 and for lot of people it worked, but for me the compiler was always set to 4.2 and still I get the same error.
On 3a if do /Library/SDKs/iphoneos.sdk
I get the following error
error: Composite SDK failed: The base SDK uses platform 'iphonesimulator', but an additional SDK uses platform 'iphoneos'. All SDKs must use the same platform (PLATFORM_NAME).
Please help
Finally, I have figured out the solution for this error:
Thanks to the developer on core-plot project and sebastien.leduc a google code user for their help.
I am using CorePlotInstaller_0.2.2.zip, and one important steps that is missing on the installation guide is you have to use LLVM GCC 4.2 and not GCC 4.2.
The other important steps which was little confused me was 3a.
Add to Additional SDKS: $HOME/Library/SDKs/CorePlotSDK/${PLATFORM_NAME}.sdk
Here you have to literally add the above line, I was changing the ${PLATFORM_NAME} with iphoneos or iphonesimulator, but no we don't have to do that.
One last thing if you don't find the sdk on the following path $HOME/Library/SDKs/CorePlotSDK
Check out /Library/SDKs/CorePlotSDK.
I hope this will help people, it took me about a week to figure out with the help of all the people who came forward to help.
I just posted a new version of the Core Plot installer that should resolve this issue. You can download it from http://code.google.com/p/core-plot/downloads/list.
You can choose to install Core Plot for all users or just your account. If you install for all users, change the Additional SDKs path from $HOME/Library/SDKs/CorePlotSDK/${PLATFORM_NAME}.sdk to /Library/SDKs/CorePlotSDK/${PLATFORM_NAME}.sdk.
I integrated core-plot into my application yesterday so it's fresh on my mind. I tried installing the SDK the same way you are and hit the same error. Comments in the google-group recommended NOT going this route, so I went back and installed the source code.
I ended up using the tutorial HERE for the basic steps and sample code. The code doesn't work anymore, but all the broken parts are answered in the comments (including a complete reposting of the code which works on the latest version).
Some stumbling points were that the "-ObjC" and "-all_load" flags were both needed, and when I added the header path the "search recursively" option wasn't checked off. Both these questions and many more are answered in the comments.

How to build and install yajl-objc on iOS

Hey I am trying to get http://github.com/gabriel/yajl-objc to work on iOS. It says to "Add the YAJLIOS.framework to your project" but I am not sure how I can get/build YAJLIOS.framework
Thanks!
-Ray
Although this is an old question, I came across the issue today updating a client's old project. The YAJL-objC project requires you to run a makefile command in order to compile the .framework file needed for installation.
To create the framework, checkout the latest from github, and then open Terminal. Change your directory to: yajl-objc\Project-iOS
Next, type the command make and run it. This will execute the compiling for you and create a new framework file here: yajl-objc\Project-iOS\Framework\YAJLiOS.framework
You can then drag that framework into the project you wish to use it in. Good luck!
I should have looked harder, but there is simply a download under the github download link that includes the framework.