I wish to use boost-python3 to wrap my C++ code in macos with xcode.
I want to use xcode because it is linked to JUCE music packages. I used a simple example taken from the boost tutorial:
#include <boost/python.hpp>
char const* greet()
{
return "hello, world";
}
BOOST_PYTHON_MODULE(hello_ext)
{
using namespace boost::python;
def("greet", greet);
}
When I compiled the code I got a linking problem.
I went over the existing documentation and questions and changed the include paths and library paths. Currently, I used these:
Header search path:
/usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/include/python3.7m/
Library search path:
/usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/lib/
This is the linking logs:
Ld build/Debug/Midi2KontaktDLL.dylib normal x86_64
cd /Users/didi/Development/Juce/Midi2KontaktDLL/Builds/MacOSX
export MACOSX_DEPLOYMENT_TARGET=10.11
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -arch x86_64 -dynamiclib -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk -L/Users/didi/Development/Juce/Midi2KontaktDLL/Builds/MacOSX/build/Debug -L/usr/local/Cellar/boost-python3/1.70.0_1/lib -L/usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/lib -F/Users/didi/Development/Juce/Midi2KontaktDLL/Builds/MacOSX/build/Debug -filelist /Users/didi/Library/Developer/Xcode/DerivedData/Midi2KontaktDLL-eupsdkbbrcwqymategfreyedipek/Build/Intermediates.noindex/Midi2KontaktDLL.build/Debug/Midi2KontaktDLL\ -\ Dynamic\ Library.build/Objects-normal/x86_64/Midi2KontaktDLL.LinkFileList -install_name /usr/local/lib/Midi2KontaktDLL.dylib -mmacosx-version-min=10.11 -Xlinker -object_path_lto -Xlinker /Users/didi/Library/Developer/Xcode/DerivedData/Midi2KontaktDLL-eupsdkbbrcwqymategfreyedipek/Build/Intermediates.noindex/Midi2KontaktDLL.build/Debug/Midi2KontaktDLL\ -\ Dynamic\ Library.build/Objects-normal/x86_64/Midi2KontaktDLL_lto.o -Xlinker -export_dynamic -Xlinker -no_deduplicate -stdlib=libc++ -framework Accelerate -framework AudioToolbox -framework Carbon -framework Cocoa -framework CoreAudio -framework CoreMIDI -framework IOKit -framework OpenGL -framework QuartzCore -framework WebKit -compatibility_version 1 -current_version 1 -Xlinker -dependency_info -Xlinker /Users/didi/Library/Developer/Xcode/DerivedData/Midi2KontaktDLL-eupsdkbbrcwqymategfreyedipek/Build/Intermediates.noindex/Midi2KontaktDLL.build/Debug/Midi2KontaktDLL\ -\ Dynamic\ Library.build/Objects-normal/x86_64/Midi2KontaktDLL_dependency_info.dat -o /Users/didi/Development/Juce/Midi2KontaktDLL/Builds/MacOSX/build/Debug/Midi2KontaktDLL.dylib
and the error I get:
Undefined symbols for architecture x86_64:
"_PyUnicode_Type", referenced from:
boost::python::to_python_value<char const* const&>::get_pytype()
const in Source.o
"__Py_NoneStruct", referenced from:
boost::python::api::object::object() in Source.o
"boost::python::detail::init_module(PyModuleDef&, void (*)())",
referenced from:
_PyInit_hello_ext in Source.o
"boost::python::detail::gcc_demangle(char const*)", referenced
from:
boost::python::type_info::name() const in Source
"boost::python::detail::scope_setattr_doc(char const*,
boost::python::api::object const&, char const*)", referenced from:
void boost::python::def<char const* (*)()>(char const*, char const*
(*)()) in Source.o
Thanks!!!
Related
I have been learning how to use Godot and recently I tried to export my project to Xcode to see how my game would look on my phone. When I try to run it, it shows that there are exactly 100 errors.
The error code is huge!
Ld /Users/tonymartini/Library/Developer/Xcode/DerivedData/Wheel-hbetymftcixgfwcvonanonkkbxsz/Build/Products/Debug-iphoneos/Wheel.app/Wheel normal (in target 'Wheel' from project 'Wheel')
cd /Users/tonymartini/Desktop/Godot\ Round\ 2
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -target arm64-apple-ios12.3 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS14.2.sdk -L/Users/tonymartini/Library/Developer/Xcode/DerivedData/Wheel-hbetymftcixgfwcvonanonkkbxsz/Build/Products/Debug-iphoneos -L/Users/tonymartini/Desktop/Godot\ Round\ 2 -F/Users/tonymartini/Library/Developer/Xcode/DerivedData/Wheel-hbetymftcixgfwcvonanonkkbxsz/Build/Products/Debug-iphoneos -F. -FWheel -FWheel/dylibs -filelist /Users/tonymartini/Library/Developer/Xcode/DerivedData/Wheel-hbetymftcixgfwcvonanonkkbxsz/Build/Intermediates.noindex/Wheel.build/Debug-iphoneos/Wheel.build/Objects-normal/arm64/Wheel.LinkFileList -Xlinker -rpath -Xlinker #executable_path/Frameworks -dead_strip -Xlinker -object_path_lto -Xlinker /Users/tonymartini/Library/Developer/Xcode/DerivedData/Wheel-hbetymftcixgfwcvonanonkkbxsz/Build/Intermediates.noindex/Wheel.build/Debug-iphoneos/Wheel.build/Objects-normal/arm64/Wheel_lto.o -Xlinker -no_deduplicate -stdlib\=libc++ -framework StoreKit /Users/tonymartini/Desktop/Godot\ Round\ 2/Wheel.a -framework GameKit -Xlinker -no_adhoc_codesign -Xlinker -dependency_info -Xlinker /Users/tonymartini/Library/Developer/Xcode/DerivedData/Wheel-hbetymftcixgfwcvonanonkkbxsz/Build/Intermediates.noindex/Wheel.build/Debug-iphoneos/Wheel.build/Objects-normal/arm64/Wheel_dependency_info.dat -o /Users/tonymartini/Library/Developer/Xcode/DerivedData/Wheel-hbetymftcixgfwcvonanonkkbxsz/Build/Products/Debug-iphoneos/Wheel.app/Wheel
Undefined symbols for architecture arm64:
"_mono_get_exception_argument", referenced from:
godot_icall_Array_CopyTo(Array*, _MonoArray*, int) in Wheel.a(collections_glue.iphone.opt.debug.arm64.o)
godot_icall_Dictionary_Add(Dictionary*, _MonoObject*, _MonoObject*) in Wheel.a(collections_glue.iphone.opt.debug.arm64.o)
"_mono_get_exception_index_out_of_range", referenced from:
godot_icall_Array_At(Array*, int) in Wheel.a(collections_glue.iphone.opt.debug.arm64.o)
godot_icall_Array_At_Generic(Array*, int, unsigned int, GDMonoClass*) in Wheel.a(collections_glue.iphone.opt.debug.arm64.o)
godot_icall_Array_SetAt(Array*, int, _MonoObject*) in Wheel.a(collections_glue.iphone.opt.debug.arm64.o)
godot_icall_Array_Insert(Array*, int, _MonoObject*) in
...
"_mono_type_full_name", referenced from:
GDMonoUtils::get_type_desc(_MonoType*) in
I reached the character limit so I cut out the middle, let me know if you want it
GDMono::get_class(_MonoClass*) in Wheel.a(gd_mono.iphone.opt.debug.arm64.o)
GDMono::~GDMono() in Wheel.a(gd_mono.iphone.opt.debug.arm64.o)
_GodotSharp::get_domain_id() in Wheel.a(gd_mono.iphone.opt.debug.arm64.o)
CSharpLanguage::debug_get_current_stack_info() in Wheel.a(csharp_script.iphone.opt.debug.arm64.o)
CSharpInstance::_internal_new_managed() in Wheel.a(csharp_script.iphone.opt.debug.arm64.o)
CSharpScript::_create_instance(Variant const**, int, Object*, bool, Variant::CallError&) in Wheel.a(csharp_script.iphone.opt.debug.arm64.o)
...
"_mono_runtime_set_main_args", referenced from:
GDMono::initialize() in Wheel.a(gd_mono.iphone.opt.debug.arm64.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Something I tried is talked about here: Link. Basically, download visual studio and export Xamarin dylib to Xcode project. The problem with this, as left unsolved in the post, is that instead of the hundred errors, a single new error appears:
"Unresolved symbol: gdmonosetupaot"
I have been stuck on this problem for awhile now. Countless hours and time and I still can't figure it out. Is there a solution to this problem that I have?
Ld /Users/alangibson/Library/Developer/Xcode/DerivedData/PumpkinMenace-ddpkivitawzujwdpdfyngakgkyxs/Build/Products/Debug-iphonesimulator/PumpkinMenace.app/PumpkinMenace normal i386
cd "/Users/alangibson/GameMaker-Studio/Pumpkin Menace/PumpkinMenace"
export IPHONEOS_DEPLOYMENT_TARGET=5.1.1
export 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/iPhoneSimulator8.0.sdk -L/Users/alangibson/Library/Developer/Xcode/DerivedData/PumpkinMenace-ddpkivitawzujwdpdfyngakgkyxs/Build/Products/Debug-iphonesimulator -L. -LFw -LPumpkinMenace -LFw/iOSSource -LPumpkinMenace/Game -LPumpkinMenace/Supporting\ Files -LFw/iOSSource/Source -LPumpkinMenace/Game/iOSSource -LPumpkinMenace/Supporting\ Files/__MACOSX -LPumpkinMenace/Supporting\ Files/games -LPumpkinMenace/Supporting\ Files/InAppSettings.bundle -LFw/iOSSource/Source/GoogleAdMobAdsSdkiOS-6.8.0 -LPumpkinMenace/Game/iOSSource/Source -LPumpkinMenace/Game/iOSSource/Source/GoogleAdMobAdsSdkiOS-6.8.0 -F/Users/alangibson/Library/Developer/Xcode/DerivedData/PumpkinMenace-ddpkivitawzujwdpdfyngakgkyxs/Build/Products/Debug-iphonesimulator -F/Users/alangibson/GameMaker-Studio/Pumpkin\ Menace/PumpkinMenace/Fw -F/Users/alangibson/GameMaker-Studio/Pumpkin\ Menace/PumpkinMenace/PumpkinMenace/Supporting\ Files -filelist /Users/alangibson/Library/Developer/Xcode/DerivedData/PumpkinMenace-ddpkivitawzujwdpdfyngakgkyxs/Build/Intermediates/Pumpkin\ Menace.build/Debug-iphonesimulator/PumpkinMenace.build/Objects-normal/i386/PumpkinMenace.LinkFileList -Xlinker -objc_abi_version -Xlinker 2 -objC -all_load -fobjc-arc -stdlib=libstdc++ -fobjc-link-runtime -Xlinker -no_implicit_dylibs -mios-simulator-version-min=5.1.1 -liconv -framework CoreMedia -framework SystemConfiguration -framework EventKit -framework EventKitUI -framework CoreTelephony -framework CoreData -framework CoreText -framework StoreKit -framework MapKit -framework AddressBookUI -framework CFNetwork -framework MobileCoreServices -framework Security -lsqlite3.0 -framework AddressBook -framework CoreLocation -framework MessageUI -framework MediaPlayer -framework AudioToolbox -framework GameKit -framework AVFoundation -lz -framework OpenGLES -framework QuartzCore -framework OpenAL -framework UIKit -framework Foundation -framework CoreGraphics -lFlurry -lyoyo_interpreted -framework GameController -framework FacebookSDK -framework AdSupport -framework iAd -lGoogleAdMobAds -Xlinker -dependency_info -Xlinker /Users/alangibson/Library/Developer/Xcode/DerivedData/PumpkinMenace-ddpkivitawzujwdpdfyngakgkyxs/Build/Intermediates/Pumpkin\ Menace.build/Debug-iphonesimulator/PumpkinMenace.build/Objects-normal/i386/PumpkinMenace_dependency_info.dat -o /Users/alangibson/Library/Developer/Xcode/DerivedData/PumpkinMenace-ddpkivitawzujwdpdfyngakgkyxs/Build/Products/Debug-iphonesimulator/PumpkinMenace.app/PumpkinMenace
This is the Error
ld: warning: ignoring file PumpkinMenace/Supporting Files/libyoyo_interpreted.a, file was built for archive which is not the architecture being linked (i386): PumpkinMenace/Supporting Files/libyoyo_interpreted.a
Undefined symbols for architecture i386:
"_main", referenced from:
implicit entry/start for main executable
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Yes, every iPhone project has a "main.m" file (in Xcode 6.1, it's usually hiding in the "Supporting Files" folder of your project).
If you don't have that main.m file (which contains a main C-style function), that's why you are seeing the error you are seeing.
Here is what the main function looks like:
int main(int argc, char * argv[]) {
#autoreleasepool {
return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
}
}
"Undefined symbols for architecture i386"
maybe the problem is in libyoyo_interpreted.a file because it was built for ios simulator architecture (i386), but you attempt to run application on device (which is arm7/armv7/arm64).
Rebuild libyoyo_interpreted.a for arm7/armv7 architectures. (it helped to me http://blog.diogot.com/blog/2013/09/18/static-libs-with-support-to-ios-5-and-arm64/)
I am attempting to call the CFSwapInt32HostToBig(<#arg: UInt32#>) method in swift file. I have added the CoreFoundation Framework to the project and I have "import CoreFoundation" at the top of my swift file. When I begin to type the method name, XCode suggest the method indicating to me that Xcode is recognizing methods from that framework. I have no errors in Xcode implying that all of my syntax is correct, but when I build I get the following error.
> Ld DerivedData/AudioToy/Build/Products/Debug-iphonesimulator/AudioToy.app/AudioToy normal x86_64
cd /Users/michaliberman/Documents/Projects/Swift/AudioToy
export IPHONEOS_DEPLOYMENT_TARGET=8.0
export 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 x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator8.0.sdk -L/Users/michaliberman/Documents/Projects/Swift/AudioToy/DerivedData/AudioToy/Build/Products/Debug-iphonesimulator -F/Users/michaliberman/Documents/Projects/Swift/AudioToy/DerivedData/AudioToy/Build/Products/Debug-iphonesimulator -filelist /Users/michaliberman/Documents/Projects/Swift/AudioToy/DerivedData/AudioToy/Build/Intermediates/AudioToy.build/Debug-iphonesimulator/AudioToy.build/Objects-normal/x86_64/AudioToy.LinkFileList -Xlinker -rpath -Xlinker #executable_path/Frameworks -Xlinker -objc_abi_version -Xlinker 2 -L/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator -Xlinker -add_ast_path -Xlinker /Users/michaliberman/Documents/Projects/Swift/AudioToy/DerivedData/AudioToy/Build/Intermediates/AudioToy.build/Debug-iphonesimulator/AudioToy.build/Objects-normal/x86_64/AudioToy.swiftmodule -mios-simulator-version-min=8.0 -framework CoreFoundation -framework AVFoundation -framework AudioToolbox -Xlinker -dependency_info -Xlinker /Users/michaliberman/Documents/Projects/Swift/AudioToy/DerivedData/AudioToy/Build/Intermediates/AudioToy.build/Debug-iphonesimulator/AudioToy.build/Objects-normal/x86_64/AudioToy_dependency_info.dat -o /Users/michaliberman/Documents/Projects/Swift/AudioToy/DerivedData/AudioToy/Build/Products/Debug-iphonesimulator/AudioToy.app/AudioToy
Undefined symbols for architecture x86_64:
"_CASwapFloat32", referenced from:
_CASwapFloat32HostToBig in AudioStudio.o
"__OSSwapInt32", referenced from:
_CFSwapInt32HostToBig in AudioStudio.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I have removed and re-imported the framework, but I still get the error. When I option-click on the method name it shows me the header file in which the method is declared and it if I click on that header file I see that it is within the framework. I am not sure what to do when the problem appears to be within the framework.
Use the bigEndian and littleEndian methods
let valueLE16 = 16
let valueBE16 = valueLE16.bigEndian
println("valueLE16: \(valueLE16)") // valueLE16: 16
println("valueBE16: \(valueBE16)") // valueBE16: 1152921504606846976
let valueLE16: Int16 = 16 //UnsafePointer<UInt16>(value.bytes)[0]
let valueBE16: Int16 = valueLE16.bigEndian
println("valueLE16: \(valueLE16)") // valueLE16: 16
println("valueBE16: \(valueBE16)") // valueBE16: 4096
I have purchased reddle kit for ipad pdf viewer. when i try to run the demo program i am getting following error
Ld /Users/svp/Library/Developer/Xcode/DerivedData/RDPDFKitSample-gjablgzmrirtqteckhbcytapkwcc/Build/Products/Debug-iphonesimulator/RDPDFKitSample.app/RDPDFKitSample normal i386
cd /Users/svp/Desktop/RDPDFKitDemo_1_2
setenv MACOSX_DEPLOYMENT_TARGET 10.6
setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-g++-4.2 -arch i386 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk -L/Users/svp/Library/Developer/Xcode/DerivedData/RDPDFKitSample-gjablgzmrirtqteckhbcytapkwcc/Build/Products/Debug-iphonesimulator -L/Users/svp/Desktop/RDPDFKitDemo_1_2/RDPDFKit.embeddedframework/RDPDFKit.framework/Versions/A -F/Users/svp/Library/Developer/Xcode/DerivedData/RDPDFKitSample-gjablgzmrirtqteckhbcytapkwcc/Build/Products/Debug-iphonesimulator -F/Users/svp/Desktop/RDPDFKitDemo_1_2/RDPDFKit.embeddedframework -filelist /Users/svp/Library/Developer/Xcode/DerivedData/RDPDFKitSample-gjablgzmrirtqteckhbcytapkwcc/Build/Intermediates/RDPDFKitSample.build/Debug-iphonesimulator/RDPDFKitSample.build/Objects-normal/i386/RDPDFKitSample.LinkFileList -mmacosx-version-min=10.6 -Xlinker -objc_abi_version -Xlinker 2 -framework SystemConfiguration -framework RDPDFKit -framework Security -framework OpenGLES -framework QuartzCore -lz -framework CoreText -framework MessageUI -weak_framework UIKit -weak_framework Foundation -framework CoreGraphics -o /Users/svp/Library/Developer/Xcode/DerivedData/RDPDFKitSample-gjablgzmrirtqteckhbcytapkwcc/Build/Products/Debug-iphonesimulator/RDPDFKitSample.app/RDPDFKitSample
Undefined symbols for architecture i386:
"_OBJC_CLASS_$_NSFileCoordinator", referenced from:
objc-class-ref in RDPDFKit(libRDPDFKit.a-i386-master.o)
"_OBJC_CLASS_$_UIReferenceLibraryViewController", referenced from:
objc-class-ref in RDPDFKit(libRDPDFKit.a-i386-master.o)
ld: symbol(s) not found for architecture i386
collect2: ld returned 1 exit status
how can i solve this issue.
We don't support building with iOS 4 SDK.
Make sure you are building with iOS 5 SDK. YOur application will still be able to run on device with iOS 4.0.
Danil Somsikov
Readdle Inc.
When i try to compile my project for the simulator or real devices, i get these errors:
Ld /Users/maumau/Library/Developer/Xcode/DerivedData/HarvestMoon-bciczopagtmfyqgxjxasrffzrnls/Build/Products/Debug-iphoneos/HarvestMoon.app/HarvestMoon normal armv7
cd /Users/maumau/Dropbox/Daten/Projekte/HMiOS
setenv IPHONEOS_DEPLOYMENT_TARGET 4.3
setenv PATH "/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/clang -arch armv7 -isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.0.sdk -L/Users/maumau/Library/Developer/Xcode/DerivedData/HarvestMoon-bciczopagtmfyqgxjxasrffzrnls/Build/Products/Debug-iphoneos -L/Users/maumau/Dropbox/Daten/Projekte/HMiOS/../../../../Library/Developer/Xcode/DerivedData/HarvestMoon-bciczopagtmfyqgxjxasrffzrnls/Build/Products/Debug-iphoneos -F/Users/maumau/Library/Developer/Xcode/DerivedData/HarvestMoon-bciczopagtmfyqgxjxasrffzrnls/Build/Products/Debug-iphoneos -filelist /Users/maumau/Library/Developer/Xcode/DerivedData/HarvestMoon-bciczopagtmfyqgxjxasrffzrnls/Build/Intermediates/HarvestMoon.build/Debug-iphoneos/HarvestMoon.build/Objects-normal/armv7/HarvestMoon.LinkFileList -dead_strip -ObjC -framework Foundation -framework UIKit -miphoneos-version-min=4.3 /Users/maumau/Library/Developer/Xcode/DerivedData/HarvestMoon-bciczopagtmfyqgxjxasrffzrnls/Build/Products/Debug-iphoneos/libbox2d.a -framework QuartzCore -framework OpenGLES -framework OpenAL -framework AudioToolbox -framework AVFoundation -framework UIKit -framework Foundation -framework CoreGraphics -o /Users/maumau/Library/Developer/Xcode/DerivedData/HarvestMoon-bciczopagtmfyqgxjxasrffzrnls/Build/Products/Debug-iphoneos/HarvestMoon.app/HarvestMoon
Undefined symbols for architecture armv7:
"_OBJC_CLASS_$_CCRepeatForever", referenced from:
objc-class-ref in KBPlayer.o
"_OBJC_METACLASS_$_CCTMXTiledMap", referenced from:
_OBJC_METACLASS_$_KBTMXTiledMap in KBTMXTiledMap.o
"_OBJC_CLASS_$_CCDirector", referenced from:
.... more errors ....
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
i use Xcode 4.2 and cocos2d-1.0. does anyone have an idea, how i can fix this?
You'd better to make sure that your project includes cocos2d source code or cocos2d static library. If you are using cocos2d static library, it must be compiled for armv7.
Your project is based on cocos2d application template?