Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -91,10 +91,13 @@ endif()
if(MINGW)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -static-libgcc")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -static-libgcc -static-libstdc++")
# Link 32 bit SolveSpace with --large-address-aware which allows it to access
# up to 3GB on a properly configured 32 bit Windows and up to 4GB on 64 bit.
# See https://msdn.microsoft.com/en-us/library/aa366778
set(CMAKE_EXE_LINKER_FLAGS "-Wl,--large-address-aware")
if(CMAKE_SYSTEM_PROCESSOR STREQUAL "i686")
# Link 32 bit SolveSpace with --large-address-aware which allows it to access
# up to 3GB on a properly configured 32 bit Windows and up to 4GB on 64 bit.
# See https://msdn.microsoft.com/en-us/library/aa366778
# This option is unavailable for 64-bit executable linking.
set(CMAKE_EXE_LINKER_FLAGS "-Wl,--large-address-aware")
endif()
endif()

# Ensure that all platforms use 64-bit IEEE floating point operations for consistency;
Expand Down
1 change: 1 addition & 0 deletions cmake/Toolchain-mingw32.cmake
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
set(CMAKE_SYSTEM_NAME Windows)
set(CMAKE_SYSTEM_PROCESSOR i686)

set(TRIPLE i686-w64-mingw32)

Expand Down
Loading