From ece77ead077bac5215b1ae372727829b0a147bc1 Mon Sep 17 00:00:00 2001 From: jing wang Date: Wed, 13 Dec 2017 09:26:41 +0800 Subject: [PATCH 1/2] Fix build issue #37 --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2d891ef..5c93705 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 2.8.12) +cmake_minimum_required(VERSION 3.5) #SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "") #SET(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS "") From 21a3f94aa5b94642fee9ed2d88025f701afd75df Mon Sep 17 00:00:00 2001 From: jing wang Date: Wed, 13 Dec 2017 09:59:33 +0800 Subject: [PATCH 2/2] fix standalone build issue this commit fix message idl translate issue when run "cmake -Dfreertps_standalone=ON ." --- r2/mega_genmsg.py | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/r2/mega_genmsg.py b/r2/mega_genmsg.py index c727f5d..ea65b50 100755 --- a/r2/mega_genmsg.py +++ b/r2/mega_genmsg.py @@ -32,6 +32,22 @@ def deserialize(self, name, cur_alignment, f): f.write(" printf(\"deserialization of {0} not implemented!\");\n".format(self.name)) f.write(" exit(1);\n") + def serialize_fixed_array(self, field_name, cur_alignment, array_size, f): + f.write(" printf(\"serialization fixed array of {0} not implemented!\");\n".format(self.name)) + f.write(" exit(1);\n") + + def deserialize_fixed_array(self, field_name, cur_alignment, array_size, f): + f.write(" printf(\"deserialization fixed array of {0} not implemented!\");\n".format(self.name)) + f.write(" exit(1);\n") + + def serialize_variable_array(self, field_name, cur_alignment, f): + f.write(" printf(\"serialization variable array of {0} not implemented!\");\n".format(self.name)) + f.write(" exit(1);\n") + + def deserialize_variable_array(self, field_name, cur_alignment, f): + f.write(" printf(\"deserialization variable array of {0} not implemented!\");\n".format(self.name)) + f.write(" exit(1);\n") + class BooleanType(PrimitiveType): def __init__(self): super(BooleanType, self).__init__('bool', 1) @@ -140,7 +156,7 @@ def deserialize_variable_array(self, field_name, cur_alignment, f): def uncamelcase(camelcase): lower = "" upper_run_len = 0 - for idx in xrange(0, len(camelcase)): + for idx in range(0, len(camelcase)): #print(camelcase[idx]) if (camelcase[idx].isupper()): next_lower = idx < len(camelcase)-1 and camelcase[idx+1].islower()