~maddevelopers/mg5amcnlo/2.5.4_run_py8_at_evtgen

« back to all changes in this revision

Viewing changes to Template/NLO/Source/make_opts.inc

  • Committer: olivier Mattelaer
  • Date: 2016-05-12 11:00:18 UTC
  • mfrom: (262.1.150 2.3.4)
  • Revision ID: olivier.mattelaer@uclouvain.be-20160512110018-sevb79f0wm4g8mpp
pass to 2.4.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Environment variables
 
1
STDLIB = -lc++
 
2
STDLIB_FLAG = -stdlib=libc++
 
3
MACFLAG = -mmacosx-version-min=10.7
 
4
DEFAULT_F_COMPILER = gfortran
 
5
DEFAULT_F2PY_COMPILER = f2py
 
6
DEFAULT_CPP_COMPILER = g++
 
7
#end_of_make_opts_variables
2
8
 
 
9
# Rest of the makefile
3
10
ifeq ($(origin FFLAGS),undefined)
4
11
  #FFLAGS= -O -w
5
12
  FFLAGS = -O -fno-automatic
6
13
  #FFLAGS+= -g -fbounds-check -ffpe-trap=invalid,zero,overflow,underflow,denormal -Wall
7
14
endif
8
15
 
 
16
# REMOVE MACFLAG IF NOT ON MAC 
 
17
UNAME := $(shell uname -s)
 
18
ifneq ($(UNAME), Darwin)
 
19
    MACFLAG=  
 
20
endif
 
21
 
 
22
 
9
23
ifeq ($(origin CXXFLAGS),undefined)
10
24
  #CXXFLAGS= -g 
11
 
  CXXFLAGS = -O 
 
25
  CXXFLAGS = -O $(STDLIB_FLAG) $(MACFLAG)
12
26
endif
13
27
 
14
28
ifeq ($(origin CFLAGS),undefined)
15
29
  #CFLAGS= -g 
16
 
  CFLAGS = -O 
 
30
  CFLAGS = -O  $(STDLIB_FLAG) $(MACFLAG)
 
31
endif
 
32
 
 
33
# REMOVE MACFLAG IF IN F2PY mode
 
34
ifdef f2pymode
 
35
    MACFLAG= 
17
36
endif
18
37
 
19
38
# Increase the number of allowed charcters in a Fortran line
22
41
# Set FC unless it's defined by an environment variable
23
42
ifeq ($(origin FC),default)
24
43
#  FC=g77
25
 
  FC=gfortran
 
44
  FC=$(DEFAULT_F_COMPILER)
26
45
endif
27
46
# Set F2PY unless it's defined by an environment variable
28
47
ifeq ($(origin F2PY),undefined)
29
 
  F2PY=f2py
 
48
  F2PY=$(DEFAULT_F2PY_COMPILER)
30
49
endif
31
50
 
32
51
# Set CXX unless it's defined by an environment variable
33
52
ifeq ($(origin CXX),default)
34
 
  CXX=g++
 
53
  CXX=$(DEFAULT_CPP_COMPILER)
35
54
endif
36
55
 
 
56
UNAME := $(shell uname -s)
 
57
ifeq ($(origin LDFLAGS), undefined)
 
58
     LDFLAGS=$(STDLIB)
 
59
endif
37
60
# Options: dynamic, lhapdf
38
61
 
39
62
UNAME := $(shell uname)
67
90
# Option lhapdf
68
91
 
69
92
ifdef lhapdf
 
93
  CXXFLAGS += $(shell $(lhapdf) --cppflags)
70
94
  alfas_functions=alfas_functions_lhapdf
71
 
  lhapdf=-lLHAPDF -lstdc++
 
95
  llhapdf+=-lLHAPDF 
72
96
  reweight_xsec_events_pdf_dummy=
73
97
else
74
98
  alfas_functions=alfas_functions
75
 
  lhapdf=
 
99
  llhapdf=
76
100
  reweight_xsec_events_pdf_dummy=reweight_xsec_events_pdf_dummy.o
77
101
endif
78
102