source: snovis/trunk/obuild/sh/build_app_snovis_session @ 153

Last change on this file since 153 was 153, checked in by barrand, 15 years ago
  • Property svn:executable set to *
File size: 27.1 KB
Line 
1#!/bin/sh -f
2
3#
4# File produced by the obuild tool version 1.0
5# for the package snovis with version v1r1.
6#
7
8#////////////////////////////////////////////////
9# Usage :
10#   UNIX> cd some_path/pack/version/obuild
11# ( UNIX> chmod a+x sh/build_snovis_session )
12#   UNIX> sh/build_snovis_session
13#
14#////////////////////////////////////////////////
15
16obuild_verbose=no
17obuild_debug=no
18obuild_optimize=yes
19obuild_do_not_compile=no
20obuild_dir_bin_o_cleanup=yes
21
22obuild_set_x=no
23while test $# -ge 1 ; do
24  case $1 in
25    -h) 
26        echo "Options :"
27        echo "  -v : verbose."
28        echo "  -d : build in debug mode."
29        echo "  -g : build in debug mode."
30        echo "  -x : execute script with set -x."
31        echo "  -l : link only, do not (re)compile."
32        echo "  -k : do not remove result of compilations (.o, .obj)."
33        echo ""
34        exit ;;
35    -v) obuild_verbose=yes ;;
36    -x) obuild_set_x=yes ;;
37    -d) obuild_debug=yes ;;
38    -g) obuild_debug=yes ;;
39    -l) obuild_do_not_compile=yes ;;
40    -k) obuild_dir_bin_o_cleanup=no ;;
41    *) echo "unknown option : $1";exit ;;
42  esac
43  shift
44done
45
46if [ ${obuild_set_x} = yes ] ; then
47  set -x
48fi
49
50if [ ${obuild_debug} = yes ] ; then
51  obuild_optimize=no
52fi
53
54if [  "${OBUILD_PLATFORM}" = "" ] ; then
55  obuild_platform=`uname`
56else
57  obuild_platform=${OBUILD_PLATFORM}
58fi
59
60if [ "${obuild_platform}" = "" ] ; then
61  echo "obuild_platform variable not defined."
62  exit
63fi
64
65if [  "${OBUILD_DIR_BIN}" = "" ] ; then
66  obuild_dir_bin=${obuild_platform}_obuild
67else
68  obuild_dir_bin=${OBUILD_DIR_BIN}
69fi
70
71if [ "${obuild_dir_bin}" = "" ] ; then
72  echo "obuild_dir_bin variable not defined."
73  exit
74fi
75
76obuild_pwd=`pwd`
77obuild_snovis_path=`dirname "${obuild_pwd}"`
78unset obuild_pwd
79
80# Create the bin directory :
81/bin/mkdir -p "${obuild_snovis_path}/${obuild_dir_bin}"
82
83if [ ! -e "${obuild_snovis_path}/${obuild_dir_bin}/obuild_platform" ] ; then
84  if [ ! -e "${obuild_snovis_path}/obuild/cpp/obuild_platform.cpp" ] ; then
85    echo "Program source obuild_platform.cpp not found."
86    exit
87  fi
88  if [ "${obuild_cxx_command}" = "" ] ; then 
89    if [  "${OBUILD_CXX}" != "" ] ; then
90      obuild_platform_compiler=${OBUILD_CXX}
91    else
92      obuild_platform_compiler=c++
93    fi
94  else
95    obuild_platform_compiler=${obuild_cxx_command} 
96  fi
97  ${obuild_platform_compiler} -o "${obuild_snovis_path}/${obuild_dir_bin}/obuild_platform" "${obuild_snovis_path}/obuild/cpp/obuild_platform.cpp"
98  unset obuild_platform_compiler
99  if [ ! -e "${obuild_snovis_path}/${obuild_dir_bin}/obuild_platform" ] ; then
100    echo "Program obuild_platform not found."
101    exit
102  fi
103fi
104obuild_platform_exe="${obuild_snovis_path}/${obuild_dir_bin}/obuild_platform"
105if [ "${obuild_platform_exe}" = "" ] ; then
106  echo "Variable obuild_platform_exe not defined."
107  exit
108fi
109obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
110if [ ${obuild_platform_result} = yes ] ; then
111CLHEP_home="/usr/local/CLHEP/2.0.3.1"
112fi
113unset obuild_platform_result
114if [ "${obuild_platform_exe}" = "" ] ; then
115  echo "Variable obuild_platform_exe not defined."
116  exit
117fi
118obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
119if [ ${obuild_platform_result} = yes ] ; then
120Geant4_home="/usr/local/geant4/8.2"
121fi
122unset obuild_platform_result
123if [ "${obuild_platform_exe}" = "" ] ; then
124  echo "Variable obuild_platform_exe not defined."
125  exit
126fi
127obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Darwin'`
128if [ ${obuild_platform_result} = yes ] ; then
129obuild_cxx_command="c++"
130fi
131unset obuild_platform_result
132if [ "${obuild_platform_exe}" = "" ] ; then
133  echo "Variable obuild_platform_exe not defined."
134  exit
135fi
136obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Linux'`
137if [ ${obuild_platform_result} = yes ] ; then
138obuild_cxx_command="c++"
139fi
140unset obuild_platform_result
141if [ "${obuild_platform_exe}" = "" ] ; then
142  echo "Variable obuild_platform_exe not defined."
143  exit
144fi
145obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'OSF1'`
146if [ ${obuild_platform_result} = yes ] ; then
147obuild_cxx_command="cxx"
148fi
149unset obuild_platform_result
150if [ "${obuild_platform_exe}" = "" ] ; then
151  echo "Variable obuild_platform_exe not defined."
152  exit
153fi
154obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Windows_NT'`
155if [ ${obuild_platform_result} = yes ] ; then
156obuild_cxx_command="cl.exe"
157fi
158unset obuild_platform_result
159if [ "${obuild_cxx_command}" = "" ] ; then
160  echo "Variable obuild_cxx_command not defined."
161  exit
162fi
163
164if [ "${obuild_platform_exe}" = "" ] ; then
165  echo "Variable obuild_platform_exe not defined."
166  exit
167fi
168obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Darwin'`
169if [ ${obuild_platform_result} = yes ] ; then
170obuild_cxx_optimize="-O"
171fi
172unset obuild_platform_result
173if [ "${obuild_platform_exe}" = "" ] ; then
174  echo "Variable obuild_platform_exe not defined."
175  exit
176fi
177obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Linux'`
178if [ ${obuild_platform_result} = yes ] ; then
179obuild_cxx_optimize="-O"
180fi
181unset obuild_platform_result
182if [ "${obuild_platform_exe}" = "" ] ; then
183  echo "Variable obuild_platform_exe not defined."
184  exit
185fi
186obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'OSF1'`
187if [ ${obuild_platform_result} = yes ] ; then
188obuild_cxx_optimize="-O"
189fi
190unset obuild_platform_result
191if [ "${obuild_platform_exe}" = "" ] ; then
192  echo "Variable obuild_platform_exe not defined."
193  exit
194fi
195obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Windows_NT'`
196if [ ${obuild_platform_result} = yes ] ; then
197obuild_cxx_optimize="/O2"
198fi
199unset obuild_platform_result
200
201if [ "${obuild_platform_exe}" = "" ] ; then
202  echo "Variable obuild_platform_exe not defined."
203  exit
204fi
205obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Darwin'`
206if [ ${obuild_platform_result} = yes ] ; then
207obuild_cxx_debug="-g"
208fi
209unset obuild_platform_result
210if [ "${obuild_platform_exe}" = "" ] ; then
211  echo "Variable obuild_platform_exe not defined."
212  exit
213fi
214obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Linux'`
215if [ ${obuild_platform_result} = yes ] ; then
216obuild_cxx_debug="-g"
217fi
218unset obuild_platform_result
219if [ "${obuild_platform_exe}" = "" ] ; then
220  echo "Variable obuild_platform_exe not defined."
221  exit
222fi
223obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'OSF1'`
224if [ ${obuild_platform_result} = yes ] ; then
225obuild_cxx_debug="-g"
226fi
227unset obuild_platform_result
228if [ "${obuild_platform_exe}" = "" ] ; then
229  echo "Variable obuild_platform_exe not defined."
230  exit
231fi
232obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Windows_NT'`
233if [ ${obuild_platform_result} = yes ] ; then
234obuild_cxx_debug="/ZI /Od"
235fi
236unset obuild_platform_result
237
238if [ "${obuild_platform_exe}" = "" ] ; then
239  echo "Variable obuild_platform_exe not defined."
240  exit
241fi
242obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Linux'`
243if [ ${obuild_platform_result} = yes ] ; then
244obuild_cxx_options="-fPIC"
245fi
246unset obuild_platform_result
247if [ "${obuild_platform_exe}" = "" ] ; then
248  echo "Variable obuild_platform_exe not defined."
249  exit
250fi
251obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Windows_NT'`
252if [ ${obuild_platform_result} = yes ] ; then
253obuild_cxx_options="/nologo /DWIN32 /MD /GX /GR /W3"
254fi
255unset obuild_platform_result
256
257if [ ${obuild_debug} = yes ] ; then
258  obuild_cxx_debug_local=${obuild_cxx_debug}
259else
260  obuild_cxx_debug_local=
261fi
262
263if [ ${obuild_optimize} = yes ] ; then
264  obuild_cxx_optimize_local=${obuild_cxx_optimize}
265else
266  obuild_cxx_optimize_local=
267fi
268
269if [ ! -e "${obuild_snovis_path}/${obuild_dir_bin}/obuild_find" ] ; then
270  if [ ! -e "${obuild_snovis_path}/obuild/cpp/obuild_find.cpp" ] ; then
271    echo "Program source obuild_find.cpp not found."
272    exit
273  fi
274  if [ "${obuild_cxx_command}" = "" ] ; then
275    if [  "${OBUILD_CXX}" != "" ] ; then
276      obuild_find_compiler=${OBUILD_CXX}
277    else
278      obuild_find_compiler=c++
279    fi
280  else
281    obuild_find_compiler=${obuild_cxx_command}
282  fi
283  ${obuild_find_compiler} -o "${obuild_snovis_path}/${obuild_dir_bin}/obuild_find" "${obuild_snovis_path}/obuild/cpp/obuild_find.cpp"
284  unset obuild_find_compiler
285  if [ ! -e "${obuild_snovis_path}/${obuild_dir_bin}/obuild_find" ] ; then
286    echo "Program obuild_find not found."
287    exit
288  fi
289fi
290obuild_find_exe="${obuild_snovis_path}/${obuild_dir_bin}/obuild_find"
291if [ "${obuild_find_exe}" = "" ] ; then
292  echo "Variable obuild_find_exe not defined."
293  exit
294fi
295obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
296if [ "${obuild_snova_path}" = "" ] ; then
297  echo "Can't find snova package."
298  exit
299fi
300if [ "${obuild_find_exe}" = "" ] ; then
301  echo "Variable obuild_find_exe not defined."
302  exit
303fi
304obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
305if [ "${obuild_snova_path}" = "" ] ; then
306  echo "Can't find snova package."
307  exit
308fi
309if [ "${obuild_find_exe}" = "" ] ; then
310  echo "Variable obuild_find_exe not defined."
311  exit
312fi
313obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
314if [ "${obuild_snova_path}" = "" ] ; then
315  echo "Can't find snova package."
316  exit
317fi
318if [ "${obuild_find_exe}" = "" ] ; then
319  echo "Variable obuild_find_exe not defined."
320  exit
321fi
322obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
323if [ "${obuild_snova_path}" = "" ] ; then
324  echo "Can't find snova package."
325  exit
326fi
327if [ "${obuild_find_exe}" = "" ] ; then
328  echo "Variable obuild_find_exe not defined."
329  exit
330fi
331obuild_bhep_path=`"${obuild_find_exe}" bhep 'v1r4p2'`
332if [ "${obuild_bhep_path}" = "" ] ; then
333  echo "Can't find bhep package."
334  exit
335fi
336if [ "${obuild_find_exe}" = "" ] ; then
337  echo "Variable obuild_find_exe not defined."
338  exit
339fi
340obuild_HDF5_path=`"${obuild_find_exe}" HDF5 'v1r*'`
341if [ "${obuild_HDF5_path}" = "" ] ; then
342  echo "Can't find HDF5 package."
343  exit
344fi
345if [ "${obuild_find_exe}" = "" ] ; then
346  echo "Variable obuild_find_exe not defined."
347  exit
348fi
349obuild_AIDA_path=`"${obuild_find_exe}" AIDA 'v3r2p1'`
350if [ "${obuild_AIDA_path}" = "" ] ; then
351  echo "Can't find AIDA package."
352  exit
353fi
354if [ "${obuild_find_exe}" = "" ] ; then
355  echo "Variable obuild_find_exe not defined."
356  exit
357fi
358obuild_G4Lab_path=`"${obuild_find_exe}" G4Lab 'v8r*'`
359if [ "${obuild_G4Lab_path}" = "" ] ; then
360  echo "Can't find G4Lab package."
361  exit
362fi
363if [ "${obuild_find_exe}" = "" ] ; then
364  echo "Variable obuild_find_exe not defined."
365  exit
366fi
367obuild_Lib_path=`"${obuild_find_exe}" Lib 'v8r*'`
368if [ "${obuild_Lib_path}" = "" ] ; then
369  echo "Can't find Lib package."
370  exit
371fi
372if [ "${obuild_find_exe}" = "" ] ; then
373  echo "Variable obuild_find_exe not defined."
374  exit
375fi
376obuild_Slash_path=`"${obuild_find_exe}" Slash 'v1r*'`
377if [ "${obuild_Slash_path}" = "" ] ; then
378  echo "Can't find Slash package."
379  exit
380fi
381if [ "${obuild_find_exe}" = "" ] ; then
382  echo "Variable obuild_find_exe not defined."
383  exit
384fi
385obuild_OnX_path=`"${obuild_find_exe}" OnX 'v17r*'`
386if [ "${obuild_OnX_path}" = "" ] ; then
387  echo "Can't find OnX package."
388  exit
389fi
390if [ "${obuild_find_exe}" = "" ] ; then
391  echo "Variable obuild_find_exe not defined."
392  exit
393fi
394obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
395if [ "${obuild_snova_path}" = "" ] ; then
396  echo "Can't find snova package."
397  exit
398fi
399if [ "${obuild_find_exe}" = "" ] ; then
400  echo "Variable obuild_find_exe not defined."
401  exit
402fi
403obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
404if [ "${obuild_snova_path}" = "" ] ; then
405  echo "Can't find snova package."
406  exit
407fi
408if [ "${obuild_find_exe}" = "" ] ; then
409  echo "Variable obuild_find_exe not defined."
410  exit
411fi
412obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
413if [ "${obuild_snova_path}" = "" ] ; then
414  echo "Can't find snova package."
415  exit
416fi
417if [ "${obuild_find_exe}" = "" ] ; then
418  echo "Variable obuild_find_exe not defined."
419  exit
420fi
421obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
422if [ "${obuild_snova_path}" = "" ] ; then
423  echo "Can't find snova package."
424  exit
425fi
426if [ "${obuild_find_exe}" = "" ] ; then
427  echo "Variable obuild_find_exe not defined."
428  exit
429fi
430obuild_bhep_path=`"${obuild_find_exe}" bhep 'v1r4p2'`
431if [ "${obuild_bhep_path}" = "" ] ; then
432  echo "Can't find bhep package."
433  exit
434fi
435if [ "${obuild_find_exe}" = "" ] ; then
436  echo "Variable obuild_find_exe not defined."
437  exit
438fi
439obuild_HDF5_path=`"${obuild_find_exe}" HDF5 'v1r*'`
440if [ "${obuild_HDF5_path}" = "" ] ; then
441  echo "Can't find HDF5 package."
442  exit
443fi
444if [ "${obuild_find_exe}" = "" ] ; then
445  echo "Variable obuild_find_exe not defined."
446  exit
447fi
448obuild_G4Lab_path=`"${obuild_find_exe}" G4Lab 'v8r*'`
449if [ "${obuild_G4Lab_path}" = "" ] ; then
450  echo "Can't find G4Lab package."
451  exit
452fi
453if [ "${obuild_find_exe}" = "" ] ; then
454  echo "Variable obuild_find_exe not defined."
455  exit
456fi
457obuild_G4Lab_path=`"${obuild_find_exe}" G4Lab 'v8r*'`
458if [ "${obuild_G4Lab_path}" = "" ] ; then
459  echo "Can't find G4Lab package."
460  exit
461fi
462if [ "${obuild_find_exe}" = "" ] ; then
463  echo "Variable obuild_find_exe not defined."
464  exit
465fi
466obuild_Lib_path=`"${obuild_find_exe}" Lib 'v8r*'`
467if [ "${obuild_Lib_path}" = "" ] ; then
468  echo "Can't find Lib package."
469  exit
470fi
471if [ "${obuild_find_exe}" = "" ] ; then
472  echo "Variable obuild_find_exe not defined."
473  exit
474fi
475obuild_expat_path=`"${obuild_find_exe}" expat 'v1r*'`
476if [ "${obuild_expat_path}" = "" ] ; then
477  echo "Can't find expat package."
478  exit
479fi
480if [ "${obuild_find_exe}" = "" ] ; then
481  echo "Variable obuild_find_exe not defined."
482  exit
483fi
484obuild_Lib_path=`"${obuild_find_exe}" Lib 'v8r*'`
485if [ "${obuild_Lib_path}" = "" ] ; then
486  echo "Can't find Lib package."
487  exit
488fi
489if [ "${obuild_find_exe}" = "" ] ; then
490  echo "Variable obuild_find_exe not defined."
491  exit
492fi
493obuild_zlib_path=`"${obuild_find_exe}" zlib 'v1r*'`
494if [ "${obuild_zlib_path}" = "" ] ; then
495  echo "Can't find zlib package."
496  exit
497fi
498if [ "${obuild_find_exe}" = "" ] ; then
499  echo "Variable obuild_find_exe not defined."
500  exit
501fi
502obuild_Lib_path=`"${obuild_find_exe}" Lib 'v8r*'`
503if [ "${obuild_Lib_path}" = "" ] ; then
504  echo "Can't find Lib package."
505  exit
506fi
507if [ "${obuild_find_exe}" = "" ] ; then
508  echo "Variable obuild_find_exe not defined."
509  exit
510fi
511obuild_HEPVis_path=`"${obuild_find_exe}" HEPVis 'v6r*'`
512if [ "${obuild_HEPVis_path}" = "" ] ; then
513  echo "Can't find HEPVis package."
514  exit
515fi
516if [ "${obuild_find_exe}" = "" ] ; then
517  echo "Variable obuild_find_exe not defined."
518  exit
519fi
520obuild_HEPVis_path=`"${obuild_find_exe}" HEPVis 'v6r*'`
521if [ "${obuild_HEPVis_path}" = "" ] ; then
522  echo "Can't find HEPVis package."
523  exit
524fi
525if [ "${obuild_find_exe}" = "" ] ; then
526  echo "Variable obuild_find_exe not defined."
527  exit
528fi
529obuild_jpeg_path=`"${obuild_find_exe}" jpeg 'v1r*'`
530if [ "${obuild_jpeg_path}" = "" ] ; then
531  echo "Can't find jpeg package."
532  exit
533fi
534if [ "${obuild_find_exe}" = "" ] ; then
535  echo "Variable obuild_find_exe not defined."
536  exit
537fi
538obuild_dvi2bitmap_path=`"${obuild_find_exe}" dvi2bitmap 'v1r*'`
539if [ "${obuild_dvi2bitmap_path}" = "" ] ; then
540  echo "Can't find dvi2bitmap package."
541  exit
542fi
543if [ "${obuild_find_exe}" = "" ] ; then
544  echo "Variable obuild_find_exe not defined."
545  exit
546fi
547obuild_freetype2_path=`"${obuild_find_exe}" freetype2 'v1r*'`
548if [ "${obuild_freetype2_path}" = "" ] ; then
549  echo "Can't find freetype2 package."
550  exit
551fi
552if [ "${obuild_find_exe}" = "" ] ; then
553  echo "Variable obuild_find_exe not defined."
554  exit
555fi
556obuild_CoinGL_path=`"${obuild_find_exe}" CoinGL 'v1r*'`
557if [ "${obuild_CoinGL_path}" = "" ] ; then
558  echo "Can't find CoinGL package."
559  exit
560fi
561
562obuild_cxx_includes="-I\"${obuild_snova_path}\""
563obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_snova_path}/source/GeomUtils/include\""
564obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_snova_path}/source/SNvertex/include\""
565obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_snova_path}/source/SNgeom2/include\""
566obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_bhep_path}\""
567if [ "${obuild_platform_exe}" = "" ] ; then
568  echo "Variable obuild_platform_exe not defined."
569  exit
570fi
571obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
572if [ ${obuild_platform_result} = yes ] ; then
573obuild_cxx_includes="${obuild_cxx_includes} -I${CLHEP_home}/include"
574fi
575unset obuild_platform_result
576if [ "${obuild_platform_exe}" = "" ] ; then
577  echo "Variable obuild_platform_exe not defined."
578  exit
579fi
580obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
581if [ ${obuild_platform_result} = yes ] ; then
582obuild_cxx_includes="${obuild_cxx_includes} -I${Geant4_home}/include"
583fi
584unset obuild_platform_result
585obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_HDF5_path}/include\""
586obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_AIDA_path}/src/cpp\""
587obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_G4Lab_path}/include\""
588obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_Lib_path}/include\""
589obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_Slash_path}\""
590
591if [ ${obuild_dir_bin_o_cleanup} = yes ] ; then
592  /bin/rm -R -f "${obuild_snovis_path}/${obuild_dir_bin}/app_snovis_session"
593fi
594
595/bin/mkdir -p "${obuild_snovis_path}/${obuild_dir_bin}/app_snovis_session"
596
597# Compile snovis_session files :
598if [ ${obuild_do_not_compile} = no ] ; then
599
600if [ ${obuild_verbose} = yes ] ; then set -x;fi
601cd "${obuild_snovis_path}/${obuild_dir_bin}"
602 eval ${obuild_cxx_command} -c ${obuild_cxx_debug_local} ${obuild_cxx_optimize_local} ${obuild_cxx_options} ${obuild_cxx_macros} ${obuild_cxx_includes} -o ./app_snovis_session/snovis_session.o \"../applications/snovis_session.cc\"
603obuild_status=$?;if [ ${obuild_status} != 0 ] ; then exit ${obuild_status};fi
604cd "${obuild_snovis_path}/obuild"
605
606if [ ${obuild_verbose} = yes ] ; then set +x;fi
607
608fi #do_not_compile
609
610if [ "${obuild_platform_exe}" = "" ] ; then
611  echo "Variable obuild_platform_exe not defined."
612  exit
613fi
614obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Darwin'`
615if [ ${obuild_platform_result} = yes ] ; then
616obuild_cxx_linker_command="c++"
617fi
618unset obuild_platform_result
619if [ "${obuild_platform_exe}" = "" ] ; then
620  echo "Variable obuild_platform_exe not defined."
621  exit
622fi
623obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Linux'`
624if [ ${obuild_platform_result} = yes ] ; then
625obuild_cxx_linker_command="c++"
626fi
627unset obuild_platform_result
628if [ "${obuild_platform_exe}" = "" ] ; then
629  echo "Variable obuild_platform_exe not defined."
630  exit
631fi
632obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'OSF1'`
633if [ ${obuild_platform_result} = yes ] ; then
634obuild_cxx_linker_command="cxx"
635fi
636unset obuild_platform_result
637if [ "${obuild_platform_exe}" = "" ] ; then
638  echo "Variable obuild_platform_exe not defined."
639  exit
640fi
641obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Windows_NT'`
642if [ ${obuild_platform_result} = yes ] ; then
643obuild_cxx_linker_command="link.exe"
644fi
645unset obuild_platform_result
646if [ "${obuild_cxx_linker_command}" = "" ] ; then
647  echo "Variable obuild_cxx_linker_command not defined."
648  exit
649fi
650
651if [ "${obuild_platform_exe}" = "" ] ; then
652  echo "Variable obuild_platform_exe not defined."
653  exit
654fi
655obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Darwin'`
656if [ ${obuild_platform_result} = yes ] ; then
657obuild_cxx_linker_debug="-g"
658fi
659unset obuild_platform_result
660if [ "${obuild_platform_exe}" = "" ] ; then
661  echo "Variable obuild_platform_exe not defined."
662  exit
663fi
664obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Linux'`
665if [ ${obuild_platform_result} = yes ] ; then
666obuild_cxx_linker_debug="-g"
667fi
668unset obuild_platform_result
669if [ "${obuild_platform_exe}" = "" ] ; then
670  echo "Variable obuild_platform_exe not defined."
671  exit
672fi
673obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'OSF1'`
674if [ ${obuild_platform_result} = yes ] ; then
675obuild_cxx_linker_debug="-g"
676fi
677unset obuild_platform_result
678if [ "${obuild_platform_exe}" = "" ] ; then
679  echo "Variable obuild_platform_exe not defined."
680  exit
681fi
682obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Windows_NT'`
683if [ ${obuild_platform_result} = yes ] ; then
684obuild_cxx_linker_debug="/DEBUG"
685fi
686unset obuild_platform_result
687
688if [ "${obuild_platform_exe}" = "" ] ; then
689  echo "Variable obuild_platform_exe not defined."
690  exit
691fi
692obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Windows_NT'`
693if [ ${obuild_platform_result} = yes ] ; then
694obuild_cxx_linker_options="/nologo"
695fi
696unset obuild_platform_result
697
698if [ ${obuild_debug} = yes ] ; then
699  obuild_cxx_linker_debug_local=${obuild_cxx_linker_debug}
700else
701  obuild_cxx_linker_debug_local=
702fi
703
704if [ ${obuild_optimize} = yes ] ; then
705  obuild_cxx_linker_optimize_local=${obuild_cxx_linker_optimize}
706else
707  obuild_cxx_linker_optimize_local=
708fi
709obuild_linked_paths="-L\"${obuild_OnX_path}/${obuild_dir_bin}\""
710obuild_linked_libraries=" -lOnXCore"
711obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_snova_path}/${obuild_dir_bin}\""
712obuild_linked_libraries="${obuild_linked_libraries}  -lsnova"
713obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_snova_path}/${obuild_dir_bin}\""
714obuild_linked_libraries="${obuild_linked_libraries}  -lsnvertex"
715obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_snova_path}/${obuild_dir_bin}\""
716obuild_linked_libraries="${obuild_linked_libraries}  -lsngeom"
717obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_snova_path}/${obuild_dir_bin}\""
718obuild_linked_libraries="${obuild_linked_libraries}  -lgeomutils"
719obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_bhep_path}/${obuild_dir_bin}\""
720obuild_linked_libraries="${obuild_linked_libraries}  -lbhep"
721obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_HDF5_path}/${obuild_dir_bin}\""
722obuild_linked_libraries="${obuild_linked_libraries}  -losc_HDF5"
723obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_G4Lab_path}/${obuild_dir_bin}\""
724obuild_linked_libraries="${obuild_linked_libraries}  -lG4LabUIOnX"
725obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_G4Lab_path}/${obuild_dir_bin}\""
726obuild_linked_libraries="${obuild_linked_libraries}  -lG4LabCore"
727if [ "${obuild_platform_exe}" = "" ] ; then
728  echo "Variable obuild_platform_exe not defined."
729  exit
730fi
731obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
732if [ ${obuild_platform_result} = yes ] ; then
733obuild_linked_libraries="${obuild_linked_libraries} -L${Geant4_home}/lib -lG4readout -lG4run -lG4event -lG4tracking -lG4processes -lG4digits_hits -lG4track -lG4particles -lG4geometry -lG4graphics_reps -lG4materials -lG4intercoms -lG4global"
734fi
735unset obuild_platform_result
736if [ "${obuild_platform_exe}" = "" ] ; then
737  echo "Variable obuild_platform_exe not defined."
738  exit
739fi
740obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
741if [ ${obuild_platform_result} = yes ] ; then
742obuild_linked_libraries="${obuild_linked_libraries} -L${CLHEP_home}/lib -lCLHEP"
743fi
744unset obuild_platform_result
745obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_Lib_path}/${obuild_dir_bin}\""
746obuild_linked_libraries="${obuild_linked_libraries}  -lLibXML"
747obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_expat_path}/${obuild_dir_bin}\""
748obuild_linked_libraries="${obuild_linked_libraries}  -losc_expat"
749obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_Lib_path}/${obuild_dir_bin}\""
750obuild_linked_libraries="${obuild_linked_libraries}  -lLibZip"
751obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_zlib_path}/${obuild_dir_bin}\""
752obuild_linked_libraries="${obuild_linked_libraries}  -losc_z"
753obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_Lib_path}/${obuild_dir_bin}\""
754obuild_linked_libraries="${obuild_linked_libraries}  -lLibUtils"
755obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_HEPVis_path}/${obuild_dir_bin}\""
756obuild_linked_libraries="${obuild_linked_libraries}  -lHEPVisGeometry"
757obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_HEPVis_path}/${obuild_dir_bin}\""
758obuild_linked_libraries="${obuild_linked_libraries}  -lHEPVisUtils"
759obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_jpeg_path}/${obuild_dir_bin}\""
760obuild_linked_libraries="${obuild_linked_libraries}  -losc_jpeg"
761obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_dvi2bitmap_path}/${obuild_dir_bin}\""
762obuild_linked_libraries="${obuild_linked_libraries}  -losc_dvi2bitmap"
763obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_freetype2_path}/${obuild_dir_bin}\""
764obuild_linked_libraries="${obuild_linked_libraries}  -losc_freetype2"
765obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_CoinGL_path}/${obuild_dir_bin}\""
766obuild_linked_libraries="${obuild_linked_libraries}  -losc_Coin"
767if [ "${obuild_platform_exe}" = "" ] ; then
768  echo "Variable obuild_platform_exe not defined."
769  exit
770fi
771obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Darwin'`
772if [ ${obuild_platform_result} = yes ] ; then
773obuild_linked_libraries="${obuild_linked_libraries} -framework OpenGL -framework AGL"
774fi
775unset obuild_platform_result
776if [ "${obuild_platform_exe}" = "" ] ; then
777  echo "Variable obuild_platform_exe not defined."
778  exit
779fi
780obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Darwin'`
781if [ ${obuild_platform_result} = yes ] ; then
782obuild_linked_libraries="${obuild_linked_libraries} -framework ApplicationServices"
783fi
784unset obuild_platform_result
785if [ "${obuild_platform_exe}" = "" ] ; then
786  echo "Variable obuild_platform_exe not defined."
787  exit
788fi
789obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Linux'`
790if [ ${obuild_platform_result} = yes ] ; then
791obuild_linked_libraries="${obuild_linked_libraries} -L/usr/lib -lGLU -lGL -lm"
792fi
793unset obuild_platform_result
794if [ "${obuild_platform_exe}" = "" ] ; then
795  echo "Variable obuild_platform_exe not defined."
796  exit
797fi
798obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Windows_NT'`
799if [ ${obuild_platform_result} = yes ] ; then
800obuild_linked_libraries="${obuild_linked_libraries} glu32.lib opengl32.lib gdi32.lib user32.lib"
801fi
802unset obuild_platform_result
803if [ "${obuild_platform_exe}" = "" ] ; then
804  echo "Variable obuild_platform_exe not defined."
805  exit
806fi
807obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'OSF1'`
808if [ ${obuild_platform_result} = yes ] ; then
809obuild_linked_libraries="${obuild_linked_libraries} -L${OBUILD_OPENGL_HOME}/lib -lGLU -lGL -lm"
810fi
811unset obuild_platform_result
812if [ "${obuild_platform_exe}" = "" ] ; then
813  echo "Variable obuild_platform_exe not defined."
814  exit
815fi
816obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
817if [ ${obuild_platform_result} = yes ] ; then
818obuild_linked_libraries="${obuild_linked_libraries} -lpthread"
819fi
820unset obuild_platform_result
821
822# Link snovis_session :
823cd "${obuild_snovis_path}/${obuild_dir_bin}"
824obuild_objs=`find ./app_snovis_session -name '*.o' -print`
825/bin/rm -f ./snovis_session
826if [ ${obuild_verbose} = yes ] ; then set -x;fi
827 eval ${obuild_cxx_linker_command} ${obuild_cxx_linker_debug_local} ${obuild_cxx_linker_optimize_local} ${obuild_cxx_linker_options} -o \"${obuild_snovis_path}/${obuild_dir_bin}/snovis_session\" ${obuild_objs} ${obuild_linked_paths} ${obuild_linked_libraries}
828obuild_status=$?;if [ ${obuild_status} != 0 ] ; then exit ${obuild_status};fi
829if [ ${obuild_verbose} = yes ] ; then set +x;fi
830cd "${obuild_snovis_path}/obuild"
831
832# Some cleanup :
833if [ ${obuild_dir_bin_o_cleanup} = yes ] ; then
834  /bin/rm -R -f "${obuild_snovis_path}/${obuild_dir_bin}/app_snovis_session"
835fi
836/bin/rm -f "${obuild_snovis_path}/${obuild_dir_bin}/obuild_find"
837
Note: See TracBrowser for help on using the repository browser.