Remove MinGW support
authorAaron Carlisle <carlisle.b3d@gmail.com>
Sat, 27 May 2017 19:34:55 +0000 (15:34 -0400)
committerAaron Carlisle <carlisle.b3d@gmail.com>
Sat, 27 May 2017 19:34:55 +0000 (15:34 -0400)
The Issue
=======

For a long time now MinGW has been unsupported and unmaintained and at this point,
it looks like something that we should just leave behind and move on.

Why Remove
==========

One of the big motivations for MinGW back in the day is that it was free compared to MSVC which was licensed based.
However, now that this is no longer true we have basically stopped updating the need CMake files.
Along with the CMake files, there are several patches to the extern libs needed to make this work.  For example, see:
https://developer.blender.org/diffusion/B/browse/master/extern/carve/patches/mingw_w64.patch

If we wanted to keep MinGW then we would need to make more custom patches to the external libs and
this is not something our platform maintainers are willing to do.

For example, here is the patches needed to build python: https://github.com/Alexpux/MINGW-packages/tree/master/mingw-w64-python3

Fixes T51301

Differential Revision: https://developer.blender.org/D2648

54 files changed:
build_files/buildbot/master_unpack.py
build_files/cmake/config/blender_full.cmake
build_files/cmake/config/blender_release.cmake
build_files/cmake/macros.cmake
build_files/cmake/platform/platform_win32.cmake
build_files/cmake/platform/platform_win32_mingw.cmake [deleted file]
build_files/cmake/platform/platform_win32_msvc.cmake
build_files/cmake/project_info.py
extern/carve/include/carve/win32.h
extern/carve/patches/mingw.patch [deleted file]
extern/carve/patches/mingw_w64.patch [deleted file]
extern/carve/patches/series
extern/carve/patches/win32.patch
intern/dualcon/intern/Projections.h
intern/dualcon/intern/dualcon_c_api.cpp
intern/elbeem/intern/mvmcoords.h
intern/ghost/intern/GHOST_Context.cpp
intern/ghost/intern/GHOST_DisplayManagerWin32.cpp
intern/ghost/intern/GHOST_SystemPathsWin32.cpp
intern/ghost/intern/GHOST_SystemWin32.cpp
intern/ghost/intern/GHOST_SystemWin32.h
intern/ghost/intern/GHOST_TaskbarWin32.h
intern/guardedalloc/intern/mallocn_intern.h
intern/opencolorio/CMakeLists.txt
source/blender/blenkernel/BKE_global.h
source/blender/blenkernel/intern/writeframeserver.c
source/blender/blenlib/BLI_alloca.h
source/blender/blenlib/BLI_compiler_compat.h
source/blender/blenlib/BLI_fileops.h
source/blender/blenlib/BLI_fileops_types.h
source/blender/blenlib/BLI_sys_types.h
source/blender/blenlib/BLI_winstuff.h
source/blender/blenlib/intern/fileops.c
source/blender/blenlib/intern/path_util.c
source/blender/blenlib/intern/storage.c
source/blender/blenlib/intern/winstuff.c
source/blender/collada/MeshImporter.cpp
source/blender/collada/SkinInfo.cpp
source/blender/editors/space_file/fsmenu.c
source/blender/imbuf/intern/IMB_anim.h
source/blender/imbuf/intern/anim_movie.c
source/blender/imbuf/intern/dds/dds_api.cpp
source/blender/imbuf/intern/oiio/openimageio_api.cpp
source/blender/imbuf/intern/openexr/openexr_api.cpp
source/blender/makesrna/intern/rna_object.c
source/blender/python/intern/bpy_app_handlers.c
source/blender/python/intern/bpy_rna.c
source/blenderplayer/CMakeLists.txt
source/creator/CMakeLists.txt
source/gameengine/Expressions/intern/HashedPtr.cpp
source/gameengine/Expressions/intern/InputParser.cpp
source/gameengine/Ketsji/KX_IPO_SGController.cpp
source/gameengine/Ketsji/KX_KetsjiEngine.cpp
source/gameengine/VideoTexture/ImageBase.cpp

index 67b628f668a24184bab73fab95eb55e03eec9b91..157e244e210135a7d69e8c9dc0b25065382f46b6 100644 (file)
@@ -49,7 +49,7 @@ def get_platform(filename):
     tokens = filename.split("-")
     platforms = ('osx', 'mac', 'bsd',
                  'win', 'linux', 'source',
-                 'irix', 'solaris', 'mingw')
+                 'irix', 'solaris')
     platform_tokens = []
     found = False
 
index ecde50ff156301cf72a63ee5d25334f0b4b368d1..62e2ce1636d466e45727d3c07138ca31ab043229 100644 (file)
@@ -63,17 +63,10 @@ if(UNIX AND NOT APPLE)
        set(WITH_OPENSUBDIV          ON  CACHE BOOL "" FORCE)
 elseif(WIN32)
        set(WITH_JACK                OFF CACHE BOOL "" FORCE)
-       if(NOT CMAKE_COMPILER_IS_GNUCC)
-               set(WITH_OPENSUBDIV          ON  CACHE BOOL "" FORCE)
-       else()
-               # MinGW exceptions
-               set(WITH_OPENSUBDIV          OFF CACHE BOOL "" FORCE)
-               set(WITH_CODEC_SNDFILE       OFF CACHE BOOL "" FORCE)
-               set(WITH_CYCLES_OSL          OFF CACHE BOOL "" FORCE)
-       endif()
+       set(WITH_OPENSUBDIV          ON  CACHE BOOL "" FORCE)
 elseif(APPLE)
        set(WITH_JACK                ON  CACHE BOOL "" FORCE)
-       set(WITH_CODEC_QUICKTIME     OFF  CACHE BOOL "" FORCE)
+       set(WITH_CODEC_QUICKTIME     OFF CACHE BOOL "" FORCE)
        set(WITH_OPENSUBDIV          OFF CACHE BOOL "" FORCE)
 
 #      include("${CMAKE_CURRENT_SOURCE_DIR}/../platform/platform_apple_xcode.cmake")
index f7239559fb8c50a02869808997d5a925bae42d76..3e2e26e6a4433c992e1c15061703e1cef6f38abe 100644 (file)
@@ -64,17 +64,10 @@ if(UNIX AND NOT APPLE)
        set(WITH_OPENSUBDIV          ON  CACHE BOOL "" FORCE)
 elseif(WIN32)
        set(WITH_JACK                OFF CACHE BOOL "" FORCE)
-       if(NOT CMAKE_COMPILER_IS_GNUCC)
-               set(WITH_OPENSUBDIV          ON  CACHE BOOL "" FORCE)
-       else()
-               # MinGW exceptions
-               set(WITH_OPENSUBDIV          OFF CACHE BOOL "" FORCE)
-               set(WITH_CODEC_SNDFILE       OFF CACHE BOOL "" FORCE)
-               set(WITH_CYCLES_OSL          OFF CACHE BOOL "" FORCE)
-       endif()
+       set(WITH_OPENSUBDIV          ON  CACHE BOOL "" FORCE)
 elseif(APPLE)
        set(WITH_JACK                ON  CACHE BOOL "" FORCE)
-       set(WITH_CODEC_QUICKTIME     OFF  CACHE BOOL "" FORCE)
+       set(WITH_CODEC_QUICKTIME     OFF CACHE BOOL "" FORCE)
        set(WITH_OPENSUBDIV          OFF CACHE BOOL "" FORCE)
 
 #      include("${CMAKE_CURRENT_SOURCE_DIR}/../platform/platform_apple_xcode.cmake")
index f62e55941a7a95c38b5a47af16804951af274112..6303119773d1a74bc6b52c5bad214005a17085fb 100644 (file)
@@ -1247,17 +1247,6 @@ endfunction()
 # hacks to override initial project settings
 # these macros must be called directly before/after project(Blender)
 macro(blender_project_hack_pre)
-       # ----------------
-       # MINGW HACK START
-       # ignore system set flag, use our own
-       # must be before project(...)
-       # if the user wants to add their own its ok after first run.
-       if(DEFINED CMAKE_C_STANDARD_LIBRARIES)
-               set(_reset_standard_libraries OFF)
-       else()
-               set(_reset_standard_libraries ON)
-       endif()
-
        # ------------------
        # GCC -O3 HACK START
        # needed because O3 can cause problems but
@@ -1276,25 +1265,6 @@ endmacro()
 
 
 macro(blender_project_hack_post)
-       # --------------
-       # MINGW HACK END
-       if(_reset_standard_libraries)
-               # Must come after projecINCt(...)
-               #
-               # MINGW workaround for -ladvapi32 being included which surprisingly causes
-               # string formatting of floats, eg: printf("%.*f", 3, value). to crash blender
-               # with a meaningless stack trace. by overriding this flag we ensure we only
-               # have libs we define.
-               set(CMAKE_C_STANDARD_LIBRARIES "" CACHE STRING "" FORCE)
-               set(CMAKE_CXX_STANDARD_LIBRARIES "" CACHE STRING "" FORCE)
-               mark_as_advanced(
-                       CMAKE_C_STANDARD_LIBRARIES
-                       CMAKE_CXX_STANDARD_LIBRARIES
-               )
-       endif()
-       unset(_reset_standard_libraries)
-
-
        # ----------------
        # GCC -O3 HACK END
        if(_reset_standard_cflags_rel)
