Merge pull request #39 from jwillemsen/jwi-bcc32c
[MPC.git] / templates / make.mpd
blob306a929df235b38e8bbbe5c655fc5c1e14c75abf
1 #----------------------------------------------------------------------------
2 #       Macros
3 #----------------------------------------------------------------------------
4 <%marker(top)%>
5 <%if(multiple(configurations) || multiple(platforms))%>
6 <%if(default_configuration)%>
7 CFG = <%default_configuration%>
8 <%else%>
9 <%foreach(configurations)%>
10 <%if(forfirst)%>
11 <%if(multiple(platforms))%>
12 <%foreach(platforms)%>
13 <%if(forfirst)%>
14 CFG = <%platform%> <%configuration%>
15 <%endif%>
16 <%endfor%>
17 <%else%>
18 CFG = <%configuration%>
19 <%endif%>
20 <%endif%>
21 <%endfor%>
22 <%endif%>
24 <%endif%>
25 <%foreach(compilers)%>
26 <%foreach(platforms)%>
27 <%foreach(configurations)%>
28 <%if(multiple(platforms))%>
29 ifeq ($(CFG), <%platform%> <%configuration%>)
30 <%else%>
31 <%if(multiple(configurations))%>
32 ifeq ($(CFG), <%configuration%>)
33 <%endif%>
34 <%endif%>
35 CC            = <%cc%>
36 CXX           = <%cxx%>
37 <%if(ld)%>
38 LD            = <%ld%>
39 <%else%>
40 LD            = $(CXX) $(CCFLAGS) $(CPPFLAGS)
41 <%endif%>
42 AR            = <%ar("ar")%>
43 <%if(nm)%>
44 NM            = <%nm%>
45 <%endif%>
46 <%if(cxxint)%>
47 CXXINT        = <%cxxint%>
48 <%endif%>
49 <%if(cputype)%>
50 CPUTYPE       = <%cputype%>
51 <%endif%>
52 <%if(cpu)%>
53 CPU           = <%cpu%>
54 <%endif%>
55 <%if(dll_ext && pic)%>
56 PICFLAGS      = <%pic%>
57 <%endif%>
58 <%if(cflags)%>
59 CFLAGS        = <%cflags%>
60 <%endif%>
61 <%if(ccflags)%>
62 CCFLAGS       = <%ccflags%>
63 <%endif%>
64 CPPFLAGS      = <%if(visibility && visopt)%><%visopt%> <%endif%>$(PICFLAGS) $(GENFLAGS)<%if(compile_flags)%> <%compile_flags%><%endif%><%if(profile)%> <%profopt%><%endif%><%if(coverage)%> <%covopt%><%endif%><%if(cpu)%> -DCPU=$(CPU)<%endif%><%if(tempincopt)%> <%tempincopt%>$(TEMPINCDIR)<%endif%><%if(compilerflags)%> <%compilerflags%><%endif%><%if(build64bit && compilerflags64)%> <%compilerflags64%><%endif%><%if(pch_source && pchsupport)%><%foreach(pch_defines)%> -D<%pch_define%><%endfor%><%endif%><%if(extracppflags)%><%foreach(extracppflags)%><%if(!starts_with(extracppflag, -D) || !contains(language, java))%> <%extracppflag%><%endif%><%endfor%><%endif%><%if(includes)%><%foreach(includes)%> -I"<%include%>"<%endfor%><%endif%><%if(!contains(language, java) && macros)%><%foreach(macros)%> -D<%macro%><%endfor%><%endif%>
65 OBJEXT        = <%obj_ext%>
66 OUTPUT_OPTION = <%output_option(-o \"$@\")%>
67 COMPILE.c     = $(CC) $(CFLAGS) $(CPPFLAGS) <%compile_option("-c")%>
68 COMPILE.cc    = $(CXX) $(CCFLAGS) $(CPPFLAGS) <%compile_option%>
69 <%if(rc)%>
70 RESEXT        = <%res_ext%>
71 <%endif%>
72 <%if(build64bit && arflags64)%>
73 ARFLAGS       = <%if(extraarflags)%><%extraarflags%> <%endif%><%arflags64%>
74 <%else%>
75 <%if(arflags)%>
76 ARFLAGS       = <%if(extraarflags)%><%extraarflags%> <%endif%><%arflags%>
77 <%endif%>
78 <%endif%>
79 <%if(tempinc)%>
80 TEMPINCDIR    = <%tempinc%><%if(tempincopt)%><%slash%><%project_name%><%endif%>
81 <%endif%>
82 LDFLAGS       =<%if(libpaths)%><%foreach(libpaths)%><%if(targetoutdir)%> <%libpathopt(-L)%>"<%libpath%><%slash%><%targetoutdir%>"<%endif%> <%libpathopt(-L)%>"<%libpath%>"<%endfor%><%endif%><%if(linkflags)%> <%linkflags%><%endif%><%if(profile)%> <%profopt%><%endif%><%if(coverage)%> <%covopt%><%endif%><%if(build64bit && linkflags64)%> <%linkflags64%><%endif%>
83 CCC           = $(CXX)
84 MAKEFILE      = <%project_file%>
85 DEPENDENCIES  = <%if(supports_include)%>.depend.<%endif%>$(MAKEFILE)
86 <%if(exename)%>
87 BTARGETDIR    = <%if(exeout)%><%exeout%><%output_dir_ext%><%else%>.<%endif%><%slash%><%targetoutdir%>
88 BIN           = $(BTARGETDIR)<%exename%>$(EXESUFFIX)$(EXEEXT)
89 <%else%>
90 LTARGETDIR    = <%libout%><%if(!compares(libout, .))%><%output_dir_ext%><%endif%><%slash%><%targetoutdir%>
91 <%endif%>
92 CAT           = <%type("cat")%>
93 MV            = <%move("mv -f")%>
94 RM            = <%delete("rm -rf")%>
95 CP            = <%copy("cp -p")%>
96 NUL           = <%devnull("/dev/null")%>
97 MKDIR         = <%makedir("mkdir -p")%>
98 TESTDIRSTART  = <%testdirstart("test -d")%>
99 TESTDIREND    = <%testdirend("||")%>
100 TOUCH         = <%touch("touch")%>
101 EXEEXT        = <%exe_ext%>
102 LIBPREFIX     = <%lib_prefix%><%libname_prefix%>
103 <%if(use_lib_modifier)%>
104 LIBSUFFIX     = <%lib_modifier%>
105 <%endif%>
106 <%if(use_exe_modifier)%>
107 EXESUFFIX     = <%lib_modifier%>
108 <%endif%>
109 GENFLAGS      =<%if(!contains(configuration, Release) || optimize)%> <%genflags%><%endif%>
110 <%if(link_lib_name)%>
111 LDLIBS        =<%foreach(libs)%> "$(LIBPREFIX)<%lib%>$(LIBSUFFIX)<%lib_ext%>"<%endfor%><%foreach(lit_libs)%> "$(LIBPREFIX)<%lit_lib%><%lib_ext%>"<%endfor%><%foreach(pure_libs)%> "<%pure_lib%>"<%endfor%> <%ldlibs%>
112 <%else%>
113 LDLIBS        =<%foreach(libs)%> <%libopt%>"<%libname_prefix%><%lib%>$(LIBSUFFIX)"<%endfor%><%foreach(lit_libs)%> <%libopt%>"<%lit_lib%>"<%endfor%><%foreach(pure_libs)%> "<%pure_lib%>"<%endfor%> <%ldlibs%>
114 <%endif%>
115 OBJS          =<%if(pch_source && pchsupport)%> <%targetoutdir%><%obj_dir%><%noextension(pch_source)%>$(OBJEXT)<%endif%><%foreach(source_files)%> <%if(targetoutdir || obj_dir)%><%targetoutdir%><%obj_dir%><%transdir(source_file)%><%basenoextension(source_file)%><%else%><%noextension(source_file)%><%endif%>$(OBJEXT)<%endfor%><%if(rc)%><%foreach(resource_files)%> <%targetoutdir%><%obj_dir%><%resource_file%>$(RESEXT)<%endfor%><%endif%>
116 <%if(lib_ext)%>
117 <%if(staticname)%>
118 AREXT         = <%lib_ext%>
119 LIB           = $(LTARGETDIR)$(LIBPREFIX)<%staticname%>$(LIBSUFFIX)$(AREXT)
120 <%endif%>
121 <%endif%>
122 <%if(dll_ext && sharedname)%>
123 SOEXT         = <%dll_ext%>
124 SHTARGETDIR   = <%if(dllout)%><%dllout%><%if(!compares(dllout, .))%><%output_dir_ext%><%endif%><%else%><%libout%><%if(!compares(libout, .))%><%output_dir_ext%><%endif%><%endif%><%slash%><%targetoutdir%>
125 <%if(version && versupport)%>
126 SHLIB_BASE    = $(LIBPREFIX)<%sharedname%>$(LIBSUFFIX)$(SOEXT)
127 <%endif%>
128 SHLIB         = $(SHTARGETDIR)$(LIBPREFIX)<%sharedname%>$(LIBSUFFIX)$(SOEXT)
129 <%if(shflags)%>
130 SHFLAGS       = <%shflags%>
131 <%endif%>
132 <%endif%>
133 SRC           =<%if(pch_source && pchsupport)%> <%pch_source%><%endif%> <%source_files%>
134 LINK.cc       = <%if(dld)%><%dld%> $(LDFLAGS)<%else%>$(LD) $(LDFLAGS)<%endif%>
135 <%if(!contains(language, java))%>
136 <%if(dynamicflags)%>
137 DYNAMICFLAGS  =<%foreach(dynamicflags)%> -D<%dynamicflag%><%endfor%>
138 <%endif%>
139 <%if(staticflags)%>
140 STATICFLAGS   =<%foreach(staticflags)%> -D<%staticflag%><%endfor%>
141 <%endif%>
142 EXPORTFLAGS   = <%if(exename)%><%if(need_staticflags)%>$(STATICFLAGS)<%endif%><%else%><%if(dll_ext && sharedname)%>$(DYNAMICFLAGS)<%else%>$(STATICFLAGS)<%endif%><%endif%>
143 <%endif%>
144 <%if(gnumake && libpaths)%>
145 <%if(exename || sharedname)%>
146 DEPLIBS       = $(foreach lib,<%foreach(libs)%> <%libname_prefix%><%lib%>$(LIBSUFFIX)<%endfor%> <%lit_libs%>, $(foreach libpath,<%foreach(libpaths)%><%if(targetoutdir)%> <%libpath%>/<%targetoutdir%><%endif%> <%libpath%><%endfor%>, $(wildcard $(libpath)/lib$(lib)<%lib_ext(".a")%>)))
147 <%endif%>
148 <%endif%>
149 <%if(multiple(configurations) || multiple(platforms))%>
150 endif
151 <%endif%>
152 <%endfor%>
153 <%if(supports_include && make_include)%>
155 include <%make_include%>
156 <%endif%>
157 <%marker(macros)%>
159 #----------------------------------------------------------------------------
160 #       Local targets
161 #----------------------------------------------------------------------------
163 <%if(exename)%>
164 all:<%if(prebuild)%> __prebuild__<%endif%> $(BIN)<%if(postbuild)%> __postbuild__<%endif%>
166 <%if(specialscript)%>
167 specialscript:
168         @echo '<%specialscript%>' > $@
169         @<%chmod("chmod")%> 755 $@
171 <%endif%>
172 <%if(prelinktarget)%>
173 <%prelinktarget%>: specialscript $(OBJS)
174         @specialscript "$(NM)" "$(OBJS)" "$(LDLIBS)" "<%if(libpaths)%><%foreach(libpaths)%><%if(targetoutdir)%><%libpath%><%slash%><%targetoutdir%> <%endif%><%libpath%><%fornotlast(" ")%><%endfor%><%else%>.<%endif%>" "$(BIN)" "$@"
175         @$(RM) specialscript
177 <%if(prelinktargetobj)%>
178 <%targetoutdir%><%obj_dir%><%prelinktargetobj%>: <%prelinktarget%>
179         $(COMPILE.cc) $(OUTPUT_OPTION) <%prelinktarget%>
180         @$(RM) <%prelinktarget%>
182 <%endif%>
183 <%endif%>
184 $(BIN):<%if(tempinc)%> $(TEMPINCDIR)<%endif%><%if(prelinktargetobj)%> <%targetoutdir%><%obj_dir%><%prelinktargetobj%><%else%><%if(prelinktarget)%> <%prelinktarget%><%endif%><%endif%> $(OBJS)<%if(gnumake && libpaths)%> $(DEPLIBS)<%endif%>
185         @$(TESTDIRSTART) "$(BTARGETDIR)" $(TESTDIREND) $(MKDIR) "$(BTARGETDIR)"
186 <%if(prelink)%>
187         <%eval(prelink)%>
188 <%endif%>
189         $(LINK.cc) $(OBJS) $(LDLIBS)<%if(exe_linkflags)%> <%eval(exe_linkflags)%><%endif%> $(OUTPUT_OPTION)
190 <%if(postlinkbinary)%>
191         <%postlinkbinary%>
192 <%endif%>
194 <%endif%>
195 <%if(dll_ext && sharedname)%>
196 all:<%if(prebuild)%> __prebuild__<%endif%><%if(version && versupport)%> $(SHLIB).<%version%><%endif%> $(SHLIB)<%if(postbuild)%> __postbuild__<%endif%>
198 <%if(version && versupport)%>
199 $(SHLIB):
200         cd $(SHTARGETDIR) && ln -s $(SHLIB_BASE).<%version%> $(SHLIB_BASE)
202 <%endif%>
203 $(SHLIB)<%if(version && versupport)%>.<%version%><%endif%>: <%if(tempinc)%>$(TEMPINCDIR) <%endif%>$(OBJS)<%if(gnumake && libpaths)%> $(DEPLIBS)<%endif%>
204         @$(TESTDIRSTART) "$(SHTARGETDIR)" $(TESTDIREND) $(MKDIR) "$(SHTARGETDIR)"
205 <%if(prelink)%>
206         <%eval(prelink)%>
207 <%endif%>
208 <%if(dmclink)%>
209         link /impl <%if(pch_source && pchsupport)%><%targetoutdir%><%obj_dir%><%noextension(pch_source)%>$(OBJEXT)+<%endif%><%foreach(source_files)%><%if(targetoutdir || obj_dir)%><%targetoutdir%><%obj_dir%><%transdir(source_file)%><%basenoextension(source_file)%><%else%><%noextension(source_file)%><%endif%>$(OBJEXT)<%fornotlast("+")%><%endfor%>,$@,<%ldlibs%><%if(rc)%><%foreach(resource_files)%><%forfirst(",,")%><%targetoutdir%><%obj_dir%><%resource_file%>$(RESEXT)<%fornotlast("+")%><%endfor%><%endif%>
210 <%else%>
211         $(LINK.cc) $(SHFLAGS) $(OBJS) $(LDLIBS) $(OUTPUT_OPTION)
212 <%endif%>
214 <%else%>
215 <%if(staticname)%>
216 all:<%if(prebuild)%> __prebuild__<%endif%> $(LIB)<%if(postbuild)%> __postbuild__<%endif%>
218 <%endif%>
219 <%endif%>
220 <%if(staticname)%>
221 $(LIB): <%if(tempinc)%>$(TEMPINCDIR) <%endif%>$(OBJS)
222         @$(TESTDIRSTART) "$(LTARGETDIR)" $(TESTDIREND) $(MKDIR) "$(LTARGETDIR)"
223         $(AR) $(ARFLAGS) <%libgenopt%>$(LIB) $(OBJS)<%if(tempinc)%> `find $(TEMPINCDIR) -name \*.o\*`<%endif%>
224 <%if(ranlib)%>
225         ranlib $(LIB)
226 <%endif%>
228 <%endif%>
229 <%if(custom_types)%>
230 <%if(gnumake)%>
231 SPACE           = $(should_be_unset) $(should_be_unset)
232 <%endif%>
233 GENERATED_DIRTY =<%foreach(custom_types)%><%foreach(custom_type->input_files)%><%if(custom_type->input_file->output_files)%><%foreach(custom_type->input_file->output_files)%> <%if(flag_overrides(custom_type->input_file, gendir))%><%flag_overrides(custom_type->input_file, gendir)%><%slash%><%basename(custom_type->input_file->output_file)%><%else%><%custom_type->input_file->output_file%><%endif%><%endfor%><%endif%><%endfor%><%endfor%>
235 <%if(!source_files)%>
236 all:<%if(prebuild)%> __prebuild__<%endif%> $(GENERATED_DIRTY)<%if(postbuild)%> __postbuild__<%endif%>
238 <%endif%>
239 <%foreach(custom_types)%>
240 <%if(expanded_variable_assignment && custom_type->libpath)%>
241 DYLD_LIBRARY_PATH := $(DYLD_LIBRARY_PATH):<%custom_type->libpath%>
242 LD_LIBRARY_PATH   := $(LD_LIBRARY_PATH):<%custom_type->libpath%>
243 SHLIB_PATH        := $(SHLIB_PATH):<%custom_type->libpath%>
244 LIBPATH           := $(LIBPATH):<%custom_type->libpath%>
245 PATH              := $(PATH):<%custom_type->libpath%>
247 <%endif%>
248 <%foreach(custom_type->input_files)%>
249 <%if(custom_type->input_file->output_files)%>
250 <%if(notparallel && multiple(custom_type->input_file->output_files))%>
251 .NOTPARALLEL:
252 <%endif%>
253 <%foreach(custom_type->input_file->output_files)%><%if(flag_overrides(custom_type->input_file, gendir))%><%flag_overrides(custom_type->input_file, gendir)%><%slash%><%basename(custom_type->input_file->output_file)%><%else%><%custom_type->input_file->output_file%><%endif%><%fornotlast(" ")%><%endfor%>: <%custom_type->input_file%><%if(custom_type->input_file->dependencies)%><%foreach(custom_type->input_file->dependencies)%><%if(gnumake)%><%if(contains(custom_type->input_file->dependencie, \$))%> $(subst $(SPACE),\$(SPACE),<%custom_type->input_file->dependencie%>)<%else%> <%scope(enter, escape, \\s)%><%custom_type->input_file->dependencie%><%scope(leave)%><%endif%><%else%><%if(!contains(custom_type->input_file->dependencie, \$))%> <%scope(enter, escape, \\s)%><%custom_type->input_file->dependencie%><%scope(leave)%><%endif%><%endif%><%endfor%><%endif%><%if(flag_overrides(custom_type->input_file, dependent))%><%foreach(dep, flag_overrides(custom_type->input_file, dependent))%><%if(gnumake)%><%if(contains(dep, \$))%> $(subst $(SPACE),\$(SPACE),<%dep%>)<%else%> <%scope(enter, escape, \\s)%><%dep%><%scope(leave)%><%endif%><%else%><%if(!contains(dep, \$))%> <%scope(enter, escape, \\s)%><%dep%><%scope(leave)%><%endif%><%endif%><%endfor%><%else%><%if(custom_type->dependent)%><%foreach(custom_type->dependent)%><%if(gnumake)%><%if(contains(custom_type->dependent, \$))%> $(subst $(SPACE),\$(SPACE),<%custom_type->dependent%>)<%else%> <%scope(enter, escape, \\s)%><%custom_type->dependent%><%scope(leave)%><%endif%><%else%><%if(!contains(custom_type->dependent, \$))%> <%scope(enter, escape, \\s)%><%custom_type->dependent%><%scope(leave)%><%endif%><%endif%><%endfor%><%endif%><%endif%><%if(!need_staticflags)%><%if(flag_overrides(custom_type->input_file, dependent_libs))%><%foreach(dep_lib, flag_overrides(custom_type->input_file, dependent_libs))%><%if(gnumake)%><%if(contains(dep_lib, \$))%> $(subst $(SPACE),\$(SPACE),<%dirname(dep_lib)%>/$(LIBPREFIX)<%basename(dep_lib)%>$(LIBSUFFIX)$(SOEXT))<%else%> <%scope(enter, escape, \\s)%><%dirname(dep_lib)%>/$(LIBPREFIX)<%basename(dep_lib)%>$(LIBSUFFIX)$(SOEXT)<%scope(leave)%><%endif%><%else%><%if(!contains(dep_lib, \$))%> <%scope(enter, escape, \\s)%><%dirname(dep_lib)%>/$(LIBPREFIX)<%basename(dep_lib)%>$(LIBSUFFIX)$(SOEXT)<%scope(leave)%><%endif%><%endif%><%endfor%><%else%><%if(custom_type->dependent_libs)%><%foreach(custom_type->dependent_libs)%><%if(gnumake)%><%if(contains(custom_type->dependent_libs, \$))%> $(subst $(SPACE),\$(SPACE),<%dirname(custom_type->dependent_lib)%>/$(LIBPREFIX)<%basename(custom_type->dependent_lib)%>$(LIBSUFFIX)$(SOEXT))<%else%> <%scope(enter, escape, \\s)%><%dirname(custom_type->dependent_lib)%>/$(LIBPREFIX)<%basename(custom_type->dependent_lib)%>$(LIBSUFFIX)$(SOEXT)<%scope(leave)%><%endif%><%else%><%if(!contains(custom_type->dependent_libs, \$))%> <%scope(enter, escape, \\s)%><%dirname(custom_type->dependent_lib)%>/$(LIBPREFIX)<%basename(custom_type->dependent_lib)%>$(LIBSUFFIX)$(SOEXT)<%scope(leave)%><%endif%><%endif%><%endfor%><%endif%><%endif%><%endif%>
254 <%if(flag_overrides(custom_type->input_file, gendir))%>
255         @$(TESTDIRSTART) "<%flag_overrides(custom_type->input_file, gendir)%>" $(TESTDIREND) $(MKDIR) "<%flag_overrides(custom_type->input_file, gendir)%>"
256 <%endif%>
257         <%if(flag_overrides(custom_type->input_file, command))%><%flag_overrides(custom_type->input_file, command)%><%else%><%custom_type->command%><%endif%> <%if(flag_overrides(custom_type->input_file, commandflags))%><%flag_overrides(custom_type->input_file, commandflags)%><%else%><%custom_type->commandflags%><%endif%> <%if(custom_type->output_option)%><%custom_type->input_file%> <%custom_type->output_option%> "$@"<%else%><%custom_type->input_file%><%endif%>
258 <%if(flag_overrides(custom_type->input_file, postcommand))%>
259 <%foreach(custom_type->input_file)%>
260         <%flag_overrides(custom_type->input_file, postcommand)%>
261 <%endfor%>
262 <%else%>
263 <%if(custom_type->postcommand)%>
264 <%foreach(custom_type->input_file)%>
265         <%custom_type->postcommand%>
266 <%endfor%>
267 <%endif%>
268 <%endif%>
269 <%if(pchsupport && pch_header)%>
270 <%if(custom_type->pch_postrule)%>
271 <%foreach(custom_type->input_file->source_output_files)%>
272         @echo <%echo_outer_quote("'")%>#include "<%pch_header%>"<%echo_outer_quote("'")%> > temp.$$$$ && $(CAT) <%if(flag_overrides(custom_type->input_file, gendir))%><%flag_overrides(custom_type->input_file, gendir)%><%slash%><%basename(custom_type->input_file->source_output_file)%><%else%><%custom_type->input_file->source_output_file%><%endif%> >> temp.$$$$ && $(MV) temp.$$$$ <%if(flag_overrides(custom_type->input_file, gendir))%><%flag_overrides(custom_type->input_file, gendir)%><%slash%><%basename(custom_type->input_file->source_output_file)%><%else%><%custom_type->input_file->source_output_file%><%endif%>
273 <%endfor%>
274 <%endif%>
275 <%endif%>
277 <%endif%>
278 <%endfor%>
279 <%endfor%>
280 .PRECIOUS: $(GENERATED_DIRTY)
281 <%if(source_files)%>
282 $(OBJS): $(GENERATED_DIRTY)
283 <%endif%>
285 <%endif%>
286 generated:<%if(prebuild)%> __prebuild__<%endif%> $(GENERATED_DIRTY)
287         @-:
289 <%if(tempinc)%>
290 $(TEMPINCDIR):
291         @-$(TESTDIRSTART) "$(TEMPINCDIR)" $(TESTDIREND) $(MKDIR) "$(TEMPINCDIR)" 2> $(NUL)
293 <%endif%>
294 <%if(pch_source && pchsupport)%>
295 <%targetoutdir%><%obj_dir%><%noextension(pch_source)%>$(OBJEXT): <%pch_source%>
296 <%if(targetoutdir || obj_dir)%>
297         @$(TESTDIRSTART) "<%targetoutdir%><%obj_dir%><%dirname(pch_source)%>" $(TESTDIREND) $(MKDIR) "<%targetoutdir%><%obj_dir%><%dirname(pch_source)%>"
298 <%endif%>
299         <%if(ends_with(pch_source, \.c))%>$(COMPILE.c)<%else%>$(COMPILE.cc)<%endif%> <%if(pchcreate)%><%pchcreate%><%targetoutdir%><%obj_dir%><%pch_header%><%pchext%> <%endif%>$(EXPORTFLAGS)<%if(!pchnobj)%> $(OUTPUT_OPTION)<%endif%> <%pch_source%>
300 <%if(pchnobj)%>
301         @$(CP) <%targetoutdir%><%obj_dir%><%pch_header%><%pchext%> <%targetoutdir%><%obj_dir%><%noextension(pch_source)%>$(OBJEXT)
302 <%endif%>
304 <%endif%>
305 <%foreach(source_files)%>
306 <%if(targetoutdir || obj_dir)%><%targetoutdir%><%obj_dir%><%transdir(source_file)%><%basenoextension(source_file)%><%else%><%noextension(source_file)%><%endif%>$(OBJEXT): <%source_file%>
307 <%if(targetoutdir || obj_dir)%>
308         @$(TESTDIRSTART) "<%targetoutdir%><%obj_dir%><%transdir(source_file)%>" $(TESTDIREND) $(MKDIR) "<%targetoutdir%><%obj_dir%><%transdir(source_file)%>"
309 <%endif%>
310         <%if(ends_with(source_file, \.c) || ends_with(source_file, \.[Ss]))%>$(COMPILE.c)<%else%>$(COMPILE.cc)<%endif%> <%if(flag_overrides(source_file, buildflags))%><%flag_overrides(source_file, buildflags)%> <%endif%><%if(pchuse && pch_source && pchsupport)%><%pchuse%><%pch_header%><%pchext%> <%if(pchstop)%><%pchstop%><%pch_header%><%endif%><%endif%>$(EXPORTFLAGS) $(OUTPUT_OPTION) <%source_file%>
311 <%if(source_file->postcommand)%>
312         <%source_file->postcommand%>
313 <%endif%>
315 <%endfor%>
316 <%if(resource_files)%>
317 <%if(rc)%>
318 <%foreach(resource_files)%>
319 <%targetoutdir%><%obj_dir%><%resource_file%>$(RESEXT):
320 <%if(targetoutdir || obj_dir)%>
321         @$(TESTDIRSTART) "<%targetoutdir%><%obj_dir%><%dirname(resource_file)%>" $(TESTDIREND) $(MKDIR) "<%targetoutdir%><%obj_dir%><%dirname(resource_file)%>"
322 <%endif%>
323         <%rc%><%foreach(includes)%> -I<%include%><%endfor%> <%resource_file%> <%targetoutdir%><%obj_dir%><%resource_file%>$(RESEXT)
325 <%endfor%>
326 <%endif%>
327 <%endif%>
328 clean:
329         -$(RM) $(OBJS)
330 <%if(pch_source && pchsupport)%>
331         -$(RM) <%targetoutdir%><%obj_dir%><%pch_header%><%pchext%>
332 <%endif%>
333 <%if(clean)%>
334         -$(RM) <%clean%><%if(sharedname)%><%foreach(dir, clean)%> $(SHTARGETDIR)<%dir%><%endfor%><%endif%><%if(staticname || sharedname)%><%foreach(dir, clean)%> $(LTARGETDIR)<%dir%><%endfor%><%endif%><%if(exename)%><%foreach(dir, clean)%> $(BTARGETDIR)<%dir%><%endfor%><%endif%>
335 <%endif%>
337 realclean: clean
338         -$(RM) <%if(exename)%>$(BIN)<%else%><%if(dll_ext && sharedname && version && versupport)%>$(SHLIB).<%version%> <%endif%>$(SHLIB) $(LIB)<%endif%>
339 <%if(custom_types)%>
340         -$(RM) $(GENERATED_DIRTY)
341 <%endif%>
342 <%if(obj_dir)%>
343         -$(RM) <%targetoutdir%><%obj_dir%>
344 <%endif%>
345 <%if(postclean)%>
346         -<%eval(postclean)%>
347 <%endif%>
349 check-syntax:
350         $(COMPILE.cc) $(EXPORTFLAGS)<%if(checkopt)%> <%checkopt%><%endif%> $(CHK_SOURCES)
352 <%if(prebuild)%>
353 __prebuild__:
354         @<%eval(prebuild)%>
356 <%endif%>
357 <%if(postbuild)%>
358 __postbuild__:<%if(exename)%> $(BIN)<%endif%><%if(dll_ext && sharedname)%><%if(version && versupport)%> $(SHLIB).<%version%><%endif%> $(SHLIB)<%else%><%if(staticname)%> $(LIB)<%endif%><%endif%>
359         @<%eval(postbuild)%>
361 <%endif%>
362 <%marker(local)%>
363 #----------------------------------------------------------------------------
364 #       Dependencies
365 #----------------------------------------------------------------------------
367 <%if(!gnumake)%>
368 $(DEPENDENCIES):
369         @$(TOUCH) $(DEPENDENCIES)
370 <%endif%>
372 depend:
373 <%if(source_files || pch_source)%>
374         -<%if(targetoutdir || obj_dir)%>VDIR='<%subst(targetoutdir,\$,$$)%><%subst(obj_dir,\$,$$)%>' <%endif%><%depgen("$(MPC_ROOT)/depgen.pl")%> <%depgen_flags%> $(CFLAGS) $(CCFLAGS) $(CPPFLAGS) -f $(DEPENDENCIES) $(SRC) 2> $(NUL)
375 <%else%>
376         @-:
377 <%endif%>
379 <%if(forlast)%>
380 <%if(supports_include)%>
381 <%if(gnumake)%>-<%endif%>include $(DEPENDENCIES)
382 <%else%>
383 # DO NOT DELETE THIS LINE
384 <%endif%>
385 <%endif%>
386 <%endfor%>
387 <%endfor%>
388 <%marker(bottom)%>