aboutsummaryrefslogtreecommitdiffhomepage
path: root/cmake/FindNanopb.cmake
diff options
context:
space:
mode:
authorGravatar Gil <mcg@google.com>2018-07-11 15:55:36 -0700
committerGravatar GitHub <noreply@github.com>2018-07-11 15:55:36 -0700
commit7fc953fc6ffa69d159c0523d3902d867fe8c0ca5 (patch)
treed8551a0c0d592f5937435819ca3d6e8c1bec72a9 /cmake/FindNanopb.cmake
parente1ace703fbf4458d9e887ebf30050b1a0482a2d2 (diff)
Firestore CMake cleanup (#1510)
* Pull out sanitizer options into a separate file * Reorder packages * Remove the extra "external/$target" directory from PREFIX Instead of BINARY_DIR/external/foo/src/foo the contents will be in BINARY_DIR/src/foo. * Make libprotobuf-nanopb targets line up with nanopb's CMakeLists.txt * Fix CMake style
Diffstat (limited to 'cmake/FindNanopb.cmake')
-rw-r--r--cmake/FindNanopb.cmake8
1 files changed, 3 insertions, 5 deletions
diff --git a/cmake/FindNanopb.cmake b/cmake/FindNanopb.cmake
index 131be2a..e7a94bb 100644
--- a/cmake/FindNanopb.cmake
+++ b/cmake/FindNanopb.cmake
@@ -14,8 +14,6 @@
include(FindPackageHandleStandardArgs)
-set(BINARY_DIR ${FIREBASE_BINARY_DIR}/external/nanopb)
-
find_path(
NANOPB_INCLUDE_DIR pb.h
)
@@ -35,10 +33,10 @@ find_package_handle_standard_args(
if(NANOPB_FOUND)
set(NANOPB_INCLUDE_DIRS ${NANOPB_INCLUDE_DIR})
- if (NOT TARGET nanopb)
- add_library(nanopb UNKNOWN IMPORTED)
+ if (NOT TARGET protobuf-nanopb)
+ add_library(protobuf-nanopb UNKNOWN IMPORTED)
set_target_properties(
- nanopb PROPERTIES
+ protobuf-nanopb PROPERTIES
INTERFACE_INCLUDE_DIRECTORIES ${NANOPB_INCLUDE_DIRS}
IMPORTED_LOCATION ${NANOPB_LIBRARY}
)