replace open coded versions of file(TO_CMAKE_PATH)
This commit is contained in:
parent
54431e3395
commit
3505e68466
|
@ -79,18 +79,14 @@ SET(FLTK_DIR_STRING "directory containing FLTKConfig.cmake. This is either the
|
||||||
# Search only if the location is not already known.
|
# Search only if the location is not already known.
|
||||||
IF(NOT FLTK_DIR)
|
IF(NOT FLTK_DIR)
|
||||||
# Get the system search path as a list.
|
# Get the system search path as a list.
|
||||||
IF(UNIX)
|
FILE(TO_CMAKE_PATH "$ENV{PATH}" FLTK_DIR_SEARCH2)
|
||||||
STRING(REGEX MATCHALL "[^:]+" FLTK_DIR_SEARCH1 "$ENV{PATH}")
|
|
||||||
ELSE(UNIX)
|
|
||||||
STRING(REGEX REPLACE "\\\\" "/" FLTK_DIR_SEARCH1 "$ENV{PATH}")
|
|
||||||
ENDIF(UNIX)
|
|
||||||
STRING(REGEX REPLACE "/;" ";" FLTK_DIR_SEARCH2 ${FLTK_DIR_SEARCH1})
|
|
||||||
|
|
||||||
# Construct a set of paths relative to the system search path.
|
# Construct a set of paths relative to the system search path.
|
||||||
SET(FLTK_DIR_SEARCH "")
|
SET(FLTK_DIR_SEARCH "")
|
||||||
FOREACH(dir ${FLTK_DIR_SEARCH2})
|
FOREACH(dir ${FLTK_DIR_SEARCH2})
|
||||||
SET(FLTK_DIR_SEARCH ${FLTK_DIR_SEARCH} "${dir}/../lib/fltk")
|
SET(FLTK_DIR_SEARCH ${FLTK_DIR_SEARCH} "${dir}/../lib/fltk")
|
||||||
ENDFOREACH(dir)
|
ENDFOREACH(dir)
|
||||||
|
STRING(REPLACE "//" "/" FLTK_DIR_SEARCH "${FLTK_DIR_SEARCH}")
|
||||||
|
|
||||||
#
|
#
|
||||||
# Look for an installation or build tree.
|
# Look for an installation or build tree.
|
||||||
|
|
|
@ -59,18 +59,14 @@ SET(FLTK2_DIR_STRING "directory containing FLTK2Config.cmake. This is either th
|
||||||
# Search only if the location is not already known.
|
# Search only if the location is not already known.
|
||||||
IF(NOT FLTK2_DIR)
|
IF(NOT FLTK2_DIR)
|
||||||
# Get the system search path as a list.
|
# Get the system search path as a list.
|
||||||
IF(UNIX)
|
FILE(TO_CMAKE_PATH "$ENV{PATH}" FLTK2_DIR_SEARCH2)
|
||||||
STRING(REGEX MATCHALL "[^:]+" FLTK2_DIR_SEARCH1 "$ENV{PATH}")
|
|
||||||
ELSE(UNIX)
|
|
||||||
STRING(REGEX REPLACE "\\\\" "/" FLTK2_DIR_SEARCH1 "$ENV{PATH}")
|
|
||||||
ENDIF(UNIX)
|
|
||||||
STRING(REGEX REPLACE "/;" ";" FLTK2_DIR_SEARCH2 ${FLTK2_DIR_SEARCH1})
|
|
||||||
|
|
||||||
# Construct a set of paths relative to the system search path.
|
# Construct a set of paths relative to the system search path.
|
||||||
SET(FLTK2_DIR_SEARCH "")
|
SET(FLTK2_DIR_SEARCH "")
|
||||||
FOREACH(dir ${FLTK2_DIR_SEARCH2})
|
FOREACH(dir ${FLTK2_DIR_SEARCH2})
|
||||||
SET(FLTK2_DIR_SEARCH ${FLTK2_DIR_SEARCH} "${dir}/../lib/fltk")
|
SET(FLTK2_DIR_SEARCH ${FLTK2_DIR_SEARCH} "${dir}/../lib/fltk")
|
||||||
ENDFOREACH(dir)
|
ENDFOREACH(dir)
|
||||||
|
STRING(REPLACE "//" "/" FLTK2_DIR_SEARCH "${FLTK2_DIR_SEARCH}")
|
||||||
|
|
||||||
#
|
#
|
||||||
# Look for an installation or build tree.
|
# Look for an installation or build tree.
|
||||||
|
|
|
@ -43,18 +43,14 @@ SET(SQUISH_CLIENT_EXECUTABLE_STRING "The squishclient executable program.")
|
||||||
# Search only if the location is not already known.
|
# Search only if the location is not already known.
|
||||||
IF(NOT SQUISH_INSTALL_DIR)
|
IF(NOT SQUISH_INSTALL_DIR)
|
||||||
# Get the system search path as a list.
|
# Get the system search path as a list.
|
||||||
IF(UNIX)
|
FILE(TO_CMAKE_PATH "$ENV{PATH}" SQUISH_INSTALL_DIR_SEARCH2)
|
||||||
STRING(REGEX MATCHALL "[^:]+" SQUISH_INSTALL_DIR_SEARCH1 "$ENV{PATH}")
|
|
||||||
ELSE(UNIX)
|
|
||||||
STRING(REGEX REPLACE "\\\\" "/" SQUISH_INSTALL_DIR_SEARCH1 "$ENV{PATH}")
|
|
||||||
ENDIF(UNIX)
|
|
||||||
STRING(REGEX REPLACE "/;" ";" SQUISH_INSTALL_DIR_SEARCH2 ${SQUISH_INSTALL_DIR_SEARCH1})
|
|
||||||
|
|
||||||
# Construct a set of paths relative to the system search path.
|
# Construct a set of paths relative to the system search path.
|
||||||
SET(SQUISH_INSTALL_DIR_SEARCH "")
|
SET(SQUISH_INSTALL_DIR_SEARCH "")
|
||||||
FOREACH(dir ${SQUISH_INSTALL_DIR_SEARCH2})
|
FOREACH(dir ${SQUISH_INSTALL_DIR_SEARCH2})
|
||||||
SET(SQUISH_INSTALL_DIR_SEARCH ${SQUISH_INSTALL_DIR_SEARCH} "${dir}/../lib/fltk")
|
SET(SQUISH_INSTALL_DIR_SEARCH ${SQUISH_INSTALL_DIR_SEARCH} "${dir}/../lib/fltk")
|
||||||
ENDFOREACH(dir)
|
ENDFOREACH(dir)
|
||||||
|
STRING(REPLACE "//" "/" SQUISH_INSTALL_DIR_SEARCH "${SQUISH_INSTALL_DIR_SEARCH}")
|
||||||
|
|
||||||
# Look for an installation
|
# Look for an installation
|
||||||
FIND_PATH(SQUISH_INSTALL_DIR bin/squishrunner
|
FIND_PATH(SQUISH_INSTALL_DIR bin/squishrunner
|
||||||
|
|
Loading…
Reference in New Issue