Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

Diff of /CMakeLists.txt [388e6d] .. [725c13] Maximize Restore

  Switch to side-by-side view

--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -28,14 +28,13 @@
     SET( CMAKE_INSTALL_PREFIX ${CMAKE_CURRENT_BINARY_DIR}/INSTALL/FILES CACHE FILEPATH "install prefix" FORCE)
 
   # look in wxWidgets distribution for depending packages.
-  SET(wxWidgets_LIB_DIR ${SOURCE_BASE_DIR}/wxMSW-2.8.7/lib/vc_lib)
-  SET(wxWidgets_ROOT_DIR ${SOURCE_BASE_DIR}/wxMSW-2.8.7)
+  SET(wxWidgets_LIB_DIR ${SOURCE_BASE_DIR}/wxWidgets-2.8.9/lib/vc_lib)
+  SET(wxWidgets_ROOT_DIR ${SOURCE_BASE_DIR}/wxWidgets-2.8.9)
 ENDIF(WIN32)
 
 ##
 ## External libraries
 ##
-
 FIND_PACKAGE(TIFF REQUIRED)
 INCLUDE_DIRECTORIES(${TIFF_INCLUDE_DIR})
 FIND_PACKAGE(JPEG REQUIRED)
@@ -83,15 +82,15 @@
   # Stop MSVC9 from bitching about POSIX names without underscores
   ADD_DEFINITIONS(/D_CRT_NONSTDC_NO_DEPRECATE)
   # compile everything for the static C runtime
-  STRING(REPLACE /MD /MT CMAKE_CXX_FLAGS_RELEASE ${CMAKE_CXX_FLAGS_RELEASE})
-  STRING(REPLACE /MD /MT CMAKE_CXX_FLAGS_DEBUG ${CMAKE_CXX_FLAGS_DEBUG})
-  STRING(REPLACE /MD /MT CMAKE_CXX_FLAGS_MINSIZEREL ${CMAKE_CXX_FLAGS_MINSIZEREL})
-  STRING(REPLACE /MD /MT CMAKE_CXX_FLAGS_RELWITHDEBINFO ${CMAKE_CXX_FLAGS_RELWITHDEBINFO})
-  STRING(REPLACE /MD /MT CMAKE_C_FLAGS_RELEASE ${CMAKE_C_FLAGS_RELEASE})
-  STRING(REPLACE /MD /MT CMAKE_C_FLAGS_DEBUG ${CMAKE_C_FLAGS_DEBUG})
-  STRING(REPLACE /MD /MT CMAKE_C_FLAGS_MINSIZEREL ${CMAKE_C_FLAGS_MINSIZEREL})
-  STRING(REPLACE /MD /MT CMAKE_C_FLAGS_RELWITHDEBINFO ${CMAKE_C_FLAGS_RELWITHDEBINFO})
-
+  FOREACH(TYPE C CXX)
+	FOREACH(CFG "_DEBUG" "_MINSIZEREL" "_RELEASE" "_RELWITHDEBINFO")
+      SET(NEW_FLAGS "${CMAKE_${TYPE}_FLAGS${CFG}}")
+	  STRING(REPLACE "/MD" "/MT" NEW_FLAGS "${NEW_FLAGS}")
+	  SET(CMAKE_${TYPE}_FLAGS${CFG} "${NEW_FLAGS}" CACHE STRING
+				"CMAKE_${TYPE}_FLAGS${CFG} (overwritten to ensure static build)" FORCE)
+	ENDFOREACH(CFG)
+  ENDFOREACH(TYPE)
+  
   # yes we DO have pano13
   ADD_DEFINITIONS( /DHAS_PANO13 )