index 631973b758b01332aeeb99235c3427d446b5a911..2f5d41dac32bcc529ae7fa7d0207c532ce0cdb56 100644 (file)
@@ -27,12 +27,10 @@ add_definitions(-DWIN32)
 
 if(MSVC)
        include(platform_win32_msvc)
-elseif(CMAKE_COMPILER_IS_GNUCC)
-       include(platform_win32_mingw)
+else()
+       message(FATAL_ERROR "Compiler is unsupported")
 endif()
 
-# Things common to both mingw and MSVC  should go here
-
 set(WINTAB_INC ${LIBDIR}/wintab/include)
 
 if(WITH_OPENAL)
diff --git a/build_files/cmake/platform/platform_win32_mingw.cmake b/build_files/cmake/platform/platform_win32_mingw.cmake
deleted file mode 100644 (file)
index 216568b..0000000
+++ /dev/null
@@ -1,302 +0,0 @@
-# ***** BEGIN GPL LICENSE BLOCK *****
-#
-# This program is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License
-# as published by the Free Software Foundation; either version 2
-# of the License, or (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software Foundation,
-# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-#
-# The Original Code is Copyright (C) 2016, Blender Foundation
-# All rights reserved.
-#
-# Contributor(s): Sergey Sharybin.
-#
-# ***** END GPL LICENSE BLOCK *****
-
-# Libraries configuration for Windows when compiling with MinGW.
-
-# keep GCC specific stuff here
-include(CheckCSourceCompiles)
-# Setup 64bit and 64bit windows systems
-CHECK_C_SOURCE_COMPILES("
-       #ifndef __MINGW64__
-       #error
-       #endif
-       int main(void) { return 0; }
-       "
-       WITH_MINGW64
-)
-
-if(NOT DEFINED LIBDIR)
-       if(WITH_MINGW64)
-               message(STATUS "Compiling for 64 bit with MinGW-w64.")
-               set(LIBDIR ${CMAKE_SOURCE_DIR}/../lib/mingw64)
-       else()
-               message(STATUS "Compiling for 32 bit with MinGW-w32.")
-               set(LIBDIR ${CMAKE_SOURCE_DIR}/../lib/mingw32)
-
-               if(WITH_RAYOPTIMIZATION)
-                       message(WARNING "MinGW-w32 is known to be unstable with 'WITH_RAYOPTIMIZATION' option enabled.")
-               endif()
-       endif()
-else()
-       message(STATUS "Using pre-compiled LIBDIR: ${LIBDIR}")
-endif()
-if(NOT EXISTS "${LIBDIR}/")
-       message(FATAL_ERROR "Windows requires pre-compiled libs at: '${LIBDIR}'")
-endif()
-
-list(APPEND PLATFORM_LINKLIBS
-       -lshell32 -lshfolder -lgdi32 -lmsvcrt -lwinmm -lmingw32 -lm -lws2_32
-       -lz -lstdc++ -lole32 -luuid -lwsock32 -lpsapi -ldbghelp
-)
-
-if(WITH_INPUT_IME)
-       list(APPEND PLATFORM_LINKLIBS -limm32)
-endif()
-
-set(PLATFORM_CFLAGS "-pipe -funsigned-char -fno-strict-aliasing")
-
-if(WITH_MINGW64)
-       set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fpermissive")
-       list(APPEND PLATFORM_LINKLIBS -lpthread)
-
-       add_definitions(-DFREE_WINDOWS64 -DMS_WIN64)
-endif()
-
-add_definitions(-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE)
-
-add_definitions(-DFREE_WINDOWS)
-
-set(PNG "${LIBDIR}/png")
-set(PNG_INCLUDE_DIRS "${PNG}/include")
-set(PNG_LIBPATH ${PNG}/lib) # not cmake defined
-
-if(WITH_MINGW64)
-       set(JPEG_LIBRARIES jpeg)
-else()
-       set(JPEG_LIBRARIES libjpeg)
-endif()
-set(PNG_LIBRARIES png)
-
-set(ZLIB ${LIBDIR}/zlib)
-set(ZLIB_INCLUDE_DIRS ${ZLIB}/include)
-set(ZLIB_LIBPATH ${ZLIB}/lib)
-set(ZLIB_LIBRARIES z)
-
-set(JPEG "${LIBDIR}/jpeg")
-set(JPEG_INCLUDE_DIR "${JPEG}/include")
-set(JPEG_LIBPATH ${JPEG}/lib) # not cmake defined
-
-# comes with own pthread library
-if(NOT WITH_MINGW64)
-       set(PTHREADS ${LIBDIR}/pthreads)
-       #set(PTHREADS_INCLUDE_DIRS ${PTHREADS}/include)
-       set(PTHREADS_LIBPATH ${PTHREADS}/lib)
-       set(PTHREADS_LIBRARIES pthreadGC2)
-endif()
-
-set(FREETYPE ${LIBDIR}/freetype)
-set(FREETYPE_INCLUDE_DIRS ${FREETYPE}/include ${FREETYPE}/include/freetype2)
-set(FREETYPE_LIBPATH ${FREETYPE}/lib)
-set(FREETYPE_LIBRARY freetype)
-
-if(WITH_FFTW3)
-       set(FFTW3 ${LIBDIR}/fftw3)
-       set(FFTW3_LIBRARIES fftw3)
-       set(FFTW3_INCLUDE_DIRS ${FFTW3}/include)
-       set(FFTW3_LIBPATH ${FFTW3}/lib)
-endif()
-
-if(WITH_OPENCOLLADA)
-       set(OPENCOLLADA ${LIBDIR}/opencollada)
-       set(OPENCOLLADA_INCLUDE_DIRS
-               ${OPENCOLLADA}/include/opencollada/COLLADAStreamWriter
-               ${OPENCOLLADA}/include/opencollada/COLLADABaseUtils
-               ${OPENCOLLADA}/include/opencollada/COLLADAFramework
-               ${OPENCOLLADA}/include/opencollada/COLLADASaxFrameworkLoader
-               ${OPENCOLLADA}/include/opencollada/GeneratedSaxParser
-       )
-       set(OPENCOLLADA_LIBPATH ${OPENCOLLADA}/lib/opencollada)
-       set(OPENCOLLADA_LIBRARIES
-               OpenCOLLADAStreamWriter
-               OpenCOLLADASaxFrameworkLoader
-               OpenCOLLADAFramework
-               OpenCOLLADABaseUtils
-               GeneratedSaxParser
-               UTF MathMLSolver buffer ftoa xml
-       )
-       set(PCRE_LIBRARIES pcre)
-endif()
-
-if(WITH_CODEC_FFMPEG)
-       set(FFMPEG ${LIBDIR}/ffmpeg)
-       set(FFMPEG_INCLUDE_DIRS ${FFMPEG}/include)
-       if(WITH_MINGW64)
-               set(FFMPEG_LIBRARIES avcodec.dll avformat.dll avdevice.dll avutil.dll swscale.dll swresample.dll)
-       else()
-               set(FFMPEG_LIBRARIES avcodec-55 avformat-55 avdevice-55 avutil-52 swscale-2)
-       endif()
-       set(FFMPEG_LIBPATH ${FFMPEG}/lib)
-endif()
-
-if(WITH_IMAGE_OPENEXR)
-       set(OPENEXR ${LIBDIR}/openexr)
-       set(OPENEXR_INCLUDE_DIR ${OPENEXR}/include)
-       set(OPENEXR_INCLUDE_DIRS ${OPENEXR}/include/OpenEXR)
-       set(OPENEXR_LIBRARIES Half IlmImf Imath IlmThread Iex)
-       set(OPENEXR_LIBPATH ${OPENEXR}/lib)
-endif()
-
-if(WITH_IMAGE_TIFF)
-       set(TIFF ${LIBDIR}/tiff)
-       set(TIFF_LIBRARY tiff)
-       set(TIFF_INCLUDE_DIR ${TIFF}/include)
-       set(TIFF_LIBPATH ${TIFF}/lib)
-endif()
-
-if(WITH_JACK)
-       set(JACK ${LIBDIR}/jack)
-       set(JACK_INCLUDE_DIRS ${JACK}/include/jack ${JACK}/include)
-       set(JACK_LIBRARIES jack)
-       set(JACK_LIBPATH ${JACK}/lib)
-
-       # TODO, gives linking errors, force off
-       set(WITH_JACK OFF)
-endif()
-
-if(WITH_PYTHON)
-       # normally cached but not since we include them with blender
-       set(PYTHON_VERSION 3.5) #  CACHE STRING)
-       string(REPLACE "." "" _PYTHON_VERSION_NO_DOTS ${PYTHON_VERSION})
-       set(PYTHON_INCLUDE_DIR "${LIBDIR}/python/include/python${PYTHON_VERSION}")  # CACHE PATH)
-       set(PYTHON_LIBRARY "${LIBDIR}/python/lib/python${_PYTHON_VERSION_NO_DOTS}mw.lib")  # CACHE FILEPATH)
-       unset(_PYTHON_VERSION_NO_DOTS)
-
-       # uncached vars
-       set(PYTHON_INCLUDE_DIRS "${PYTHON_INCLUDE_DIR}")
-       set(PYTHON_LIBRARIES  "${PYTHON_LIBRARY}")
-endif()
-
-if(WITH_BOOST)
-       set(BOOST ${LIBDIR}/boost)
-       set(BOOST_INCLUDE_DIR ${BOOST}/include)
-       if(WITH_MINGW64)
-               set(BOOST_POSTFIX "mgw47-mt-s-1_49")
-               set(BOOST_DEBUG_POSTFIX "mgw47-mt-sd-1_49")
-       else()
-               set(BOOST_POSTFIX "mgw46-mt-s-1_49")
-               set(BOOST_DEBUG_POSTFIX "mgw46-mt-sd-1_49")
-       endif()
-       set(BOOST_LIBRARIES
-               optimized boost_date_time-${BOOST_POSTFIX} boost_filesystem-${BOOST_POSTFIX}
-               boost_regex-${BOOST_POSTFIX}
-               boost_system-${BOOST_POSTFIX} boost_thread-${BOOST_POSTFIX}
-               debug boost_date_time-${BOOST_DEBUG_POSTFIX} boost_filesystem-${BOOST_DEBUG_POSTFIX}
-               boost_regex-${BOOST_DEBUG_POSTFIX}
-               boost_system-${BOOST_DEBUG_POSTFIX} boost_thread-${BOOST_DEBUG_POSTFIX})
-       if(WITH_INTERNATIONAL)
-               set(BOOST_LIBRARIES ${BOOST_LIBRARIES}
-                       optimized boost_locale-${BOOST_POSTFIX}
-                       debug boost_locale-${BOOST_DEBUG_POSTFIX}
-               )
-       endif()
-       if(WITH_CYCLES_OSL)
-               set(BOOST_LIBRARIES ${BOOST_LIBRARIES}
-                       optimized boost_wave-${BOOST_POSTFIX}
-                       debug boost_wave-${BOOST_DEBUG_POSTFIX}
-               )
-       endif()
-       set(BOOST_LIBPATH ${BOOST}/lib)
-       set(BOOST_DEFINITIONS "-DBOOST_ALL_NO_LIB -DBOOST_THREAD_USE_LIB ")
-endif()
-
-if(WITH_OPENIMAGEIO)
-       set(OPENIMAGEIO ${LIBDIR}/openimageio)
-       set(OPENIMAGEIO_INCLUDE_DIRS ${OPENIMAGEIO}/include)
-       set(OPENIMAGEIO_LIBRARIES OpenImageIO)
-       set(OPENIMAGEIO_LIBPATH ${OPENIMAGEIO}/lib)
-       set(OPENIMAGEIO_DEFINITIONS "")
-       set(OPENIMAGEIO_IDIFF "${OPENIMAGEIO}/bin/idiff.exe")
-endif()
-
-if(WITH_LLVM)
-       set(LLVM_ROOT_DIR ${LIBDIR}/llvm CACHE PATH     "Path to the LLVM installation")
-       set(LLVM_LIBPATH ${LLVM_ROOT_DIR}/lib)
-       # Explicitly set llvm lib order.
-       #---- WARNING ON GCC ORDER OF LIBS IS IMPORTANT, DO NOT CHANGE! ---------
-       set(LLVM_LIBRARY LLVMSelectionDAG LLVMCodeGen LLVMScalarOpts LLVMAnalysis LLVMArchive
-               LLVMAsmParser LLVMAsmPrinter
-               LLVMBitReader LLVMBitWriter
-               LLVMDebugInfo LLVMExecutionEngine
-               LLVMInstCombine LLVMInstrumentation
-               LLVMInterpreter LLVMJIT
-               LLVMLinker LLVMMC
-               LLVMMCDisassembler LLVMMCJIT
-               LLVMMCParser LLVMObject
-               LLVMRuntimeDyld
-               LLVMSupport
-               LLVMTableGen LLVMTarget
-               LLVMTransformUtils LLVMVectorize
-               LLVMX86AsmParser LLVMX86AsmPrinter
-               LLVMX86CodeGen LLVMX86Desc
-               LLVMX86Disassembler LLVMX86Info
-               LLVMX86Utils LLVMipa
-               LLVMipo LLVMCore)
-       # imagehelp is needed by LLVM 3.1 on MinGW, check lib\Support\Windows\Signals.inc
-       list(APPEND PLATFORM_LINKLIBS -limagehlp)
-endif()
-
-if(WITH_OPENCOLORIO)
-       set(OPENCOLORIO ${LIBDIR}/opencolorio)
-       set(OPENCOLORIO_INCLUDE_DIRS ${OPENCOLORIO}/include)
-       set(OPENCOLORIO_LIBRARIES OpenColorIO)
-       set(OPENCOLORIO_LIBPATH ${OPENCOLORIO}/lib)
-       set(OPENCOLORIO_DEFINITIONS)
-endif()
-
-if(WITH_SDL)
-       set(SDL ${LIBDIR}/sdl)
-       set(SDL_INCLUDE_DIR ${SDL}/include)
-       set(SDL_LIBRARY SDL)
-       set(SDL_LIBPATH ${SDL}/lib)
-endif()
-
-if(WITH_OPENVDB)
-       set(OPENVDB ${LIBDIR}/openvdb)
-       set(OPENVDB_INCLUDE_DIRS ${OPENVDB}/include)
-       set(OPENVDB_LIBRARIES openvdb ${TBB_LIBRARIES})
-       set(OPENVDB_LIBPATH ${LIBDIR}/openvdb/lib)
-       set(OPENVDB_DEFINITIONS)
-endif()
-
-if(WITH_ALEMBIC)
-       # TODO(sergey): For until someone drops by and compiles libraries for
-       # MinGW we allow users to compile their own Alembic library and use
-       # that via find_package(),
-       #
-       # Once precompiled libraries are there we'll use hardcoded locations.
-       find_package_wrapper(Alembic)
-       if(WITH_ALEMBIC_HDF5)
-               set(HDF5_ROOT_DIR ${LIBDIR}/hdf5)
-               find_package_wrapper(HDF5)
-       endif()
-       if(NOT ALEMBIC_FOUND OR (WITH_ALEMBIC_HDF5 AND NOT HDF5_FOUND))
-               set(WITH_ALEMBIC OFF)
-               set(WITH_ALEMBIC_HDF5 OFF)
-       endif()
-endif()
-
-set(PLATFORM_LINKFLAGS "-Xlinker --stack=2097152")
-
-## DISABLE - causes linking errors
-## for re-distribution, so users dont need mingw installed
-# set(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -static-libgcc -static-libstdc++")
index 6447559f62cfd861ac91f838876b5153134f28b7..2055b164f6d97f698c2c17f2771b813f410c8956 100644 (file)
@@ -116,7 +116,6 @@ set(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} /NODEFAULTLIB:msvcrt.lib /NODEFAUL
 set(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} /ignore:4049 /ignore:4217 /ignore:4221")
 set(CMAKE_STATIC_LINKER_FLAGS "${CMAKE_STATIC_LINKER_FLAGS} /ignore:4221")
 
