Index: snovis/head/obuild/setup.bat
===================================================================
--- snovis/head/obuild/setup.bat	(revision 6)
+++ snovis/head/obuild/setup.bat	(revision 92)
@@ -44,5 +44,5 @@
 IF NOT EXIST "%obuild_snovis_path%\%obuild_dir_bin%" MKDIR "%obuild_snovis_path%\%obuild_dir_bin%"
 IF NOT EXIST "%obuild_snovis_path%\%obuild_dir_bin%\obuild_platform.exe" (
-  cl.exe /nologo /DWIN32 /MD /O2 /W3  /GX /GR /Fe"%obuild_snovis_path%\%obuild_dir_bin%\obuild_platform.exe" "%obuild_snovis_path%\obuild\cpp\obuild_platform.cpp"
+  cl.exe /nologo /DWIN32 /MD /O2 /W3  /GX /GR /Fe"%obuild_snovis_path%\%obuild_dir_bin%\obuild_platform.exe" "%obuild_snovis_path%\obuild\cpp\obuild_platform.cpp" 1> NUL
   IF EXIST obuild_platform.obj DEL obuild_platform.obj
 )
@@ -54,7 +54,7 @@
 cd "%obuild_pwd_snovis_0%"
 SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
-SET bhep_home=/Users/barrand/dev/exp/nemo/bhep/v1r4p1
-)
+IF NOT %obuild_platform_result% == yes GOTO end_if_platform_1
+SET bhep_home=/Users/barrand/dev/exp/nemo/bhep/v1r4p2
+:end_if_platform_1
 SET obuild_platform_result=
 FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snovis_0=%%d
@@ -64,7 +64,7 @@
 cd "%obuild_pwd_snovis_0%"
 SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
+IF NOT %obuild_platform_result% == yes GOTO end_if_platform_3
 SET bhep_platform=Darwin
-)
+:end_if_platform_3
 SET obuild_platform_result=
 FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snovis_0=%%d
@@ -74,7 +74,7 @@
 cd "%obuild_pwd_snovis_0%"
 SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
-SET GeomUtils_home=/Users/barrand/dev/exp/nemo/SNgeom/v0r1p0/build_area/GeomUtils
-)
+IF NOT %obuild_platform_result% == yes GOTO end_if_platform_5
+SET snova_home=/Users/barrand/dev/exp/nemo/snova/v2r0p0
+:end_if_platform_5
 SET obuild_platform_result=
 FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snovis_0=%%d
@@ -84,7 +84,7 @@
 cd "%obuild_pwd_snovis_0%"
 SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
-SET GeomUtils_platform=Darwin-i386
-)
+IF NOT %obuild_platform_result% == yes GOTO end_if_platform_7
+SET snova_platform=Darwin
+:end_if_platform_7
 SET obuild_platform_result=
 FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snovis_0=%%d
@@ -94,7 +94,7 @@
 cd "%obuild_pwd_snovis_0%"
 SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
-SET SNgeom2_home=/Users/barrand/dev/exp/nemo/SNgeom/v0r1p0/build_area/SNgeom2
-)
+IF NOT %obuild_platform_result% == yes GOTO end_if_platform_9
+SET CLHEP_home=/usr/local/CLHEP/2.0.3.1
+:end_if_platform_9
 SET obuild_platform_result=
 FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snovis_0=%%d
@@ -104,81 +104,11 @@
 cd "%obuild_pwd_snovis_0%"
 SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
