requirements-lite 5.84 KB
Newer Older
1 2
package CAMEL

3
#THE FOLLWING LINKS TO YOUR CLASS LIBRARY- YOU CAN TEST WHICH ONE IN YOUR
4
#SHELL WITH THE FOLLWING COMMAND :  cmt show uses
5 6
# you may put an explicit version instead of * (as v2.4.4 or v2.*...)
use class *
7

8 9 10
#CLASS optional FastPk access
#macro_append cppflags " -DFASTPK "

11 12 13 14 15 16 17 18 19

#COMPILER - TO EASE PAIN USE THE SAME THAN FOR CLASS/CLIK COMPILATION
# DEFAULT IS gcc SO DO NOT UNCOMMENT IF YOUR ARE HAPPY WITH THIS (EXAMPLE FOR CHANGING TO ICPC)
#macro cpp "icpc"

#COMPILER FLAGS for default=gcc
#C++ flags
macro cppflags " -O2 -pipe -ansi -Woverloaded-virtual -Wpedantic -Wunused -Wmaybe-uninitialized -Wno-deprecated -Wno-div-by-zero -Wno-variadic-macros"
# C flags
20
macro_append cpplinkflags  " -fopenmp "
21

22
# or for icpc (if you changed previously the compiler otherwise don't touch)
23 24 25 26 27 28
#macro cppflags " -O2  -ip -ansi_alias -align -Wbrief "

#
# CFITSIO IS REQUIRED. 
# include_dirs indicates the path to fitsio.h/ and CAMEL_linkopts teh
# link to the propoer library. In the following we use the one that was
29 30 31 32 33
# compiled when building CLIK but it can be also found
# in your /usr area. If the  library is shared you may need to update your
# LD_LIBRARY_PATH or uncomment the next line before sourcing camel_setup.sh
#path_append LD_LIBRARY_PATH "$(CLIKDIR)/lib"

34 35 36 37
include_dirs "$(CLIKDIR)/include"
macro_append  CAMEL_linkopts " -L$(CLIKDIR)/lib -lcfitsio"


38 39 40
# PLANCK CLIK support [optional]
# NB: you always have access to PLanck/Hillipop (high-ell) likelihood since
# it is native in CAMEL.
41 42 43 44 45 46 47 48 49 50 51
# CLIKCFLAGS and CLIKLIBS were defined when you ran: camel_setup.sh
#macro_append cppflags " -DCLIK  $(CLIKCFLAGS)"
#macro_append cflags " -DCLIK  $(CLIKCFLAGS)"
#macro_append  CAMEL_linkopts " $(CLIKLIBS) "
#macro_append  CAMEL_linkopts "-L$(CLIKDIR)/lib -lclik "
#application dump_clik -group=test -s=../src/camel test/test_clik.cc
#application dump_lensing -group=test -s=../src/camel test/test_lensing.cc


#JLA [optional] :requires cblas/lapack
# in most linux distributions packaged with the atlas library.
52 53
# if you installed CLIK you may also look for them in teh MKLROOT you used.
# macro_append cppflags ' -DJLA '
54 55 56 57 58 59
#include_dirs  "/usr/include/atlas"
#macro_append  CAMEL_linkopts " -L/usr/lib64/atlas -lcblas -llapack -ljla "
#application test_jla -group=test -s=../src/camel test/test_jla.cc


# PICO  [optional]
60 61 62 63 64 65
#macro_append cppflags " -DPICO $(PICOINC) "
#macro_append CAMEL_linkopts " -L$(PICO_CODE) -lpico -lpython2.7 "
# if the previous link fails try using the PICOLIBS defined in camel_setup.sh
#macro_append cppflags ' -DPICODATA=\"$(PICO_DATA)\" '
#application testPico -group=test -s=../src/camel/pico/exec testPico.cc

