]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - STARLIGHT/starlight/CMakeLists.txt
Updated STARLIGHT from r176 ro r188 (http://starlight.hepforge.org/svn/)
[u/mrichter/AliRoot.git] / STARLIGHT / starlight / CMakeLists.txt
index b66349c179cb1ae94f30261e49a4c50a70b1d26f..62f48487568353de99cac0f323be887d0280aa6d 100644 (file)
@@ -20,9 +20,9 @@
 ###########################################################################
 #
 # File and Version Information:
-# $Rev:: 165                         $: revision of last commit
-# $Author:: odjuvsla                 $: author of last commit
-# $Date:: 2013-10-06 16:18:10 +0200 #$: date of last commit
+# $Rev:: 186                         $: revision of last commit
+# $Author:: jnystrand                $: author of last commit
+# $Date:: 2014-09-12 02:39:02 +0200 #$: date of last commit
 #
 # Description:
 #      Starlight build file
@@ -49,12 +49,9 @@ set (Starlight_VERSION_MINOR_MINOR 0)
 project(starlight)
 find_package (Threads)
 
-
 # load some common cmake macros
 # set path, where to look first for cmake modules, before ${CMAKE_ROOT}/Modules/ is checked
-
-message(STATUS "Using cmake module path '${CMAKE_MODULE_PATH}'")
-set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake_modules ${CMAKE_MODULE_PATH})
+set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake_modules")
 message(STATUS "Using cmake module path '${CMAKE_MODULE_PATH}'")
 include(CommonMacros)
 
@@ -74,7 +71,7 @@ option (CPP11 "Enable compilation with C++11 features" OFF)
 
 # define build types
 # set a default build type for single-configuration CMake generators, if no build type is set.
-set(CMAKE_BUILD_TYPE RELWITHDEBINFO)
+set(CMAKE_BUILD_TYPE Debug)
 if(NOT CMAKE_CONFIGURATION_TYPES AND NOT CMAKE_BUILD_TYPE)
   message(STATUS "No build type was specified. Setting build type to 'Release'.")
   set(CMAKE_BUILD_TYPE Release)
@@ -94,14 +91,14 @@ if (CMAKE_COMPILER_IS_GNUCC)
     endif()
   else()
     message(STATUS "GCC_VERSION<4.6")
-    set(CMAKE_CXX_FLAGS "-Wall -Wextra ")
+    set(CMAKE_CXX_FLAGS "-Wall -Wextra -Werror")
     if(CPP11)
       message(WARNING "C++11 feautures not supported for your compiler")
     endif()
   endif()
 else()
   message(STATUS "Not GCC")
-  set(CMAKE_CXX_FLAGS "-Wall -Wextra")
+  set(CMAKE_CXX_FLAGS "-Wall -Wextra -Werror")
   if(CPP11)
     message(WARNING "C++11 feautures not supported for your compiler")
   endif()
@@ -219,21 +216,8 @@ if(ENABLE_DPMJET)
    else(DPMJET_FOUND)
       option (ENABLE_DPMJET  "Enable compilation against DPMJet" OFF)
    endif(DPMJET_FOUND)
-endif(ENABLE_DPMJET)
-
-# setup TStarLight
-option (ENABLE_TSTARLIGHT "Enable ROOT interface for Starlight" OFF)
-if(ENABLE_TSTARLIGHT)  
-  find_package(ROOT REQUIRED)
-  set(TSTARLIGHT_DICTIONARY ${CMAKE_CURRENT_BINARY_DIR}/TStarLight_dict.cxx)  # set dictionary path
-  root_generate_dictionary(
-    "${TSTARLIGHT_DICTIONARY}"                                  # path to dictionary to generate
-    "${CMAKE_SOURCE_DIR}/TStarLight;${CMAKE_SOURCE_DIR}/include;${ROOT_INCLUDE_DIR};"     # list of includes
-    "${CMAKE_SOURCE_DIR}/TStarLight/TStarLight.h"               # list of classes to process
-    "${CMAKE_SOURCE_DIR}/TStarLight/TStarLightLinkDef.h"        # ROOT linkDef file
-    )  
-  set(SOURCES_SL TStarLight/TStarLight.cxx ${TSTARLIGHT_DICTIONARY})  # append dictionary to sources  
-endif(ENABLE_TSTARLIGHT)
+ endif(ENABLE_DPMJET)
+
 
 # set include directories
 set(INCLUDE_DIRECTORIES
@@ -241,11 +225,6 @@ set(INCLUDE_DIRECTORIES
        ${PROJECT_BINARY_DIR}
 #      ${PYTHIA8_INCLUDE_DIR}
        )
-
-if(ENABLE_TSTARLIGHT)  
-  set(INCLUDE_DIRECTORIES ${ROOT_INCLUDE_DIR} ${INCLUDE_DIRECTORIES})
-endif(ENABLE_TSTARLIGHT)
-
 include_directories(${INCLUDE_DIRECTORIES})
 
 # Set our source files, include the generated dictionary
@@ -260,7 +239,6 @@ set(SOURCES
   src/nucleus.cpp
   src/eventchannel.cpp
   src/gammaavm.cpp
-  src/psifamily.cpp
   src/gammagammasingle.cpp
   src/photonNucleusCrossSection.cpp
   src/wideResonanceCrossSection.cpp
@@ -309,15 +287,6 @@ endif()
 # add Starlight library to the build system
 set(THIS_LIB "Starlib")
 add_library(${THIS_LIB} STATIC ${SOURCES})
-
-if(ENABLE_TSTARLIGHT)
-  ## build shared starlight library
-  set(THIS_LIB "StarLight")
-  add_library(${THIS_LIB} SHARED ${SOURCES})
-  include_directories(${INCLUDE_DIRECTORIES} ${CMAKE_SOURCE_DIR}/TStarLight ${ROOT_INCLUDE_DIR})
-  add_library(TStarLight SHARED ${SOURCES_SL})
-endif(ENABLE_TSTARLIGHT)
-
 #make_shared_library("${THIS_LIB}" "${SOURCES}"
 #      "${PYTHIA8_LIBRARY}"
 #      "${LHAPDF_LIBRARIES}"
@@ -329,6 +298,7 @@ if(ENABLE_DPMJET)
   message(STATUS "DPMJet objects: ${DPMJET_OBJECTS}")
   add_library(${DPMJET_LIB} STATIC dpmjet/dpmjetint.f ${DPMJET_OBJECTS})
   set(optionalLibs ${optionalLibs} ${DPMJET_LIB})
+
 endif()
 
 if(ENABLE_PYTHIA6)