-SET snova_home=/Users/barrand/dev/exp/nemo/SNgeom/v0r1p0/build_area/snova
-)
-SET obuild_platform_result=
-FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snovis_0=%%d
-cd "%obuild_snovis_path%\%obuild_dir_bin%"
-IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
-FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% UNIX`) DO SET obuild_platform_result=%%j
-cd "%obuild_pwd_snovis_0%"
-SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
-SET CLHEP_home=/usr/local/CLHEP/2.0.3.1
-)
-SET obuild_platform_result=
-FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snovis_0=%%d
-cd "%obuild_snovis_path%\%obuild_dir_bin%"
-IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
-FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% UNIX`) DO SET obuild_platform_result=%%j
-cd "%obuild_pwd_snovis_0%"
-SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
-SET Geant4_home=/geant4/geant4.8.2
-)
-SET obuild_platform_result=
-FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snovis_0=%%d
-cd "%obuild_snovis_path%\%obuild_dir_bin%"
-IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
-FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Darwin`) DO SET obuild_platform_result=%%j
-cd "%obuild_pwd_snovis_0%"
-SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
-SET Geant4_work=${Geant4_home}/Darwin
-)
-SET obuild_platform_result=
-FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snovis_0=%%d
-cd "%obuild_snovis_path%\%obuild_dir_bin%"
-IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
-FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Linux`) DO SET obuild_platform_result=%%j
-cd "%obuild_pwd_snovis_0%"
-SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
-SET Geant4_work=${Geant4_home}/slc3_gcc323
-)
-SET obuild_platform_result=
-FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snovis_0=%%d
-cd "%obuild_snovis_path%\%obuild_dir_bin%"
-IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
-FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Darwin`) DO SET obuild_platform_result=%%j
-cd "%obuild_pwd_snovis_0%"
-SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
-SET Geant4_system=Darwin-g++
-)
-SET obuild_platform_result=
-FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snovis_0=%%d
-cd "%obuild_snovis_path%\%obuild_dir_bin%"
-IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
-FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Linux`) DO SET obuild_platform_result=%%j
-cd "%obuild_pwd_snovis_0%"
-SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
-SET Geant4_system=Linux-g++
-)
-SET obuild_platform_result=
-FOR /F "usebackq delims=;" %%d IN (`cd`) DO SET obuild_pwd_snovis_0=%%d
-cd "%obuild_snovis_path%\%obuild_dir_bin%"
-IF NOT EXIST .\obuild_platform.exe  ECHO Program obuild_platform.exe not found.  && GOTO obuild_return
-FOR /F "usebackq" %%j IN (`.\obuild_platform.exe  %obuild_platform% Windows_NT`) DO SET obuild_platform_result=%%j
-cd "%obuild_pwd_snovis_0%"
-SET obuild_pwd_snovis_0=
-IF %obuild_platform_result% == yes (
-SET Geant4_system=WIN32-VC
-)
+IF NOT %obuild_platform_result% == yes GOTO end_if_platform_11
+SET Geant4_home=/usr/local/geant4/8.2
+:end_if_platform_11
 SET obuild_platform_result=
 IF NOT EXIST "%obuild_snovis_path%\%obuild_dir_bin%" MKDIR "%obuild_snovis_path%\%obuild_dir_bin%"
 IF NOT EXIST "%obuild_snovis_path%\%obuild_dir_bin%\obuild_find.exe" (
-  cl.exe /nologo /DWIN32 /MD /O2 /W3 /GX /GR /Fe"%obuild_snovis_path%\%obuild_dir_bin%\obuild_find.exe" "%obuild_snovis_path%\obuild\cpp\obuild_find.cpp"
+  cl.exe /nologo /DWIN32 /MD /O2 /W3 /GX /GR /Fe"%obuild_snovis_path%\%obuild_dir_bin%\obuild_find.exe" "%obuild_snovis_path%\obuild\cpp\obuild_find.cpp" 1> NUL
   IF EXIST obuild_find.obj DEL obuild_find.obj
 )
@@ -214,9 +144,10 @@
 SET NeutronHPCrossSections=%Geant4_home%\data\G4NDL3.10
 
-IF NOT DEFINED PATH (
+IF DEFINED PATH GOTO else_if_path_snovis_17
   SET PATH=%obuild_snovis_path%\%obuild_dir_bin%
-) ELSE (
+  GOTO end_if_path_snovis_17
+:else_if_path_snovis_17
   SET PATH=%PATH%;%obuild_snovis_path%\%obuild_dir_bin%
-)
+:end_if_path_snovis_17
 
 :obuild_return