66 67 68 69 70 71 72
#macro_append cppflags " -DPICO "
#include_dirs "/usr/include/python2.7"
#include_dirs "/usr/lib64/python2.7/site-packages/numpy/core/include"
#include_dirs "$(PICO_CODE)/pypico"
#macro_append CAMEL_linkopts " -L$(PICO_CODE)/build/temp.linux-x86_64-2.7 -lpico -L/usr/lib64/python2.7/config -lpython2.7 "
#macro_append cppflags ' -DPICODATA=\"$(PICO_DATA)\" '
#application testPico -group=test -s=../src/camel/pico/exec testPico.cc
73
#application FitClassFromPico -group=exec -s=../src/camel exec/FitClassFromPico.cc
74
###########################################################################################
75
###FROM THERE YOU SHOUL NOT NEED TO TOUCH ANYTHING
76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98
###########################################################################################
#CAMEL includes
include_dirs " ../src"
include_dirs "../src/camel"
include_dirs "../src/Minuit2-5.28.00/src"
include_dirs "../src/Minuit2-5.28.00/inc"
include_dirs  "../src/cxxsupport"
include_dirs  "../src/AbsRand"
include_dirs  "../src/camel/JLA"
include_dirs  "../src/camel/JLA/jla_likelihood_v3/src"

#CAMEL LIBRARIES
library Minuit -no_share ../src/Minuit2-5.28.00/src/*.cxx
library Util -no_share -x=ddl.cc ../src/cxxsupport/*.cc
library AbsRand -no_share ../src/AbsRand/*.cc
library CLHEP -no_share ../src/CLHEP/src/*.cc
library jla  -no_share ../src/camel/JLA/jla_likelihood_v3/src/ini.c ../src/camel/JLA/jla_likelihood_v3/src/jla.cc

macro camelsrc "*.cc CMB/*.cc BAO/*.cc Lensing/*.cc pico/*.cc JLA/*.cc Class/*.cc Constraints/*.cc"
library MinuitFit  -no_share -s=../src/camel $(camelsrc)
library MCMC  -no_share  -s=../src/camel/MCMC *.cc

macro CAMEL_linkopts "-L$(CAMEL_root)/${CMTCONFIG} -lMinuitFit -lMinuit -lMCMC -lCLHEP -lAbsRand -lUtil "
99
macro_append cppflags ' -DRELPATH=\"$(CAMELROOT)/lik\" '
100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135


#CAMEL applications
# pour relinker si changement: toutes les application du package
macro CAMEL_stamps $(PACKAGE_ROOT)/$(CMTCONFIG)/MinuitFit.stamp
macro application_suffix ""

#groupe exec: to build run: make exec
application writeChi2 -group=exec -s=../src/camel exec/writeChi2.cc
application writeSpectra -group=exec -s=../src/camel exec/writeSpectra.cc
application Minimize -group=exec -s=../src/camel exec/Minimize.cc
application ScanParam -group=exec -s=../src/camel exec/ScanParam.cc
application mcmc -group=exec -s=../src/camel/MCMC exec/mainMCMC.cc

#tests
application testKlass -group=test -s=../src/camel test/testKlass.cc
application testCLHEP -group=test -s=../src/camel/test testCLHEP.cc
application testBAO -group=test -s=../src/camel/test testBAO.cc
application testHiLLiPOP -group=test -s=../src/camel/test testHiLLiPOP.cc

#lIST OF ALL DEPENDENCIES
macro_append Minimize_dependencies " MinuitFit "
macro_append ScanParam_dependencies " MinuitFit "
macro_append writeChi2_dependencies " MinuitFit "
macro_append writeSpectra_dependencies " MinuitFit "
macro_append mcmc_dependencies " MinuitFit MCMC"
macro_append testKlass_dependencies " MinuitFit"
macro_append clik_example_CC_dependencies " MinuitFit "
macro_append test_clik_dependencies " MinuitFit "
macro_append test_lensing_dependencies " MinuitFit "
macro_append testCLHEP_dependencies " CLHEP "
macro_append testBAO_dependencies " MinuitFit "
macro_append testHiLLiPOP_dependencies " MinuitFit "
macro_append test_jla_dependencies " MinuitFit "
macro_append testPico_dependencies " MinuitFit "