Commit ed09a031 authored by Andrea Sciaba's avatar Andrea Sciaba
Browse files

Using new OSG SW discovery

parent 410bb11a
......@@ -3,9 +3,26 @@
echo "<h2>Test of FroNtier under CMSSW</h2>"
# Source the CMS environment
echo "<h3>Sourcing the CMS environment</h3>"
if [ -n "$OSG_APP" ] ; then
SW_DIR=$OSG_APP/cmssoft/cms
if [ -n "$OSG_GRID" ] ; then
[ -f $OSG_GRID/setup.sh ] && source $OSG_GRID/setup.sh
echo "<p>OSG Middleware</p>"
if [ -d $OSG_APP/cmssoft/cms ] ;then
SW_DIR=$OSG_APP/cmssoft/cms
echo "<p>Checking variable: \$OSG_APP/cmssoft/cms=$OSG_APP/cmssoft/cms</p>"
elif [ -d $CVMFS/cms.cern.ch ] ; then
SW_DIR=$CVMFS/cms.cern.ch
echo "<p>Checking variable: \$CVMFS/cms.cern.ch=$CVMFS/cms.cern.ch</p>"
elif [ -d /cvmfs/cms.cern.ch ] ; then
SW_DIR=/cvmfs/cms.cern.ch
echo "<p>Checking fallback location: /cvmfs/cms.cern.ch</p>"
else
echo "<p>"
echo "Cannot find CMS software area."
echo "</p>"
exit $SAME_ERROR
fi
elif [ -n "$VO_CMS_SW_DIR" ] ; then
echo "<p>gLite Middleware</p>"
SW_DIR=$VO_CMS_SW_DIR
else
echo "ERROR: Neither VO_CMS_SW_DIR nor OSG_APP defined"
......
......@@ -12,10 +12,27 @@ echo "</pre>"
# Source the CMS environment
echo "<h3>Sourcing the CMS environment</h3>"
export SCRAM_ARCH=slc5_ia32_gcc434
if [ -n "$VO_CMS_SW_DIR" ] ; then
if [ -n "$OSG_GRID" ] ; then
[ -f $OSG_GRID/setup.sh ] && source $OSG_GRID/setup.sh
echo "<p>OSG Middleware</p>"
if [ -d $OSG_APP/cmssoft/cms ] ;then
SW_DIR=$OSG_APP/cmssoft/cms
echo "<p>Checking variable: \$OSG_APP/cmssoft/cms=$OSG_APP/cmssoft/cms</p>"
elif [ -d $CVMFS/cms.cern.ch ] ; then
SW_DIR=$CVMFS/cms.cern.ch
echo "<p>Checking variable: \$CVMFS/cms.cern.ch=$CVMFS/cms.cern.ch</p>"
elif [ -d /cvmfs/cms.cern.ch ] ; then
SW_DIR=/cvmfs/cms.cern.ch
echo "<p>Checking fallback location: /cvmfs/cms.cern.ch</p>"
else
echo "<p>"
echo "Cannot find CMS software area."
echo "</p>"
exit $SAME_ERROR
fi
elif [ -n "$VO_CMS_SW_DIR" ] ; then
echo "<p>gLite Middleware</p>"
SW_DIR=$VO_CMS_SW_DIR
elif [ -n "$OSG_APP" ] ; then
SW_DIR=$OSG_APP/cmssoft/cms
else
echo "<p>ERROR: Neither VO_CMS_SW_DIR nor OSG_APP defined</p>"
exit $SAME_ERROR
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment