source: snovis/trunk/obuild/sh/build_darwin_app_snovis_session @ 136

Last change on this file since 136 was 136, checked in by barrand, 15 years ago
  • Property svn:executable set to *
File size: 11.7 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_find" ] ; then
84  if [ ! -e "${obuild_snovis_path}/obuild/cpp/obuild_find.cpp" ] ; then
85    echo "Program source obuild_find.cpp not found."
86    exit
87  fi
88  if [ "${obuild_cxx_command}" = "" ] ; then
89    if [  "${OBUILD_CXX}" != "" ] ; then
90      obuild_find_compiler=${OBUILD_CXX}
91    else
92      obuild_find_compiler=c++
93    fi
94  else
95    obuild_find_compiler=${obuild_cxx_command}
96  fi
97  ${obuild_find_compiler} -o "${obuild_snovis_path}/${obuild_dir_bin}/obuild_find" "${obuild_snovis_path}/obuild/cpp/obuild_find.cpp"
98  unset obuild_find_compiler
99  if [ ! -e "${obuild_snovis_path}/${obuild_dir_bin}/obuild_find" ] ; then
100    echo "Program obuild_find not found."
101    exit
102  fi
103fi
104obuild_find_exe="${obuild_snovis_path}/${obuild_dir_bin}/obuild_find"
105if [ "${obuild_find_exe}" = "" ] ; then
106  echo "Variable obuild_find_exe not defined."
107  exit
108fi
109obuild_G4Lab_path=`"${obuild_find_exe}" G4Lab 'v8r*'`
110if [ "${obuild_G4Lab_path}" = "" ] ; then
111  echo "Can't find G4Lab package."
112  exit
113fi
114if [ "${obuild_find_exe}" = "" ] ; then
115  echo "Variable obuild_find_exe not defined."
116  exit
117fi
118obuild_OnXLab_path=`"${obuild_find_exe}" OnXLab 'v1r0'`
119if [ "${obuild_OnXLab_path}" = "" ] ; then
120  echo "Can't find OnXLab package."
121  exit
122fi
123if [ "${obuild_find_exe}" = "" ] ; then
124  echo "Variable obuild_find_exe not defined."
125  exit
126fi
127obuild_BatchLab_path=`"${obuild_find_exe}" BatchLab 'v1r*'`
128if [ "${obuild_BatchLab_path}" = "" ] ; then
129  echo "Can't find BatchLab package."
130  exit
131fi
132if [ "${obuild_find_exe}" = "" ] ; then
133  echo "Variable obuild_find_exe not defined."
134  exit
135fi
136obuild_OnX_path=`"${obuild_find_exe}" OnX 'v17r*'`
137if [ "${obuild_OnX_path}" = "" ] ; then
138  echo "Can't find OnX package."
139  exit
140fi
141if [ "${obuild_find_exe}" = "" ] ; then
142  echo "Variable obuild_find_exe not defined."
143  exit
144fi
145obuild_HEPVis_path=`"${obuild_find_exe}" HEPVis 'v6r*'`
146if [ "${obuild_HEPVis_path}" = "" ] ; then
147  echo "Can't find HEPVis package."
148  exit
149fi
150if [ "${obuild_find_exe}" = "" ] ; then
151  echo "Variable obuild_find_exe not defined."
152  exit
153fi
154obuild_CoinPython_path=`"${obuild_find_exe}" CoinPython 'v1r*'`
155if [ "${obuild_CoinPython_path}" = "" ] ; then
156  echo "Can't find CoinPython package."
157  exit
158fi
159
160if [ ! -e "${obuild_snovis_path}/${obuild_dir_bin}/obuild_platform" ] ; then
161  if [ ! -e "${obuild_snovis_path}/obuild/cpp/obuild_platform.cpp" ] ; then
162    echo "Program source obuild_platform.cpp not found."
163    exit
164  fi
165  if [ "${obuild_cxx_command}" = "" ] ; then 
166    if [  "${OBUILD_CXX}" != "" ] ; then
167      obuild_platform_compiler=${OBUILD_CXX}
168    else
169      obuild_platform_compiler=c++
170    fi
171  else
172    obuild_platform_compiler=${obuild_cxx_command} 
173  fi
174  ${obuild_platform_compiler} -o "${obuild_snovis_path}/${obuild_dir_bin}/obuild_platform" "${obuild_snovis_path}/obuild/cpp/obuild_platform.cpp"
175  unset obuild_platform_compiler
176  if [ ! -e "${obuild_snovis_path}/${obuild_dir_bin}/obuild_platform" ] ; then
177    echo "Program obuild_platform not found."
178    exit
179  fi
180fi
181obuild_platform_exe="${obuild_snovis_path}/${obuild_dir_bin}/obuild_platform"
182if [ "${obuild_platform_exe}" = "" ] ; then
183  echo "Variable obuild_platform_exe not defined."
184  exit
185fi
186obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Darwin'`
187if [ ${obuild_platform_result} = yes ] ; then
188./sh/build_Darwin_app snovis_session "${obuild_snovis_path}/${obuild_dir_bin}/snovis.bundle" "${obuild_G4Lab_path}/${obuild_dir_bin}/G4Lab.bundle" "${obuild_OnXLab_path}/${obuild_dir_bin}/OnXLabInventor.bundle" "${obuild_OnXLab_path}/${obuild_dir_bin}/OnXLabKUIP.bundle" "${obuild_OnXLab_path}/${obuild_dir_bin}/OnXLab.bundle" "${obuild_OnXLab_path}/${obuild_dir_bin}/OnXLab_SWIG_Python.so" "${obuild_BatchLab_path}/${obuild_dir_bin}/BatchLabXML.bundle" "${obuild_BatchLab_path}/${obuild_dir_bin}/BatchLabRio.bundle" "${obuild_BatchLab_path}/${obuild_dir_bin}/BatchLabHDF5.bundle" "${obuild_OnX_path}/${obuild_dir_bin}/OnXTestDLD.bundle" "${obuild_OnX_path}/${obuild_dir_bin}/OnXKUIP.bundle" "${obuild_OnX_path}/${obuild_dir_bin}/OnX.bundle" "${obuild_OnX_path}/${obuild_dir_bin}/OnXQt.bundle" "${obuild_OnX_path}/${obuild_dir_bin}/OnXPython.bundle" "${obuild_OnX_path}/${obuild_dir_bin}/OnX_SWIG_Python.so" "${obuild_HEPVis_path}/${obuild_dir_bin}/HEPVis_SWIG_Python.so" "${obuild_CoinPython_path}/${obuild_dir_bin}/_CoinPython.so"
189
190/bin/mkdir -p "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/snovis/."
191if [ -d "${obuild_snovis_path}/scripts" ] ; then
192  /bin/cp -R "${obuild_snovis_path}/scripts" "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/snovis/."
193else
194  echo "Directory ${obuild_snovis_path}/scripts not found."
195fi
196find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/snovis/." -depth -name CVS -exec /bin/rm -R -f {} \;
197find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/snovis/." -depth -name .svn -exec /bin/rm -R -f {} \;
198/bin/mkdir -p "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/G4Lab/."
199if [ -d "${obuild_G4Lab_path}/scripts" ] ; then
200  /bin/cp -R "${obuild_G4Lab_path}/scripts" "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/G4Lab/."
201else
202  echo "Directory ${obuild_G4Lab_path}/scripts not found."
203fi
204find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/G4Lab/." -depth -name CVS -exec /bin/rm -R -f {} \;
205find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/G4Lab/." -depth -name .svn -exec /bin/rm -R -f {} \;
206/bin/mkdir -p "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/OnXLab/."
207if [ -d "${obuild_OnXLab_path}/scripts" ] ; then
208  /bin/cp -R "${obuild_OnXLab_path}/scripts" "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/OnXLab/."
209else
210  echo "Directory ${obuild_OnXLab_path}/scripts not found."
211fi
212find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/OnXLab/." -depth -name CVS -exec /bin/rm -R -f {} \;
213find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/OnXLab/." -depth -name .svn -exec /bin/rm -R -f {} \;
214/bin/mkdir -p "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/OnXLab/."
215if [ -d "${obuild_OnXLab_path}/examples" ] ; then
216  /bin/cp -R "${obuild_OnXLab_path}/examples" "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/OnXLab/."
217else
218  echo "Directory ${obuild_OnXLab_path}/examples not found."
219fi
220find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/OnXLab/." -depth -name CVS -exec /bin/rm -R -f {} \;
221find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/OnXLab/." -depth -name .svn -exec /bin/rm -R -f {} \;
222/bin/mkdir -p "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/BatchLab/."
223if [ -d "${obuild_BatchLab_path}/scripts" ] ; then
224  /bin/cp -R "${obuild_BatchLab_path}/scripts" "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/BatchLab/."
225else
226  echo "Directory ${obuild_BatchLab_path}/scripts not found."
227fi
228find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/BatchLab/." -depth -name CVS -exec /bin/rm -R -f {} \;
229find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/BatchLab/." -depth -name .svn -exec /bin/rm -R -f {} \;
230/bin/mkdir -p "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/OnX/."
231if [ -d "${obuild_OnX_path}/scripts" ] ; then
232  /bin/cp -R "${obuild_OnX_path}/scripts" "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/OnX/."
233else
234  echo "Directory ${obuild_OnX_path}/scripts not found."
235fi
236find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/OnX/." -depth -name CVS -exec /bin/rm -R -f {} \;
237find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/OnX/." -depth -name .svn -exec /bin/rm -R -f {} \;
238/bin/mkdir -p "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/HEPVis/."
239if [ -d "${obuild_HEPVis_path}/fonts" ] ; then
240  /bin/cp -R "${obuild_HEPVis_path}/fonts" "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/HEPVis/."
241else
242  echo "Directory ${obuild_HEPVis_path}/fonts not found."
243fi
244find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/HEPVis/." -depth -name CVS -exec /bin/rm -R -f {} \;
245find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/HEPVis/." -depth -name .svn -exec /bin/rm -R -f {} \;
246/bin/mkdir -p "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/HEPVis/."
247if [ -d "${obuild_HEPVis_path}/scripts" ] ; then
248  /bin/cp -R "${obuild_HEPVis_path}/scripts" "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/HEPVis/."
249else
250  echo "Directory ${obuild_HEPVis_path}/scripts not found."
251fi
252find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/HEPVis/." -depth -name CVS -exec /bin/rm -R -f {} \;
253find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/HEPVis/." -depth -name .svn -exec /bin/rm -R -f {} \;
254/bin/mkdir -p "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/CoinPython/."
255if [ -d "${obuild_CoinPython_path}/scripts" ] ; then
256  /bin/cp -R "${obuild_CoinPython_path}/scripts" "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/CoinPython/."
257else
258  echo "Directory ${obuild_CoinPython_path}/scripts not found."
259fi
260find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/CoinPython/." -depth -name CVS -exec /bin/rm -R -f {} \;
261find "${obuild_snovis_path}/${obuild_dir_bin}/snovis_session.app/Contents/Resources/CoinPython/." -depth -name .svn -exec /bin/rm -R -f {} \;
262
263fi
264unset obuild_platform_result
265/bin/rm -f "${obuild_snovis_path}/${obuild_dir_bin}/obuild_find"
266
Note: See TracBrowser for help on using the repository browser.