-# MSVC only, Mingw doesnt need
 if(CMAKE_CL_64)
        set(PLATFORM_LINKFLAGS "/MACHINE:X64 ${PLATFORM_LINKFLAGS}")
 else()
@@ -473,12 +472,7 @@ if(WITH_SDL)
        set(SDL ${LIBDIR}/sdl)
        set(SDL_INCLUDE_DIR ${SDL}/include)
        set(SDL_LIBPATH ${SDL}/lib)
-       # MinGW TODO: Update MinGW to SDL2
-       if(NOT CMAKE_COMPILER_IS_GNUCC)
-               set(SDL_LIBRARY SDL2)
-       else()
-               set(SDL_LIBRARY SDL)
-       endif()
+       set(SDL_LIBRARY SDL2)
 endif()
 
 # Audio IO
index deea844034cd9eb5fe6b89897733b367d411ff65..3ac4c4c9480f041f53280d3f599847ab6e743417 100755 (executable)
@@ -145,7 +145,7 @@ def cmake_advanced_info():
     def create_eclipse_project():
         print("CMAKE_DIR %r" % CMAKE_DIR)
         if sys.platform == "win32":
-            cmd = 'cmake "%s" -G"Eclipse CDT4 - MinGW Makefiles"' % CMAKE_DIR
+            raise Exception("Error: win32 is not supported")
         else:
             if make_exe_basename.startswith(("make", "gmake")):
                 cmd = 'cmake "%s" -G"Eclipse CDT4 - Unix Makefiles"' % CMAKE_DIR
index 81b2ea4d6facd2e90190e636284894fed1cff0e6..78a101e6f980844b65e02c0dafa4157d5b3c72c8 100755 (executable)
@@ -8,11 +8,9 @@
 #include <string.h>
 #include <stdlib.h>
 
-#if !defined(__MINGW32__)
 inline int strcasecmp(const char *a, const char *b) {
   return _stricmp(a,b);
 }
