From 8e1ece69f7ae5be326a206b43de65c9379b088f9 Mon Sep 17 00:00:00 2001 From: Sebastian Krzyszkowiak Date: Fri, 6 Jul 2018 14:29:14 +0200 Subject: [PATCH] mingw: link i686 binaries as large address aware so they can use more than 2GB RAM (up to 4GB) --- cmake/i686-w64-mingw32.toolchain | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cmake/i686-w64-mingw32.toolchain b/cmake/i686-w64-mingw32.toolchain index ed7956e..9bcca0a 100644 --- a/cmake/i686-w64-mingw32.toolchain +++ b/cmake/i686-w64-mingw32.toolchain @@ -11,6 +11,8 @@ set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY) set(MINGDIR /usr/i686-w64-mingw32) +set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--large-address-aware") + # Do a no-op access on the CMAKE_TOOLCHAIN_FILE variable so that CMake will not issue a warning on it being unused. if (CMAKE_TOOLCHAIN_FILE) endif()