xcode - Unable to merge Unity 5 into our iOS application -


we have large , complicated application , looking upgrade our 3d engine unity 5.0. having trouble integrating unity.

i been trying follow these tutorials constant errors keep poping whatever do. http://www.the-nerd.be/2014/09/08/sandbox-unity-app-in-existing-ios-app/ http://www.makethegame.net/unity/add-unity3d-to-native-ios-app-with-unity-5-and-vuforia-4-x/ http://www.markuszancolo.at/2014/05/integrating-unity-into-a-native-ios-app/

if add "libraries" , "classes" folders project, odd amount errors. gets confused other c code in project(really doesn't msgpack) , tries import wrong files (ilcpp files). if remove offending code project still have list of errors native cstring class.

compilec /users/jess/library/developer/xcode/deriveddata/crichq-bsrxghpplcwahnadlgmwxmzwbxff/build/intermediates/crichq.build/debug-iphoneos/crichq.build/objects-normal/armv7/main-5d1dd4e92c87f57a.o classes/other/main.mm normal armv7 objective-c++ com.apple.compilers.llvm.clang.1_0.compiler cd /users/jess/projects/git/crichq-iphone export lang=en_us.us-ascii export path="/applications/xcode.app/contents/developer/platforms/iphoneos.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 -x objective-c++ -arch armv7 -fmessage-length=0 -fdiagnostics-show-note-include-stack -fmacro-backtrace-limit=0 -std=c++11 -stdlib=libc++ -fobjc-arc -fmodules -fmodules-cache-path=/users/jess/library/developer/xcode/deriveddata/modulecache -fmodules-prune-interval=86400 -fmodules-prune-after=345600 -fbuild-session-file=/users/jess/library/developer/xcode/deriveddata/modulecache/session.modulevalidation -fmodules-validate-once-per-build-session -wno-trigraphs -fpascal-strings -o0 -werror=incompatible-pointer-types -wmissing-field-initializers -wmissing-prototypes -wno-return-type -wimplicit-atomic-properties -wno-receiver-is-weak -warc-repeated-use-of-weak -wexplicit-ownership-type -wimplicit-retain-self -wno-non-virtual-dtor -wno-overloaded-virtual -wexit-time-destructors -wduplicate-method-match -wno-missing-braces -wparentheses -wswitch -wno-unused-function -wno-unused-label -wno-unused-parameter -wunused-variable -wunused-value -wempty-body -wuninitialized -wno-unknown-pragmas -wno-shadow -wno-four-char-constants -wno-conversion -wno-constant-conversion -wint-conversion -wno-bool-conversion -wenum-conversion -wassign-enum -wno-shorten-64-to-32 -wno-newline-eof -wno-selector -wstrict-selector-match -wno-undeclared-selector -wdeprecated-implementations -wc++11-extensions -ddebug=1 -dobjc_old_dispatch_prototypes=0 -isysroot /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk -fstrict-aliasing -wprotocol -wdeprecated-declarations -winvalid-offsetof -g -fvisibility=hidden -fvisibility-inlines-hidden -wno-sign-conversion -miphoneos-version-min=7.0 -i/users/jess/library/developer/xcode/deriveddata/crichq-bsrxghpplcwahnadlgmwxmzwbxff/build/intermediates/crichq.build/debug-iphoneos/crichq.build/crichq\ next.hmap -i/users/jess/library/developer/xcode/deriveddata/crichq-bsrxghpplcwahnadlgmwxmzwbxff/build/products/debug-iphoneos/include -i/applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/include -i/users/jess/projects/git/crichq-iphone/libraries -i/applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/usr/include/libxml2 -i/users/jess/projects/git/crichq-iphone/../crichq-3d/ios-export/classes -i/users/jess/projects/git/crichq-iphone/../crichq-3d/ios-export/libraries/bdwgc/include -i/users/jess/projects/git/crichq-iphone/../crichq-3d/ios-export/libraries/libil2cpp/include -i/users/jess/projects/git/crichq-iphone/../crichq-3d/ios-export/classes/native -i/users/jess/projects/git/crichq-iphone/libraries/cricengine/source -i/users/jess/library/developer/xcode/deriveddata/crichq-bsrxghpplcwahnadlgmwxmzwbxff/build/intermediates/crichq.build/debug-iphoneos/crichq.build/derivedsources/armv7 -i/users/jess/library/developer/xcode/deriveddata/crichq-bsrxghpplcwahnadlgmwxmzwbxff/build/intermediates/crichq.build/debug-iphoneos/crichq.build/derivedsources -f/users/jess/library/developer/xcode/deriveddata/crichq-bsrxghpplcwahnadlgmwxmzwbxff/build/products/debug-iphoneos -f/users/jess/projects/git/crichq-iphone -mno-thumb -dinit_scripting_backend=1 -include /users/jess/projects/git/crichq-iphone/classes/other/crichq_prefix.pch -mmd -mt dependencies -mf /users/jess/library/developer/xcode/deriveddata/crichq-bsrxghpplcwahnadlgmwxmzwbxff/build/intermediates/crichq.build/debug-iphoneos/crichq.build/objects-normal/armv7/main-5d1dd4e92c87f57a.d --serialize-diagnostics /users/jess/library/developer/xcode/deriveddata/crichq-bsrxghpplcwahnadlgmwxmzwbxff/build/intermediates/crichq.build/debug-iphoneos/crichq.build/objects-normal/armv7/main-5d1dd4e92c87f57a.dia -c /users/jess/projects/git/crichq-iphone/classes/other/main.mm -o /users/jess/library/developer/xcode/deriveddata/crichq-bsrxghpplcwahnadlgmwxmzwbxff/build/intermediates/crichq.build/debug-iphoneos/crichq.build/objects-normal/armv7/main-5d1dd4e92c87f57a.o

in file included :353: in file included :4: in file included /users/jess/projects/git/crichq-iphone/classes/other/crichq_prefix.pch:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/foundation.framework/headers/foundation.h:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/corefoundation.framework/headers/corefoundation.h:18: in file included /users/jess/projects/git/crichq-iphone/libraries/../../crichq-3d/ios-export/libraries/libil2cpp/include/os/locale.h:4: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/string:436: /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:70:9: error: no member named 'memcpy' in global namespace; did mean 'wmemcpy'? using ::memcpy; ~~^ in file included :353: in file included :4: in file included /users/jess/projects/git/crichq-iphone/classes/other/crichq_prefix.pch:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/foundation.framework/headers/foundation.h:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/corefoundation.framework/headers/corefoundation.h:18: in file included /users/jess/projects/git/crichq-iphone/libraries/../../crichq-3d/ios-export/libraries/libil2cpp/include/os/locale.h:4: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/string:435: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/iosfwd:90: /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/usr/include/wchar.h:152:10: note: 'wmemcpy' declared here wchar_t *wmemcpy(wchar_t * __restrict, const wchar_t * __restrict, size_t); ^ in file included :353: in file included :4: in file included /users/jess/projects/git/crichq-iphone/classes/other/crichq_prefix.pch:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/foundation.framework/headers/foundation.h:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/corefoundation.framework/headers/corefoundation.h:18: in file included /users/jess/projects/git/crichq-iphone/libraries/../../crichq-3d/ios-export/libraries/libil2cpp/include/os/locale.h:4: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/string:436: /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:71:9: error: no member named 'memmove' in global namespace; did mean 'wmemmove'? using ::memmove; ~~^ in file included :353: in file included :4: in file included /users/jess/projects/git/crichq-iphone/classes/other/crichq_prefix.pch:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/foundation.framework/headers/foundation.h:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/corefoundation.framework/headers/corefoundation.h:18: in file included /users/jess/projects/git/crichq-iphone/libraries/../../crichq-3d/ios-export/libraries/libil2cpp/include/os/locale.h:4: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/string:435: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/iosfwd:90: /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/usr/include/wchar.h:153:10: note: 'wmemmove' declared here wchar_t *wmemmove(wchar_t *, const wchar_t *, size_t); ^ in file included :353: in file included :4: in file included /users/jess/projects/git/crichq-iphone/classes/other/crichq_prefix.pch:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/foundation.framework/headers/foundation.h:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/corefoundation.framework/headers/corefoundation.h:18: in file included /users/jess/projects/git/crichq-iphone/libraries/../../crichq-3d/ios-export/libraries/libil2cpp/include/os/locale.h:4: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/string:436: /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:72:9: error: no member named 'strcpy' in global namespace using ::strcpy; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:73:9: error: no member named 'strncpy' in global namespace using ::strncpy; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:74:9: error: no member named 'strcat' in global namespace using ::strcat; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:75:9: error: no member named 'strncat' in global namespace using ::strncat; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:76:9: error: no member named 'memcmp' in global namespace; did mean 'wmemcmp'? using ::memcmp; ~~^ in file included :353: in file included :4: in file included /users/jess/projects/git/crichq-iphone/classes/other/crichq_prefix.pch:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/foundation.framework/headers/foundation.h:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/corefoundation.framework/headers/corefoundation.h:18: in file included /users/jess/projects/git/crichq-iphone/libraries/../../crichq-3d/ios-export/libraries/libil2cpp/include/os/locale.h:4: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/string:435: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/iosfwd:90: /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/usr/include/wchar.h:151:5: note: 'wmemcmp' declared here int wmemcmp(const wchar_t *, const wchar_t *, size_t); ^ in file included :353: in file included :4: in file included /users/jess/projects/git/crichq-iphone/classes/other/crichq_prefix.pch:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/foundation.framework/headers/foundation.h:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/corefoundation.framework/headers/corefoundation.h:18: in file included /users/jess/projects/git/crichq-iphone/libraries/../../crichq-3d/ios-export/libraries/libil2cpp/include/os/locale.h:4: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/string:436: /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:77:9: error: no member named 'strcmp' in global namespace using ::strcmp; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:78:9: error: no member named 'strncmp' in global namespace using ::strncmp; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:79:9: error: no member named 'strcoll' in global namespace; did mean 'strtoll'? using ::strcoll; ~~^ in file included :353: in file included :4: in file included /users/jess/projects/git/crichq-iphone/classes/other/crichq_prefix.pch:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/foundation.framework/headers/foundation.h:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/corefoundation.framework/headers/corefoundation.h:13: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/usr/include/assert.h:44: /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/usr/include/stdlib.h:169:3: note: 'strtoll' declared here strtoll(const char *, char **, int); ^ in file included :353: in file included :4: in file included /users/jess/projects/git/crichq-iphone/classes/other/crichq_prefix.pch:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/foundation.framework/headers/foundation.h:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/corefoundation.framework/headers/corefoundation.h:18: in file included /users/jess/projects/git/crichq-iphone/libraries/../../crichq-3d/ios-export/libraries/libil2cpp/include/os/locale.h:4: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/string:436: /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:80:9: error: no member named 'strxfrm' in global namespace using ::strxfrm; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:82:9: error: no member named 'memchr' in global namespace; did mean 'wmemchr'? using ::memchr; ~~^ in file included :353: in file included :4: in file included /users/jess/projects/git/crichq-iphone/classes/other/crichq_prefix.pch:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/foundation.framework/headers/foundation.h:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/corefoundation.framework/headers/corefoundation.h:18: in file included /users/jess/projects/git/crichq-iphone/libraries/../../crichq-3d/ios-export/libraries/libil2cpp/include/os/locale.h:4: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/string:435: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/iosfwd:90: /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/usr/include/wchar.h:150:10: note: 'wmemchr' declared here wchar_t *wmemchr(const wchar_t , wchar_t, size_t); ^ in file included :353: in file included :4: in file included /users/jess/projects/git/crichq-iphone/classes/other/crichq_prefix.pch:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/foundation.framework/headers/foundation.h:6: in file included /applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/sdks/iphoneos8.3.sdk/system/library/frameworks/corefoundation.framework/headers/corefoundation.h:18: in file included /users/jess/projects/git/crichq-iphone/libraries/../../crichq-3d/ios-export/libraries/libil2cpp/include/os/locale.h:4: in file included /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/string:436: /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:84:9: error: no member named 'strchr' in global namespace using ::strchr; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:86:9: error: no member named 'strcspn' in global namespace using ::strcspn; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:88:9: error: no member named 'strpbrk' in global namespace using ::strpbrk; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:90:9: error: no member named 'strrchr' in global namespace using ::strrchr; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:92:9: error: no member named 'strspn' in global namespace using ::strspn; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:94:9: error: no member named 'strstr' in global namespace using ::strstr; ~~^ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:98:87: error: no member named 'strchr' in global namespace; did mean 'strchr'? inline _libcpp_inline_visibility char strchr( char* __s, int __c) {return ::strchr(__s, __c);} ^~ /applications/xcode.app/contents/developer/toolchains/xcodedefault.xctoolchain/usr/bin/../include/c++/v1/cstring:98:46: note: 'strchr' declared here inline _libcpp_inline_visibility
char* strchr( char* __s, int __c) {return ::strchr(__s, __c);}

screenshot: xcode errors

anyone know of solution? in matter great i'm totally stuck on should try next.

edit: plain project worked, start. sounds 1 of libraries interfering maybe. code base large need narrowing issue down.

edit 2: updated unity 5.1, xcode 7 beta, clean, deleted deriveddata folder , still no change. once added "-ferror-limit=1000" saw 999+ errors instead of 30.

common errors:

"declaration conflicts target of using declaration in scope".

"call 'x' ambiguous" (cos, exp, ceil)

"could not build module 'x'" (foundation, darwin)

"no member named 'x" in namespace" (memset, memcpy, memmove)

"use of undeclared identifier 'x'" (strdup)

"expected ';' after top level declarator"

edit 3: solve errors setting "always search user paths" "no" in xcode project settings.

but i'm having few other issues.

unity still using cpu when pause it. there anyway solve this? calling unity's "applicationdidbecomeactive" method. tried calling "unitypause".

calling unity's "getappcontroller()" in own code causes error:

undefined symbols architecture armv7:

"_getappcontroller", referenced from:

-[test3d viewdiddisappear:] in test3d.o ld: symbol(s) not found architecture armv7

i dont have enough reputation here comment, write answer: after 3 edits not sure problems still left...

getappcontroller inline function in unityappcontroller.h if isnt linked project, didnt include file (but instead declared getappcontroller() somewhere yourself).

the other errors looks have conflicts basic c-libs. other code using c++ std lib? , if yes, one? 1 stated in buildsettings under "c++ standard library"? should libc++

the "solution" switch "always search user paths" "no" sounds more problem other included projects.


Comments

Popular posts from this blog

Magento/PHP - Get phones on all members in a customer group -

php - Bypass Geo Redirect for specific directories -

php - .htaccess mod_rewrite for dynamic url which has domain names -