Skip to content

Including the Firebase C++ SDK in a CMake/MSVC2019 CMake project. #162

Closed
@nohype

Description

@nohype
  • Pre-built SDK from the website
  • Firebase C++ SDK version: 6.16.0
  • Main Firebase Components in concern: Database
  • Other Firebase Components in use: App, Auth
  • Platform you are using the C++ SDK on: Windows
  • Platform you are targeting: desktop

[REQUIRED] Please describe the question here:

Hi! When attempting to build a project with the prebuilt Firebase C++ SDK, using the MSVC2019 compiler and CMake on Windows, I always get the following errors. I could not seem to find out where those methods should be located, which library I might be missing/not linking.

`firebase_database.lib(f4a1508f798b6b861526e21467e4be6e_database.dir_Debug_level_db_persistence_storage_engine.obj):
error LNK2019: unresolved external symbol "class firebase::Variant __cdecl firebase::util::FlexbufferToVariant(class flexbuffers::Reference const &)" (?FlexbufferToVariant@util@firebase@@ya?AVVariant@2@AEBVReference@flexbuffers@@@z)
referenced in function "public: virtual class firebase::Variant __cdecl firebase::database::internal::LevelDbPersistenceStorageEngine::ServerCache(class firebase::Path const &)" (?ServerCache@LevelDbPersistenceStorageEngine@internal@database@firebase@@UEAA?AVVariant@4@AEBVPath@4@@z)

firebase_database.lib(f4a1508f798b6b861526e21467e4be6e_database.dir_Debug_flatbuffer_conversions.obj) : error LNK2001: unresolved external symbol "class firebase::Variant __cdecl firebase::util::FlexbufferToVariant(class flexbuffers::Reference const &)" (?FlexbufferToVariant@util@firebase@@ya?AVVariant@2@AEBVReference@flexbuffers@@@z)

firebase_database.lib(f4a1508f798b6b861526e21467e4be6e_database.dir_Debug_level_db_persistence_storage_engine.obj) : error LNK2019: unresolved external symbol "bool __cdecl firebase::util::VariantToFlexbuffer(class firebase::Variant const &,class flexbuffers::Builder *)" (?VariantToFlexbuffer@util@firebase@@YA_NAEBVVariant@2@PEAVBuilder@flexbuffers@@@z) referenced in function "public: bool __cdecl <lambda_e4f0c2f9cb695facf4fbcf828e4775a5>::operator()(class std::vector<unsigned char,class std::allocator > *)const " (??R<lambda_e4f0c2f9cb695facf4fbcf828e4775a5>@@QEBA_NPEAV?$vector@EV?$allocator@E@std@@@std@@@z)`

Maybe anybody would kindly have a hint or any kind of help?

And a minor second question: Is clang-cl supported to build the Firebase C++ SDK itself, and/or to use the prebuilt one?

Thanks a lot in advance!

Kind regards,
Julian

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions