Remove unneeded test and code duplication. Add WIN32 test. Make all ADVANCED.

This commit is contained in:
Sebastien Barre 2001-12-04 10:55:17 -05:00
parent f68e64e2d8
commit cb4f04c94e
8 changed files with 145 additions and 155 deletions

View File

@ -7,6 +7,7 @@
# Build the documentation ?
#
OPTION(BUILD_DOCUMENTATION "Build the documentation (Doxygen)." OFF)
MARK_AS_ADVANCED(BUILD_DOCUMENTATION)
IF (BUILD_DOCUMENTATION)
@ -25,6 +26,11 @@ IF (BUILD_DOCUMENTATION)
OPTION(DOCUMENTATION_HTML_TARZ
"Build a compressed tar archive of the HTML doc." OFF)
MARK_AS_ADVANCED(
DOCUMENTATION_HTML_HELP
DOCUMENTATION_HTML_TARZ
)
#
# The documentation process is controled by a batch file.
# We will probably need bash to create the custom target

View File

@ -2,8 +2,14 @@
# this module looks for Cygwin
#
FIND_PATH(CYGWIN_INSTALL_PATH
cygwin.bat
"C:/Cygwin"
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\Cygnus Solutions\\Cygwin\\mounts v2\\/;native]"
)
IF (WIN32)
FIND_PATH(CYGWIN_INSTALL_PATH
cygwin.bat
"C:/Cygwin"
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\Cygnus Solutions\\Cygwin\\mounts v2\\/;native]"
)
MARK_AS_ADVANCED(
CYGWIN_INSTALL_PATH
)
ENDIF (WIN32)

View File

@ -12,7 +12,12 @@ FIND_PROGRAM(DOT
)
# HKEY_CURRENT_USER\Software\AT&T\Graphviz
# Since most of the time dot is called by Doxygen, the path to dot is useful too
# Since most of the time dot is called by Doxygen, the path to dot is
# useful too
GET_FILENAME_COMPONENT(DOT_PATH ${DOT} PATH CACHE)
MARK_AS_ADVANCED(
DOT
DOT_PATH
DOXYGEN
)

View File

@ -2,8 +2,14 @@
# this module looks for Microsoft HTML Help Compiler
#
FIND_PROGRAM(HHC
hhc
"C:/Program Files/HTML Help Workshop"
"[HKEY_CURRENT_USER\\Software\\Microsoft\\HTML Help Workshop;InstallDir]"
)
IF (WIN32)
FIND_PROGRAM(HHC
hhc
"C:/Program Files/HTML Help Workshop"
"[HKEY_CURRENT_USER\\Software\\Microsoft\\HTML Help Workshop;InstallDir]"
)
MARK_AS_ADVANCED(
HHC
)
ENDIF (WIN32)

View File

@ -4,21 +4,13 @@
INCLUDE(${CMAKE_ROOT}/Modules/FindCygwin.cmake)
IF (CYGWIN_INSTALL_PATH)
FIND_PROGRAM(PERL
perl
"C:/Perl/bin"
[HKEY_LOCAL_MACHINE\\SOFTWARE\\ActiveState\\ActivePerl\\628]/bin
${CYGWIN_INSTALL_PATH}/bin
)
FIND_PROGRAM(PERL
perl
"C:/Perl/bin"
[HKEY_LOCAL_MACHINE\\SOFTWARE\\ActiveState\\ActivePerl\\628]/bin
${CYGWIN_INSTALL_PATH}/bin
)
ELSE (CYGWIN_INSTALL_PATH)
FIND_PROGRAM(PERL
perl
"C:/Perl/bin"
[HKEY_LOCAL_MACHINE\\SOFTWARE\\ActiveState\\ActivePerl\\628]/bin
)
ENDIF (CYGWIN_INSTALL_PATH)
MARK_AS_ADVANCED(
PERL
)

View File

