ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/CMSDIST/cms-env.spec
(Generate patch)

Comparing COMP/CMSDIST/cms-env.spec (file contents):
Revision 1.12 by eulisse, Fri Jul 14 17:14:59 2006 UTC vs.
Revision 1.17 by eulisse, Tue Jul 18 08:44:46 2006 UTC

# Line 28 | Line 28 | case $SCRAM_ARCH in
28      osx104_pcc32) compilerv=gcc400;;
29   esac
30   SCRAM_ARCH=${SCRAM_ARCH}_$compilerv
31 +
32 + if [ $# -gt 0 ]
33 + then
34 +    SCRAM_ARCH=$1
35 + fi
36 +
37   export SCRAM_ARCH
38  
39 + here=%{instroot}
40 +
41   if [ "$VO_CMS_SW_DIR" != ""  ]
42   then
43      here=$VO_CMS_SW_DIR
44   else
37    here=`dirname $0`
38
45      if [ "$OSG_APP" != "" ]
46      then
47          here=$OSG_APP/cmssoft/cms
48      fi
49   fi
50  
51 < [ -d $here/${SCRAM_ARCH}/etc/profile.d ] || {echo "Your shell is not able to find where cmsset_default.sh is. Either cd into the directory where it is or move to zsh".; exit 1}
51 > if [ ! -d $here/${SCRAM_ARCH}/etc/profile.d ]
52 > then
53 >    echo "Your shell is not able to find where cmsset_default.sh is. Either cd into the directory where it is or move to zsh"
54 >    exit 1
55 > fi
56  
57 < for pkg in `ls $here/${SCRAM_ARCH}/etc/profile.d/ | grep -e'^S.*[.]sh'`
57 > for pkg in `/bin/ls $here/${SCRAM_ARCH}/etc/profile.d/ | grep -e'^S.*[.]sh'`
58   do
59          source $here/${SCRAM_ARCH}/etc/profile.d/$pkg
60   done
# Line 93 | Line 103 | switch ( ${SCRAM_ARCH} )
103   endsw
104  
105   setenv SCRAM_ARCH ${SCRAM_ARCH}_${compilerv}
106 +
107 + if ( $# > 0 ) then
108 +    setenv SCRAM_ARCH $1
109 + endif
110 +
111 + setenv here %instroot
112 +
113   if ( ${?VO_CMS_SW_DIR} ) then
114      setenv here $VO_CMS_SW_DIR
115   else
99    setenv here .
116      # OSG
117      if ( ${?OSG_APP} ) then
118          setenv here $OSG_APP/cmssoft/cms
# Line 108 | Line 124 | if ( ! -e $here/cmsset_default.csh ) the
124      echo "Please cd into the directory where cmsset_default.csh is."
125   endif
126  
127 < foreach pkg ( `ls ${here}/${SCRAM_ARCH}/etc/profile.d/ | grep -e'^S.*[.]csh'` )
127 > foreach pkg ( `/bin/ls ${here}/${SCRAM_ARCH}/etc/profile.d/ | grep -e'^S.*[.]csh'` )
128          source ${here}/${SCRAM_ARCH}/etc/profile.d/$pkg
129   end
130   setenv CMS_PATH $here

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines