Hi,
I'm trying to utilize CBL 1.4.2 in a Swift app extension, so I need to
build the dynamic framework version of CBL.
That seems to be ok when I build the iOS Framework - Carthage version
(built right from within Xcode, not actually using Carthage).
But when I do that and try to compile my app which also includes the CBL
Listener framework, I get a bunch of compile errors referencing symbols in
CBL Listener that aren't available for the arm64 architecture:
Undefined symbols for architecture arm64:
"__mdictof", referenced from:
-[CBL_Router queries] in CouchbaseLiteListener(CBL_Router.o)
-[CBLDatabase(REST)
updateAttachment:body:type:encoding:ofDocID:revID:source:status:error:] in
CouchbaseLiteListener(CBLDatabase+REST.o)
-[CBL_Router(Handlers) do_POST_revs_diff:] in
CouchbaseLiteListener(CBL_Router+Handlers.o)
"__castIf", referenced from:
-[CBL_Router bodyAsDictionary] in CouchbaseLiteListener(CBL_Router.o)
-[CBLView(REST) compileFromDesignDoc] in
CouchbaseLiteListener(CBLView+REST.o)
-[CBLView(REST) compileFromProperties:language:] in
CouchbaseLiteListener(CBLView+REST.o)
-[CBLDatabase(REST) getDesignDocFunction:key:language:] in
CouchbaseLiteListener(CBLDatabase+REST.o)
-[CBLDatabase(REST) compileFilterNamed:status:] in
CouchbaseLiteListener(CBLDatabase+REST.o)
-[CBL_Router(Handlers) do_POST_facebook_token] in
CouchbaseLiteListener(CBL_Router+Handlers.o)
-[CBL_Router(Handlers) do_POST_bulk_docs:] in
CouchbaseLiteListener(CBL_Router+Handlers.o)
...
"_$regex", referenced from:
-[CBL_Router processRequestRanges] in
CouchbaseLiteListener(CBL_Router.o)
"__dictof", referenced from:
-[CBLResponse setInternalStatus:] in
CouchbaseLiteListener(CBL_Router.o)
-[CBLResponse setMultipartBody:type:] in
CouchbaseLiteListener(CBL_Router.o)
-[CBLDatabase(REST)
updateAttachment:body:type:encoding:ofDocID:revID:source:status:error:] in
CouchbaseLiteListener(CBLDatabase+REST.o)
-[CBL_Router(Handlers) do_POST_persona_assertion] in
CouchbaseLiteListener(CBL_Router+Handlers.o)
-[CBL_Router(Handlers) do_POST_facebook_token] in
CouchbaseLiteListener(CBL_Router+Handlers.o)
-[CBL_Router(Handlers) do_GET_uuids] in
CouchbaseLiteListener(CBL_Router+Handlers.o)
-[CBL_Router(Handlers) do_GET_session] in
CouchbaseLiteListener(CBL_Router+Handlers.o)
...
"__AssertFailed", referenced from:
-[CBL_Router route] in CouchbaseLiteListener(CBL_Router.o)
-[CBL_Router run] in CouchbaseLiteListener(CBL_Router.o)
_CBLStartServer in CouchbaseLiteListener(CBL_URLProtocol.o)
-[CBLDatabase(REST) attachmentForRevision:named:status:] in
CouchbaseLiteListener(CBLDatabase+REST.o)
___42-[CBL_Router(Handlers) do_POST_bulk_docs:]_block_invoke in
CouchbaseLiteListener(CBL_Router+Handlers.o)
"_$equal", referenced from:
-[CBLHTTPConnection supportsMethod:atPath:] in
CouchbaseLiteListener(CBLHTTPConnection.o)
-[CBLHTTPConnection expectsRequestBodyFromMethod:atPath:] in
CouchbaseLiteListener(CBLHTTPConnection.o)
-[CBL_Router boolQuery:] in CouchbaseLiteListener(CBL_Router.o)
-[CBL_Router cacheWithEtag:] in CouchbaseLiteListener(CBL_Router.o)
-[CBL_Router route] in CouchbaseLiteListener(CBL_Router.o)
-[CBL_Router processRequestRanges] in
CouchbaseLiteListener(CBL_Router.o)
-[CBL_Router sendResponseHeaders] in
CouchbaseLiteListener(CBL_Router.o)
...
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see
invocation)
Is this because I'm using the dynamic CBL framework and the static CBL
Listener framework together?
Is there a way to compile the CBL Listener as a dynamic framework?
When I type 'file CouchbaseLite', I get the following:
CouchbaseLite: Mach-O universal binary with 2 architectures: [arm_v7:Mach-O
dynamically linked shared library arm_v7] [arm64]
CouchbaseLite (for architecture armv7): Mach-O dynamically linked shared
library arm_v7
CouchbaseLite (for architecture arm64): Mach-O 64-bit dynamically linked
shared library arm64
But when I type 'file CouchbaseLiteListener', I get the following:
CouchbaseLiteListener: Mach-O universal binary with 4 architectures:
[arm_v7:current ar archive] [arm64]
CouchbaseLiteListener (for architecture armv7): current ar archive
CouchbaseLiteListener (for architecture i386): current ar archive
CouchbaseLiteListener (for architecture x86_64): current ar archive
CouchbaseLiteListener (for architecture arm64): current ar archive
So it would seem that the two frameworks are built differently.
Can you think of a reason why CouchbaseLiteListener is not able to see
those symbols?
I think this is the only thing preventing me from successfully compiling my
iOS app extension.
Thanks,
Brendan
--
You received this message because you are subscribed to the Google Groups
"Couchbase Mobile" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/mobile-couchbase/20ef2fc2-0622-467f-986d-befe71b50a33%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.