Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/lod/cmake/CheckTardis.cmake @ 2390

Last change on this file since 2390 was 1505, checked in by rgrieder, 16 years ago

f* svn: It doesn't even inform you if you attempt to set a non existing property. It is svn:eol-style and not eol-style when using the command by the way…

  • Property svn:eol-style set to native
File size: 889 bytes
Line 
1################# Tardis check ##################
2# This code checks whether the current machine  #
3# is an ETH tardis box.                         #
4#################################################
5
6# only run this test on a lunix/unix machine
7IF (UNIX)
8
9  FIND_PROGRAM(UNAME_CMD "uname"
10  PATHS "/usr/bin /bin")
11  IF(NOT UNAME_CMD)
12    MESSAGE(ERROR "Unable to find uname. Tardis-Check cannot be done.")
13  ENDIF(NOT UNAME_CMD)
14
15  # run uname -n to get nodename
16  EXECUTE_PROCESS(
17  COMMAND "${UNAME_CMD}" "-n"
18  RESULT_VARIABLE UNAME_RV
19  ERROR_VARIABLE UNAME_EV
20  OUTPUT_VARIABLE UNAME_OV)
21
22  IF (NOT "${UNAME_RV}" STREQUAL "0")
23    MESSAGE(ERROR "ERROR: uname terminated unclean.")
24  ENDIF (NOT "${UNAME_RV}" STREQUAL "0")
25
26  # check wheter we are on a tardis machine
27  IF ("${UNAME_OV}" MATCHES "tardis")
28    SET (IS_TARDIS ON)
29  ENDIF ("${UNAME_OV}" MATCHES "tardis")
30
31ENDIF (UNIX)
Note: See TracBrowser for help on using the repository browser.