Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-01-05 11:52:03 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-01-05 11:52:03 +0400
commitb5ce2b028a4f43c3e24caecfac337f85029ca575 (patch)
treee443f9d9b404bc2088025b5ba38a002f66b9e856
parent890c97ca40024ae32edbc3c5af6db0ee257a942d (diff)
link mingw libstdc++ and libgcc libs statically so users dont need mingw installed to use mingw builds
-rw-r--r--CMakeLists.txt5
-rw-r--r--build_files/scons/config/win32-mingw-config.py3
2 files changed, 7 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 01d81eb7f00..f584ad29f8c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1026,9 +1026,12 @@ elseif(WIN32)
set(OPENIMAGEIO_LIBPATH ${OPENIMAGEIO}/lib)
set(OPENIMAGEIO_DEFINITIONS)
endif()
-
+
set(PLATFORM_LINKFLAGS "-Xlinker --stack=2097152")
+ # for re-distrobution, so users dont need mingw installed
+ set(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -static-libgcc -static-libstdc++")
+
endif()
# used in many places so include globally, like OpenGL
diff --git a/build_files/scons/config/win32-mingw-config.py b/build_files/scons/config/win32-mingw-config.py
index e4f8827b7c8..8894432e417 100644
--- a/build_files/scons/config/win32-mingw-config.py
+++ b/build_files/scons/config/win32-mingw-config.py
@@ -190,6 +190,9 @@ LLIBS = ['-lshell32', '-lshfolder', '-lgdi32', '-lmsvcrt', '-lwinmm', '-lmingw32
PLATFORM_LINKFLAGS = ['-Xlinker', '--stack=2097152']
+# for re-distrobution, so users dont need mingw installed
+PLATFORM_LINKFLAGS += ["-static-libgcc", "-static-libstdc++"]
+
BF_DEBUG = False
BF_DEBUG_CCFLAGS= ['-g', '-D_DEBUG']