Index: snovis/trunk/obuild/sh/build_app_prog_snova
===================================================================
--- snovis/trunk/obuild/sh/build_app_prog_snova	(revision 134)
+++ snovis/trunk/obuild/sh/build_app_prog_snova	(revision 137)
@@ -107,31 +107,4 @@
   exit
 fi
-obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'Darwin'`
-if [ ${obuild_platform_result} = yes ] ; then
-snova_platform="Darwin"
-fi
-unset obuild_platform_result
-if [ "${obuild_platform_exe}" = "" ] ; then
-  echo "Variable obuild_platform_exe not defined."
-  exit
-fi
-obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
-if [ ${obuild_platform_result} = yes ] ; then
-bhep_home="/Users/barrand/dev/exp/nemo/bhep/v1r4p2"
-fi
-unset obuild_platform_result
-if [ "${obuild_platform_exe}" = "" ] ; then
-  echo "Variable obuild_platform_exe not defined."
-  exit
-fi
-obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
-if [ ${obuild_platform_result} = yes ] ; then
-snova_home="/Users/barrand/dev/exp/nemo/snova/v2r0p0"
-fi
-unset obuild_platform_result
-if [ "${obuild_platform_exe}" = "" ] ; then
-  echo "Variable obuild_platform_exe not defined."
-  exit
-fi
 obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
 if [ ${obuild_platform_result} = yes ] ; then
@@ -320,4 +293,49 @@
   exit
 fi
+obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
+if [ "${obuild_snova_path}" = "" ] ; then
+  echo "Can't find snova package."
+  exit
+fi
+if [ "${obuild_find_exe}" = "" ] ; then
+  echo "Variable obuild_find_exe not defined."
+  exit
+fi
+obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
+if [ "${obuild_snova_path}" = "" ] ; then
+  echo "Can't find snova package."
+  exit
+fi
+if [ "${obuild_find_exe}" = "" ] ; then
+  echo "Variable obuild_find_exe not defined."
+  exit
+fi
+obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
+if [ "${obuild_snova_path}" = "" ] ; then
+  echo "Can't find snova package."
+  exit
+fi
+if [ "${obuild_find_exe}" = "" ] ; then
+  echo "Variable obuild_find_exe not defined."
+  exit
+fi
+obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
+if [ "${obuild_snova_path}" = "" ] ; then
+  echo "Can't find snova package."
+  exit
+fi
+if [ "${obuild_find_exe}" = "" ] ; then
+  echo "Variable obuild_find_exe not defined."
+  exit
+fi
+obuild_bhep_path=`"${obuild_find_exe}" bhep 'v1r4p2'`
+if [ "${obuild_bhep_path}" = "" ] ; then
+  echo "Can't find bhep package."
+  exit
+fi
+if [ "${obuild_find_exe}" = "" ] ; then
+  echo "Variable obuild_find_exe not defined."
+  exit
+fi
 obuild_HDF5_path=`"${obuild_find_exe}" HDF5 'v1r*'`
 if [ "${obuild_HDF5_path}" = "" ] ; then
@@ -329,4 +347,49 @@
   exit
 fi
+obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
+if [ "${obuild_snova_path}" = "" ] ; then
+  echo "Can't find snova package."
+  exit
+fi
+if [ "${obuild_find_exe}" = "" ] ; then
+  echo "Variable obuild_find_exe not defined."
+  exit
+fi
+obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
+if [ "${obuild_snova_path}" = "" ] ; then
+  echo "Can't find snova package."
+  exit
+fi
+if [ "${obuild_find_exe}" = "" ] ; then
+  echo "Variable obuild_find_exe not defined."
+  exit
+fi
+obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
+if [ "${obuild_snova_path}" = "" ] ; then
+  echo "Can't find snova package."
+  exit
+fi
+if [ "${obuild_find_exe}" = "" ] ; then
+  echo "Variable obuild_find_exe not defined."
+  exit
+fi
+obuild_snova_path=`"${obuild_find_exe}" snova 'v2r0p0'`
+if [ "${obuild_snova_path}" = "" ] ; then
+  echo "Can't find snova package."
+  exit
+fi
+if [ "${obuild_find_exe}" = "" ] ; then
+  echo "Variable obuild_find_exe not defined."
+  exit
+fi
+obuild_bhep_path=`"${obuild_find_exe}" bhep 'v1r4p2'`
+if [ "${obuild_bhep_path}" = "" ] ; then
+  echo "Can't find bhep package."
+  exit
+fi
+if [ "${obuild_find_exe}" = "" ] ; then
+  echo "Variable obuild_find_exe not defined."
+  exit
+fi
 obuild_HDF5_path=`"${obuild_find_exe}" HDF5 'v1r*'`
 if [ "${obuild_HDF5_path}" = "" ] ; then
@@ -344,49 +407,9 @@
 fi
 
-if [ "${obuild_platform_exe}" = "" ] ; then
-  echo "Variable obuild_platform_exe not defined."
-  exit
-fi
-obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
-if [ ${obuild_platform_result} = yes ] ; then
-obuild_cxx_includes="-I${snova_home}"
-fi
-unset obuild_platform_result
-if [ "${obuild_platform_exe}" = "" ] ; then
-  echo "Variable obuild_platform_exe not defined."
-  exit
-fi
-obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
-if [ ${obuild_platform_result} = yes ] ; then
-obuild_cxx_includes="${obuild_cxx_includes} -I${snova_home}/source/GeomUtils/include"
-fi
-unset obuild_platform_result
-if [ "${obuild_platform_exe}" = "" ] ; then
-  echo "Variable obuild_platform_exe not defined."
-  exit
-fi
-obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
-if [ ${obuild_platform_result} = yes ] ; then
-obuild_cxx_includes="${obuild_cxx_includes} -I${snova_home}/source/SNgeom2/include"
-fi
-unset obuild_platform_result
-if [ "${obuild_platform_exe}" = "" ] ; then
-  echo "Variable obuild_platform_exe not defined."
-  exit
-fi
-obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
-if [ ${obuild_platform_result} = yes ] ; then
-obuild_cxx_includes="${obuild_cxx_includes} -I${snova_home}/source/SNvertex/include"
-fi
-unset obuild_platform_result
-if [ "${obuild_platform_exe}" = "" ] ; then
-  echo "Variable obuild_platform_exe not defined."
-  exit
-fi
-obuild_platform_result=`"${obuild_platform_exe}" ${obuild_platform} 'UNIX'`
-if [ ${obuild_platform_result} = yes ] ; then
-obuild_cxx_includes="${obuild_cxx_includes} -I${bhep_home}"
-fi
-unset obuild_platform_result
+obuild_cxx_includes="-I\"${obuild_snova_path}\""
+obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_snova_path}/source/GeomUtils/include\""
+obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_snova_path}/source/SNvertex/include\""
+obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_snova_path}/source/SNgeom2/include\""
+obuild_cxx_includes="${obuild_cxx_includes} -I\"${obuild_bhep_path}\""
 if [ "${obuild_platform_exe}" = "" ] ; then
   echo "Variable obuild_platform_exe not defined."
@@ -527,6 +550,14 @@
   obuild_cxx_linker_optimize_local=
 fi
-obuild_linked_libraries="-L${snova_home}/Darwin -lsnova -lsnvertex -lsngeom -lgeomutils"
-obuild_linked_libraries="${obuild_linked_libraries} -L${bhep_home}/Darwin -lbhep"
+obuild_linked_paths="-L\"${obuild_snova_path}/${obuild_dir_bin}\""
+obuild_linked_libraries=" -lsnova"
+obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_snova_path}/${obuild_dir_bin}\""
+obuild_linked_libraries="${obuild_linked_libraries}  -lsnvertex"
+obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_snova_path}/${obuild_dir_bin}\""
+obuild_linked_libraries="${obuild_linked_libraries}  -lsngeom"
+obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_snova_path}/${obuild_dir_bin}\""
+obuild_linked_libraries="${obuild_linked_libraries}  -lgeomutils"
+obuild_linked_paths="${obuild_linked_paths} -L\"${obuild_bhep_path}/${obuild_dir_bin}\""
+obuild_linked_libraries="${obuild_linked_libraries}  -lbhep"
 obuild_linked_libraries="${obuild_linked_libraries} -L${Geant4_home}/lib -lG4interfaces"
 if [ "${obuild_platform_exe}" = "" ] ; then
