From af0c68c183bb1f33be503a37f57deb579cb32be9 Mon Sep 17 00:00:00 2001 From: Tim Wojtulewicz Date: Fri, 30 Jun 2023 14:04:23 -0700 Subject: [PATCH] bifcl: Add /J flag on Windows to force unsigned char --- tools/bifcl/CMakeLists.txt | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/tools/bifcl/CMakeLists.txt b/tools/bifcl/CMakeLists.txt index 3df5f0f39c..52210aec45 100644 --- a/tools/bifcl/CMakeLists.txt +++ b/tools/bifcl/CMakeLists.txt @@ -9,16 +9,17 @@ FindRequiredPackage(BISON) FindRequiredPackage(FLEX) if ( MISSING_PREREQS ) - foreach (prereq ${MISSING_PREREQ_DESCS}) - message(SEND_ERROR ${prereq}) - endforeach () - message(FATAL_ERROR "Configuration aborted due to missing prerequisites") + foreach (prereq ${MISSING_PREREQ_DESCS}) + message(SEND_ERROR ${prereq}) + endforeach () + message(FATAL_ERROR "Configuration aborted due to missing prerequisites") endif () if (MSVC) - set_property(SOURCE bif_lex.cc APPEND_STRING PROPERTY COMPILE_FLAGS "/wd4018") + add_compile_options(/J) # Similar to -funsigned-char on other platforms + set_property(SOURCE bif_lex.cc APPEND_STRING PROPERTY COMPILE_FLAGS "/wd4018") else() - set_property(SOURCE bif_lex.cc APPEND_STRING PROPERTY COMPILE_FLAGS "-Wno-sign-compare") + set_property(SOURCE bif_lex.cc APPEND_STRING PROPERTY COMPILE_FLAGS "-Wno-sign-compare") endif() include_directories(BEFORE