1. Installing XD2016 for Linux

The XD2016 package for Linux is supplied as precompiled, 64-bit statically linked executable, which should run under any flavour of Linux. Dynamically linked executables are also available for the PowerPC and Intel versions of Mac OS-X 10.
The plotting program XDGRAPH is quite platform dependent, so that precompiled executables may not work properly. For this reason the source code and makefile are also supplied. To compile XDGRAPH you need a FORTRAN-95 compiler such as gfortran , or a FORTRAN-77 compiler which knows about some common language extensions like INCLUDE or DO ...ENDDO. The graphics program and the master control program are written in C, so you need an ANSI C compiler, as well. Note that some C compilers provided as part of the operating system are not ANSI compatible. In addition, the Tcl and Tk libraries (available from http://www.tcl.tk) and optionally some OpenGL library such as MESA (usually supplied with Linux installation) are required. The program is tested with Tcl/Tk version 8.3. The file mk.config will need to be edited to suit your local installation of Linux/Mac.

The program is provided as a tar GZipped archive. This should be copied to a suitable directory (probably root privileges are required) and unzipped


gunzip xd2016.01.tar.gz
tar -xvf xd2016.01.tar
The resultant directory structure is something like :
xd2016 			containing the Makefile and config files for XDGRAPH
xd2016/ports            config files for various compilers for XDGRAPH
xd2016/bin              containing all the executables
xd2016/xdgraph/src      containing the source code for XDGRAPH
xd2016/lib/xd		containing system files and databanks
xd2016/lib/xdgraph      containing system files for XDGRAPH
The environment variable XD_DATADIR needs to be set to point to the full pathname of xd2016/lib/xd, and the executables directory xd2016/bin need to be added to the PATH environment variable of each user.

For Mac users, the dynamically linked executables require a pointer to the directory containing the relevant libraries. These libraries are included in the installation download, and are placed in the same directory as the executables. Set the environment variable DYLD_LIBRARY_PATH to point to this directory. For example, if you have installed XD2006 into /usr/xd2006_macm, then

export DYLD_LIBRARY_PATH=/usr/xd2006_macm/bin:$DYLD_LIBRARY_PATH
2 Installing XD2016 for Windows

The MS Windows release of XD2016 has been tested for all current Windows operating systems.

Two versions are provided, both as standard Windows installation programs. Both versions include all executables (with all required run-time libraries) and all system files. It is strongly suggested to install into the default directory given by the installation program. In addition, the working directory containing the XD data files (xd.mas, xd.inp etc) should not contain an embedded blank in its name, or all programs may not work.

The console version of XD for Windows works as a "DOS" like program, driven by the command line, in virtually exactly the same manner as the Linux versions of the program. It is necessary to open a DOS/Command prompt window, change to the working directory using "cd" and issue text commands.

The GUI version is controlled by the WinXD GUI (which has its own separate manual). The XD system programs (XDLSM, XDPROP etc) have exactly the same functionality as their console versions, but the text output is directed to the text window of the GUI. Programs may be executed, and the parameter and master files edited, using standard Windows drop-down menus and dialog boxes. In addition to the standard functionality of XD, the WinXD GUI has a number of extra useful graphical features. From version 2016.01 it is not longer necessary for the user to set any environment variables with the GUI version

In order for the console to function, the following environment variables need to be set

XD_DATADIR  (points to directory containing the data bank files)
XD_TCLDIR   (points to directory containing the XDGRAPH Tcl scripts)
TCL_LIBRARY (points to directory containing the TCL 8.3 system scripts)
Example values for these variables would be
XD_DATADIR={xddir}/lib/xd
XD_TCLDIR={xddir}/lib/xdgraph
TCL_LIBRARY={xddir}\bin\tcl8.3\
where {xddir} is the fullpath of the XD installation directory, e.g. "c:/xd2016" or "c:\xd2016".

Note the use of Unix style forward slashes "/" rather than DOS backslashes "\" as delimiters for the directory names with XD_DATADIR & XD_TCLDIR. These are a result of porting a Unix program to Windows and appear to be necessary. The standard DOS backslash should be used for the TCL_LIBRARY environment variable.

Finally, the console version requires that the directory {xddir}/bin is in the path, so that Windows has access to all the executables.