[Cmake-commits] [cmake-commits] king committed CMakeLists.txt 1.1 1.2

cmake-commits at cmake.org cmake-commits at cmake.org
Mon Oct 5 09:07:17 EDT 2009


Update of /cvsroot/CMake/CMake/Tests/LinkLanguage
In directory public:/mounts/ram/cvs-serv12389/Tests/LinkLanguage

Modified Files:
	CMakeLists.txt 
Log Message:
Test target link information invalidation

We test this by adding export(TARGETS) to the LinkLanguage test to
export the executable before the library is linked to it.  Since
export(TARGETS) computes the link interface of the target (so that it
can export it), this ensures that the information is recomputed after
the link library is added.


Index: CMakeLists.txt
===================================================================
RCS file: /cvsroot/CMake/CMake/Tests/LinkLanguage/CMakeLists.txt,v
retrieving revision 1.1
retrieving revision 1.2
diff -C 2 -d -r1.1 -r1.2
*** CMakeLists.txt	10 Jul 2009 17:53:38 -0000	1.1
--- CMakeLists.txt	5 Oct 2009 13:07:09 -0000	1.2
***************
*** 4,7 ****
--- 4,12 ----
  add_library(foo STATIC foo.cxx)
  add_executable(LinkLanguage LinkLanguage.c)
+ 
+ # Export the target now to compute its link interface and implementation.
+ # This tests that the link info is recomputed after the library is linked.
+ export(TARGETS LinkLanguage FILE LinkLanguageTargets.cmake)
+ 
  target_link_libraries(LinkLanguage foo)
  



More information about the Cmake-commits mailing list