@ -8,37 +8,28 @@
INCLUDE(${CMAKE_ROOT}/Modules/FindCygwin.cmake)
IF (CYGWIN_INSTALL_PATH)
FIND_PROGRAM(SELF_PACKER_FOR_EXECUTABLE
upx
${CYGWIN_INSTALL_PATH}/bin
/bin
/usr/bin
/usr/local/bin
/sbin
)
FIND_PROGRAM(SELF_PACKER_FOR_EXECUTABLE
upx
${CYGWIN_INSTALL_PATH}/bin
)
FIND_PROGRAM(SELF_PACKER_FOR_SHARED_LIB
upx
${CYGWIN_INSTALL_PATH}/bin
/bin
/usr/bin
/usr/local/bin
/sbin
)
FIND_PROGRAM(SELF_PACKER_FOR_SHARED_LIB
upx
${CYGWIN_INSTALL_PATH}/bin
)
ELSE (CYGWIN_INSTALL_PATH)
FIND_PROGRAM(SELF_PACKER_FOR_EXECUTABLE
upx
/bin
/usr/bin
/usr/local/bin
/sbin
)
FIND_PROGRAM(SELF_PACKER_FOR_SHARED_LIB
upx
/bin
/usr/bin
/usr/local/bin
/sbin
)
ENDIF (CYGWIN_INSTALL_PATH)
MARK_AS_ADVANCED(
SELF_PACKER_FOR_EXECUTABLE
SELF_PACKER_FOR_SHARED_LIB
)
#
# Set flags
@ -58,3 +49,8 @@ ELSE (SELF_PACKER_FOR_SHARED_LIB MATCHES "upx")
SET (SELF_PACKER_FOR_SHARED_LIB_FLAGS "" CACHE STRING
"Flags for the shared lib self-packer.")
ENDIF (SELF_PACKER_FOR_SHARED_LIB MATCHES "upx")
MARK_AS_ADVANCED(
SELF_PACKER_FOR_EXECUTABLE_FLAGS
SELF_PACKER_FOR_SHARED_LIB_FLAGS
)

View File

@ -4,92 +4,77 @@
INCLUDE(${CMAKE_ROOT}/Modules/FindCygwin.cmake)
IF (CYGWIN_INSTALL_PATH)
FIND_PROGRAM(BASH
bash
${CYGWIN_INSTALL_PATH}/bin
/bin
/usr/bin
/usr/local/bin
/sbin
)
MARK_AS_ADVANCED(
BASH
)
FIND_PROGRAM(BASH
bash
${CYGWIN_INSTALL_PATH}/bin
)
FIND_PROGRAM(CP
cp
${CYGWIN_INSTALL_PATH}/bin
/bin
/usr/bin
/usr/local/bin
/sbin
)
MARK_AS_ADVANCED(
CP
)
FIND_PROGRAM(CP
cp
${CYGWIN_INSTALL_PATH}/bin
)
FIND_PROGRAM(GZIP
gzip
${CYGWIN_INSTALL_PATH}/bin
/bin
/usr/bin
/usr/local/bin
/sbin
)
MARK_AS_ADVANCED(
GZIP
)
FIND_PROGRAM(GZIP
gzip
${CYGWIN_INSTALL_PATH}/bin
)
FIND_PROGRAM(MV
mv
${CYGWIN_INSTALL_PATH}/bin
/bin
/usr/bin
/usr/local/bin
/sbin
)
MARK_AS_ADVANCED(
MV
)
FIND_PROGRAM(MV
mv
${CYGWIN_INSTALL_PATH}/bin
)
FIND_PROGRAM(RM
rm
${CYGWIN_INSTALL_PATH}/bin
/bin
/usr/bin
/usr/local/bin
/sbin
)
MARK_AS_ADVANCED(
RM
)
FIND_PROGRAM(RM
rm
${CYGWIN_INSTALL_PATH}/bin
)
FIND_PROGRAM(TAR
NAMES
tar
gtar
PATH
${CYGWIN_INSTALL_PATH}/bin
)
ELSE (CYGWIN_INSTALL_PATH)
FIND_PROGRAM(BASH
bash
/bin
/usr/bin
/usr/local/bin
/sbin
)
FIND_PROGRAM(CP
cp
/bin
/usr/bin
/usr/local/bin
/sbin
)
FIND_PROGRAM(GZIP
gzip
/bin
/usr/bin
/usr/local/bin
/sbin
)
FIND_PROGRAM(MV
mv
/bin
/usr/bin
/usr/local/bin
/sbin
)
FIND_PROGRAM(RM
rm
/bin
/usr/bin
/usr/local/bin
/sbin
)
FIND_PROGRAM(TAR
NAMES
tar
gtar
PATH
/bin
/usr/bin
/usr/local/bin
/sbin
)
ENDIF (CYGWIN_INSTALL_PATH)
FIND_PROGRAM(TAR
NAMES
tar
gtar
PATH
${CYGWIN_INSTALL_PATH}/bin
/bin
/usr/bin
/usr/local/bin
/sbin
)
MARK_AS_ADVANCED(
TAR
)

View File

@ -4,17 +4,11 @@
INCLUDE(${CMAKE_ROOT}/Modules/FindCygwin.cmake)
IF (CYGWIN_INSTALL_PATH)
FIND_PROGRAM(WGET
wget
${CYGWIN_INSTALL_PATH}/bin
)
FIND_PROGRAM(WGET
wget
${CYGWIN_INSTALL_PATH}/bin
)
ELSE (CYGWIN_INSTALL_PATH)
FIND_PROGRAM(WGET
wget
)
ENDIF (CYGWIN_INSTALL_PATH)
MARK_AS_ADVANCED(
WGET
)