On 28 March 2013 13:02, Tim Jenness <[log in to unmask]> wrote:
>
> Note that the kappa initialization scripts are created from a definitions file and converted to sh and csh versions using a program called IFD. In principal these sorts of module definitions could be generated automatically at build time (although I'm not sure anyone would be motivated to do the work of modifying IFD).
>
Fair enough.
> also, if you have a module file for generic starlink then I'm happy to consider putting it in git.
I have attached what I have however, it needed to be tailored for the
local environment
(so adding the system lookup path for the system TCL library) so is
not of much use
as a generic template, indeed, as mentioned in the thread, I have
simply coddled the
StarlInk startup script to add the system lookup path for the system
TCL library and told
the users to carry on as before.
Notes:
1) It probably serves to highlight my knowledge of modules than anything else
2) It looked to add the Kappa functionality butthat is currently not
working, as per
other posts in the thread.
Thanks for the feedback,
Kevin
----
Starlink User Support list
For list configuration, including subscribing to and unsubscribing from the list, see
https://www.jiscmail.ac.uk/cgi-bin/webadmin?A0=STARLINK
#%Module1.0#####################################################################
##
## starlink modulefile
##
proc ModulesHelp { } {
global version
puts stderr "\tStarlink Kapuahi 2012091"
puts stderr "\n\tVersion $version\n"
}
module-whatis "Starlink Kapuahi 2012091"
conflict pgplot
set STARLINK_DIR /opt/Starlink/20120913/star-kapuahi
setenv STARLINK_DIR $STARLINK_DIR
#prepend-path PATH $STARLINK_DIR/bin
prepend-path LD_LIBRARY_PATH $STARLINK_DIR/starjava/lib/amd64
prepend-path LD_LIBRARY_PATH $STARLINK_DIR/lib
#
# This is needed last because Starlink has it's own TCL
prepend-path LD_LIBRARY_PATH /usr/lib64
if [ module-info mode load ] {
# Kappa
if { [ file exists $STARLINK_DIR/bin/kappa/kappa.sh ] } {
# puts stderr "Found the kappa.sh"
setenv KAPPA_DIR $STARLINK_DIR/bin/kappa
setenv KAPPA_HELP $STARLINK_DIR/help/kappa/kappa
set KAPPA_DIR $STARLINK_DIR/bin/kappa
set-alias "kappa" ". $KAPPA_DIR/kappa.sh"
set-alias "kappasetup" ". $KAPPA_DIR/kappa.sh"
}
# PGPLOT
setenv PGPLOT_DIR $STARLINK_DIR/bin
}
}
if [ module-info mode remove ] {
# Kappa
# This seems counter intuitive but does see the alias unset
set-alias "kappa" "echo not loaded"
set-alias "kappasetup" "echo not loaded"
unsetenv KAPPA_DIR
unsetenv KAPPA_HELP
# PGPLOT
unsetenv PGPLOT_DIR
}
# for Tcl script use only
set version "3.2.7"
----
Starlink User Support list
For list configuration, including subscribing to and unsubscribing from the list, see
https://www.jiscmail.ac.uk/cgi-bin/webadmin?A0=STARLINK
|