summaryrefslogtreecommitdiffstats
path: root/Modules/FindTclsh.cmake
diff options
context:
space:
mode:
authorSebastien Barre <sebastien.barre@kitware.com>2008-01-26 06:11:04 (GMT)
committerSebastien Barre <sebastien.barre@kitware.com>2008-01-26 06:11:04 (GMT)
commit59d29d6079b735452e18676b0e572f6601d40fa7 (patch)
tree68eceea8541711172415181a79548b8e3c7ae146 /Modules/FindTclsh.cmake
parenta35145fb272802a9c1ddf10fdcfc1f27a4361816 (diff)
downloadCMake-59d29d6079b735452e18676b0e572f6601d40fa7.zip
CMake-59d29d6079b735452e18676b0e572f6601d40fa7.tar.gz
CMake-59d29d6079b735452e18676b0e572f6601d40fa7.tar.bz2
ENH: Update Tcl/Tk 8.5
Diffstat (limited to 'Modules/FindTclsh.cmake')
-rw-r--r--Modules/FindTclsh.cmake7
1 files changed, 7 insertions, 0 deletions
diff --git a/Modules/FindTclsh.cmake b/Modules/FindTclsh.cmake
index c9940cf..d2cc86b 100644
--- a/Modules/FindTclsh.cmake
+++ b/Modules/FindTclsh.cmake
@@ -13,15 +13,21 @@ ENDIF(WIN32 AND UNIX)
GET_FILENAME_COMPONENT(TK_WISH_PATH "${TK_WISH}" PATH)
GET_FILENAME_COMPONENT(TK_WISH_PATH_PARENT "${TK_WISH_PATH}" PATH)
+STRING(REGEX REPLACE
+ "^.*wish([0-9]\\.*[0-9]).*$" "\\1" TK_WISH_VERSION "${TK_WISH}")
GET_FILENAME_COMPONENT(TCL_INCLUDE_PATH_PARENT "${TCL_INCLUDE_PATH}" PATH)
GET_FILENAME_COMPONENT(TK_INCLUDE_PATH_PARENT "${TK_INCLUDE_PATH}" PATH)
GET_FILENAME_COMPONENT(TCL_LIBRARY_PATH "${TCL_LIBRARY}" PATH)
GET_FILENAME_COMPONENT(TCL_LIBRARY_PATH_PARENT "${TCL_LIBRARY_PATH}" PATH)
+STRING(REGEX REPLACE
+ "^.*tcl([0-9]\\.*[0-9]).*$" "\\1" TCL_LIBRARY_VERSION "${TCL_LIBRARY}")
GET_FILENAME_COMPONENT(TK_LIBRARY_PATH "${TK_LIBRARY}" PATH)
GET_FILENAME_COMPONENT(TK_LIBRARY_PATH_PARENT "${TK_LIBRARY_PATH}" PATH)
+STRING(REGEX REPLACE
+ "^.*tk([0-9]\\.*[0-9]).*$" "\\1" TK_LIBRARY_VERSION "${TK_LIBRARY}")
SET(TCLTK_POSSIBLE_BIN_PATHS
"${TCL_INCLUDE_PATH_PARENT}/bin"
@@ -49,6 +55,7 @@ ENDIF(WIN32)
SET(TCL_TCLSH_NAMES
tclsh
+ tclsh${TCL_LIBRARY_VERSION} tclsh${TK_LIBRARY_VERSION} tclsh${TK_WISH_VERSION}
tclsh86 tclsh8.6
tclsh85 tclsh8.5
tclsh84 tclsh8.4