message( WARNING "Found ${casaroot}/aipshosts. You probably don't need this file unless you need to build multiple architectures. If you remove aipshosts the name of the installation directory will be automatically set based on this machine's architecture, or defined by the cmake command line option -Darch=<arch name>. Specifying on the command line will override the aipshosts entry." )
# CASA - Common Astronomy Software Applications
# Copyright (C) 2010 by ESO (in the framework of the ALMA collaboration)
# Copyright (C) 2010 by NAOJ (in the framework of the ALMA collaboration)
# Copyright (C) 2010 Associated Universities, Inc. Washington DC, USA.
# This file is part of CASA.
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
cmake_minimum_required( VERSION 2.8 )
message (STATUS "Searching for ccache.")
find_program(CCACHE_FOUND ccache)
message (STATUS "Ccache found.")
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache)
set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache)
set( CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/install )
add_definitions ("-DUseCasacoreNamespace")
execute_process( COMMAND svn info
RESULT_VARIABLE SVNINFOSTATUS
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
message("SVNINFOSTATUS: ${SVNINFOSTATUS}")
if(${SVNINFOSTATUS} STREQUAL "0")
message("Running svn scripts.")
set( CASA_svngen ${CMAKE_SOURCE_DIR}/install/generate-svninfo )
execute_process( COMMAND %{CASA_svngen} "u=+%a %Y/%m/%d %H:%M:%S UTC"
OUTPUT_VARIABLE BUILDTIME
OUTPUT_STRIP_TRAILING_WHITESPACE
message("Couldn't detect svn. Not running svn scripts.")
set( CASA_svngen ${CMAKE_SOURCE_DIR}/install/generate-gitinfo )
execute_process( COMMAND %{CASA_svngen} "u=+%a %Y/%m/%d %H:%M:%S UTC"
OUTPUT_VARIABLE BUILDTIME
OUTPUT_STRIP_TRAILING_WHITESPACE