#%Module6.0##################################################################### proc ModulesHelp { } { global helpmsg puts stderr "\t$helpmsg\n" } # # 1. change 'version' string to appropriate version number: 6.0, 5.2, ... # set version 6.1 # # 2. change 'pgihome' to base directory: /usr/pgi, /opt/pgi, ... # set pgihome /usr/pgi # # 3. if you want to use exclusively 32-bit compilers # set target linux86 # if you want to use exclusively 64-bit compilers # set target linux86-64 # if you want the target to depend on the host # use the following code # set f [ exec arch ] if { $f == "x86_64" } { set target linux86-64 } else { set target linux86 } set pgidir $pgihome/$target/$version if [ file isdirectory $pgidir/bin ] { module-whatis "Changes the PGI home directory to $target $version" set helpmsg "Changes the PGI home directory to Target $target Version $version" # bring in new version setenv PGI $pgihome prepend-path PATH $pgidir/bin prepend-path MANPATH $pgidir/man } else { module-whatis "PGI $target $version not installed" set helpmsg "PGI $target $version not installed" if [ expr [ module-info mode load ] || [ module-info mode display ] ] { # bring in new version puts stderr "PGI $target $version not installed on [uname nodename]" } }