[472] | 1 | case $CONFIG in |
---|
| 2 | '') |
---|
| 3 | if test -f config.sh; then TOP=.; |
---|
| 4 | elif test -f ../config.sh; then TOP=..; |
---|
| 5 | elif test -f ../../config.sh; then TOP=../..; |
---|
| 6 | elif test -f ../../../config.sh; then TOP=../../..; |
---|
| 7 | elif test -f ../../../../config.sh; then TOP=../../../..; |
---|
| 8 | else |
---|
| 9 | echo "Can't find config.sh."; exit 1 |
---|
| 10 | fi |
---|
| 11 | . $TOP/config.sh |
---|
| 12 | ;; |
---|
| 13 | esac |
---|
| 14 | : This forces SH files to create target in same directory as SH file. |
---|
| 15 | : This is so that make depend always knows where to find SH derivatives. |
---|
| 16 | case "$0" in |
---|
| 17 | */*) cd `expr X$0 : 'X\(.*\)/'` ;; |
---|
| 18 | esac |
---|
| 19 | #echo "Extracting env.csh (with variable substitutions)" |
---|
| 20 | : This section of the file will have variable substitutions done on it. |
---|
| 21 | : Move anything that needs config subs from !NO!SUBS! section to !GROK!THIS!. |
---|
| 22 | : Protect any dollar signs and backticks that you do not want interpreted |
---|
| 23 | : by putting a backslash in front. You may delete these comments. |
---|
| 24 | $spitshell >env.csh <<!GROK!THIS! |
---|
| 25 | ###################################### |
---|
| 26 | # |
---|
[483] | 27 | # Clean all G4 envs |
---|
| 28 | unsetenv CLHEP_BASE_DIR |
---|
| 29 | unsetenv CLHEP_INCLUDE_DIR |
---|
| 30 | unsetenv CLHEP_LIB |
---|
| 31 | unsetenv CLHEP_LIB_DIR |
---|
| 32 | |
---|
| 33 | unsetenv G4DEBUG |
---|
| 34 | unsetenv G4INCLUDE |
---|
| 35 | unsetenv G4INSTALL |
---|
| 36 | |
---|
| 37 | unsetenv G4LEDATA |
---|
| 38 | unsetenv G4LEVELGAMMADATA |
---|
[593] | 39 | unsetenv G4NEUTRONHPDATA |
---|
[483] | 40 | unsetenv G4RADIOACTIVEDATA |
---|
[606] | 41 | unsetenv G4ABLADATA |
---|
[1195] | 42 | unsetenv G4REALSURFACEDATA |
---|
[1337] | 43 | unsetenv G4NEUTRONXSDATA |
---|
[1349] | 44 | unsetenv G4PIIDATA |
---|
[483] | 45 | |
---|
| 46 | unsetenv G4LIB |
---|
| 47 | unsetenv G4LIB_BUILD_G3TOG4 |
---|
| 48 | unsetenv G4LIB_BUILD_SHARED |
---|
| 49 | unsetenv G4LIB_BUILD_STATIC |
---|
| 50 | unsetenv G4LIB_BUILD_ZLIB |
---|
[606] | 51 | unsetenv G4LIB_BUILD_GDML |
---|
[483] | 52 | unsetenv G4LIB_USE_G3TOG4 |
---|
| 53 | unsetenv G4LIB_USE_GRANULAR |
---|
| 54 | unsetenv G4LIB_USE_ZLIB |
---|
| 55 | |
---|
| 56 | unsetenv G4SYSTEM |
---|
| 57 | |
---|
[1195] | 58 | unsetenv G4UI_NONE |
---|
[483] | 59 | unsetenv G4UI_BUILD_WIN32_SESSION |
---|
[1337] | 60 | unsetenv G4UI_BUILD_XAW_SESSION |
---|
[483] | 61 | unsetenv G4UI_BUILD_XM_SESSION |
---|
| 62 | unsetenv G4UI_USE_TCSH |
---|
| 63 | unsetenv G4UI_USE_WIN32 |
---|
[1337] | 64 | unsetenv G4UI_USE_XAW |
---|
[483] | 65 | unsetenv G4UI_USE_XM |
---|
[689] | 66 | unsetenv G4UI_USE_QT |
---|
[483] | 67 | |
---|
[1195] | 68 | unsetenv G4VIS_NONE |
---|
[483] | 69 | unsetenv G4VIS_BUILD_DAWN_DRIVER |
---|
| 70 | unsetenv G4VIS_BUILD_OIWIN32_DRIVER |
---|
| 71 | unsetenv G4VIS_BUILD_OIX_DRIVER |
---|
| 72 | unsetenv G4VIS_BUILD_OPENGLWIN32_DRIVER |
---|
| 73 | unsetenv G4VIS_BUILD_OPENGLXM_DRIVER |
---|
| 74 | unsetenv G4VIS_BUILD_OPENGLX_DRIVER |
---|
| 75 | unsetenv G4VIS_BUILD_RAYTRACERX_DRIVER |
---|
| 76 | unsetenv G4VIS_BUILD_VRML_DRIVER |
---|
[689] | 77 | unsetenv G4VIS_BUILD_OPENGLQT_DRIVER |
---|
[483] | 78 | |
---|
| 79 | unsetenv G4VIS_USE_DAWN |
---|
| 80 | unsetenv G4VIS_USE_OIWIN32 |
---|
| 81 | unsetenv G4VIS_USE_OIX |
---|
| 82 | unsetenv G4VIS_USE_OPENGLWIN32 |
---|
| 83 | unsetenv G4VIS_USE_OPENGLX |
---|
| 84 | unsetenv G4VIS_USE_OPENGLXM |
---|
| 85 | unsetenv G4VIS_USE_RAYTRACERX |
---|
| 86 | unsetenv G4VIS_USE_VRML |
---|
[689] | 87 | unsetenv G4VIS_USE_OPENGLQT |
---|
[483] | 88 | |
---|
| 89 | ###################################### |
---|
| 90 | # |
---|
[472] | 91 | # g4system.U |
---|
| 92 | # |
---|
| 93 | #+ |
---|
| 94 | setenv G4SYSTEM "$g4system" |
---|
| 95 | echo "On this machine the G4SYSTEM=\$G4SYSTEM" |
---|
| 96 | |
---|
| 97 | # |
---|
| 98 | # g4dirs.U |
---|
| 99 | # |
---|
| 100 | #+ |
---|
| 101 | if ( X$g4install != X$g4final_install ) then |
---|
[1337] | 102 | setenv G4INSTALL "$g4final_install/src/geant4" |
---|
| 103 | echo "On this machine the G4INSTALL=\$G4INSTALL" |
---|
[472] | 104 | else |
---|
[1337] | 105 | setenv G4INSTALL "$g4install" |
---|
| 106 | echo "On this machine the G4INSTALL=\$G4INSTALL" |
---|
[472] | 107 | endif |
---|
| 108 | |
---|
| 109 | #+ |
---|
| 110 | if ( X$g4includes_flag != Xn ) then |
---|
[1337] | 111 | if ( X$g4install != X$g4final_install ) then |
---|
| 112 | setenv G4INCLUDE "$g4final_install/include/geant4" |
---|
| 113 | else |
---|
| 114 | setenv G4INCLUDE "$g4final_install/include" |
---|
| 115 | endif |
---|
| 116 | |
---|
| 117 | echo "On this machine the G4INCLUDE=\$G4INCLUDE" |
---|
[472] | 118 | endif |
---|
| 119 | |
---|
| 120 | #+ |
---|
| 121 | if ( X$g4lib != X ) then |
---|
[1337] | 122 | if ( X$g4install != X$g4final_install ) then |
---|
| 123 | setenv G4LIB "$g4final_install/lib/geant4" |
---|
| 124 | else |
---|
| 125 | setenv G4LIB "$g4final_install/lib" |
---|
| 126 | endif |
---|
| 127 | |
---|
| 128 | echo "On this machine the G4LIB=\$G4LIB" |
---|
[472] | 129 | endif |
---|
| 130 | |
---|
| 131 | #+ |
---|
| 132 | if ( X$g4levelgammadata != X ) then |
---|
[1337] | 133 | setenv G4LEVELGAMMADATA "$g4levelgammadata" |
---|
| 134 | echo "On this machine the G4LEVELGAMMADATA=\$G4LEVELGAMMADATA" |
---|
[472] | 135 | endif |
---|
| 136 | |
---|
| 137 | #+ |
---|
| 138 | if ( X$g4radioactivedata != X ) then |
---|
[1337] | 139 | setenv G4RADIOACTIVEDATA "$g4radioactivedata" |
---|
| 140 | echo "On this machine the G4RADIOACTIVEDATA=\$G4RADIOACTIVEDATA" |
---|
[472] | 141 | endif |
---|
| 142 | |
---|
| 143 | #+ |
---|
| 144 | if ( X$g4ledata != X ) then |
---|
[1337] | 145 | setenv G4LEDATA "$g4ledata" |
---|
| 146 | echo "On this machine the G4LEDATA=\$G4LEDATA" |
---|
[472] | 147 | endif |
---|
| 148 | |
---|
| 149 | #+ |
---|
| 150 | if ( X$g4neutronhpcrosssections != X ) then |
---|
[1337] | 151 | setenv G4NEUTRONHPDATA "$g4neutronhpcrosssections" |
---|
| 152 | echo "On this machine the G4NEUTRONHPDATA=\$G4NEUTRONHPDATA" |
---|
[472] | 153 | endif |
---|
| 154 | |
---|
| 155 | #+ |
---|
[606] | 156 | if ( X$g4abladata != X ) then |
---|
[1337] | 157 | setenv G4ABLADATA "$g4abladata" |
---|
| 158 | echo "On this machine the G4ABLADATA=\$G4ABLADATA" |
---|
[606] | 159 | endif |
---|
| 160 | |
---|
| 161 | #+ |
---|
[1195] | 162 | if ( X$g4realsurfacedata != X ) then |
---|
[1337] | 163 | setenv G4REALSURFACEDATA "$g4realsurfacedata" |
---|
| 164 | echo "On this machine the G4REALSURFACEDATA=\$G4REALSURFACEDATA" |
---|
[1195] | 165 | endif |
---|
[472] | 166 | |
---|
[1337] | 167 | #+ |
---|
| 168 | if ( X$g4neutronxsdata != X ) then |
---|
| 169 | setenv G4NEUTRONXSDATA "$g4neutronxsdata" |
---|
| 170 | echo "On this machine the G4NEUTRONXSDATA=\$G4NEUTRONXSDATA" |
---|
| 171 | endif |
---|
[1195] | 172 | |
---|
[1349] | 173 | #+ |
---|
| 174 | if ( X$g4piidata != X ) then |
---|
| 175 | setenv G4PIIDATA "$g4piidata" |
---|
| 176 | echo "On this machine the G4PIIDATA=\$G4PIIDATA" |
---|
| 177 | endif |
---|
[1337] | 178 | |
---|
[1349] | 179 | |
---|
| 180 | |
---|
[472] | 181 | # |
---|
| 182 | # g4clhep.U |
---|
| 183 | # |
---|
| 184 | if ( X$g4clhep_base_dir != X ) then |
---|
[1337] | 185 | setenv CLHEP_BASE_DIR "$g4clhep_base_dir" |
---|
| 186 | echo "On this machine the CLHEP_BASE_DIR=\$CLHEP_BASE_DIR" |
---|
[472] | 187 | endif |
---|
| 188 | |
---|
| 189 | #+ |
---|
| 190 | if ( X$g4clhep_include_dir != X ) then |
---|
[1337] | 191 | setenv CLHEP_INCLUDE_DIR "$g4clhep_include_dir" |
---|
| 192 | echo "On this machine the CLHEP_INCLUDE_DIR=\$CLHEP_INCLUDE_DIR" |
---|
[472] | 193 | endif |
---|
| 194 | |
---|
| 195 | #+ |
---|
| 196 | if ( X$g4clhep_lib_dir != X ) then |
---|
[1337] | 197 | setenv CLHEP_LIB_DIR "$g4clhep_lib_dir" |
---|
| 198 | echo "On this machine the CLHEP_LIB_DIR=\$CLHEP_LIB_DIR" |
---|
[472] | 199 | endif |
---|
| 200 | |
---|
| 201 | #+ |
---|
| 202 | if ( X$g4clhep_lib != X ) then |
---|
[1337] | 203 | setenv CLHEP_LIB "$g4clhep_lib" |
---|
| 204 | echo "On this machine the CLHEP_LIB=\$CLHEP_LIB" |
---|
[472] | 205 | endif |
---|
| 206 | |
---|
| 207 | #+ |
---|
| 208 | # |
---|
| 209 | # g4debug |
---|
| 210 | # |
---|
[483] | 211 | if ( X$g4debug == Xy ) then |
---|
[1337] | 212 | setenv G4DEBUG 1 |
---|
| 213 | echo "On this machine the G4DEBUG=\$G4DEBUG" |
---|
[472] | 214 | endif |
---|
| 215 | |
---|
| 216 | |
---|
| 217 | # |
---|
| 218 | # g4ui |
---|
| 219 | # |
---|
| 220 | #+ |
---|
[1195] | 221 | if ( X$g4ui_none == Xy ) then |
---|
[1337] | 222 | setenv G4UI_NONE 1 |
---|
| 223 | echo "On this machine G4UI_NONE is set, so no user interfaces are available" |
---|
[1195] | 224 | endif |
---|
| 225 | |
---|
| 226 | # Check for Windows! |
---|
| 227 | if ( "X\$G4SYSTEM" != "XWIN32-VC" && "X\$G4SYSTEM" != "XWIN32-VC7" ) then |
---|
[1337] | 228 | if ( X$g4ui_none != Xy ) then |
---|
| 229 | setenv G4UI_USE_TCSH 1 |
---|
| 230 | echo "On this machine the G4UI_USE_TCSH=\$G4UI_USE_TCSH" |
---|
| 231 | endif |
---|
[1195] | 232 | endif |
---|
[1337] | 233 | |
---|
| 234 | #+ |
---|
| 235 | if ( X$g4ui_build_xaw_session == Xy ) then |
---|
| 236 | setenv G4UI_BUILD_XAW_SESSION 1 |
---|
| 237 | echo "On this machine the G4UI_BUILD_XAW_SESSION=\$G4UI_BUILD_XAW_SESSION" |
---|
[1195] | 238 | endif |
---|
| 239 | |
---|
| 240 | #+ |
---|
[1337] | 241 | if ( X$g4ui_use_xaw == Xy ) then |
---|
| 242 | setenv G4UI_USE_XAW 1 |
---|
| 243 | echo "On this machine the G4UI_USE_XAW=\$G4UI_USE_XAW" |
---|
| 244 | endif |
---|
| 245 | |
---|
| 246 | #+ |
---|
[472] | 247 | if ( X$g4ui_build_xm_session == Xy ) then |
---|
[1337] | 248 | setenv G4UI_BUILD_XM_SESSION 1 |
---|
| 249 | echo "On this machine the G4UI_BUILD_XM_SESSION=\$G4UI_BUILD_XM_SESSION" |
---|
[472] | 250 | endif |
---|
| 251 | |
---|
| 252 | #+ |
---|
| 253 | if ( X$g4ui_use_xm == Xy ) then |
---|
[1337] | 254 | setenv G4UI_USE_XM 1 |
---|
| 255 | echo "On this machine the G4UI_USE_XM=\$G4UI_USE_XM" |
---|
[472] | 256 | endif |
---|
| 257 | |
---|
| 258 | #+ |
---|
| 259 | if ( X$g4ui_build_win32_session == Xy ) then |
---|
[1337] | 260 | setenv G4UI_BUILD_WIN32_SESSION 1 |
---|
| 261 | echo "On this machine the G4UI_BUILD_WIN32_SESSION=\$G4UI_BUILD_WIN32_SESSION" |
---|
[472] | 262 | endif |
---|
| 263 | |
---|
| 264 | #+ |
---|
| 265 | if ( X$g4ui_use_win32 == Xy ) then |
---|
[1337] | 266 | setenv G4UI_USE_WIN32 1 |
---|
| 267 | echo "On this machine the G4UI_USE_WIN32=\$G4UI_USE_WIN32" |
---|
[472] | 268 | endif |
---|
| 269 | |
---|
[689] | 270 | #+ |
---|
| 271 | if ( X$g4ui_build_qt_session == Xy ) then |
---|
[1337] | 272 | setenv G4UI_BUILD_QT_SESSION 1 |
---|
| 273 | echo "On this machine the G4UI_BUILD_QT_SESSION=\$G4UI_BUILD_QT_SESSION" |
---|
[689] | 274 | endif |
---|
| 275 | |
---|
| 276 | #+ |
---|
| 277 | if ( X$g4ui_use_qt == Xy ) then |
---|
[1337] | 278 | setenv G4UI_USE_QT 1 |
---|
| 279 | echo "On this machine the G4UI_USE_QT=\$G4UI_USE_QT" |
---|
[689] | 280 | endif |
---|
| 281 | |
---|
| 282 | |
---|
| 283 | |
---|
[472] | 284 | # |
---|
| 285 | # g4vis |
---|
| 286 | # |
---|
| 287 | #+ |
---|
[1195] | 288 | if ( X$g4vis_none == Xy ) then |
---|
[1337] | 289 | setenv G4VIS_NONE 1 |
---|
| 290 | echo "On this machine G4VIS_NONE is set, so no vis drivers are available" |
---|
[1195] | 291 | endif |
---|
| 292 | |
---|
| 293 | #+ |
---|
[472] | 294 | if ( X$g4vis_build_dawn_driver == Xy ) then |
---|
[1337] | 295 | setenv G4VIS_BUILD_DAWN_DRIVER 1 |
---|
| 296 | echo "On this machine the G4VIS_BUILD_DAWN_DRIVER=\$G4VIS_BUILD_DAWN_DRIVER" |
---|
[472] | 297 | endif |
---|
| 298 | |
---|
| 299 | #+ |
---|
| 300 | if ( X$g4vis_build_openglx_driver == Xy ) then |
---|
[1337] | 301 | setenv G4VIS_BUILD_OPENGLX_DRIVER 1 |
---|
| 302 | echo "On this machine the G4VIS_BUILD_OPENGLX_DRIVER=\$G4VIS_BUILD_OPENGLX_DRIVER" |
---|
[472] | 303 | endif |
---|
| 304 | |
---|
| 305 | #+ |
---|
| 306 | if ( X$g4vis_build_openglxm_driver == Xy ) then |
---|
[1337] | 307 | setenv G4VIS_BUILD_OPENGLXM_DRIVER 1 |
---|
| 308 | echo "On this machine the G4VIS_BUILD_OPENGLXM_DRIVER=\$G4VIS_BUILD_OPENGLXM_DRIVER" |
---|
[472] | 309 | endif |
---|
| 310 | |
---|
| 311 | #+ |
---|
| 312 | if ( X$g4vis_build_openglwin32_driver == Xy ) then |
---|
[1337] | 313 | setenv G4VIS_BUILD_OPENGLWIN32_DRIVER 1 |
---|
| 314 | echo "On this machine the G4VIS_BUILD_OPENGLWIN32_DRIVER=\$G4VIS_BUILD_OPENGLWIN32_DRIVER" |
---|
[472] | 315 | endif |
---|
| 316 | |
---|
| 317 | #+ |
---|
| 318 | if ( X$g4vis_build_oix_driver == Xy ) then |
---|
[1337] | 319 | setenv G4VIS_BUILD_OIX_DRIVER 1 |
---|
| 320 | echo "On this machine the G4VIS_BUILD_OIX_DRIVER=\$G4VIS_BUILD_OIX_DRIVER" |
---|
[472] | 321 | endif |
---|
| 322 | |
---|
| 323 | #+ |
---|
| 324 | if ( X$g4vis_build_raytracerx_driver == Xy ) then |
---|
[1337] | 325 | setenv G4VIS_BUILD_RAYTRACERX_DRIVER 1 |
---|
| 326 | echo "On this machine the G4VIS_BUILD_RAYTRACERX_DRIVER=\$G4VIS_BUILD_RAYTRACERX_DRIVER" |
---|
[472] | 327 | endif |
---|
| 328 | |
---|
| 329 | #+ |
---|
| 330 | if ( X$g4vis_build_oiwin32_driver == Xy ) then |
---|
[1337] | 331 | setenv G4VIS_BUILD_OIWIN32_DRIVER 1 |
---|
| 332 | echo "On this machine the G4VIS_BUILD_OIWIN32_DRIVER=\$G4VIS_BUILD_OIWIN32_DRIVER" |
---|
[472] | 333 | endif |
---|
| 334 | |
---|
| 335 | #+ |
---|
| 336 | if ( X$g4vis_build_vrml_driver == Xy ) then |
---|
[1337] | 337 | setenv G4VIS_BUILD_VRML_DRIVER 1 |
---|
| 338 | echo "On this machine the G4VIS_BUILD_VRML_DRIVER=\$G4VIS_BUILD_VRML_DRIVER" |
---|
[472] | 339 | endif |
---|
| 340 | |
---|
| 341 | #+ |
---|
[689] | 342 | if ( X$g4vis_build_openglqt_driver == Xy ) then |
---|
[1337] | 343 | setenv G4VIS_BUILD_OPENGLQT_DRIVER 1 |
---|
| 344 | echo "On this machine the G4VIS_BUILD_OPENGLQT_DRIVER=\$G4VIS_BUILD_OPENGLQT_DRIVER" |
---|
[689] | 345 | endif |
---|
| 346 | |
---|
| 347 | |
---|
| 348 | #+ |
---|
[472] | 349 | if ( X$g4vis_use_dawn == Xy ) then |
---|
[1337] | 350 | setenv G4VIS_USE_DAWN 1 |
---|
| 351 | echo "On this machine the G4VIS_USE_DAWN=\$G4VIS_USE_DAWN" |
---|
[472] | 352 | endif |
---|
| 353 | |
---|
| 354 | #+ |
---|
| 355 | if ( X$g4vis_use_openglx == Xy ) then |
---|
[1337] | 356 | setenv G4VIS_USE_OPENGLX 1 |
---|
| 357 | echo "On this machine the G4VIS_USE_OPENGLX=\$G4VIS_USE_OPENGLX" |
---|
[472] | 358 | endif |
---|
| 359 | |
---|
| 360 | #+ |
---|
| 361 | if ( X$g4vis_use_openglxm == Xy ) then |
---|
[1337] | 362 | setenv G4VIS_USE_OPENGLXM 1 |
---|
| 363 | echo "On this machine the G4VIS_USE_OPENGLXM=\$G4VIS_USE_OPENGLXM" |
---|
[472] | 364 | endif |
---|
| 365 | |
---|
| 366 | #+ |
---|
| 367 | if ( X$g4vis_use_openglwin32 == Xy ) then |
---|
[1337] | 368 | setenv G4VIS_USE_OPENGLWIN32 1 |
---|
| 369 | echo "On this machine the G4VIS_USE_OPENGLWIN32=\$G4VIS_USE_OPENGLWIN32" |
---|
[472] | 370 | endif |
---|
| 371 | |
---|
| 372 | #+ |
---|
| 373 | if ( X$g4vis_use_oix == Xy ) then |
---|
[1337] | 374 | setenv G4VIS_USE_OIX 1 |
---|
| 375 | echo "On this machine the G4VIS_USE_OIX=\$G4VIS_USE_OIX" |
---|
[472] | 376 | endif |
---|
| 377 | |
---|
| 378 | #+ |
---|
| 379 | if ( X$g4vis_use_raytracerx == Xy ) then |
---|
[1337] | 380 | setenv G4VIS_USE_RAYTRACERX 1 |
---|
| 381 | echo "On this machine the G4VIS_USE_RAYTRACERX=\$G4VIS_USE_RAYTRACERX" |
---|
[472] | 382 | endif |
---|
| 383 | |
---|
| 384 | #+ |
---|
| 385 | if ( X$g4vis_use_oiwin32 == Xy ) then |
---|
[1337] | 386 | setenv G4VIS_USE_OIWIN32 1 |
---|
| 387 | echo "On this machine the G4VIS_USE_OIWIN32=\$G4VIS_USE_OIWIN32" |
---|
[472] | 388 | endif |
---|
| 389 | |
---|
| 390 | #+ |
---|
| 391 | if ( X$g4vis_use_vrml == Xy ) then |
---|
[1337] | 392 | setenv G4VIS_USE_VRML 1 |
---|
| 393 | echo "On this machine the G4VIS_USE_VRML=\$G4VIS_USE_VRML" |
---|
[472] | 394 | endif |
---|
| 395 | |
---|
| 396 | #+ |
---|
[689] | 397 | if ( X$g4vis_use_openglqt == Xy ) then |
---|
[1337] | 398 | setenv G4VIS_USE_OPENGLQT 1 |
---|
| 399 | echo "On this machine the G4VIS_USE_OPENGLQT=\$G4VIS_USE_OPENGLQT" |
---|
[689] | 400 | endif |
---|
| 401 | |
---|
| 402 | #+ |
---|
[472] | 403 | if ( X$g4vis_oglhome != X ) then |
---|
[1337] | 404 | setenv OGLHOME "$g4vis_oglhome" |
---|
| 405 | echo "On this machine the OGLHOME=\$OGLHOME" |
---|
[472] | 406 | endif |
---|
| 407 | |
---|
| 408 | #+ |
---|
| 409 | if ( X$g4vis_oivhome != X ) then |
---|
[1337] | 410 | setenv OIVHOME "$g4vis_oivhome" |
---|
| 411 | echo "On this machine the OIVHOME=\$OIVHOME" |
---|
[472] | 412 | endif |
---|
| 413 | |
---|
[689] | 414 | |
---|
| 415 | #+ |
---|
[472] | 416 | if ( X$g4vis_build_openglxm_driver != X ) then |
---|
[1337] | 417 | setenv XMFLAGS "$g4vis_xmflags" |
---|
| 418 | echo "On this machine the XMFLAGS=\$XMFLAGS" |
---|
[472] | 419 | endif |
---|
| 420 | |
---|
| 421 | #+ |
---|
| 422 | if ( X$g4vis_build_openglxm_driver != X ) then |
---|
[1337] | 423 | setenv XMLIBS "$g4vis_xmlibs" |
---|
| 424 | echo "On this machine the XMLIBS=\$XMLIBS" |
---|
[472] | 425 | endif |
---|
| 426 | |
---|
| 427 | #+ |
---|
| 428 | if ( X$g4ui_build_xm_session != X ) then |
---|
[1337] | 429 | setenv XMFLAGS "$g4vis_xmflags" |
---|
| 430 | echo "On this machine the XMFLAGS=\$XMFLAGS" |
---|
[472] | 431 | endif |
---|
| 432 | |
---|
| 433 | #+ |
---|
| 434 | if ( X$g4ui_build_xm_session != X ) then |
---|
[1337] | 435 | setenv XMLIBS "$g4vis_xmlibs" |
---|
| 436 | echo "On this machine the XMLIBS=\$XMLIBS" |
---|
[472] | 437 | endif |
---|
| 438 | |
---|
[1337] | 439 | #+ |
---|
| 440 | if ( X$g4ui_build_xaw_session != X ) then |
---|
| 441 | setenv XAWFLAGS "$g4ui_xawflags" |
---|
| 442 | echo "On this machine the XAWFLAGS=\$XAWFLAGS" |
---|
| 443 | endif |
---|
| 444 | |
---|
| 445 | #+ |
---|
| 446 | if ( X$g4ui_build_xaw_session != X ) then |
---|
| 447 | setenv XAWLIBS "$g4ui_xawlibs" |
---|
| 448 | echo "On this machine the XAWLIBS=\$XAWLIBS" |
---|
| 449 | endif |
---|
| 450 | |
---|
| 451 | |
---|
[886] | 452 | # |
---|
| 453 | # Qt Flags and Libs, messy, but needed for backward compatibility |
---|
| 454 | #+ |
---|
| 455 | if ( "X$g4ui_build_qt_session" == "Xy" || "X$g4ui_use_qt" == "Xy" ) then |
---|
[1337] | 456 | setenv QTFLAGS "$g4_qt_cxxflags" |
---|
| 457 | setenv QTLIBS "$g4_qt_libs" |
---|
| 458 | setenv QTMOC "$g4_qt_moc" |
---|
| 459 | echo "On this machine the QTFLAGS=\$QTFLAGS" |
---|
| 460 | echo "On this machine the QTLIBS=\$QTLIBS" |
---|
| 461 | echo "On this machine the QTMOC=\$QTMOC" |
---|
[886] | 462 | endif |
---|
[606] | 463 | |
---|
[886] | 464 | if ( "X$g4vis_build_openglqt_driver" == "Xy" || "X$g4vis_build_openglqt_driver" == "Xy" ) then |
---|
[1337] | 465 | if ( "X\$QTFLAGS" == "X" ) then |
---|
| 466 | setenv QTFLAGS "$g4_qt_cxxflags $g4_qt_gl_cxxflags" |
---|
| 467 | else |
---|
| 468 | setenv QTFLAGS "\$QTFLAGS $g4_qt_gl_cxxflags" |
---|
| 469 | endif |
---|
| 470 | |
---|
| 471 | if ( "X\$QTMOC" == "X" ) then |
---|
| 472 | setenv QTMOC "$g4_qt_moc" |
---|
| 473 | endif |
---|
| 474 | |
---|
| 475 | setenv GLQTLIBS "$g4_qt_libs $g4_qt_gl_libs" |
---|
| 476 | echo "On this machine the QTFLAGS=\$QTFLAGS" |
---|
| 477 | echo "On this machine the GLQTLIBS=\$GLQTLIBS" |
---|
| 478 | echo "On this machine the QTMOC=\$QTMOC" |
---|
[886] | 479 | endif |
---|
| 480 | |
---|
| 481 | |
---|
| 482 | |
---|
| 483 | |
---|
| 484 | |
---|
[472] | 485 | # |
---|
[606] | 486 | # Use GDML module |
---|
| 487 | # |
---|
| 488 | #+ |
---|
| 489 | if ( X$g4lib_build_gdml == Xy ) then |
---|
[1337] | 490 | setenv G4LIB_BUILD_GDML 1 |
---|
| 491 | echo "On this machine the G4LIB_BUILD_GDML=\$G4LIB_BUILD_GDML" |
---|
[606] | 492 | endif |
---|
| 493 | |
---|
| 494 | if ( X$g4lib_build_gdml == Xy ) then |
---|
[1337] | 495 | setenv XERCESCROOT "$g4gdml_xercesc_root" |
---|
| 496 | echo "On this machine the XERCESCROOT=\$XERCESCROOT" |
---|
[606] | 497 | endif |
---|
| 498 | |
---|
| 499 | |
---|
| 500 | |
---|
| 501 | |
---|
| 502 | # |
---|
[472] | 503 | # Use G3TOG4 module |
---|
| 504 | # |
---|
| 505 | #+ |
---|
| 506 | if ( X$g4wlib_build_g3tog4 == Xy ) then |
---|
[1337] | 507 | setenv G4LIB_BUILD_G3TOG4 1 |
---|
| 508 | echo "On this machine the G4LIB_BUILD_G3TOG4=\$G4LIB_BUILD_G3TOG4" |
---|
[472] | 509 | endif |
---|
| 510 | |
---|
| 511 | if ( X$g4w_use_g3tog4 == Xy ) then |
---|
[1337] | 512 | setenv G4LIB_USE_G3TOG4 1 |
---|
| 513 | echo "On this machine the G4LIB_USE_G3TOG4=\$G4LIB_USE_G3TOG4" |
---|
[472] | 514 | endif |
---|
| 515 | |
---|
| 516 | |
---|
| 517 | # |
---|
| 518 | # Use ZLIB module |
---|
| 519 | # |
---|
| 520 | #+ |
---|
| 521 | if ( X$g4wlib_build_zlib == Xy ) then |
---|
[1337] | 522 | setenv G4LIB_BUILD_ZLIB 1 |
---|
| 523 | echo "On this machine the G4LIB_BUILD_ZLIB=\$G4LIB_BUILD_ZLIB" |
---|
[472] | 524 | endif |
---|
| 525 | |
---|
| 526 | if ( X$g4w_use_ZLIB == Xy ) then |
---|
[1337] | 527 | setenv G4LIB_USE_ZLIB 1 |
---|
| 528 | echo "On this machine the G4LIB_USE_ZLIB=\$G4LIB_USE_ZLIB" |
---|
[472] | 529 | endif |
---|
| 530 | |
---|
| 531 | #+ |
---|
| 532 | # |
---|
| 533 | # g4shared |
---|
| 534 | # |
---|
| 535 | if ( X$g4lib_build_shared == Xy ) then |
---|
[1337] | 536 | setenv G4LIB_BUILD_SHARED 1 |
---|
| 537 | echo "On this machine the G4LIB_BUILD_SHARED=\$G4LIB_BUILD_SHARED" |
---|
[472] | 538 | endif |
---|
| 539 | |
---|
| 540 | if ( X$g4lib_build_static == Xy ) then |
---|
[1337] | 541 | setenv G4LIB_BUILD_STATIC 1 |
---|
| 542 | echo "On this machine the G4LIB_BUILD_STATIC=\$G4LIB_BUILD_STATIC" |
---|
[472] | 543 | endif |
---|
| 544 | |
---|
| 545 | #+ |
---|
| 546 | # |
---|
| 547 | # g4granular |
---|
| 548 | # |
---|
| 549 | if ( X$g4lib_use_granular == Xy ) then |
---|
[1337] | 550 | setenv G4LIB_USE_GRANULAR 1 |
---|
| 551 | echo "On this machine the G4LIB_USE_GRANULAR=\$G4LIB_USE_GRANULAR" |
---|
[472] | 552 | endif |
---|
| 553 | |
---|
| 554 | ##################################################################### |
---|
| 555 | |
---|
| 556 | !GROK!THIS! |
---|
| 557 | |
---|
| 558 | : In the following dollars and backticks do not need the extra backslash. |
---|
| 559 | $spitshell >>env.csh <<'!NO!SUBS!' |
---|
| 560 | |
---|
| 561 | |
---|
| 562 | #+ |
---|
| 563 | # |
---|
| 564 | # G4WORKDIR |
---|
| 565 | # |
---|
| 566 | if ( ${?G4WORKDIR} ) then |
---|
[1337] | 567 | echo "In your environment you have the G4WORKDIR=$G4WORKDIR" |
---|
[472] | 568 | else |
---|
[1337] | 569 | # Check for Windows! |
---|
| 570 | if ( "X$G4SYSTEM" == "XWIN32-VC" || "X$G4SYSTEM" == "XWIN32-VC7" ) then |
---|
| 571 | echo "G4WORKDIR will be set to c:/geant4 (in "native" Windows syntax)." |
---|
| 572 | setenv G4WORKDIR "c:/geant4" |
---|
| 573 | else # if Unix |
---|
| 574 | echo "G4WORKDIR will be set to HOME/geant4=$HOME/geant4" |
---|
| 575 | setenv G4WORKDIR $HOME/geant4 |
---|
| 576 | endif |
---|
[472] | 577 | endif |
---|
| 578 | |
---|
| 579 | # |
---|
[1337] | 580 | # *NIX Shared Libraries |
---|
| 581 | # If we built Geant4 with shared libraries, we need to add the Gean4 |
---|
| 582 | # library directory to (DY)LD_LIBRARY_PATH. |
---|
| 583 | # In all cases, external shared library directories should be added to |
---|
| 584 | # (DY)LD_LIBRARY_PATH |
---|
[483] | 585 | |
---|
[1337] | 586 | if ( "X$G4SYSTEM" != "XDarwin-g++" ) then |
---|
| 587 | if ( ${?LD_LIBRARY_PATH} ) then |
---|
| 588 | if ( ${?G4LIB_BUILD_SHARED} ) then |
---|
| 589 | setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:${G4LIB}/${G4SYSTEM} |
---|
| 590 | endif |
---|
[483] | 591 | |
---|
[1337] | 592 | setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:${CLHEP_LIB_DIR} |
---|
[606] | 593 | |
---|
[1337] | 594 | if ( ${?G4LIB_BUILD_GDML} ) then |
---|
| 595 | setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:${XERCESCROOT}/lib |
---|
| 596 | endif |
---|
[606] | 597 | |
---|
[1337] | 598 | else |
---|
| 599 | if ( ${?G4LIB_BUILD_SHARED} ) then |
---|
| 600 | setenv LD_LIBRARY_PATH ${G4LIB}/${G4SYSTEM} |
---|
| 601 | setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:${CLHEP_LIB_DIR} |
---|
| 602 | else |
---|
| 603 | setenv LD_LIBRARY_PATH ${CLHEP_LIB_DIR} |
---|
| 604 | endif |
---|
| 605 | |
---|
| 606 | if ( ${?G4LIB_BUILD_GDML} ) then |
---|
| 607 | setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:${XERCESCROOT}/lib |
---|
| 608 | endif |
---|
| 609 | endif |
---|
[472] | 610 | else |
---|
[1337] | 611 | # |
---|
| 612 | # Darwin Shared Libraries |
---|
| 613 | # we repeat the above logic, but for DYLD_LIBRARY_PATH |
---|
| 614 | # |
---|
| 615 | if ( ${?DYLD_LIBRARY_PATH} ) then |
---|
| 616 | if ( ${?G4LIB_BUILD_SHARED} ) then |
---|
| 617 | setenv DYLD_LIBRARY_PATH ${DYLD_LIBRARY_PATH}:${G4LIB}/${G4SYSTEM} |
---|
| 618 | endif |
---|
[606] | 619 | |
---|
[1337] | 620 | setenv DYLD_LIBRARY_PATH ${DYLD_LIBRARY_PATH}:${CLHEP_LIB_DIR} |
---|
[606] | 621 | |
---|
[1337] | 622 | if ( ${?G4LIB_BUILD_GDML} ) then |
---|
| 623 | setenv DYLD_LIBRARY_PATH ${DYLD_LIBRARY_PATH}:${XERCESCROOT}/lib |
---|
| 624 | endif |
---|
| 625 | else |
---|
| 626 | if ( ${?G4LIB_BUILD_SHARED} ) then |
---|
| 627 | setenv DYLD_LIBRARY_PATH ${G4LIB}/${G4SYSTEM} |
---|
| 628 | setenv DYLD_LIBRARY_PATH ${DYLD_LIBRARY_PATH}:${CLHEP_LIB_DIR} |
---|
| 629 | else |
---|
| 630 | setenv DYLD_LIBRARY_PATH ${CLHEP_LIB_DIR} |
---|
| 631 | endif |
---|
| 632 | |
---|
| 633 | if ( ${?G4LIB_BUILD_GDML} ) then |
---|
| 634 | setenv DYLD_LIBRARY_PATH ${DYLD_LIBRARY_PATH}:${XERCESCROOT}/lib |
---|
| 635 | endif |
---|
| 636 | endif |
---|
[472] | 637 | endif |
---|
| 638 | |
---|
[1337] | 639 | |
---|
[472] | 640 | # |
---|
[1337] | 641 | # Warning about LD_LIBRARY_PATH |
---|
[483] | 642 | # |
---|
[1337] | 643 | echo '' |
---|
[483] | 644 | if ( ${?G4LIB_BUILD_SHARED} ) then |
---|
[1337] | 645 | if ( "X$G4SYSTEM" == "XDarwin-g++" ) then |
---|
| 646 | echo 'DYLD_LIBRARY_PATH is set to include CLHEP and Geant4 libraries. ' |
---|
| 647 | else |
---|
| 648 | echo 'LD_LIBRARY_PATH is set to include CLHEP and Geant4 libraries. ' |
---|
| 649 | endif |
---|
[483] | 650 | else |
---|
[1337] | 651 | if ( "X$G4SYSTEM" == "XDarwin-g++" ) then |
---|
| 652 | echo 'DYLD_LIBRARY_PATH is set to include CLHEP libraries. ' |
---|
| 653 | else |
---|
| 654 | echo 'LD_LIBRARY_PATH is set to include CLHEP libraries. ' |
---|
| 655 | endif |
---|
[483] | 656 | endif |
---|
[1337] | 657 | echo 'NOTE : you should verify that the correct path for the CLHEP library' |
---|
| 658 | echo '' |
---|
| 659 | echo ${CLHEP_BASE_DIR}/lib |
---|
| 660 | echo '' |
---|
| 661 | echo 'is included in the dynamic library search path ahead of any other' |
---|
| 662 | echo 'installations of CLHEP on your system that may be referenced by this' |
---|
| 663 | echo 'path.' |
---|
| 664 | echo '' |
---|
[606] | 665 | |
---|
[483] | 666 | # |
---|
[472] | 667 | # For BIN |
---|
| 668 | # |
---|
| 669 | setenv PATH ${PATH}:${G4WORKDIR}/bin/${G4SYSTEM} |
---|
| 670 | |
---|
| 671 | !NO!SUBS! |
---|
| 672 | chmod 755 env.csh |
---|
| 673 | $eunicefix env.csh |
---|