Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
arm systems have unsigned chars by default, enforce signedness for consistancy
[simgrid.git] / tools / cmake / Flags.cmake
index de55de0..6fdaa31 100644 (file)
@@ -84,6 +84,12 @@ if(enable_compile_optimizations)
 else()
   set(optCFLAGS "-O0 ")
 endif()
+
+#ARM platforms have signed char by default, switch to unsigned for consistancy
+if(${CMAKE_SYSTEM_PROCESSOR} MATCHES "aarch64")
+  set(optCFLAGS "${optCFLAGS} -fsigned-char")
+endif()
+
 if(enable_compile_optimizations AND CMAKE_COMPILER_IS_GNUCC
     AND (NOT enable_model-checking))
   # This is redundant (already in -03):