[Cmake-commits] [cmake-commits] king committed CMakeLists.txt 1.2 1.3 foo1c.c NONE 1.1 foo2c.c NONE 1.1 foo3b.c 1.1 1.2 foo3c.c NONE 1.1
cmake-commits at cmake.org
cmake-commits at cmake.org
Tue Sep 1 10:38:06 EDT 2009
Update of /cvsroot/CMake/CMake/Tests/Dependency/Case2
In directory public:/mounts/ram/cvs-serv2109/Tests/Dependency/Case2
Modified Files:
CMakeLists.txt foo3b.c
Added Files:
foo1c.c foo2c.c foo3c.c
Log Message:
Test link multiplicity
This tests the LINK_INTERFACE_MULTIPLICITY property for a cycle of three
static libraries that must be scanned three times to link properly.
Index: foo3b.c
===================================================================
RCS file: /cvsroot/CMake/CMake/Tests/Dependency/Case2/foo3b.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -C 2 -d -r1.1 -r1.2
*** foo3b.c 7 Feb 2008 21:14:17 -0000 1.1
--- foo3b.c 1 Sep 2009 14:38:03 -0000 1.2
***************
*** 1 ****
! int foo3b(void) { return 0; }
--- 1,2 ----
! extern int foo1c(void);
! int foo3b(void) { return foo1c(); }
Index: CMakeLists.txt
===================================================================
RCS file: /cvsroot/CMake/CMake/Tests/Dependency/Case2/CMakeLists.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C 2 -d -r1.2 -r1.3
*** CMakeLists.txt 7 Feb 2008 21:14:17 -0000 1.2
--- CMakeLists.txt 1 Sep 2009 14:38:01 -0000 1.3
***************
*** 1,10 ****
project(CASE2 C)
! add_library(case2Foo1 STATIC foo1.c foo1b.c)
! add_library(case2Foo2 STATIC foo2.c foo2b.c)
! add_library(case2Foo3 STATIC foo3.c foo3b.c)
target_link_libraries(case2Foo1 case2Foo2)
target_link_libraries(case2Foo2 case2Foo3)
target_link_libraries(case2Foo3 case2Foo1)
add_library(case2Bar1 STATIC bar1.c)
--- 1,11 ----
project(CASE2 C)
! add_library(case2Foo1 STATIC foo1.c foo1b.c foo1c.c)
! add_library(case2Foo2 STATIC foo2.c foo2b.c foo2c.c)
! add_library(case2Foo3 STATIC foo3.c foo3b.c foo3c.c)
target_link_libraries(case2Foo1 case2Foo2)
target_link_libraries(case2Foo2 case2Foo3)
target_link_libraries(case2Foo3 case2Foo1)
+ set_property(TARGET case2Foo1 PROPERTY LINK_INTERFACE_MULTIPLICITY 3)
add_library(case2Bar1 STATIC bar1.c)
--- NEW FILE: foo3c.c ---
int foo3c(void) { return 0; }
--- NEW FILE: foo1c.c ---
extern int foo2c(void);
int foo1c(void) { return foo2c(); }
--- NEW FILE: foo2c.c ---
extern int foo3c(void);
int foo2c(void) { return foo3c(); }
More information about the Cmake-commits
mailing list