-#endif
 
 inline void srandom(unsigned long input) {
   srand(input);
@@ -34,7 +32,7 @@ typedef unsigned long uintptr_t;
 
 #  if _MSC_VER < 1600
 // stdint.h is not available before VS2010
-#if defined(_WIN32) && !defined(__MINGW32__)
+#if defined(_WIN32)
 /* The __intXX are built-in types of the visual complier! So we don't
    need to include anything else here.
    This typedefs should be in sync with types from MEM_sys_types.h */
diff --git a/extern/carve/patches/mingw.patch b/extern/carve/patches/mingw.patch
deleted file mode 100644 (file)
index c237edf..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-diff -r 525472fb477a include/carve/win32.h
---- a/include/carve/win32.h    Sun Jan 15 23:07:40 2012 -0500
-+++ b/include/carve/win32.h    Wed Jan 18 00:40:10 2012 +0600
-@@ -8,9 +8,11 @@
- #include <string.h>
- #include <stdlib.h>
-+#if !defined(__MINGW32__)
- inline int strcasecmp(const char *a, const char *b) {
-   return _stricmp(a,b);
- }
-+#endif
- inline void srandom(unsigned long input) {
-   srand(input);
diff --git a/extern/carve/patches/mingw_w64.patch b/extern/carve/patches/mingw_w64.patch
deleted file mode 100644 (file)
index 26a30be..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-Index: bundle.sh
-===================================================================
---- bundle.sh  (revision 45912)
-+++ bundle.sh  (working copy)
-@@ -114,7 +114,7 @@
- if env['WITH_BF_BOOST']:
-     if env['OURPLATFORM'] not in ('win32-vc', 'win64-vc'):
-         # Boost is setting as preferred collections library in the Carve code when using MSVC compiler
--        if env['OURPLATFORM'] != 'win32-mingw':
-+        if env['OURPLATFORM'] not in ('win32-mingw', 'win64-mingw'):
-             defs.append('HAVE_BOOST_UNORDERED_COLLECTIONS')
-     defs.append('CARVE_SYSTEM_BOOST')
index b7e97d68c4c340092b775c088da428f321f2f799..c5c5fd766b8a846addc97f1884bdcc1a660ac6ff 100644 (file)
@@ -1,7 +1,6 @@
 includes.patch
 win32.patch
 mesh_iterator.patch
-mingw.patch
 gcc46.patch
 clang_is_heap_fix.patch
 strict_flags.patch
index 680bceb2421e9e290b6f0687f5fd8203d9e102bf..1a5f96505320026d493786d44c0157d98699a822 100644 (file)
@@ -8,7 +8,7 @@ diff -r e82d852e4fb0 include/carve/win32.h
 -typedef char int8_t;
 -typedef short int16_t;
 -typedef long int32_t;
-+#if defined(_WIN32) && !defined(__MINGW32__)
++#if defined(_WIN32)
 +/* The __intXX are built-in types of the visual complier! So we don't
 +   need to include anything else here.
 +   This typedefs should be in sync with types from MEM_sys_types.h */
index 2d1eca55997c1b4758cf9078cb407c483e0715e6..2d245a77d15cfbde0bdd14d549dd953bf8ffd898 100644 (file)
@@ -29,7 +29,7 @@
 #define CONTAINS_INDEX
 #define GRID_DIMENSION 20
 
-#if defined(_WIN32) && !defined(__MINGW32__) && !(_MSC_VER >= 1900)
+#if defined(_WIN32) && !(_MSC_VER >= 1900)
 #define isnan(n) _isnan(n)
 #define LONG __int64
 #define int64_t __int64
index e55de2ed354960a0e820e74ec31c107143725465..92f8b0cfd1a002e03ed6813b305f6d5eba57a8c9 100644 (file)
@@ -28,7 +28,7 @@
 #include <cstdio>
 #include <float.h>
 
-#if defined(_WIN32) && !defined(__MINGW32__)
+#if defined(_WIN32)
 #define isnan(n) _isnan(n)
 #endif
 
index 56d991aac6e161c1cef410930077339cc7a14450..deeedcf9dd431259fafc48fd148a5dea9ad18a2f 100644 (file)
 #define mvmFloat double
 
 #ifdef WIN32
-#ifndef FREE_WINDOWS
 #include "float.h"
 #define isnan(n) _isnan(n)
 #define finite _finite
 #endif
-#endif
 
 #ifdef sun
 #include "ieeefp.h"
index f69f2181ef72f136e0dea960e106719b1da850c4..72db17c4f56599107e548f01532fa2afa45271fd 100644 (file)
@@ -38,7 +38,7 @@
 #  include <tchar.h>
 #
 #  ifndef ERROR_PROFILE_DOES_NOT_MATCH_DEVICE
-#    define ERROR_PROFILE_DOES_NOT_MATCH_DEVICE 0x7E7 // Mingw64 headers may have had this
+#    define ERROR_PROFILE_DOES_NOT_MATCH_DEVICE 0x7E7
 #  endif
 #endif
 
index 252ea7753293a025ce62e934ff0ab154a0561dcd..7b9a897fe57bfa30b0b406b551d9fc9f8524d2e1 100644 (file)
@@ -41,9 +41,7 @@
 
 // We do not support multiple monitors at the moment
 #define COMPILE_MULTIMON_STUBS
-#ifndef FREE_WINDOWS
 #include <multimon.h>
-#endif
 
 
 GHOST_DisplayManagerWin32::GHOST_DisplayManagerWin32(void)
index 7d0ce5158fe6949343659df3246e8a0ec48e5b26..8056bc76edb334c29e2b0421c0e3cd5794a1fe78 100644 (file)
 #include <shlobj.h>
 #include "utfconv.h"
 
-#ifdef __MINGW32__
-
-#if !defined(SHARD_PIDL)
-#define SHARD_PIDL      0x00000001L
-#endif
-
-#if !defined(SHARD_PATHA)
-#define SHARD_PATHA     0x00000002L
-#endif
-
-#if !defined(SHARD_PATHW)
-#define SHARD_PATHW     0x00000003L
-#endif
-
-#if !defined(SHARD_PATH)
-#ifdef UNICODE
-#define SHARD_PATH  SHARD_PATHW
-#else
-#define SHARD_PATH  SHARD_PATHA
-#endif
-#endif
-
-#endif
-
 GHOST_SystemPathsWin32::GHOST_SystemPathsWin32()
 {
 }
index 240d7ccd2fe63187b280e44647687eae72d97611..ca7118de7b0bc48365dbf0ceead73e9637868001 100644 (file)
@@ -890,25 +890,15 @@ bool GHOST_SystemWin32::processNDOF(RAWINPUT const &raw)
        // send motion. Mark as 'sent' so motion will always get dispatched.
        eventSent = true;
 
-#if defined(_MSC_VER) || defined(FREE_WINDOWS64)
+#if defined(_MSC_VER)
        // using Microsoft compiler & header files
        // they invented the RawInput API, so this version is (probably) correct.
-       // MinGW64 also works fine with this
        BYTE const *data = raw.data.hid.bRawData;
        // struct RAWHID {
        // DWORD dwSizeHid;
        // DWORD dwCount;
        // BYTE  bRawData[1];
        // };
-#else
-       // MinGW's definition (below) doesn't agree, so we need a slight
-       // workaround until it's fixed
-       BYTE const *data = &raw.data.hid.bRawData;
-       // struct RAWHID {
-       // DWORD dwSizeHid;
-       // DWORD dwCount;
-       // BYTE bRawData; // <== isn't this s'posed to be a BYTE*?
-       // };
 #endif
 
        BYTE packetType = data[0];
index d534a300b35c195930410102a4f71263c3c3c566..099d14e68aeef25d8f7e9e76cfb5296dfcedfd78 100644 (file)
 #error WIN32 only!
 #endif // WIN32
 
-#ifndef __MINGW64__
-#  undef _WIN32_WINNT
-#  define _WIN32_WINNT 0x501 // require Windows XP or newer
-#endif
+/* require Windows XP or newer */
+#undef _WIN32_WINNT
+#define _WIN32_WINNT 0x501
+
 #define WIN32_LEAN_AND_MEAN
 #include <windows.h>
 #include <ole2.h> // for drag-n-drop
index 6fcff2972375fd750d753061368353e019046c88..0ef71754717e4853016ff1814a225ff5ca2e0bdd 100644 (file)
@@ -8,10 +8,10 @@
 #error WIN32 only!
 #endif // WIN32
 
-#ifndef __MINGW64__
-#  undef _WIN32_WINNT
-#  define _WIN32_WINNT 0x501 // require Windows XP or newer
-#endif
+/* require Windows XP or newer */
+#undef _WIN32_WINNT
+#define _WIN32_WINNT 0x501
+
 #define WIN32_LEAN_AND_MEAN
 #include <windows.h>
 #include <shlobj.h>
index 3f7e462c1c7f41a0a13d60cfee0056d11a16a087..a292a2eb5a05427ed0df6b937d75e01a129a0b88 100644 (file)
 
 #if !defined(__APPLE__) && !defined(__FreeBSD__) && !defined(__NetBSD__)
 // Needed for memalign on Linux and _aligned_alloc on Windows.
-#  ifdef FREE_WINDOWS
-/* make sure _aligned_malloc is included */
-#    ifdef __MSVCRT_VERSION__
-#      undef __MSVCRT_VERSION__
-#    endif
-
-#    define __MSVCRT_VERSION__ 0x0700
-#  endif  // FREE_WINDOWS
 
 #  include <malloc.h>
 #else
index 61a8d995f4078e402d2f7f44466a93feac8d2d64..75e228933aa9dfda515210c174992f2da634b445 100644 (file)
@@ -59,7 +59,7 @@ if(WITH_OPENCOLORIO)
                ocio_impl_glsl.cc
        )
 
-       if(WIN32 AND NOT MINGW)
+       if(WIN32)
                list(APPEND INC_SYS
                        ${BOOST_INCLUDE_DIR}
                )
index 4bb2b950901ab7c3d69996ffa6c5d592a5c858e9..830518906ab78f6723677c9d1fdd5218e1511b7a 100644 (file)
@@ -189,11 +189,6 @@ enum {
 #  error Either __BIG_ENDIAN__ or __LITTLE_ENDIAN__ must be defined.
 #endif
 
-/* there is really no good place for this */
-#if defined(FREE_WINDOWS) && ((__GNUC__ < 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ < 6)))
-#  error "Mingw requires GCC 4.6 minimum"
-#endif
-
 #define L_ENDIAN    1
 #define B_ENDIAN    0
 
index 212af76a7e856958850fc5d020c844f0cd7f67b5..4757186f546bdb8055275a7f61947e737e52d49a 100644 (file)
@@ -268,11 +268,7 @@ int BKE_frameserver_loop(void *context_v, RenderData *rd, ReportList *UNUSED(rep
        struct timeval tv;
        struct sockaddr_in addr;
        int len, rval;
-#ifdef FREE_WINDOWS
-       int socklen;
-#else
        unsigned int socklen;
-#endif
        char buf[4096];
 
        FrameserverContext *context = context_v;
index b44e6c66d2a77148921afaea21955a87a3fbf594..4fa69a24966623da5d5c296f5a9e2dbb24a78f27 100644 (file)
 
 /* BLI_array_alloca / alloca */
 
-#if defined(__MINGW32__)
-#  include <malloc.h>  /* mingw needs for alloca() */
-#endif
-
 #if defined(__GNUC__) || defined(__clang__)
 #if defined(__cplusplus) && (__cplusplus > 199711L)
 #define BLI_array_alloca(arr, realsize) \
index 8edbc25bcbce2721382c051d8fa4a25a54bbbe82..01fc9d702073cb90e77eb07846161a8a6d01ccdf 100644 (file)
 #  define alloca _alloca
 #endif
 
-/* alloca is defined here for MinGW32 */
-#ifdef __MINGW32__
-#  include <malloc.h>
-#endif
-
 #if defined(__cplusplus) && ((__cplusplus >= 201103L) || defined(_MSC_VER))
 #  define HAS_CPP11_FEATURES
 #endif
index 91d139c7085876ad16c3db66b624ff4a67b10eeb..5c1fa57886a2a326f520a791b2c566f14319f470 100644 (file)
@@ -65,10 +65,8 @@ int    BLI_create_symlink(const char *path, const char *to) ATTR_NONNULL();
 
 /* keep in sync with the definition of struct direntry in BLI_fileops_types.h */
 #ifdef WIN32
-#  if defined(_MSC_VER) || defined(__MINGW64__)
+#  if defined(_MSC_VER)
 typedef struct _stat64 BLI_stat_t;
-#  elif defined(__MINGW32__)
-typedef struct _stati64 BLI_stat_t;
 #  else
 typedef struct _stat BLI_stat_t;
 #  endif
index 0cf8c8ddb4a3af11138f4be0cde4e044e0c608f4..0ffa3276f1ffb2309150537fd0604d938659ec4b 100644 (file)
@@ -35,7 +35,7 @@
 
 #include <sys/stat.h>
 
-#if defined(WIN32) && !defined(FREE_WINDOWS)
+#if defined(WIN32)
 typedef unsigned int mode_t;
 #endif
 
@@ -50,10 +50,8 @@ struct direntry {
        const char   *relname;
        const char   *path;
 #ifdef WIN32 /* keep in sync with the definition of BLI_stat_t in BLI_fileops.h */
-#  if defined(_MSC_VER) || defined(__MINGW64__)
+#  if defined(_MSC_VER)
        struct _stat64 s;
-#  elif defined(__MINGW32__)
-       struct _stati64 s;
 #  else
        struct _stat s;
 #  endif
index 9d8222c575da7955fae9322a8590a1bc81bb5f95..9477f61713cafdbbfac79af293903377c58cc950 100644 (file)
@@ -65,8 +65,8 @@ typedef uint64_t u_int64_t;
 
 #include <inttypes.h>
 
-/* MinGW and MSVC >= 2010 */
-#elif defined(FREE_WINDOWS) || defined(_MSC_VER)
+/* MSVC >= 2010 */
+#elif defined(_MSC_VER)
 #include <stdint.h>
 
 #else
index b421b7dbb90f89ae65063c5cde9a088e882f49dd..6fbbed01400afedba9baed139ae9c8a91d607b64 100644 (file)
 #  error "This include is for Windows only!"
 #endif
 
-#ifdef FREE_WINDOWS
-#  ifdef WINVER
-#    undef WINVER
-#  endif
-
-/* Some stuff requires WINVER 0x500, but mingw's default is 0x400 */
-#  define WINVER 0x0501
-#endif
-
 #define WIN32_LEAN_AND_MEAN
 
 #ifndef WIN32_SKIP_HKEY_PROTECTION
@@ -94,7 +85,7 @@ extern "C" {
 #  define snprintf _snprintf
 #endif
 
-#if defined(_MSC_VER) || (defined(FREE_WINDOWS) && !defined(FREE_WINDOWS64))
+#if defined(_MSC_VER)
 #  define      R_OK    4
 #  define      W_OK    2
 // not accepted by access() on windows
@@ -102,28 +93,22 @@ extern "C" {
 #  define      F_OK    0
 #endif
 
-#ifndef FREE_WINDOWS
 typedef unsigned int mode_t;
-#endif
 
 /* use functions that take a 64 bit offset for files larger than 4GB */
-#ifndef FREE_WINDOWS
-#  include <stdio.h>
-#  define fseek(stream, offset, origin) _fseeki64(stream, offset, origin)
-#  define ftell(stream) _ftelli64(stream)
-#  define lseek(fd, offset, origin) _lseeki64(fd, offset, origin)
-#  define tell(fd) _telli64(fd)
-#endif
+#include <stdio.h>
+#define fseek(stream, offset, origin) _fseeki64(stream, offset, origin)
+#define ftell(stream) _ftelli64(stream)
+#define lseek(fd, offset, origin) _lseeki64(fd, offset, origin)
+#define tell(fd) _telli64(fd)
+
 
-/* mingw using _SSIZE_T_ to declare ssize_t type */
 #ifndef _SSIZE_T_
 #  define _SSIZE_T_
 /* python uses HAVE_SSIZE_T */
 #  ifndef HAVE_SSIZE_T
 #    define HAVE_SSIZE_T 1
-#    ifndef FREE_WINDOWS64
 typedef long ssize_t;
-#    endif
 #  endif
 #endif
 
index db4b3bcf20ce91bf9e4bdbace65f0e6f79807fe4..1df7f6f81e4c28b6bbdf26e42a38f3d662960efa 100644 (file)
@@ -42,9 +42,6 @@
 #include "zlib.h"
 
 #ifdef WIN32
-#  ifdef __MINGW32__
-#    include <ctype.h>
-#  endif
 #  include <io.h>
 #  include "BLI_winstuff.h"
 #  include "BLI_callbacks.h"
@@ -265,7 +262,7 @@ void *BLI_gzopen(const char *filename, const char *mode)
 
        /* temporary #if until we update all libraries to 1.2.7
         * for correct wide char path handling */
-#if ZLIB_VERNUM >= 0x1270 && !defined(FREE_WINDOWS)
+#if ZLIB_VERNUM >= 0x1270
        UTF16_ENCODE(filename);
 
        gzfile = gzopen_w(filename_16, mode);
index 40b6aaa18c1fc9fdb692cc595052e0eac4a2feb9..4b3a74d02aefaa7c3b5c4a31a8d8f4543946bceb 100644 (file)
@@ -1173,22 +1173,10 @@ bool BLI_path_program_search(
 void BLI_setenv(const char *env, const char *val)
 {
        /* free windows */
-#if (defined(WIN32) || defined(WIN64)) && defined(FREE_WINDOWS)
-       char *envstr;
 
-       if (val)
-               envstr = BLI_sprintfN("%s=%s", env, val);
-       else
-               envstr = BLI_sprintfN("%s=", env);
-
-       putenv(envstr);
-       MEM_freeN(envstr);
-
-       /* non-free windows */
-#elif (defined(WIN32) || defined(WIN64)) /* not free windows */
+#if (defined(WIN32) || defined(WIN64))
        uputenv(env, val);
 
-
 #else
        /* linux/osx/bsd */
        if (val)
index 3edc00a8c1a4fc09e9f880ef7192f9c6edb20b81..48280c14d7d9239692b1d1904eca616a47ea117e 100644 (file)
@@ -113,7 +113,7 @@ double BLI_dir_free_space(const char *dir)
 #ifdef WIN32
        DWORD sectorspc, bytesps, freec, clusters;
        char tmp[4];
-       
+
        tmp[0] = '\\'; tmp[1] = 0; /* Just a failsafe */
        if (dir[0] == '/' || dir[0] == '\\') {
                tmp[0] = '\\';
@@ -139,10 +139,10 @@ double BLI_dir_free_space(const char *dir)
 
        char name[FILE_MAXDIR], *slash;
        int len = strlen(dir);
-       
+
        if (len >= FILE_MAXDIR) /* path too long */
                return -1;
-       
+
        strcpy(name, dir);
 
        if (len) {
@@ -194,7 +194,7 @@ size_t BLI_file_size(const char *path)
  */
 int BLI_exists(const char *name)
 {
-#if defined(WIN32) 
+#if defined(WIN32)
        BLI_stat_t st;
        wchar_t *tmp_16 = alloc_utf16_from_8(name, 1);
        int len, res;
@@ -253,10 +253,8 @@ int BLI_stat(const char *path, BLI_stat_t *buffer)
 
 int BLI_wstat(const wchar_t *path, BLI_stat_t *buffer)
 {
-#if defined(_MSC_VER) || defined(__MINGW64__)
+#if defined(_MSC_VER)
        return _wstat64(path, buffer);
-#elif defined(__MINGW32__)
-       return _wstati64(path, buffer);
 #else
        return _wstat(path, buffer);
 #endif
@@ -372,7 +370,7 @@ LinkNode *BLI_file_read_as_lines(const char *name)
        size_t size;
 
        if (!fp) return NULL;
-               
+
        fseek(fp, 0, SEEK_END);
        size = (size_t)ftell(fp);
        fseek(fp, 0, SEEK_SET);
@@ -385,7 +383,7 @@ LinkNode *BLI_file_read_as_lines(const char *name)
        buf = MEM_mallocN(size, "file_as_lines");
        if (buf) {
                size_t i, last = 0;
-               
+
                /*
                 * size = because on win32 reading
                 * all the bytes in the file will return
@@ -403,10 +401,10 @@ LinkNode *BLI_file_read_as_lines(const char *name)
                                last = i + 1;
                        }
                }
-               
+
                MEM_freeN(buf);
        }
-       
+
        fclose(fp);
 
        return lines.list;
@@ -424,23 +422,13 @@ void BLI_file_free_lines(LinkNode *lines)
 bool BLI_file_older(const char *file1, const char *file2)
 {
 #ifdef WIN32
-#ifndef __MINGW32__
-       struct _stat st1, st2;
-#else
-       struct _stati64 st1, st2;
-#endif
+  struct _stat st1, st2;
 
        UTF16_ENCODE(file1);
        UTF16_ENCODE(file2);
-       
-#ifndef __MINGW32__
-       if (_wstat(file1_16, &st1)) return false;
-       if (_wstat(file2_16, &st2)) return false;
-#else
-       if (_wstati64(file1_16, &st1)) return false;
-       if (_wstati64(file2_16, &st2)) return false;
-#endif
 
+       if (_wstat(file1_16, &st1)) return false;
+  if (_wstat(file2_16, &st2)) return false;
 
        UTF16_UN_ENCODE(file2);
        UTF16_UN_ENCODE(file1);
index 3b06b7df09a4ac161dbb5588426765eb33b88e76..d68344283766e4b89212cb15116270bb8db03c3d 100644 (file)
@@ -160,8 +160,6 @@ void RegisterBlendExtension(void)
        GetSystemDirectory(SysDir, FILE_MAXDIR);
 #ifdef _WIN64
        ThumbHandlerDLL = "BlendThumb64.dll";
-#elif defined(__MINGW32__)
-       ThumbHandlerDLL = "BlendThumb.dll";
 #else
        IsWow64Process(GetCurrentProcess(), &IsWOW64);
        if (IsWOW64 == true)
index 8f3bf88af65cb44934d6d168aa15bc3fd434ae13..a1bfce8813176ea0e33166c309104aae7ef14eb5 100644 (file)
@@ -27,7 +27,7 @@
 
 #include <algorithm>
 
-#if !defined(WIN32) || defined(FREE_WINDOWS)
+#if !defined(WIN32)
 #include <iostream>
 #endif
 
index 71875d6274a19091d9162a500e92b4ed45a042b4..c48c060dc95d3606cbab7d9328b93c8c5ac78264 100644 (file)
@@ -27,7 +27,7 @@
 
 #include <algorithm>
 
-#if !defined(WIN32) || defined(FREE_WINDOWS)
+#if !defined(WIN32)
 #include <stdint.h>
 #endif
 
index 71d49e0dc2ee99bc67e1a0c8ae67d91cf52376f9..ee0ec3fda3934477f3c2cd4b2542fa0fe8b9f93e 100644 (file)
@@ -48,9 +48,6 @@
 
 #ifdef WIN32
 #  include <windows.h> /* need to include windows.h so _WIN32_IE is defined  */
-#  ifndef _WIN32_IE
-#    define _WIN32_IE 0x0400 /* minimal requirements for SHGetSpecialFolderPath on MINGW MSVC has this defined already */
-#  endif
 #  include <shlobj.h>  /* for SHGetSpecialFolderPath, has to be done before BLI_winstuff
                         * because 'near' is disabled through BLI_windstuff */
 #  include "BLI_winstuff.h"
index d89393b99037588ba89205bdec6d745e2831e734..6d7ad7985f939b45134fe34f5507cd768dd59921 100644 (file)
 #  include <mmsystem.h>
 #  include <memory.h>
 #  include <commdlg.h>
-
-#  ifndef FREE_WINDOWS
-#    include <vfw.h>
-#  endif
+#  include <vfw.h>
 
 #  undef AVIIF_KEYFRAME // redefined in AVI_avi.h
 #  undef AVIIF_LIST // redefined in AVI_avi.h
@@ -130,7 +127,7 @@ struct anim {
        /* avi */
        struct _AviMovie *avi;
 
-#if defined(_WIN32) && !defined(FREE_WINDOWS)
+#if defined(_WIN32)
        /* windows avi */
        int avistreams;
        int firstvideo;
index a40b257b75b14c830a7b3bcb7c304d61c932746c..9806ff006d792718e1b1adffed2ae586988606e3 100644 (file)
 #include <mmsystem.h>
 #include <memory.h>
 #include <commdlg.h>
-
-#ifndef FREE_WINDOWS
 #include <vfw.h>
-#endif
 
 #undef AVIIF_KEYFRAME /* redefined in AVI_avi.h */
 #undef AVIIF_LIST /* redefined in AVI_avi.h */
@@ -173,7 +170,7 @@ static void an_stringenc(char *string, const char *head, const char *tail, unsig
 #ifdef WITH_AVI
 static void free_anim_avi(struct anim *anim)
 {
-#if defined(_WIN32) && !defined(FREE_WINDOWS)
+#if defined(_WIN32)
        int i;
 #endif
 
@@ -184,7 +181,7 @@ static void free_anim_avi(struct anim *anim)
        MEM_freeN(anim->avi);
        anim->avi = NULL;
 
-#if defined(_WIN32) && !defined(FREE_WINDOWS)
+#if defined(_WIN32)
 
        if (anim->pgf) {
                AVIStreamGetFrameClose(anim->pgf);
@@ -283,7 +280,7 @@ static int startavi(struct anim *anim)
 {
 
        AviError avierror;
-#if defined(_WIN32) && !defined(FREE_WINDOWS)
+#if defined(_WIN32)
        HRESULT hr;
        int i, firstvideo = -1;
        int streamcount;
@@ -304,7 +301,7 @@ static int startavi(struct anim *anim)
 
        avierror = AVI_open_movie(anim->name, anim->avi);
 
-#if defined(_WIN32) && !defined(FREE_WINDOWS)
+#if defined(_WIN32)
        if (avierror == AVI_ERROR_COMPRESSION) {
                AVIFileInit();
                hr = AVIFileOpen(&anim->pfile, anim->name, OF_READ, 0L);
@@ -401,7 +398,7 @@ static ImBuf *avi_fetchibuf(struct anim *anim, int position)
                return NULL;
        }
 
-#if defined(_WIN32) && !defined(FREE_WINDOWS)
+#if defined(_WIN32)
        if (anim->avistreams) {
                LPBITMAPINFOHEADER lpbi;
 
index 12e03f554507132e38a5872a8068dfb1123787fe..67a0b0ffd0035918faa1979628206b2523de915c 100644 (file)
@@ -37,7 +37,7 @@ extern "C" {
 #include <stdio.h> // printf
 #include <fstream>
 
-#if defined (WIN32) && !defined(FREE_WINDOWS)
+#if defined (WIN32)
 #include "utfconv.h"
 #endif
 
@@ -62,7 +62,7 @@ int imb_save_dds(struct ImBuf *ibuf, const char *name, int /*flags*/)
        /* open file for writing */
        std::ofstream fildes;
 
-#if defined (WIN32) && !defined(FREE_WINDOWS)
+#if defined (WIN32)
        wchar_t *wname = alloc_utf16_from_8(name, 0);
        fildes.open(wname);
        free(wname);
index 224cf6347d2d12cda12ca56244c5513625a96332..b123d508f99f1ccd5d7c3c5208cbd1b8b54583a4 100644 (file)
@@ -31,7 +31,7 @@
 
 #include <set>
 
-#if defined(WIN32) && !defined(FREE_WINDOWS)
+#if defined(WIN32)
 #include "utfconv.h"
 #endif
 
index 29332a5c8997d1888e16854602d84b4ffd5a14dd..ec544e653558012ca21200d2853d9a60daac9a3c 100644 (file)
@@ -69,7 +69,7 @@
 
 #include <openexr_api.h>
 
-#if defined (WIN32) && !defined(FREE_WINDOWS)
+#if defined (WIN32)
 #include "utfconv.h"
 #endif
 
@@ -77,7 +77,7 @@ extern "C"
 {
 
 // The following prevents a linking error in debug mode for MSVC using the libs in CVS
-#if defined(WITH_OPENEXR) && defined(_WIN32) && defined(DEBUG) && !defined(__MINGW32__) && _MSC_VER < 1900
+#if defined(WITH_OPENEXR) && defined(_WIN32) && defined(DEBUG) && _MSC_VER < 1900
 _CRTIMP void __cdecl _invalid_parameter_noinfo(void)
 {
 }
@@ -180,7 +180,7 @@ public:
        : IStream(filename)
        {
                /* utf-8 file path support on windows */
-#if defined (WIN32) && !defined(FREE_WINDOWS)
+#if defined (WIN32)
                wchar_t *wfilename = alloc_utf16_from_8(filename, 0);
                ifs.open(wfilename, std::ios_base::binary);
                free(wfilename);
@@ -243,7 +243,7 @@ public:
        : OStream(filename)
        {
                /* utf-8 file path support on windows */
-#if defined (WIN32) && !defined(FREE_WINDOWS)
+#if defined (WIN32)
                wchar_t *wfilename = alloc_utf16_from_8(filename, 0);
                ofs.open(wfilename, std::ios_base::binary);
                free(wfilename);
index ec6a03e713dc3844eb72d073a5d33ff0c69962d9..7fc6aab7885f1f29e45f317cba406351d561f724 100644 (file)
@@ -432,11 +432,7 @@ static void rna_Object_parent_set(PointerRNA *ptr, PointerRNA value)
 {
        Object *ob = (Object *)ptr->data;
        Object *par = (Object *)value.data;
-       
-#ifdef FREE_WINDOWS
-       /* NOTE: this dummy check here prevents this method causing weird runtime errors on mingw 4.6.2 */
-       if (ob)
-#endif
+
        {
                ED_object_parent(ob, par, ob->partype, ob->parsubstr);
        }
index 1cc2d6f1307348d9ef0d82baee653d2b2f51ad47..fdc2371c259c970274b6bc61f19de0eb48ea96a8 100644 (file)
@@ -126,7 +126,7 @@ static PyObject *bpy_app_handlers_persistent_new(PyTypeObject *UNUSED(type), PyO
 /* dummy type because decorators can't be PyCFunctions */
 static PyTypeObject BPyPersistent_Type = {
 
-#if defined(_MSC_VER) || defined(FREE_WINDOWS)
+#if defined(_MSC_VER)
        PyVarObject_HEAD_INIT(NULL, 0)
 #else
        PyVarObject_HEAD_INIT(&PyType_Type, 0)
@@ -206,7 +206,7 @@ PyObject *BPY_app_handlers_struct(void)
 {
        PyObject *ret;
 
-#if defined(_MSC_VER) || defined(FREE_WINDOWS)
+#if defined(_MSC_VER)
        BPyPersistent_Type.ob_base.ob_base.ob_type = &PyType_Type;
 #endif
 
index 6613bb8a5f7a60570d869b2693fa8abe48524fbd..a0b76bd67ee4bf37cb412a3db021a99c7af7a10e 100644 (file)
@@ -5692,7 +5692,7 @@ PyTypeObject pyrna_struct_meta_idprop_Type = {
        NULL,                       /* struct PyMethodDef *tp_methods; */
        NULL,                       /* struct PyMemberDef *tp_members; */
        NULL,                       /* struct PyGetSetDef *tp_getset; */
-#if defined(_MSC_VER) || defined(FREE_WINDOWS)
+#if defined(_MSC_VER)
        NULL, /* defer assignment */
 #else
        &PyType_Type,                       /* struct _typeobject *tp_base; */
@@ -6267,7 +6267,7 @@ static PyTypeObject pyrna_prop_collection_iter_Type = {
        NULL,                       /* reprfunc tp_str; */
 
        /* will only use these if this is a subtype of a py class */
-#if defined(_MSC_VER) || defined(FREE_WINDOWS)
+#if defined(_MSC_VER)
        NULL, /* defer assignment */
 #else
        PyObject_GenericGetAttr,    /* getattrofunc tp_getattro; */
@@ -6300,7 +6300,7 @@ static PyTypeObject pyrna_prop_collection_iter_Type = {
 #endif
        /*** Added in release 2.2 ***/
        /*   Iterators */
-#if defined(_MSC_VER) || defined(FREE_WINDOWS)
+#if defined(_MSC_VER)
        NULL, /* defer assignment */
 #else
        PyObject_SelfIter,          /* getiterfunc tp_iter; */
@@ -6776,7 +6776,7 @@ void BPY_rna_init(void)
 #endif
 
        /* for some reason MSVC complains of these */
-#if defined(_MSC_VER) || defined(FREE_WINDOWS)
+#if defined(_MSC_VER)
        pyrna_struct_meta_idprop_Type.tp_base = &PyType_Type;
 
        pyrna_prop_collection_iter_Type.tp_iter = PyObject_SelfIter;
index bee76a12ee5247c22e8cb671d6e1805fb4b74e58..66c72be3d5de2d6f4a233e5a64f43c8dd33a01de 100644 (file)
@@ -35,24 +35,13 @@ if(WIN32 AND NOT UNIX)
        string(SUBSTRING ${BLENDER_VERSION} 0 1 bver1)
        string(SUBSTRING ${BLENDER_VERSION} 2 1 bver2)
        string(SUBSTRING ${BLENDER_VERSION} 3 1 bver3)
-       if(MINGW)
-               add_definitions(
-                       -DWINDRES
-                       -DBLEN_VER_RC_STR_M=${BLENDER_VERSION}
-                       -DBLEN_VER_RC_1=${bver1}
-                       -DBLEN_VER_RC_2=${bver2}
-                       -DBLEN_VER_RC_3=${bver3}
-                       -DBLEN_VER_RC_4=0
-               )
-       else()
-               add_definitions(
-                       -DBLEN_VER_RC_STR=${BLENDER_VERSION}
-                       -DBLEN_VER_RC_1=${bver1}
-                       -DBLEN_VER_RC_2=${bver2}
-                       -DBLEN_VER_RC_3=${bver3}
-                       -DBLEN_VER_RC_4=0
-               )
-       endif()
+       add_definitions(
+               -DBLEN_VER_RC_STR=${BLENDER_VERSION}
+               -DBLEN_VER_RC_1=${bver1}
+               -DBLEN_VER_RC_2=${bver2}
+               -DBLEN_VER_RC_3=${bver3}
+               -DBLEN_VER_RC_4=0
+       )
 
        add_executable(
                        blenderplayer ${EXETYPE}
index 7a34f8bcb69eadc659885e134f8707c90d4de8ad..8f26e2484247da483aa3afdccb65ce5aea0df432 100644 (file)
@@ -113,24 +113,13 @@ if(WIN32 AND NOT UNIX)
        string(SUBSTRING ${BLENDER_VERSION} 0 1 bver1)
        string(SUBSTRING ${BLENDER_VERSION} 2 1 bver2)
        string(SUBSTRING ${BLENDER_VERSION} 3 1 bver3)
-       if(MINGW)
-               add_definitions(
-                       -DWINDRES
-                       -DBLEN_VER_RC_STR_M=${BLENDER_VERSION}
-                       -DBLEN_VER_RC_1=${bver1}
-                       -DBLEN_VER_RC_2=${bver2}
-                       -DBLEN_VER_RC_3=${bver3}
-                       -DBLEN_VER_RC_4=0
-               )
-       else()
-               add_definitions(
-                       -DBLEN_VER_RC_STR=${BLENDER_VERSION}
-                       -DBLEN_VER_RC_1=${bver1}
-                       -DBLEN_VER_RC_2=${bver2}
-                       -DBLEN_VER_RC_3=${bver3}
-                       -DBLEN_VER_RC_4=0
-               )
-       endif()
+       add_definitions(
+               -DBLEN_VER_RC_STR=${BLENDER_VERSION}
+               -DBLEN_VER_RC_1=${bver1}
+               -DBLEN_VER_RC_2=${bver2}
+               -DBLEN_VER_RC_3=${bver3}
+               -DBLEN_VER_RC_4=0
+       )
 
 
        list(APPEND SRC
@@ -652,7 +641,6 @@ elseif(WIN32)
        if(WITH_PYTHON)
                string(REPLACE "." "" _PYTHON_VERSION_NO_DOTS ${PYTHON_VERSION})
 
-               # MinGW TODO: This bit of Python configuration diverges from MSVC
                if(NOT CMAKE_COMPILER_IS_GNUCC)
                        install(
                                FILES ${LIBDIR}/python/lib/python${_PYTHON_VERSION_NO_DOTS}.dll
@@ -749,20 +737,6 @@ elseif(WIN32)
                                DESTINATION ${BLENDER_VERSION}/python/bin
                                CONFIGURATIONS Debug
                        )
-
-                       # MinGW needs Python DLL
-                       if(MINGW)
-                               install(
-                                       FILES ${LIBDIR}/python/lib/python${_PYTHON_VERSION_NO_DOTS}.dll
-                                       DESTINATION "."
-                                       CONFIGURATIONS Release;RelWithDebInfo;MinSizeRel
-                               )
-                               install(
-                                       FILES ${LIBDIR}/python/lib/python${_PYTHON_VERSION_NO_DOTS}_d.dll
-                                       DESTINATION "."
-                                       CONFIGURATIONS Debug
-                               )
-                       endif()
                endif()
 
                unset(_PYTHON_VERSION_NO_DOTS)
@@ -785,57 +759,19 @@ elseif(WIN32)
                        FILES ${LIBDIR}/pthreads/lib/pthreadVC2.dll
                        DESTINATION "."
                )
-       else()
-               #MinGW64 comes with own version. For portable builds it will probaly have to be copied to work
-               if(NOT WITH_MINGW64)
-                       install(
-                               FILES ${LIBDIR}/pthreads/lib/pthreadGC2.dll
-                               DESTINATION "."
-                       )
-               elseif(WITH_MINGW64)
-                       install(
-                               FILES 
-                                       ${LIBDIR}/binaries/libgcc_s_sjlj-1.dll
-                                       ${LIBDIR}/binaries/libwinpthread-1.dll
-                                       ${LIBDIR}/binaries/libstdc++-6.dll
-                               DESTINATION "."
-                       )
-                       
-                       if(WITH_OPENMP)
-                               install(
-                                       FILES 
-                                       ${LIBDIR}/binaries/libgomp-1.dll
-                                       DESTINATION "."
-                               )
-                       endif()
-               endif()
        endif()
 
        if(WITH_CODEC_FFMPEG)
-               if(WITH_MINGW64)
-                       install(
-                               FILES
-                                       ${LIBDIR}/ffmpeg/lib/avcodec-53.dll
-                                       ${LIBDIR}/ffmpeg/lib/avformat-53.dll
-                                       ${LIBDIR}/ffmpeg/lib/avdevice-53.dll
-                                       ${LIBDIR}/ffmpeg/lib/avutil-51.dll
-                                       ${LIBDIR}/ffmpeg/lib/swscale-2.dll
-                                       ${LIBDIR}/ffmpeg/lib/swresample-0.dll
-                                       ${LIBDIR}/ffmpeg/lib/xvidcore.dll
-                               DESTINATION "."
-                       )
-               else()
-                       install(
-                               FILES
-                                       ${LIBDIR}/ffmpeg/lib/avcodec-57.dll
-                                       ${LIBDIR}/ffmpeg/lib/avformat-57.dll
-                                       ${LIBDIR}/ffmpeg/lib/avdevice-57.dll
-                                       ${LIBDIR}/ffmpeg/lib/avutil-55.dll
-                                       ${LIBDIR}/ffmpeg/lib/swscale-4.dll
-                                       ${LIBDIR}/ffmpeg/lib/swresample-2.dll
-                               DESTINATION "."
-                       )
-               endif()
+               install(
+                       FILES
+                               ${LIBDIR}/ffmpeg/lib/avcodec-57.dll
+                               ${LIBDIR}/ffmpeg/lib/avformat-57.dll
+                               ${LIBDIR}/ffmpeg/lib/avdevice-57.dll
+                               ${LIBDIR}/ffmpeg/lib/avutil-55.dll
+                               ${LIBDIR}/ffmpeg/lib/swscale-4.dll
+                               ${LIBDIR}/ffmpeg/lib/swresample-2.dll
+                       DESTINATION "."
+               )
        endif()
 
        if(WITH_CODEC_SNDFILE)
@@ -851,30 +787,13 @@ elseif(WIN32)
                                ${LIBDIR}/openal/lib/OpenAL32.dll
                        DESTINATION "."
                )
-               # MinGW TODO: Need to update to a newer OpenAL version
-               # which does not depend on wrap_oal.dll
-               if(CMAKE_COMPILER_IS_GNUCC)
-                       install(
-                               FILES
-                                       ${LIBDIR}/openal/lib/wrap_oal.dll
-                               DESTINATION "."
-                       )
-               endif()
        endif()
 
        if(WITH_SDL)
-               #MinGW TODO: Update to SDL2
-               if(NOT CMAKE_COMPILER_IS_GNUCC)
-                       install(
-                               FILES ${LIBDIR}/sdl/lib/SDL2.dll
-                               DESTINATION "."
-                       )
-               else()
-                       install(
-                               FILES ${LIBDIR}/sdl/lib/SDL.dll
-                               DESTINATION "."
-                       )
-               endif()
+               install(
+                       FILES ${LIBDIR}/sdl/lib/SDL2.dll
+                       DESTINATION "."
+               )
        endif()
        
        if(WITH_SYSTEM_AUDASPACE)
@@ -901,19 +820,11 @@ elseif(WIN32)
 
        if(WITH_OPENCOLORIO)
                set(OCIOBIN ${LIBDIR}/opencolorio/bin)
-               if(NOT MINGW)
                        install(
                                FILES
                                        ${OCIOBIN}/OpenColorIO.dll
                                DESTINATION "."
                        )
-               else()
-                       install(
-                               FILES
-                                       ${OCIOBIN}/libOpenColorIO.dll
-                               DESTINATION "."
-                       )
-               endif()
        endif()
 
 elseif(APPLE)
index 005ac16b231f9034cb5e33247a60c08fe229197d..11d9482f993866a9fe118ff4fc594f0b7b19f203 100644 (file)
@@ -40,10 +40,8 @@ CHashedPtr::CHashedPtr(void* val) : m_valptr(val)
 
 unsigned int CHashedPtr::hash() const
 {
-#if defined(_WIN64) && !defined(FREE_WINDOWS64)
+#if defined(_WIN64)
        unsigned __int64 key = (unsigned __int64)m_valptr;
-#elif defined(FREE_WINDOWS64)
-       unsigned long long key = (unsigned long long)m_valptr;
 #else
        unsigned long key = (unsigned long)m_valptr;
 #endif
index e8cc7fba284e7f2b180794a75beb18ae93802a99..583d8da63cb5eb8aaab854b7ff0df7eb0e0ec162 100644 (file)
@@ -37,7 +37,7 @@
 // cool things like (IF(LOD==1,CCurvedValue,IF(LOD==2,CCurvedValue2)) etc...
 #include "EXP_IfExpr.h"
 
-#if (defined(WIN32) || defined(WIN64)) && !defined(FREE_WINDOWS)
+#if defined(WIN32) || defined(WIN64)
 #define strcasecmp     _stricmp
 
 #ifndef strtoll
index f3947fdd710ae8b199d5a4147c31fdef48fdf0e5..be1a4b4ef3a1454f0f670b8e6cea024213e85d1a 100644 (file)
  */
 
 
-#if defined(_WIN64) && !defined(FREE_WINDOWS64)
+#if defined(_WIN64)
 typedef unsigned __int64 uint_ptr;
-#elif defined(FREE_WINDOWS64)
-typedef unsigned long long uint_ptr;
 #else
 typedef unsigned long uint_ptr;
 #endif
index b0a8e376eb6a19b5a45b7f377a3c81731231b783..d82a0fd533bbf33b9f5aa155fdcba96b67c4eadb 100644 (file)
 #define DEFAULT_LOGIC_TIC_RATE 60.0
 //#define DEFAULT_PHYSICS_TIC_RATE 60.0
 
-#ifdef FREE_WINDOWS /* XXX mingw64 (gcc 4.7.0) defines a macro for DrawText that translates to DrawTextA. Not good */
-#ifdef DrawText
-#undef DrawText
-#endif
-#endif
-
 const char KX_KetsjiEngine::m_profileLabels[tc_numCategories][15] = {
        "Physics:",             // tc_physics
        "Logic:",               // tc_logic
index 0db1fa293daca7f5ca04cddc89a10cf632041d2c..b91a312a5d7cbdad679830e5e9e418d79dcc4ec8 100644 (file)
@@ -43,7 +43,7 @@ extern "C" {
 
 #include "Exception.h"
 
-#if (defined(WIN32) || defined(WIN64)) && !defined(FREE_WINDOWS)
+#if (defined(WIN32) || defined(WIN64))
 #define strcasecmp     _stricmp
 #endif