source: PSPA/madxPSPA/make/compiler.cl @ 442

Last change on this file since 442 was 430, checked in by touze, 11 years ago

import madx-5.01.00

File size: 2.1 KB
Line 
1# |
2# o---------------------------------------------------------------------o
3# |
4# | MAD makefile - cl compiler settings (Visual Studio C++)
5# |
6# o---------------------------------------------------------------------o
7# |
8# | Methodical Accelerator Design
9# |
10# | Copyright (c) 2011+ CERN, mad@cern.ch
11# |
12# | For more information, see http://cern.ch/mad
13# |
14# o---------------------------------------------------------------------o
15# |
16# | $Id$
17# |
18
19#####################
20# CL specific
21#
22
23#
24# preprocessor flags
25#
26
27CPPFLAGS += -D_MCC
28
29#
30# command translator
31#
32
33CL_CC1 := -D%  -I% /O3 /O0
34CL_CC2 := /D%  /I% /O2 /Od
35
36###############
37# C language
38#
39
40ifeq ($(CCNAME),cl)
41
42#
43# makedep
44#
45
46ifneq ($(and $(SED),$(GREP)),)
47CDEP = $(CC) /nologo /c /Zs /showIncludes
48CDEP_tr = | $(GREP) -i -F "$(call f1bs,$(CURDIR))" \
49          | $(SED)  -e "s/$(call f2bs,$(CURDIR)/)//gi" \
50                    -e "s/Note: including file:/$<:/gi" \
51                    -e "s/\.c:/\.o:/g"
52endif
53
54#
55# compiler flags
56#
57
58CFLAGS = /O$(NOPT) /c # /Wall
59
60#
61# options flags
62#
63
64ifeq ($(DEBUG),yes)
65CFLAGS += /Zi /Yd
66endif
67
68ifeq ($(PROFILE),yes)
69CFLAGS +=
70endif
71
72#
73# extra flags
74#
75
76CFLAGS += /nologo /fp:precise /Zm1000 /EHsc /D_CRT_SECURE_NO_WARNINGS /Dinline=__inline
77
78#
79# command translator
80#
81
82CC_tr = $(strip $(subst $(SPACE)-o , /Fo,$(call trans,$(CL_CC1),$(CL_CC2),$1)))
83
84endif
85
86###############
87# C++ language
88#
89
90ifeq ($(CXXNAME),cl)
91
92#
93# makedep
94#
95
96ifneq ($(and $(SED),$(GREP)),)
97CXXDEP = $(CC) /nologo /c /Zs /showIncludes
98CXXDEP_tr = | $(GREP) -i -F "$(call f1bs,$(CURDIR))" \
99            | $(SED)  -e "s/$(call f2bs,$(CURDIR)/)//gi" \
100                      -e "s/Note: including file:/$<:/gi" \
101                      -e "s/\.c:/\.o:/g"
102endif
103
104#
105# compiler flags
106#
107
108CXXFLAGS = /O$(NOPT) /c # /Wall
109
110#
111# options flags
112#
113
114ifeq ($(DEBUG),yes)
115CXXFLAGS += /Zi /Yd
116endif
117
118ifeq ($(PROFILE),yes)
119CXXFLAGS +=
120endif
121
122#
123# extra flags
124#
125
126CXXFLAGS += /nologo /fp:precise /Zm1000 /EHsc /D_CRT_SECURE_NO_WARNINGS /Dinline=__inline
127
128#
129# command translator
130#
131
132CXX_tr = $(strip $(subst $(SPACE)-o , /Fo,$(call trans,$(CL_CC1),$(CL_CC2),$1)))
133
134endif
135
136# end of makefile
Note: See TracBrowser for help on using the repository browser.