File tree Expand file tree Collapse file tree 3 files changed +9
-0
lines changed Expand file tree Collapse file tree 3 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -83,6 +83,7 @@ project (Jerry CXX C ASM)
83
83
84
84
set (EXTERNAL_LIBC_INTERFACE "UNDEFINED" CACHE STRING "Path to external libc include directory" )
85
85
set (EXTERNAL_LIBS_INTERFACE "UNDEFINED" CACHE STRING "Path to external libraries' include directory" )
86
+ set (EXTERNAL_MEM_HEAP_SIZE_KB "256" CACHE STRING "Size of memory heap, in kilobytes" )
86
87
else ()
87
88
message (FATAL_ERROR "Platform '${PLATFORM} ' is not supported" )
88
89
endif ()
Original file line number Diff line number Diff line change @@ -88,6 +88,12 @@ project (JerryCore CXX C ASM)
88
88
math (EXPR MEM_HEAP_AREA_SIZE_16K "16 * 1024" )
89
89
set (DEFINES_JERRY_MCU_STM32F4 CONFIG_MEM_HEAP_AREA_SIZE=${MEM_HEAP_AREA_SIZE_16K} )
90
90
91
+ # External
92
+ if (DEFINED EXTERNAL_MEM_HEAP_SIZE_KB )
93
+ math (EXPR MEM_HEAP_AREA_SIZE_EXTERNAL "${EXTERNAL_MEM_HEAP_SIZE_KB} * 1024" )
94
+ set (DEFINES_JERRY_EXTERNAL CONFIG_MEM_HEAP_AREA_SIZE=${MEM_HEAP_AREA_SIZE_EXTERNAL} )
95
+ endif ()
96
+
91
97
# Include directories
92
98
set (INCLUDE_CORE
93
99
${CMAKE_SOURCE_DIR} /jerry-core
Original file line number Diff line number Diff line change 53
53
*/
54
54
#ifndef CONFIG_MEM_HEAP_AREA_SIZE
55
55
# define CONFIG_MEM_HEAP_AREA_SIZE (256 * 1024)
56
+ #elif CONFIG_MEM_HEAP_AREA_SIZE > (256 * 1024 )
57
+ # error "Currently, maximum 256 kilobytes heap size is supported"
56
58
#endif /* !CONFIG_MEM_HEAP_AREA_SIZE */
57
59
58
60
/**
You can’t perform that action at this time.
0 commit comments