Newer
Older
# This is mainly here so you don't get a complaint when running cmake
cmake_minimum_required ( VERSION 2.6 )
# Add the path to our custom 'find' modules
set ( CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/Build/CMake")
# Define the project name.
project ( Mantid )
Russell Taylor
committed
# Set paths to Third_Party for Windows builds
if ( WIN32 )
Russell Taylor
committed
set ( THIRD_PARTY "${PROJECT_SOURCE_DIR}/../Third_Party" )
include ( WindowsSetup )
elseif ( CMAKE_COMPILER_IS_GNUCXX OR CMAKE_COMPILER_IS_GNUCC )
include ( GNUSetup )
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
endif ()
# Call our setup script
include ( CommonSetup )
# Now add the components
add_subdirectory ( Framework )
# Check for Qt
find_package ( Qt4 COMPONENTS QtCore QtGui QtOpenGL QtXml QtSvg Qt3Support REQUIRED )
include ( ${QT_USE_FILE} )
# Now qwt
find_package ( Qwt REQUIRED )
add_subdirectory ( QtPropertyBrowser )
include_directories ( Framework/Kernel/inc )
include_directories ( Framework/Geometry/inc )
include_directories ( Framework/API/inc )
set ( CORE_MANTIDLIBS Kernel Geometry API )
add_subdirectory ( MantidQt )
include_directories ( QtPropertyBrowser/src )
include_directories ( MantidQt/API/inc )
include_directories ( MantidQt/MantidWidgets/inc )
include_directories ( ${CMAKE_CURRENT_BINARY_DIR}/MantidQt/API )
include_directories ( ${CMAKE_CURRENT_BINARY_DIR}/MantidQt/MantidWidgets )
add_subdirectory ( MantidPlot )
set ( MAKE_VATES OFF CACHE BOOL "Switch for compiling the Vates project")
set ( CXXTEST_SINGLE_LOGFILE CACHE BOOL "Switch to have the tests for each package run together")
Michael Reuter
committed
if ( MAKE_VATES )
add_subdirectory ( Vates )
Michael Reuter
committed
endif ( MAKE_VATES )
# python unit tests
if (PYUNITTEST_FOUND)
add_subdirectory (Scripts)
endif ()