Copy generator's rule name when cloning
[boost.git] / BuildSlave.cmake
blobec8a1253902b44f0c383e7f57eae038b61d11105
1 ##########################################################################
2 # Boost Build Slave Support                                              #
3 ##########################################################################
4 # Copyright (C) 2008 Troy D. Straszheim                                  #
5 #                                                                        #
6 # Distributed under the Boost Software License, Version 1.0.             #
7 # See accompanying file LICENSE_1_0.txt or copy at                       #
8 #   http://www.boost.org/LICENSE_1_0.txt                                 #
9 ##########################################################################
11 # Quick configuration of build slaves. 
12
13 # 1. Copy this file to your (empty, newly created) build directory
14 # 2. Customize below where you see CUSTOMIZE
15 # 3. Use this file to populate your build directory.  From the build
16 #    directory execute:
17 #     
18 #      cmake -C path/to/this/file ../path/to/source/directory   
19
20 #    e.g.
21 #  
22 #      cmake -C BuildSlave.cmake ../src
25 message (STATUS "Reading initial cache for build slaves.")
27
28 #  CUSTOMIZE
30 set(BOOST_BUILD_SLAVE_CONTACT_INFO "buildmeister@example.com"
31     CACHE STRING "who to contact with questions" FORCE)
33 set(BOOST_BUILD_SLAVE_HOSTNAME "descriptive.name.of.host.example.com"
34     CACHE STRING "descriptive hostname" FORCE)
36
37 #  CUSTOMIZE: Either set this to the path of an existing file 
38 #  (relative to build directory) or create the file slave-description.txt
40 set(BOOST_BUILD_SLAVE_DETAILS_FILE "slave-description.txt"
41     CACHE STRING "file containing details about the build/platform" FORCE)
44 #   Below this line oughtn't require customization.
46 if(EXISTS ${BOOST_BUILD_SLAVE_DETAILS_FILE})
47   message(STATUS "Will take build details from ${BOOST_BUILD_SLAVE_DETAILS_FILE}")
48 else(EXISTS ${BOOST_BUILD_SLAVE_DETAILS_FILE})
49   message(FATAL_ERROR "Please configure BOOST_BUILD_SLAVE_DETAILS_FILE (${BOOST_BUILD_SLAVE_DETAILS_FILE}) and create this file")           
50 endif(EXISTS ${BOOST_BUILD_SLAVE_DETAILS_FILE})
52 if(WIN32)
53   set(CMAKE_GENERATOR "NMake Makefiles" CACHE INTERNAL "generator" FORCE)
54   set(CMAKE_MAKE_PROGRAM "nmake" CACHE INTERNAL "nmake" FORCE)
55 endif(WIN32)
57 set(BUILD_TESTING ON
58     CACHE BOOL "build testing" FORCE)
60 set(BOOST_BUILD_SLAVE ON 
61     CACHE BOOL "build slave mode" FORCE)