Ignore:
Timestamp:
Feb 15, 2007, 11:45:43 AM (17 years ago)
Author:
barrand
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • build/bhep/trunk/obuild/DOS/build_lib_bhep.bat

    r127 r249  
    105105cd "%obuild_bhep_path%\%obuild_dir_bin%"
    106106IF 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_bhep_0%"
     109SET obuild_pwd_bhep_0=
     110IF NOT %obuild_platform_result% == yes GOTO end_if_platform_3
     111SET HDF5_home=/usr/local/HDF5/1.6.5
     112:end_if_platform_3
     113SET obuild_platform_result=
     114FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     115cd "%obuild_bhep_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% UNIX`) DO SET obuild_platform_result=%%j
     118cd "%obuild_pwd_bhep_0%"
     119SET obuild_pwd_bhep_0=
     120IF NOT %obuild_platform_result% == yes GOTO end_if_platform_5
     121SET zlib_home=/usr
     122:end_if_platform_5
     123SET obuild_platform_result=
     124FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     125cd "%obuild_bhep_path%\%obuild_dir_bin%"
     126IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
    107127FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Darwin`) DO SET obuild_platform_result=%%j
    108128cd "%obuild_pwd_bhep_0%"
    109129SET obuild_pwd_bhep_0=
    110 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_2
     130IF NOT %obuild_platform_result% == yes GOTO end_if_platform_6
    111131SET obuild_cxx_command=c++
    112 :end_if_platform_2
     132:end_if_platform_6
    113133SET obuild_platform_result=
    114134FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    118138cd "%obuild_pwd_bhep_0%"
    119139SET obuild_pwd_bhep_0=
    120 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_3
     140IF NOT %obuild_platform_result% == yes GOTO end_if_platform_7
    121141SET obuild_cxx_command=c++
    122 :end_if_platform_3
     142:end_if_platform_7
    123143SET obuild_platform_result=
    124144FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    128148cd "%obuild_pwd_bhep_0%"
    129149SET obuild_pwd_bhep_0=
    130 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_4
     150IF NOT %obuild_platform_result% == yes GOTO end_if_platform_8
    131151SET obuild_cxx_command=cxx
    132 :end_if_platform_4
     152:end_if_platform_8
    133153SET obuild_platform_result=
    134154FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    138158cd "%obuild_pwd_bhep_0%"
    139159SET obuild_pwd_bhep_0=
    140 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_5
     160IF NOT %obuild_platform_result% == yes GOTO end_if_platform_9
    141161SET obuild_cxx_command=cl.exe
    142 :end_if_platform_5
     162:end_if_platform_9
    143163SET obuild_platform_result=
    144164IF "%obuild_cxx_command%" == ""  ECHO Variable obuild_cxx_command not defined.  && GOTO obuild_return
     
    150170cd "%obuild_pwd_bhep_0%"
    151171SET obuild_pwd_bhep_0=
    152 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_6
     172IF NOT %obuild_platform_result% == yes GOTO end_if_platform_10
    153173SET obuild_cxx_optimize=-O
    154 :end_if_platform_6
     174:end_if_platform_10
    155175SET obuild_platform_result=
    156176FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    160180cd "%obuild_pwd_bhep_0%"
    161181SET obuild_pwd_bhep_0=
    162 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_7
     182IF NOT %obuild_platform_result% == yes GOTO end_if_platform_11
    163183SET obuild_cxx_optimize=-O
    164 :end_if_platform_7
     184:end_if_platform_11
    165185SET obuild_platform_result=
    166186FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    170190cd "%obuild_pwd_bhep_0%"
    171191SET obuild_pwd_bhep_0=
    172 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_8
     192IF NOT %obuild_platform_result% == yes GOTO end_if_platform_12
    173193SET obuild_cxx_optimize=-O
    174 :end_if_platform_8
     194:end_if_platform_12
    175195SET obuild_platform_result=
    176196FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    180200cd "%obuild_pwd_bhep_0%"
    181201SET obuild_pwd_bhep_0=
    182 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_9
     202IF NOT %obuild_platform_result% == yes GOTO end_if_platform_13
    183203SET obuild_cxx_optimize=/O2
    184 :end_if_platform_9
     204:end_if_platform_13
    185205SET obuild_platform_result=
    186206
     
    191211cd "%obuild_pwd_bhep_0%"
    192212SET obuild_pwd_bhep_0=
    193 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_10
     213IF NOT %obuild_platform_result% == yes GOTO end_if_platform_14
    194214SET obuild_cxx_debug=-g
    195 :end_if_platform_10
     215:end_if_platform_14
    196216SET obuild_platform_result=
    197217FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    201221cd "%obuild_pwd_bhep_0%"
    202222SET obuild_pwd_bhep_0=
    203 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_11
     223IF NOT %obuild_platform_result% == yes GOTO end_if_platform_15
    204224SET obuild_cxx_debug=-g
    205 :end_if_platform_11
     225:end_if_platform_15
    206226SET obuild_platform_result=
    207227FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    211231cd "%obuild_pwd_bhep_0%"
    212232SET obuild_pwd_bhep_0=
    213 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_12
     233IF NOT %obuild_platform_result% == yes GOTO end_if_platform_16
    214234SET obuild_cxx_debug=-g
    215 :end_if_platform_12
     235:end_if_platform_16
    216236SET obuild_platform_result=
    217237FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    221241cd "%obuild_pwd_bhep_0%"
    222242SET obuild_pwd_bhep_0=
    223 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_13
     243IF NOT %obuild_platform_result% == yes GOTO end_if_platform_17
    224244SET obuild_cxx_debug=/ZI /Od
    225 :end_if_platform_13
     245:end_if_platform_17
    226246SET obuild_platform_result=
    227247
     
    232252cd "%obuild_pwd_bhep_0%"
    233253SET obuild_pwd_bhep_0=
    234 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_14
     254IF NOT %obuild_platform_result% == yes GOTO end_if_platform_18
    235255SET obuild_cxx_options=-fPIC
    236 :end_if_platform_14
     256:end_if_platform_18
    237257SET obuild_platform_result=
    238258FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    242262cd "%obuild_pwd_bhep_0%"
    243263SET obuild_pwd_bhep_0=
    244 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_15
     264IF NOT %obuild_platform_result% == yes GOTO end_if_platform_19
    245265SET obuild_cxx_options=/nologo /DWIN32 /MD /GX /GR /W3
    246 :end_if_platform_15
    247 SET obuild_platform_result=
    248 
    249 IF NOT %obuild_debug% == yes GOTO else_if_db_build_lib_bhep_sh_16
     266:end_if_platform_19
     267SET obuild_platform_result=
     268
     269IF NOT %obuild_debug% == yes GOTO else_if_db_build_lib_bhep_sh_20
    250270  SET obuild_cxx_debug_local=%obuild_cxx_debug%
    251   GOTO end_if_db_build_lib_bhep_sh_16
    252 :else_if_db_build_lib_bhep_sh_16
     271  GOTO end_if_db_build_lib_bhep_sh_20
     272:else_if_db_build_lib_bhep_sh_20
    253273  SET obuild_cxx_debug_local=
    254 :end_if_db_build_lib_bhep_sh_16
    255 
    256 IF NOT %obuild_optimize% == yes GOTO else_if_opt_build_lib_bhep_sh_17
     274:end_if_db_build_lib_bhep_sh_20
     275
     276IF NOT %obuild_optimize% == yes GOTO else_if_opt_build_lib_bhep_sh_21
    257277  SET obuild_cxx_optimize_local=%obuild_cxx_optimize%
    258   GOTO end_if_opt_build_lib_bhep_sh_17
    259 :else_if_opt_build_lib_bhep_sh_17
     278  GOTO end_if_opt_build_lib_bhep_sh_21
     279:else_if_opt_build_lib_bhep_sh_21
    260280  SET obuild_cxx_optimize_local=
    261 :end_if_opt_build_lib_bhep_sh_17
    262 
    263 
    264 FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
    265 cd "%obuild_bhep_path%\%obuild_dir_bin%"
    266 IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
    267 FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Windows_NT`) DO SET obuild_platform_result=%%j
    268 cd "%obuild_pwd_bhep_0%"
    269 SET obuild_pwd_bhep_0=
    270 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_18
    271 SET obuild_cxx_macros=%obuild_cxx_macros% /D_HDF5USEDLL_
    272 :end_if_platform_18
    273 SET obuild_platform_result=
    274 
    275 IF NOT EXIST "%obuild_bhep_path%\%obuild_dir_bin%" MKDIR "%obuild_bhep_path%\%obuild_dir_bin%"
    276 IF NOT EXIST "%obuild_bhep_path%\%obuild_dir_bin%\obuild_find.exe" (
    277   cl.exe /nologo /DWIN32 /MD /O2 /W3 /GX /GR /Fe"%obuild_bhep_path%\%obuild_dir_bin%\obuild_find.exe" "%obuild_bhep_path%\obuild\cpp\obuild_find.cpp" 1> NUL
    278   IF EXIST obuild_find.obj DEL obuild_find.obj
    279 )
    280 FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
    281 cd "%obuild_bhep_path%\%obuild_dir_bin%"
    282 IF NOT EXIST obuild_find.exe  ECHO Program obuild_find.exe not found.  && GOTO obuild_return
    283 FOR /F "usebackq delims=;" %%j IN (`.\obuild_find.exe  HDF5 v1r*`) DO SET obuild_HDF5_path=%%j
    284 cd "%obuild_pwd_bhep_0%"
    285 SET obuild_pwd_bhep_0=
    286 IF NOT DEFINED obuild_HDF5_path  ECHO Can't find HDF5 package.  && GOTO obuild_return
    287 FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
    288 cd "%obuild_bhep_path%\%obuild_dir_bin%"
    289 IF NOT EXIST obuild_find.exe  ECHO Program obuild_find.exe not found.  && GOTO obuild_return
    290 FOR /F "usebackq delims=;" %%j IN (`.\obuild_find.exe  zlib v1r*`) DO SET obuild_zlib_path=%%j
    291 cd "%obuild_pwd_bhep_0%"
    292 SET obuild_pwd_bhep_0=
    293 IF NOT DEFINED obuild_zlib_path  ECHO Can't find zlib package.  && GOTO obuild_return
     281:end_if_opt_build_lib_bhep_sh_21
     282
     283
    294284
    295285SET obuild_cxx_includes=/I"%obuild_bhep_path%"
     
    301291cd "%obuild_pwd_bhep_0%"
    302292SET obuild_pwd_bhep_0=
    303 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_21
     293IF NOT %obuild_platform_result% == yes GOTO end_if_platform_24
    304294SET obuild_cxx_includes=%obuild_cxx_includes% -I${CLHEP_home}/include
    305 :end_if_platform_21
    306 SET obuild_platform_result=
    307 SET obuild_cxx_includes=%obuild_cxx_includes% /I"%obuild_HDF5_path%\include"
    308 SET obuild_cxx_includes=%obuild_cxx_includes% /I"%obuild_zlib_path%\include"
     295:end_if_platform_24
     296SET obuild_platform_result=
     297FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     298cd "%obuild_bhep_path%\%obuild_dir_bin%"
     299IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
     300FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% UNIX`) DO SET obuild_platform_result=%%j
     301cd "%obuild_pwd_bhep_0%"
     302SET obuild_pwd_bhep_0=
     303IF NOT %obuild_platform_result% == yes GOTO end_if_platform_25
     304SET obuild_cxx_includes=%obuild_cxx_includes% -I${HDF5_home}/include
     305:end_if_platform_25
     306SET obuild_platform_result=
    309307
    310308IF EXIST "%obuild_bhep_path%\%obuild_dir_bin%\lib_bhep" RMDIR /S /Q "%obuild_bhep_path%\%obuild_dir_bin%\lib_bhep"
     
    530528cd "%obuild_pwd_bhep_0%"
    531529SET obuild_pwd_bhep_0=
    532 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_59
     530IF NOT %obuild_platform_result% == yes GOTO end_if_platform_61
    533531SET obuild_cxx_linker_command=c++
    534 :end_if_platform_59
     532:end_if_platform_61
    535533SET obuild_platform_result=
    536534FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    540538cd "%obuild_pwd_bhep_0%"
    541539SET obuild_pwd_bhep_0=
    542 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_60
     540IF NOT %obuild_platform_result% == yes GOTO end_if_platform_62
    543541SET obuild_cxx_linker_command=c++
    544 :end_if_platform_60
     542:end_if_platform_62
    545543SET obuild_platform_result=
    546544FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    550548cd "%obuild_pwd_bhep_0%"
    551549SET obuild_pwd_bhep_0=
    552 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_61
     550IF NOT %obuild_platform_result% == yes GOTO end_if_platform_63
    553551SET obuild_cxx_linker_command=cxx
    554 :end_if_platform_61
     552:end_if_platform_63
    555553SET obuild_platform_result=
    556554FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     
    560558cd "%obuild_pwd_bhep_0%"
    561559SET obuild_pwd_bhep_0=
    562 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_62
     560IF NOT %obuild_platform_result% == yes GOTO end_if_platform_64
    563561SET obuild_cxx_linker_command=link.exe
    564 :end_if_platform_62
     562:end_if_platform_64
    565563SET obuild_platform_result=
    566564IF "%obuild_cxx_linker_command%" == ""  ECHO Variable obuild_cxx_linker_command not defined.  && GOTO obuild_return
     
    570568IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
    571569FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Darwin`) DO SET obuild_platform_result=%%j
    572 cd "%obuild_pwd_bhep_0%"
    573 SET obuild_pwd_bhep_0=
    574 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_63
    575 SET obuild_cxx_linker_debug=-g
    576 :end_if_platform_63
    577 SET obuild_platform_result=
    578 FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
    579 cd "%obuild_bhep_path%\%obuild_dir_bin%"
    580 IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
    581 FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Linux`) DO SET obuild_platform_result=%%j
    582 cd "%obuild_pwd_bhep_0%"
    583 SET obuild_pwd_bhep_0=
    584 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_64
    585 SET obuild_cxx_linker_debug=-g
    586 :end_if_platform_64
    587 SET obuild_platform_result=
    588 FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
    589 cd "%obuild_bhep_path%\%obuild_dir_bin%"
    590 IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
    591 FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% OSF1`) DO SET obuild_platform_result=%%j
    592570cd "%obuild_pwd_bhep_0%"
    593571SET obuild_pwd_bhep_0=
     
    599577cd "%obuild_bhep_path%\%obuild_dir_bin%"
    600578IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
     579FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Linux`) DO SET obuild_platform_result=%%j
     580cd "%obuild_pwd_bhep_0%"
     581SET obuild_pwd_bhep_0=
     582IF NOT %obuild_platform_result% == yes GOTO end_if_platform_66
     583SET obuild_cxx_linker_debug=-g
     584:end_if_platform_66
     585SET obuild_platform_result=
     586FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     587cd "%obuild_bhep_path%\%obuild_dir_bin%"
     588IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
     589FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% OSF1`) DO SET obuild_platform_result=%%j
     590cd "%obuild_pwd_bhep_0%"
     591SET obuild_pwd_bhep_0=
     592IF NOT %obuild_platform_result% == yes GOTO end_if_platform_67
     593SET obuild_cxx_linker_debug=-g
     594:end_if_platform_67
     595SET obuild_platform_result=
     596FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
     597cd "%obuild_bhep_path%\%obuild_dir_bin%"
     598IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
    601599FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Windows_NT`) DO SET obuild_platform_result=%%j
    602600cd "%obuild_pwd_bhep_0%"
    603601SET obuild_pwd_bhep_0=
    604 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_66
     602IF NOT %obuild_platform_result% == yes GOTO end_if_platform_68
    605603SET obuild_cxx_linker_debug=/DEBUG
    606 :end_if_platform_66
     604:end_if_platform_68
    607605SET obuild_platform_result=
    608606
     
    613611cd "%obuild_pwd_bhep_0%"
    614612SET obuild_pwd_bhep_0=
    615 IF NOT %obuild_platform_result% == yes GOTO end_if_platform_67
     613IF NOT %obuild_platform_result% == yes GOTO end_if_platform_69
    616614SET obuild_cxx_linker_options=/nologo
    617 :end_if_platform_67
    618 SET obuild_platform_result=
    619 
    620 IF NOT %obuild_debug% == yes GOTO else_if_db_build_lib_bhep_sh_68
     615:end_if_platform_69
     616SET obuild_platform_result=
     617
     618IF NOT %obuild_debug% == yes GOTO else_if_db_build_lib_bhep_sh_70
    621619  SET obuild_cxx_linker_debug_local=%obuild_cxx_linker_debug%
    622   GOTO end_if_db_build_lib_bhep_sh_68
    623 :else_if_db_build_lib_bhep_sh_68
     620  GOTO end_if_db_build_lib_bhep_sh_70
     621:else_if_db_build_lib_bhep_sh_70
    624622  SET obuild_cxx_linker_debug_local=
    625 :end_if_db_build_lib_bhep_sh_68
    626 
    627 IF NOT %obuild_optimize% == yes GOTO else_if_opt_build_lib_bhep_sh_69
     623:end_if_db_build_lib_bhep_sh_70
     624
     625IF NOT %obuild_optimize% == yes GOTO else_if_opt_build_lib_bhep_sh_71
    628626  SET obuild_cxx_linker_optimize_local=%obuild_cxx_linker_optimize%
    629   GOTO end_if_opt_build_lib_bhep_sh_69
    630 :else_if_opt_build_lib_bhep_sh_69
     627  GOTO end_if_opt_build_lib_bhep_sh_71
     628:else_if_opt_build_lib_bhep_sh_71
    631629  SET obuild_cxx_linker_optimize_local=
    632 :end_if_opt_build_lib_bhep_sh_69
     630:end_if_opt_build_lib_bhep_sh_71
    633631
    634632FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_bhep_0=%%d
Note: See TracChangeset for help on using the changeset viewer.