Skip to content

Commit da5d6a9

Browse files
authored
Fix Firestore 7.10.0 build in C++ SDK, and match NanoPB versions. (#370)
Update NanoPB package to match Firestore version, and add the new Firestore nanopb proto header path to the build.
1 parent c46da1a commit da5d6a9

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

cmake/external/nanopb.cmake

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,14 @@ if(TARGET nanopb OR NOT DOWNLOAD_NANOPB)
1818
return()
1919
endif()
2020

21+
set(version 0.3.9.8)
22+
2123
ExternalProject_Add(
2224
nanopb
2325

2426
DOWNLOAD_DIR ${FIREBASE_DOWNLOAD_DIR}
25-
URL https://github.com/nanopb/nanopb/archive/0.3.9.2.tar.gz
26-
URL_HASH SHA256=b8dd5cb0d184d424ddfea13ddee3f7b0920354334cbb44df434d55e5f0086b12
27+
URL https://github.com/nanopb/nanopb/archive/nanopb-${version}.tar.gz
28+
URL_HASH SHA256=2047ff111ca408c9b3c06a6774b723c1b1c9e31dc2320c61ee3abce93359eb30
2729

2830
PREFIX ${PROJECT_BINARY_DIR}
2931

firestore/CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -299,6 +299,7 @@ if(IOS)
299299
# The Firestore core on iOS comes via the FirebaseFirestore CocoaPod, and
300300
# public headers should come from there.
301301
${FIREBASE_POD_DIR}/Pods/FirebaseFirestore/Firestore/core/include
302+
${FIREBASE_POD_DIR}/Pods/FirebaseFirestore/Firestore/Protos/nanopb
302303
PRIVATE
303304
# Additionally, the core C++ API is not declared publicly within the
304305
# FirebaseFirestore pod, so depend on headers available in the source
@@ -312,6 +313,7 @@ else()
312313
target_include_directories(firebase_firestore
313314
PUBLIC
314315
${FIRESTORE_SOURCE_DIR}/Firestore/core/include
316+
${FIRESTORE_SOURCE_DIR}/Firestore/Protos/nanopb
315317
PRIVATE
316318
${FIRESTORE_SOURCE_DIR}
317319
)

0 commit comments

Comments
 (0)