Selaa lähdekoodia

NodesetCompiler: Remove unused --encode-binary-size

Stefan Profanter 5 vuotta sitten
vanhempi
commit
c7d2daa58a
3 muutettua tiedostoa jossa 2 lisäystä ja 20 poistoa
  1. 0 5
      CMakeLists.txt
  2. 1 8
      tools/cmake/macros_public.cmake
  3. 1 7
      tools/nodeset_compiler/nodeset_compiler.py

+ 0 - 5
CMakeLists.txt

@@ -905,16 +905,11 @@ if (UA_ENABLE_AMALGAMATION)
                      open62541-generator-transport open62541-generator-statuscode)
 endif()
 
-if(NOT UA_NODESET_ENCODE_BINARY_SIZE)
-    set(UA_NODESET_ENCODE_BINARY_SIZE 32000)
-endif()
-
 ua_generate_nodeset(
     NAME "ns0"
     FILE ${UA_FILE_NODESETS}
     INTERNAL
     IGNORE "${PROJECT_SOURCE_DIR}/tools/nodeset_compiler/NodeID_NS0_Base.txt"
-    ENCODE_BINARY_SIZE ${UA_NODESET_ENCODE_BINARY_SIZE}
     DEPENDS_TARGET "open62541-generator-types"
 )
 

+ 1 - 8
tools/cmake/macros_public.cmake

@@ -225,7 +225,6 @@ endfunction()
 #   NAME            Name of the nodeset, e.g. 'di'
 #   [TYPES_ARRAY]   Optional name of the types array containing the custom datatypes of this node set.
 #   [OUTPUT_DIR]    Optional target directory for the generated files. Default is '${PROJECT_BINARY_DIR}/src_generated'
-#   [ENCODE_BINARY_SIZE]    Optional array size for binary encoding extension objects.
 #   [IGNORE]        Optional file containing a list of node ids which should be ignored. The file should have one id per line.
 #   [TARGET_PREFIX] Optional prefix for the resulting target. Default `open62541-generator`
 #
@@ -240,7 +239,7 @@ endfunction()
 function(ua_generate_nodeset)
 
     set(options INTERNAL )
-    set(oneValueArgs NAME TYPES_ARRAY OUTPUT_DIR ENCODE_BINARY_SIZE IGNORE TARGET_PREFIX)
+    set(oneValueArgs NAME TYPES_ARRAY OUTPUT_DIR IGNORE TARGET_PREFIX)
     set(multiValueArgs FILE DEPENDS_TYPES DEPENDS_NS DEPENDS_TARGET)
     cmake_parse_arguments(UA_GEN_NS "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN} )
 
@@ -291,12 +290,6 @@ function(ua_generate_nodeset)
         set(GEN_IGNORE "--ignore=${UA_GEN_NS_IGNORE}")
     endif()
 
-    set(GEN_BIN_SIZE "")
-    if (UA_GEN_NS_ENCODE_BINARY_SIZE OR "${UA_GEN_NS_ENCODE_BINARY_SIZE}" STREQUAL "0")
-        set(GEN_BIN_SIZE "--encode-binary-size=${UA_GEN_NS_ENCODE_BINARY_SIZE}")
-    endif()
-
-
     set(TYPES_ARRAY_LIST "")
     foreach(f ${UA_GEN_NS_DEPENDS_TYPES})
         # Replace dash with underscore to make valid c literal

+ 1 - 7
tools/nodeset_compiler/nodeset_compiler.py

@@ -82,12 +82,6 @@ parser.add_argument('-t', '--types-array',
                     default=[],
                     help='Types array for the given namespace. Can be used mutliple times to define (in the same order as the .xml files, first for --existing, then --xml) the type arrays')
 
-parser.add_argument('--encode-binary-size',
-                    type=int,
-                    dest="encode_binary_size",
-                    default=32000,
-                    help='Size of the temporary array used to encode custom datatypes. If you don\'t know what it is, do not use this option')
-
 parser.add_argument('-v', '--verbose', action='count',
                     default=1,
                     help='Make the script more verbose. Can be applied up to 4 times')
@@ -202,7 +196,7 @@ logger.info("Generating Code for Backend: {}".format(args.backend))
 if args.backend == "open62541":
     # Create the C code with the open62541 backend of the compiler
     from backend_open62541 import generateOpen62541Code
-    generateOpen62541Code(ns, args.outputFile, args.generate_ns0, args.internal_headers, args.typesArray, args.encode_binary_size)
+    generateOpen62541Code(ns, args.outputFile, args.generate_ns0, args.internal_headers, args.typesArray)
 elif args.backend == "graphviz":
     from backend_graphviz import generateGraphvizCode
     generateGraphvizCode(ns, filename=args.outputFile)