[CMAKE] Add GCC options to make a long double 64 bits

This adds -mlong-double-64 to make the size of a long double 64 bits in GCC builds to match MSVC builds.
This commit is contained in:
Timo Kreuzer 2023-11-01 20:09:44 +02:00
parent 469e7c6d4e
commit 9be24a9d51
2 changed files with 4 additions and 1 deletions

View file

@ -28,7 +28,7 @@ target_compile_definitions(msvcrt_winetest PRIVATE
__msvcrt_ulong=ULONG)
if(CMAKE_C_COMPILER_ID STREQUAL "GNU" OR CMAKE_C_COMPILER_ID STREQUAL "Clang")
target_compile_options(msvcrt_winetest PRIVATE -Wno-format -Wno-stringop-truncation)
target_compile_options(msvcrt_winetest PRIVATE -Wno-format -Wno-stringop-truncation -Wno-overflow)
endif()
set_module_type(msvcrt_winetest win32cui)

View file

@ -42,6 +42,9 @@ endif()
# note: -fno-common is default since GCC 10
add_compile_options(-pipe -fms-extensions -fno-strict-aliasing -fno-common)
# A long double is 64 bits
add_compile_options(-mlong-double-64)
# Prevent GCC from searching any of the default directories.
# The case for C++ is handled through the reactos_c++ INTERFACE library
add_compile_options("$<$<NOT:$<COMPILE_LANGUAGE:CXX>>:-nostdinc>")