source: build/snova/trunk/obuild/DOS/build_lib_snvertex.bat @ 132

Last change on this file since 132 was 132, checked in by barrand, 17 years ago
  • Property svn:executable set to *
File size: 24.7 KB
Line 
1@ECHO OFF
2SETLOCAL
3
4REM #
5REM # File produced by the obuild tool version 1.0
6REM # for the package snova with version v2r0p0.
7REM #
8
9REM #////////////////////////////////////////////////
10REM # Usage :
11REM #   DOS> CD some_path\pack\version\obuild
12REM #   DOS> DOS\build_snvertex
13REM #
14REM #////////////////////////////////////////////////
15
16REM #////////////////////////////////////////////////
17REM #/// Get path of this file :
18REM #////////////////////////////////////////////////
19SET obuild_snova_path=%~dp0
20REM # Remove ending \obuild\DOS\
21SET obuild_snova_path=%obuild_snova_path:~0,-12%
22
23REM #////////////////////////////////////////////////
24REM #/// Treat arguments :
25REM #////////////////////////////////////////////////
26
27SET obuild_verbose=no
28SET obuild_debug=no
29SET obuild_optimize=yes
30SET obuild_set_x=no
31
32:next_arg
33IF "%1%" == "" GOTO end_args
34
35IF NOT "%1%" == "-v" GOTO end_if_v
36  SET obuild_verbose=yes
37  SHIFT
38  GOTO next_arg
39:end_if_v
40
41IF NOT "%1%" == "-g" GOTO end_if_g
42  SET obuild_debug=yes
43  SHIFT
44  GOTO next_arg
45:end_if_g
46
47IF NOT "%1%" == "-x" GOTO end_if_x
48  SET obuild_set_x=yes
49  SHIFT
50  GOTO next_arg
51:end_if_x
52
53:end_args
54
55REM #////////////////////////////////////////////////
56REM #/// End arguments.
57REM #////////////////////////////////////////////////
58
59IF %obuild_set_x% == yes ECHO ON
60
61IF %obuild_debug% == yes SET obuild_optimize=no
62
63IF "%OBUILD_PLATFORM%" == "" (
64  IF "%OS%" == "" ECHO Environment variable OS not found. & GOTO obuild_return
65  SET obuild_platform=%OS%
66) ELSE (
67  SET obuild_platform=%OBUILD_PLATFORM%
68)
69
70IF "%obuild_platform%" == "" (
71  ECHO obuild_platform variable not defined.
72  GOTO obuild_return
73)
74
75IF "%OBUILD_DIR_BIN%" == "" (
76  SET obuild_dir_bin=%obuild_platform%_obuild
77) ELSE (
78  SET obuild_dir_bin=%OBUILD_DIR_BIN%
79)
80
81IF "%obuild_dir_bin%" == "" (
82  ECHO obuild_dir_bin variable not defined.
83  GOTO obuild_return
84)
85
86IF NOT EXIST "%obuild_snova_path%\%obuild_dir_bin%" MKDIR "%obuild_snova_path%\%obuild_dir_bin%"
87
88IF NOT EXIST "%obuild_snova_path%\%obuild_dir_bin%" MKDIR "%obuild_snova_path%\%obuild_dir_bin%"
89IF NOT EXIST "%obuild_snova_path%\%obuild_dir_bin%\obuild_platform.exe" (
90  cl.exe /nologo /DWIN32 /MD /O2 /W3  /GX /GR /Fe"%obuild_snova_path%\%obuild_dir_bin%\obuild_platform.exe" "%obuild_snova_path%\obuild\cpp\obuild_platform.cpp" 1> NUL
91  IF EXIST obuild_platform.obj DEL obuild_platform.obj
92)
93
94FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
95cd "%obuild_snova_path%\%obuild_dir_bin%"
96IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
97FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% UNIX`) DO SET obuild_platform_result=%%j
98cd "%obuild_pwd_snova_0%"
99SET obuild_pwd_snova_0=
100IF NOT %obuild_platform_result% == yes GOTO end_if_platform_1
101SET CLHEP_home=/usr/local/CLHEP/2.0.3.1
102:end_if_platform_1
103SET obuild_platform_result=
104FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
105cd "%obuild_snova_path%\%obuild_dir_bin%"
106IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
107FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% UNIX`) DO SET obuild_platform_result=%%j
108cd "%obuild_pwd_snova_0%"
109SET obuild_pwd_snova_0=
110IF NOT %obuild_platform_result% == yes GOTO end_if_platform_3
111SET Geant4_home=/usr/local/geant4/8.2
112:end_if_platform_3
113SET obuild_platform_result=
114FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
115cd "%obuild_snova_path%\%obuild_dir_bin%"
116IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
117FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Darwin`) DO SET obuild_platform_result=%%j
118cd "%obuild_pwd_snova_0%"
119SET obuild_pwd_snova_0=
120IF NOT %obuild_platform_result% == yes GOTO end_if_platform_4
121SET obuild_cxx_command=c++
122:end_if_platform_4
123SET obuild_platform_result=
124FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
125cd "%obuild_snova_path%\%obuild_dir_bin%"
126IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
127FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Linux`) DO SET obuild_platform_result=%%j
128cd "%obuild_pwd_snova_0%"
129SET obuild_pwd_snova_0=
130IF NOT %obuild_platform_result% == yes GOTO end_if_platform_5
131SET obuild_cxx_command=c++
132:end_if_platform_5
133SET obuild_platform_result=
134FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
135cd "%obuild_snova_path%\%obuild_dir_bin%"
136IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
137FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% OSF1`) DO SET obuild_platform_result=%%j
138cd "%obuild_pwd_snova_0%"
139SET obuild_pwd_snova_0=
140IF NOT %obuild_platform_result% == yes GOTO end_if_platform_6
141SET obuild_cxx_command=cxx
142:end_if_platform_6
143SET obuild_platform_result=
144FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
145cd "%obuild_snova_path%\%obuild_dir_bin%"
146IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
147FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Windows_NT`) DO SET obuild_platform_result=%%j
148cd "%obuild_pwd_snova_0%"
149SET obuild_pwd_snova_0=
150IF NOT %obuild_platform_result% == yes GOTO end_if_platform_7
151SET obuild_cxx_command=cl.exe
152:end_if_platform_7
153SET obuild_platform_result=
154IF "%obuild_cxx_command%" == ""  ECHO Variable obuild_cxx_command not defined.  && GOTO obuild_return
155
156FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
157cd "%obuild_snova_path%\%obuild_dir_bin%"
158IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
159FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Darwin`) DO SET obuild_platform_result=%%j
160cd "%obuild_pwd_snova_0%"
161SET obuild_pwd_snova_0=
162IF NOT %obuild_platform_result% == yes GOTO end_if_platform_8
163SET obuild_cxx_optimize=-O
164:end_if_platform_8
165SET obuild_platform_result=
166FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
167cd "%obuild_snova_path%\%obuild_dir_bin%"
168IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
169FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Linux`) DO SET obuild_platform_result=%%j
170cd "%obuild_pwd_snova_0%"
171SET obuild_pwd_snova_0=
172IF NOT %obuild_platform_result% == yes GOTO end_if_platform_9
173SET obuild_cxx_optimize=-O
174:end_if_platform_9
175SET obuild_platform_result=
176FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
177cd "%obuild_snova_path%\%obuild_dir_bin%"
178IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
179FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% OSF1`) DO SET obuild_platform_result=%%j
180cd "%obuild_pwd_snova_0%"
181SET obuild_pwd_snova_0=
182IF NOT %obuild_platform_result% == yes GOTO end_if_platform_10
183SET obuild_cxx_optimize=-O
184:end_if_platform_10
185SET obuild_platform_result=
186FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
187cd "%obuild_snova_path%\%obuild_dir_bin%"
188IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
189FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Windows_NT`) DO SET obuild_platform_result=%%j
190cd "%obuild_pwd_snova_0%"
191SET obuild_pwd_snova_0=
192IF NOT %obuild_platform_result% == yes GOTO end_if_platform_11
193SET obuild_cxx_optimize=/O2
194:end_if_platform_11
195SET obuild_platform_result=
196
197FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
198cd "%obuild_snova_path%\%obuild_dir_bin%"
199IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
200FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Darwin`) DO SET obuild_platform_result=%%j
201cd "%obuild_pwd_snova_0%"
202SET obuild_pwd_snova_0=
203IF NOT %obuild_platform_result% == yes GOTO end_if_platform_12
204SET obuild_cxx_debug=-g
205:end_if_platform_12
206SET obuild_platform_result=
207FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
208cd "%obuild_snova_path%\%obuild_dir_bin%"
209IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
210FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Linux`) DO SET obuild_platform_result=%%j
211cd "%obuild_pwd_snova_0%"
212SET obuild_pwd_snova_0=
213IF NOT %obuild_platform_result% == yes GOTO end_if_platform_13
214SET obuild_cxx_debug=-g
215:end_if_platform_13
216SET obuild_platform_result=
217FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
218cd "%obuild_snova_path%\%obuild_dir_bin%"
219IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
220FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% OSF1`) DO SET obuild_platform_result=%%j
221cd "%obuild_pwd_snova_0%"
222SET obuild_pwd_snova_0=
223IF NOT %obuild_platform_result% == yes GOTO end_if_platform_14
224SET obuild_cxx_debug=-g
225:end_if_platform_14
226SET obuild_platform_result=
227FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
228cd "%obuild_snova_path%\%obuild_dir_bin%"
229IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
230FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Windows_NT`) DO SET obuild_platform_result=%%j
231cd "%obuild_pwd_snova_0%"
232SET obuild_pwd_snova_0=
233IF NOT %obuild_platform_result% == yes GOTO end_if_platform_15
234SET obuild_cxx_debug=/ZI /Od
235:end_if_platform_15
236SET obuild_platform_result=
237
238FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
239cd "%obuild_snova_path%\%obuild_dir_bin%"
240IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
241FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Linux`) DO SET obuild_platform_result=%%j
242cd "%obuild_pwd_snova_0%"
243SET obuild_pwd_snova_0=
244IF NOT %obuild_platform_result% == yes GOTO end_if_platform_16
245SET obuild_cxx_options=-fPIC
246:end_if_platform_16
247SET obuild_platform_result=
248FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
249cd "%obuild_snova_path%\%obuild_dir_bin%"
250IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
251FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Windows_NT`) DO SET obuild_platform_result=%%j
252cd "%obuild_pwd_snova_0%"
253SET obuild_pwd_snova_0=
254IF NOT %obuild_platform_result% == yes GOTO end_if_platform_17
255SET obuild_cxx_options=/nologo /DWIN32 /MD /GX /GR /W3
256:end_if_platform_17
257SET obuild_platform_result=
258
259IF NOT %obuild_debug% == yes GOTO else_if_db_build_lib_snvertex_sh_18
260  SET obuild_cxx_debug_local=%obuild_cxx_debug%
261  GOTO end_if_db_build_lib_snvertex_sh_18
262:else_if_db_build_lib_snvertex_sh_18
263  SET obuild_cxx_debug_local=
264:end_if_db_build_lib_snvertex_sh_18
265
266IF NOT %obuild_optimize% == yes GOTO else_if_opt_build_lib_snvertex_sh_19
267  SET obuild_cxx_optimize_local=%obuild_cxx_optimize%
268  GOTO end_if_opt_build_lib_snvertex_sh_19
269:else_if_opt_build_lib_snvertex_sh_19
270  SET obuild_cxx_optimize_local=
271:end_if_opt_build_lib_snvertex_sh_19
272
273
274IF NOT EXIST "%obuild_snova_path%\%obuild_dir_bin%" MKDIR "%obuild_snova_path%\%obuild_dir_bin%"
275IF NOT EXIST "%obuild_snova_path%\%obuild_dir_bin%\obuild_find.exe" (
276  cl.exe /nologo /DWIN32 /MD /O2 /W3 /GX /GR /Fe"%obuild_snova_path%\%obuild_dir_bin%\obuild_find.exe" "%obuild_snova_path%\obuild\cpp\obuild_find.cpp" 1> NUL
277  IF EXIST obuild_find.obj DEL obuild_find.obj
278)
279FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
280cd "%obuild_snova_path%\%obuild_dir_bin%"
281IF NOT EXIST obuild_find.exe  ECHO Program obuild_find.exe not found.  && GOTO obuild_return
282FOR /F "usebackq delims=;" %%j IN (`.\obuild_find.exe  bhep v1r4p2`) DO SET obuild_bhep_path=%%j
283cd "%obuild_pwd_snova_0%"
284SET obuild_pwd_snova_0=
285IF NOT DEFINED obuild_bhep_path  ECHO Can't find bhep package.  && GOTO obuild_return
286
287SET obuild_cxx_includes=/I"%obuild_snova_path%\source\SNvertex\include"
288SET obuild_cxx_includes=%obuild_cxx_includes% /I"%obuild_snova_path%\source\GeomUtils\include"
289SET obuild_cxx_includes=%obuild_cxx_includes% /I"%obuild_snova_path%\source\SNgeom2\include"
290SET obuild_cxx_includes=%obuild_cxx_includes% /I"%obuild_bhep_path%"
291FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
292cd "%obuild_snova_path%\%obuild_dir_bin%"
293IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
294FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% UNIX`) DO SET obuild_platform_result=%%j
295cd "%obuild_pwd_snova_0%"
296SET obuild_pwd_snova_0=
297IF NOT %obuild_platform_result% == yes GOTO end_if_platform_24
298SET obuild_cxx_includes=%obuild_cxx_includes% -I${CLHEP_home}/include
299:end_if_platform_24
300SET obuild_platform_result=
301
302IF EXIST "%obuild_snova_path%\%obuild_dir_bin%\lib_snvertex" RMDIR /S /Q "%obuild_snova_path%\%obuild_dir_bin%\lib_snvertex"
303IF NOT EXIST "%obuild_snova_path%\%obuild_dir_bin%\lib_snvertex" MKDIR "%obuild_snova_path%\%obuild_dir_bin%\lib_snvertex"
304
305@IF %obuild_verbose% == yes @ECHO ON
306cd "%obuild_snova_path%\%obuild_dir_bin%"
307%obuild_cxx_command% /c %obuild_cxx_debug_local% %obuild_cxx_optimize_local% %obuild_cxx_options% %obuild_cxx_macros% %obuild_cxx_includes% /Fo.\lib_snvertex\CALO_basic_VG.obj  /Tp"..\source\SNvertex\src\CALO_basic_VG.cc" 1> cl_exe_error
308@IF ERRORLEVEL 1 @TYPE cl_exe_error && @GOTO obuild_return
309@IF NOT ERRORLEVEL 1 @DEL cl_exe_error
310cd "%obuild_snova_path%\obuild"
311
312cd "%obuild_snova_path%\%obuild_dir_bin%"
313%obuild_cxx_command% /c %obuild_cxx_debug_local% %obuild_cxx_optimize_local% %obuild_cxx_options% %obuild_cxx_macros% %obuild_cxx_includes% /Fo.\lib_snvertex\base_VG.obj  /Tp"..\source\SNvertex\src\base_VG.cc" 1> cl_exe_error
314@IF ERRORLEVEL 1 @TYPE cl_exe_error && @GOTO obuild_return
315@IF NOT ERRORLEVEL 1 @DEL cl_exe_error
316cd "%obuild_snova_path%\obuild"
317
318cd "%obuild_snova_path%\%obuild_dir_bin%"
319%obuild_cxx_command% /c %obuild_cxx_debug_local% %obuild_cxx_optimize_local% %obuild_cxx_options% %obuild_cxx_macros% %obuild_cxx_includes% /Fo.\lib_snvertex\base_VG_factory.obj  /Tp"..\source\SNvertex\src\base_VG_factory.cc" 1> cl_exe_error
320@IF ERRORLEVEL 1 @TYPE cl_exe_error && @GOTO obuild_return
321@IF NOT ERRORLEVEL 1 @DEL cl_exe_error
322cd "%obuild_snova_path%\obuild"
323
324cd "%obuild_snova_path%\%obuild_dir_bin%"
325%obuild_cxx_command% /c %obuild_cxx_debug_local% %obuild_cxx_optimize_local% %obuild_cxx_options% %obuild_cxx_macros% %obuild_cxx_includes% /Fo.\lib_snvertex\base_geom_VG.obj  /Tp"..\source\SNvertex\src\base_geom_VG.cc" 1> cl_exe_error
326@IF ERRORLEVEL 1 @TYPE cl_exe_error && @GOTO obuild_return
327@IF NOT ERRORLEVEL 1 @DEL cl_exe_error
328cd "%obuild_snova_path%\obuild"
329
330cd "%obuild_snova_path%\%obuild_dir_bin%"
331%obuild_cxx_command% /c %obuild_cxx_debug_local% %obuild_cxx_optimize_local% %obuild_cxx_options% %obuild_cxx_macros% %obuild_cxx_includes% /Fo.\lib_snvertex\box_VG.obj  /Tp"..\source\SNvertex\src\box_VG.cc" 1> cl_exe_error
332@IF ERRORLEVEL 1 @TYPE cl_exe_error && @GOTO obuild_return
333@IF NOT ERRORLEVEL 1 @DEL cl_exe_error
334cd "%obuild_snova_path%\obuild"
335
336cd "%obuild_snova_path%\%obuild_dir_bin%"
337%obuild_cxx_command% /c %obuild_cxx_debug_local% %obuild_cxx_optimize_local% %obuild_cxx_options% %obuild_cxx_macros% %obuild_cxx_includes% /Fo.\lib_snvertex\cylinder_VG.obj  /Tp"..\source\SNvertex\src\cylinder_VG.cc" 1> cl_exe_error
338@IF ERRORLEVEL 1 @TYPE cl_exe_error && @GOTO obuild_return
339@IF NOT ERRORLEVEL 1 @DEL cl_exe_error
340cd "%obuild_snova_path%\obuild"
341
342cd "%obuild_snova_path%\%obuild_dir_bin%"
343%obuild_cxx_command% /c %obuild_cxx_debug_local% %obuild_cxx_optimize_local% %obuild_cxx_options% %obuild_cxx_macros% %obuild_cxx_includes% /Fo.\lib_snvertex\dummy_snvertex.obj  /Tp"..\source\SNvertex\src\dummy_snvertex.cc" 1> cl_exe_error
344@IF ERRORLEVEL 1 @TYPE cl_exe_error && @GOTO obuild_return
345@IF NOT ERRORLEVEL 1 @DEL cl_exe_error
346cd "%obuild_snova_path%\obuild"
347
348cd "%obuild_snova_path%\%obuild_dir_bin%"
349%obuild_cxx_command% /c %obuild_cxx_debug_local% %obuild_cxx_optimize_local% %obuild_cxx_options% %obuild_cxx_macros% %obuild_cxx_includes% /Fo.\lib_snvertex\from_file_VG.obj  /Tp"..\source\SNvertex\src\from_file_VG.cc" 1> cl_exe_error
350@IF ERRORLEVEL 1 @TYPE cl_exe_error && @GOTO obuild_return
351@IF NOT ERRORLEVEL 1 @DEL cl_exe_error
352cd "%obuild_snova_path%\obuild"
353
354cd "%obuild_snova_path%\%obuild_dir_bin%"
355%obuild_cxx_command% /c %obuild_cxx_debug_local% %obuild_cxx_optimize_local% %obuild_cxx_options% %obuild_cxx_macros% %obuild_cxx_includes% /Fo.\lib_snvertex\snvertex_utils.obj  /Tp"..\source\SNvertex\src\snvertex_utils.cc" 1> cl_exe_error
356@IF ERRORLEVEL 1 @TYPE cl_exe_error && @GOTO obuild_return
357@IF NOT ERRORLEVEL 1 @DEL cl_exe_error
358cd "%obuild_snova_path%\obuild"
359
360cd "%obuild_snova_path%\%obuild_dir_bin%"
361%obuild_cxx_command% /c %obuild_cxx_debug_local% %obuild_cxx_optimize_local% %obuild_cxx_options% %obuild_cxx_macros% %obuild_cxx_includes% /Fo.\lib_snvertex\source_simple_VG.obj  /Tp"..\source\SNvertex\src\source_simple_VG.cc" 1> cl_exe_error
362@IF ERRORLEVEL 1 @TYPE cl_exe_error && @GOTO obuild_return
363@IF NOT ERRORLEVEL 1 @DEL cl_exe_error
364cd "%obuild_snova_path%\obuild"
365
366cd "%obuild_snova_path%\%obuild_dir_bin%"
367%obuild_cxx_command% /c %obuild_cxx_debug_local% %obuild_cxx_optimize_local% %obuild_cxx_options% %obuild_cxx_macros% %obuild_cxx_includes% /Fo.\lib_snvertex\spot_VG.obj  /Tp"..\source\SNvertex\src\spot_VG.cc" 1> cl_exe_error
368@IF ERRORLEVEL 1 @TYPE cl_exe_error && @GOTO obuild_return
369@IF NOT ERRORLEVEL 1 @DEL cl_exe_error
370cd "%obuild_snova_path%\obuild"
371
372@IF %obuild_verbose% == yes @ECHO OFF
373
374FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
375cd "%obuild_snova_path%\%obuild_dir_bin%"
376IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
377FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Darwin`) DO SET obuild_platform_result=%%j
378cd "%obuild_pwd_snova_0%"
379SET obuild_pwd_snova_0=
380IF NOT %obuild_platform_result% == yes GOTO end_if_platform_36
381SET obuild_cxx_linker_command=c++
382:end_if_platform_36
383SET obuild_platform_result=
384FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
385cd "%obuild_snova_path%\%obuild_dir_bin%"
386IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
387FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Linux`) DO SET obuild_platform_result=%%j
388cd "%obuild_pwd_snova_0%"
389SET obuild_pwd_snova_0=
390IF NOT %obuild_platform_result% == yes GOTO end_if_platform_37
391SET obuild_cxx_linker_command=c++
392:end_if_platform_37
393SET obuild_platform_result=
394FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
395cd "%obuild_snova_path%\%obuild_dir_bin%"
396IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
397FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% OSF1`) DO SET obuild_platform_result=%%j
398cd "%obuild_pwd_snova_0%"
399SET obuild_pwd_snova_0=
400IF NOT %obuild_platform_result% == yes GOTO end_if_platform_38
401SET obuild_cxx_linker_command=cxx
402:end_if_platform_38
403SET obuild_platform_result=
404FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
405cd "%obuild_snova_path%\%obuild_dir_bin%"
406IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
407FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Windows_NT`) DO SET obuild_platform_result=%%j
408cd "%obuild_pwd_snova_0%"
409SET obuild_pwd_snova_0=
410IF NOT %obuild_platform_result% == yes GOTO end_if_platform_39
411SET obuild_cxx_linker_command=link.exe
412:end_if_platform_39
413SET obuild_platform_result=
414IF "%obuild_cxx_linker_command%" == ""  ECHO Variable obuild_cxx_linker_command not defined.  && GOTO obuild_return
415
416FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
417cd "%obuild_snova_path%\%obuild_dir_bin%"
418IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
419FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Darwin`) DO SET obuild_platform_result=%%j
420cd "%obuild_pwd_snova_0%"
421SET obuild_pwd_snova_0=
422IF NOT %obuild_platform_result% == yes GOTO end_if_platform_40
423SET obuild_cxx_linker_debug=-g
424:end_if_platform_40
425SET obuild_platform_result=
426FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
427cd "%obuild_snova_path%\%obuild_dir_bin%"
428IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
429FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Linux`) DO SET obuild_platform_result=%%j
430cd "%obuild_pwd_snova_0%"
431SET obuild_pwd_snova_0=
432IF NOT %obuild_platform_result% == yes GOTO end_if_platform_41
433SET obuild_cxx_linker_debug=-g
434:end_if_platform_41
435SET obuild_platform_result=
436FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
437cd "%obuild_snova_path%\%obuild_dir_bin%"
438IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
439FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% OSF1`) DO SET obuild_platform_result=%%j
440cd "%obuild_pwd_snova_0%"
441SET obuild_pwd_snova_0=
442IF NOT %obuild_platform_result% == yes GOTO end_if_platform_42
443SET obuild_cxx_linker_debug=-g
444:end_if_platform_42
445SET obuild_platform_result=
446FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
447cd "%obuild_snova_path%\%obuild_dir_bin%"
448IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
449FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Windows_NT`) DO SET obuild_platform_result=%%j
450cd "%obuild_pwd_snova_0%"
451SET obuild_pwd_snova_0=
452IF NOT %obuild_platform_result% == yes GOTO end_if_platform_43
453SET obuild_cxx_linker_debug=/DEBUG
454:end_if_platform_43
455SET obuild_platform_result=
456
457FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
458cd "%obuild_snova_path%\%obuild_dir_bin%"
459IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
460FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Windows_NT`) DO SET obuild_platform_result=%%j
461cd "%obuild_pwd_snova_0%"
462SET obuild_pwd_snova_0=
463IF NOT %obuild_platform_result% == yes GOTO end_if_platform_44
464SET obuild_cxx_linker_options=/nologo
465:end_if_platform_44
466SET obuild_platform_result=
467
468IF NOT %obuild_debug% == yes GOTO else_if_db_build_lib_snvertex_sh_45
469  SET obuild_cxx_linker_debug_local=%obuild_cxx_linker_debug%
470  GOTO end_if_db_build_lib_snvertex_sh_45
471:else_if_db_build_lib_snvertex_sh_45
472  SET obuild_cxx_linker_debug_local=
473:end_if_db_build_lib_snvertex_sh_45
474
475IF NOT %obuild_optimize% == yes GOTO else_if_opt_build_lib_snvertex_sh_46
476  SET obuild_cxx_linker_optimize_local=%obuild_cxx_linker_optimize%
477  GOTO end_if_opt_build_lib_snvertex_sh_46
478:else_if_opt_build_lib_snvertex_sh_46
479  SET obuild_cxx_linker_optimize_local=
480:end_if_opt_build_lib_snvertex_sh_46
481
482FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snova_0=%%d
483cd "%obuild_snova_path%\%obuild_dir_bin%"
484IF EXIST .\lib_snvertex\tmp_objs DEL .\lib_snvertex\tmp_objs
485FOR %%f IN (.\lib_snvertex\*.obj) DO ECHO %%f >> .\lib_snvertex\tmp_objs
486
487REM # Create the archive library snvertex :
488@IF %obuild_verbose% == yes @ECHO ON
489lib.exe /nologo /machine:ix86 /out:.\lib_snvertex\snvertex.arc @.\lib_snvertex\tmp_objs
490@IF ERRORLEVEL 1 @GOTO obuild_return
491@IF %obuild_verbose% == yes @ECHO OFF
492
493REM # Build the obuild_windef.exe utility program :
494cl.exe /nologo /DWIN32 /MD /O2 /W3 /Feobuild_windef.exe "%obuild_snova_path%\obuild\cpp\obuild_windef.c" 1> NUL
495IF EXIST obuild_windef.obj DEL obuild_windef.obj
496
497REM # Building the .def file :
498@IF %obuild_verbose% == yes @ECHO ON
499dumpbin.exe /symbols /out:.\lib_snvertex\tmp .\lib_snvertex\snvertex.arc 1> dumpbin_exe_error .\lib_snvertex\snvertex.arc
500@IF ERRORLEVEL 1 @TYPE dumpbin_exe_error && @GOTO obuild_return
501@IF NOT ERRORLEVEL 1 @DEL dumpbin_exe_error
502@IF %obuild_verbose% == yes @ECHO OFF
503.\obuild_windef.exe snvertex < .\lib_snvertex\tmp > .\lib_snvertex\snvertex.def
504REM # Building the linking library :
505REM # It produces a .exp file.
506@IF %obuild_verbose% == yes @ECHO ON
507lib.exe /nologo /machine:ix86 /out:.\snvertex.lib /def:.\lib_snvertex\snvertex.def 1> lib_exe_error
508@IF ERRORLEVEL 1 @TYPE lib_exe_error && @GOTO obuild_return
509@IF NOT ERRORLEVEL 1 @DEL lib_exe_error
510@IF %obuild_verbose% == yes @ECHO OFF
511
512REM # Building the DLL :
513IF EXIST .\snvertex.dll DEL .\snvertex.dll
514@IF %obuild_verbose% == yes @ECHO ON
515link.exe /nologo /dll /out:.\snvertex.dll .\snvertex.exp .\lib_snvertex\snvertex.arc %obuild_linked_libraries%
516@IF %obuild_verbose% == yes @ECHO OFF
517
518cd "%obuild_pwd_snova_0%"
519SET obuild_pwd_snova_0=
520REM # Some cleanup :
521IF EXIST "%obuild_snova_path%\%obuild_dir_bin%\lib_snvertex\tmp_objs" DEL "%obuild_snova_path%\%obuild_dir_bin%\lib_snvertex\tmp_objs"
522IF EXIST "%obuild_snova_path%\%obuild_dir_bin%\snvertex.exp" DEL "%obuild_snova_path%\%obuild_dir_bin%\snvertex.exp"
523
524:obuild_return
525ENDLOCAL
526@ECHO ON
Note: See TracBrowser for help on using the repository browser.