5 Linking user-supplied subroutines

User-defined commands can be added to SPECX by making use of the subroutines EXTRNL1 to EXTRNL10. There is currently little support for this and the user is left to hack her way around the SPECX directory tree.

It is relatively easy to modify the distributed source code. This is mainly an option for a local but site-wide version with EXTRNLn routines. Assuming that you are a Starlink site manager you would proceed as follows

  % cd /star/sources/specx                       # 1
  % setenv INSTALL /star
  % ./mk deinstall
  
  % cd /star                                     # 2
  % mv specx /star/specx /star/local/specx
  
  % cd /star/local/specx/external                # 3
  {Make your modifications in this directory}
  
  % cd /star/local/specx                         # 4
  % setenv INSTALL /star/local
  % ./mk build
  % ./mk clean
  % ./mk install
  
  % cd /star/local/etc                           # 5
  {Modify files login and cshrc to reflect that SPECX is in /star/local}

In order to re-build SPECX you need a number of Starlink libraries and include files in their usual place. Non-Starlink sites may or may not have been issued with these libraries. As indicators, you can check whether you have /star/lib/libhds*, /star/include/dat_par and /star/figaro/lib/libfit.a.