浏览代码

synchronizing with host versions

philippe44 1 年之前
父节点
当前提交
93a2c0969c

+ 10 - 3
components/spotify/cspot/bell/external/nanopb/extra/FindNanopb.cmake

@@ -118,12 +118,15 @@
 #
 #=============================================================================
 
-
 function(NANOPB_GENERATE_CPP SRCS HDRS)
   cmake_parse_arguments(NANOPB_GENERATE_CPP "" "RELPATH" "" ${ARGN})
   if(NOT NANOPB_GENERATE_CPP_UNPARSED_ARGUMENTS)
     return()
   endif()
+  
+  if(MSVC)
+    set(CALL_PREFIX call)
+  endif()
 
   if(NANOPB_GENERATE_CPP_APPEND_PATH)
     # Create an include path for each file specified
@@ -184,7 +187,7 @@ function(NANOPB_GENERATE_CPP SRCS HDRS)
       set(GENERATOR_CORE_PYTHON_SRC ${GENERATOR_CORE_PYTHON_SRC} ${output})
       add_custom_command(
         OUTPUT ${output}
-        COMMAND ${PROTOBUF_PROTOC_EXECUTABLE}
+        COMMAND ${CALL_PREFIX} ${PROTOBUF_PROTOC_EXECUTABLE}
         ARGS -I${GENERATOR_PATH}/proto
           --python_out=${GENERATOR_CORE_DIR} ${ABS_FIL}
         DEPENDS ${ABS_FIL}
@@ -276,7 +279,7 @@ function(NANOPB_GENERATE_CPP SRCS HDRS)
     add_custom_command(
       OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/${FIL_PATH_REL}/${FIL_WE}.pb.c"
              "${CMAKE_CURRENT_BINARY_DIR}/${FIL_PATH_REL}/${FIL_WE}.pb.h"
-      COMMAND  ${PROTOBUF_PROTOC_EXECUTABLE}
+      COMMAND ${CALL_PREFIX} ${PROTOBUF_PROTOC_EXECUTABLE}
       ARGS -I${GENERATOR_PATH} -I${GENERATOR_CORE_DIR}
            -I${CMAKE_CURRENT_BINARY_DIR} ${_nanopb_include_path}
            --plugin=protoc-gen-nanopb=${NANOPB_GENERATOR_PLUGIN}
@@ -292,6 +295,10 @@ function(NANOPB_GENERATE_CPP SRCS HDRS)
   set_source_files_properties(${${SRCS}} ${${HDRS}} PROPERTIES GENERATED TRUE)
   set(${SRCS} ${${SRCS}} ${NANOPB_SRCS} PARENT_SCOPE)
   set(${HDRS} ${${HDRS}} ${NANOPB_HDRS} PARENT_SCOPE)
+  
+  if(MSVC)
+      unset(CALL_PREFIX)
+  endif()    
 
 endfunction()
 

+ 2 - 0
components/spotify/cspot/protobuf/authentication.proto

@@ -1,3 +1,5 @@
+syntax = "proto2";
+
 enum CpuFamily {
     CPU_UNKNOWN = 0x0;
     CPU_X86 = 0x1;

+ 2 - 0
components/spotify/cspot/protobuf/keyexchange.proto

@@ -1,3 +1,5 @@
+syntax = "proto2";
+
 message LoginCryptoDiffieHellmanChallenge {
     required bytes gs = 0xa; 
 }

+ 2 - 0
components/spotify/cspot/protobuf/mercury.proto

@@ -1,3 +1,5 @@
+syntax = "proto2";
+
 message Header {
     optional string uri = 0x01;
     optional string method = 0x03;

+ 2 - 0
components/spotify/cspot/protobuf/spirc.proto

@@ -1,3 +1,5 @@
+syntax = "proto2";
+
 enum MessageType {
     kMessageTypeHello = 0x1;
     kMessageTypeGoodbye = 0x2;