[Cmake-commits] [cmake-commits] king committed CMakeLists.txt 1.12 1.13 testLib4libdbg1.c NONE 1.1 testLib4libopt1.c NONE 1.1

cmake-commits at cmake.org cmake-commits at cmake.org
Tue Aug 12 17:27:50 EDT 2008


Update of /cvsroot/CMake/CMake/Tests/ExportImport/Export
In directory public:/mounts/ram/cvs-serv31764/Tests/ExportImport/Export

Modified Files:
	CMakeLists.txt 
Added Files:
	testLib4libdbg1.c testLib4libopt1.c 
Log Message:
BUG: Fix ExportImport test on VS6

Visual Studio 6 does not support per-target object files, so just use two
separate source file names in this case.


Index: CMakeLists.txt
===================================================================
RCS file: /cvsroot/CMake/CMake/Tests/ExportImport/Export/CMakeLists.txt,v
retrieving revision 1.12
retrieving revision 1.13
diff -C 2 -d -r1.12 -r1.13
*** CMakeLists.txt	11 Aug 2008 20:23:10 -0000	1.12
--- CMakeLists.txt	12 Aug 2008 21:27:48 -0000	1.13
***************
*** 36,39 ****
--- 36,45 ----
  set_property(TARGET testLib4 PROPERTY FRAMEWORK 1)
  
+ # Work-around: Visual Studio 6 does not support per-target object files.
+ set(VS6)
+ if("${CMAKE_GENERATOR}" MATCHES "Visual Studio 6")
+   set(VS6 1)
+ endif("${CMAKE_GENERATOR}" MATCHES "Visual Studio 6")
+ 
  # Test using the target_link_libraries command to set the
  # LINK_INTERFACE_LIBRARIES* properties.  We construct two libraries
***************
*** 44,49 ****
  # used via the link interface the import test will fail to link.
  add_library(testLib4lib STATIC testLib4lib.c)
! add_library(testLib4libdbg STATIC testLib4libopt.c testLib4libdbg.c)
! add_library(testLib4libopt STATIC testLib4libdbg.c testLib4libopt.c)
  set_property(TARGET testLib4libdbg PROPERTY COMPILE_DEFINITIONS LIB_DBG)
  set_property(TARGET testLib4libopt PROPERTY COMPILE_DEFINITIONS LIB_OPT)
--- 50,55 ----
  # used via the link interface the import test will fail to link.
  add_library(testLib4lib STATIC testLib4lib.c)
! add_library(testLib4libdbg STATIC testLib4libopt.c testLib4libdbg${VS6}.c)
! add_library(testLib4libopt STATIC testLib4libdbg.c testLib4libopt${VS6}.c)
  set_property(TARGET testLib4libdbg PROPERTY COMPILE_DEFINITIONS LIB_DBG)
  set_property(TARGET testLib4libopt PROPERTY COMPILE_DEFINITIONS LIB_OPT)

--- NEW FILE: testLib4libdbg1.c ---
#include "testLib4libdbg.c"

--- NEW FILE: testLib4libopt1.c ---
#include "testLib4libopt.c"



More information about the Cmake-commits mailing list