ASCEND IV UNIX Source Distribution

This page is out of date. Please see the ASCEND wiki for current content.

The ASCEND IV software is provided WITHOUT WARRANTY under the GNU Public License.

If you wish to obtain information regarding short courses on the use of ASCEND, send email to Art Westerberg <aw0a@edrc.cmu.edu>.


Warranty

ASCEND is distributed without warranty. See the file COPYING for details.


Registration

Register yourself as an ASCEND user, if you haven't already done so. Our user support is free, but subject to the demands of our primary research. Most questions are addressed within 48 hours, though the hard ones may take longer.


Documentation

Documentation is no longer built into the distributions, per user request. It can be viewed or downloaded as PDF files from the web.

You can also download and print the books:


Requirements

To build and run ASCEND, you need

  1. Some flavor of UNIX. This release of ASCEND has been built on the following platforms:
    • DEC Alpha running OSF/Digital Unix 3.2, 4.0
    • HP9000/700 running HP-UX 9.05, 10.20
    • IBM PowerPC running AIX 3.2, 4.2
    • Intel x86 running RedHat Linux 4.2 and later.
    • Intel x86 running NetBSD 1.1
    • SGI Indy running Irix 6.2
    • Sun Sparc running SunOS 4.1.x
    • Sun Sparc running Solaris 2.5
  2. An ANSI-C compiler and C libraries that support ANSI C.
  3. X11. This release of ASCEND has only been built on X11r6.
  4. The ASCEND IV v0.9.1 source code [ gzipped 3M | bzip2'ed 2.5M ].
  5. Tcl/Tk 8.3.5 built and installed on your system. You may download the
    Tcl v8.3.5 source [ gzipped 2.9M | compressed 3.3M ] and the
    Tk v8.3.5 source [ gzipped 2.6M | compressed 3.3M ] from our web site, or, if you prefer, you may download Tcl and Tk from the official Tcl/Tk 8.3 web site. Do not use Tcl/Tk8.4 (or later) as this version does not work.
  6. Tktable 2.8 built and installed on your system.
  7. yacc or bison.
  8. Recommend (but not required) tools are:

  9. The flex lexer, version 2.4.1 or later.
  10. A FORTRAN compiler. (You can build ASCEND without a FORTRAN compiler, but you will lose some functionality. See below.) gcc/g77 users take note: your g77 and gcc must be a matched pair, as indicated in the g77 documentation. We have successfully built with gcc 2.7.2.3.f.2 and g77 0.5.22 under Red Hat Linux release 4.2 (Biltmore) Kernel 2.0.30, 5.2 k2.0.36, and 6.1 k2.2.12-20.
  11. xgraph [ gzipped 94k | compressed 146k ] or tkxgraph [ gzipped 141k | compressed 241k ], graphing programs, to take advantage of the graphing capabilities in ASCEND.


Unpacking ASCEND

Building and using ASCEND requires release 8.3.5 of the Tcl language and Tk Toolkit, and release 2.5 of the Tktable add-on, as well as the ASCEND sources. Please make sure you have all the pieces. Links to download these pieces are in the previous section.

Once you have downloaded the files your site requires, you are ready to unpack ASCEND. We suggest you move the files you downloaded into their own directory. `cd' into that directory.

To unpack the *.gz files, issue the command:

gzip -c -d ascend4-0.9.1.tar.gz | tar xf -

and repeat for each ...tar.gz file.

To unpack the *.bz2 files, issue the command:

bzip2 -c -d ascend4-0.9.1.tar.bz2 | tar xf -

and repeat for each ...tar.bz2 file.

To unpack the *.Z files, issue the command:

compress -c -d ascend4-0.9.1tar.Z | tar xf -

and repeat for each ...tar.Z file.


Building ASCEND

These are the instructions for building and installing release 0.9.1 of the ASCEND IV mathematical modeling environment on a UNIX system. Where these instructions and the INSTALL file of the distribution disagree, the INSTALL file is more likely to be correct.

ASCEND comes with a `configure' script to help you build ASCEND on your favorite platform. However, the configure script is not perfect and UNIX systems vary widely, so take some time to read through this file to see what you must do to have ASCEND successfully build on your machine.

The `configure' shell script attempts to guess correct values for various system-dependent variables used during compilation. It uses those values to create a `Makefile' in each directory of the ASCEND source tree and a `ConfigAscend' file in the ascend4 directory. Also, it creates a shell script `config.status' that you can run in the future to recreate the current configuration of Makefiles, and a file `config.log' containing compiler output (useful mainly for debugging `configure').

The file `configure.in' is used to create `configure' by a program called `autoconf'. You only need `configure.in' if you want to change it or regenerate `configure' using a newer version of `autoconf'. The `configure.in' that comes with ASCEND was designed to use version 2.12 of `autoconf'.

The following instructions assume you have downloaded the files

from the ASCEND web site into the directory where you plan to build ASCEND; we'll call that directory BUILD_DIR. Unpacking those files in the build directory creates the directories

  • ascend4-0.9.1/
  • tcl8.3/
  • tk8.3/
  • Tktable2.8/

The simplest way to compile this package is:

  1. Build and install Tcl v8.3.5. If Tcl v8.3.5 is already installed, go to the next step; otherwise obtain the Tcl v8.3.5 distribution, unpack it, and build it following the directions in the distribution. A summary of the steps to build Tcl are:
    1. `cd' into the `tcl8.3/unix' directory.
    2. Type `./configure' to configure Tcl's Makefile. If you want to install Tcl in a directory other than `/usr/local', pass that directory in the `--prefix' argument to `configure'. For example:

      ./configure --prefix=/full/install/path

      If you do not plan to install ASCEND, a reasonable value for the `--prefix' option is the ascend4 directory in the ASCEND distribution, i.e.,

      ./configure --prefix=BUILD_DIR/ascend4-0.9.1/ascend4

    3. Type `make' to build Tcl.
    4. Type `make test' to test Tcl (optional).
    5. Type `make install' to install Tcl into the directory in the `--prefix' argument. If you do not want to install the man pages, issue the command

      make install-binaries install-libraries

      to install only the binaries, the header file, and the *.tcl files.
    6. Do NOT `make clean' ntil after you have made the Tk library.
    7. If you run into problems building Tcl, please consult the Tcl distribution.
  2. Build and install Tk v8.3.5. If Tk v8.3.5 is already installed, go to the next step; otherwise obtain the Tk v8.3.5 distribution, unpack it, and build it following the directions in the distribution. A summary of the steps to build Tk are:
    1. `cd' into the `tk8.3/unix' directory.
    2. Type `./configure' to configure Tk's Makefile. You should use the same value for `--prefix' here as you did when building Tcl.
    3. Type `make' to build Tk.
    4. Type `make test' to test Tk (optional).
    5. Type `make install' to install Tk into the directory in the `--prefix' argument. If you do not want to install the man pages, issue the command

      make install-binariesinstall-libraries

      to install only the binaries, the header file, and the *.tcl files.
    6. You can now `make clean' to remove the object files, library, and executable. You can also `cd' into the `tcl8.3/unix' directory and `make clean' there.
    7. If you run into problems building Tk, please consult the Tk distribution.
  3. Build and install Tktable v2.8. If Tktable v2.8 is already installed, go to the next step; otherwise obtain the Tktable v2.8 distribution, unpack it, and build it following the directions in the distribution. A summary of the steps to build Tktable are:
    1. `cd' into the `Tktable2.8' directory.
    2. Type `./configure' to configure Tktable's Makefile. You should use the same value for `--prefix' here as you did when building Tcl and Tk.
    3. Type `make' to build Tktable.
    4. Type `make install' to install Tktable into the directory in the `--prefix' argument.
    5. You can now `make clean' to remove the object files, and library.
    6. If you run into problems building Tktable, please consult the Tktable distribution.
  4. `cd' to the `ascend4-0.9.1' directory and type `./configure' to configure ASCEND for your system. If you're using `csh' on an old version of System V, you might need to type `sh ./configure' instead to prevent `csh' from trying to execute `configure' itself. Running `configure' takes awhile. While running, it prints some messages telling which features it is checking for. See below for arguments to pass to `configure' and for explanations of the and error messages `configure' may produce.
  5. `cd' into the `ascend4' directory and type `make'. This will build any FORTRAN libraries that `configure' didn't find (assuming `configure' found a FORTRAN compiler) before it builds ASCEND.
  6. Once `make' successfully completes, typing `bin/ascend4' should start ASCEND. Note that your `DISPLAY' environment variable will need to be set to run ASCEND. In the `Script' window you will see the License and Warranty for ASCEND. Please read it.
  7. If you have built ASCEND for your personal use, you can continue to run ASCEND from the build directory. If you want to install ASCEND elsewhere so that others may use it or to free disk space, type `make install' which will install the ascend binary (ascend4), the ASCEND tcl support files (found in the TK directory), and the ASCEND models (found in the models directory).
  8. You can remove the program binaries and object files from the source code directory by typing `make clean'. To also remove the files that `configure' created (so you can compile the package for a different kind of computer), type `make distclean'.


Compilers and Options

Some systems require unusual options for compilation or linking that the `configure' script does not know about. You can give `configure' initial values for variables by setting them in the environment. Using a Bourne-compatible shell, you can do that on the command line like this:

CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure

Or on systems that have the `env' program, you can do it like this:

env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure


Warnings and Errors Generated by Configure

Most of the time `configure' will work properly and no intervention is needed. We have developed `configure' to work around common problems, in which case it prints a warning and goes on. These common problems include:

  • You do not have a recent version of the `flex' lexer.

    In this case, `configure' will set up the Makefiles to use pregenerated C files instead of running `flex' on the input files ascend4/compiler/scanner.l and ascend4/interface/typelex.l. If you have `flex' version 2.4.1 or newer and `configure' cannot find it, set the `LEX' environment variable to the full path of your `flex' program and run `configure' again.

  • You do not have a FORTRAN77 compiler.

    For this case, `configure' disables use of the LSODE integrator, so you will not be able to integrate with ASCEND. If you have a Fortran compiler that `configure' is not finding, re-run `configure' with the option --with-fortran=COMPILER,LIBRARIES where COMPILER is your Fortran compiler and LIBRARIES are any libraries it needs. For example, under SunOS:

    configure --with-fortran='/usr/lang/f77,-L/usr/lang/lib -lF77 -lM77'

    If you have GNU Fortran compiler installed as `g77', configure should do the right thing. If you have it installed as `f77', configure may become confused because it look for the wrong set of libraries. In this case, run configure with the argument

    configure --with-fortran='g77,-lf2c'

  • Cannot find CONOPT library nor source code.

    CONOPT is proprietary, so we cannot distribute it, but we do distribute an interface to it. To build with CONOPT, run `configure' with the option --with-conopt=CONOPTLIB where CONOPTLIB is the location of your CONOPT library. For example:

    configure --with-conopt=/export/conopt/lib/libconsub.a

There are problems which `configure' lists as fatal errors because these problems prevent you from building ASCEND. Those problems are:

  • Cannot find ANSI C compiler.

    We have written ASCEND in ANSI C; you'll need a compiler that understands ANSI C and C libraries that implement ANSI C features in order to build ASCEND. If you have an ANSI compiler that `configure' is not finding, set the `CC' environment variable to its location and run configure again. If you still get the error, please make sure your compiler understands ANSI C and send us mail so we can fix `configure'. Note that `gcc' understands ANSI C, so run `configure' with the `--enable-gcc' argument which allows `configure' the search for `gcc'. Also note when using `gcc' under SunOS 4.1.x the link phase will fail, since the standard SunOS 4.1.x setup does not provide ANSI C libraries.

  • Cannot find compatible Tcl/Tk library or header.

    ASCEND needs Tcl v8.3.5 and Tk v8.3.5 compatible library files and header files. If you have built and installed Tcl and Tk 8.3.5 and `configure' cannot find them, run configure again with the arguments `--with-tcl=TCL_LIB,TCL_HEADER' where TCL_LIB is the location of the Tcl library, and TCL_HEADER is the location of the Tcl header file; a similar `--with-tk' argument exists. For example,

    configure --with-tcl='-L/usr/local/lib -ltcl,/usr/local/include/tcl.h' --with-tk='-L/usr/local/lib -ltk,/usr/local/include/tk.h'


ASCEND Specific Options for Configure

`configure' accepts several options. Type `configure --help' for a full list. Options of particular interest when building ASCEND are:

  • --enable-gcc

    By default, `configure' uses the environment variable `CC', then `cc', `c89', `xlf', and `acc' when searching for an ANSI C compiler. This option tells `configure' to use the environment variable `CC', next to look for `gcc', and then to consider the other compilers as listed above when it is trying to locate an ANSI C compiler.

  • --enable-optimization

    By default, `configure' sets `CFLAGS' such that the C files are built with debugging information (-g). This option turns off debugging and turns on optimization and NDEBUG (-O -DNDEBUG=1).

  • --without-models

    If `configure' finds the `models' source directory, it will descend into it and create Makefiles. With this option, `configure' does not create Makefiles in the `models' directory. If there is no `models' source directory, this option has no effect. The only purpose for the Makefiles in the `models' directory is to allow the `make install' target to work.

  • --without-TK

    Same as the `--without-models' option except is applies to the `TK' subdirectory.


Compiling For Multiple Architectures

You can compile ASCEND for more than one kind of computer at the same time, by placing the object files for each architecture in their own directory. To do this, you must use a version of `make' that supports the `VPATH' variable, such as GNU `make'. `cd' to the directory where you want the object files and executables to go and run the `configure' script. `configure' automatically checks for the source code in the directory that `configure' is in and in `..'.

If you have to use a `make' that does not support the `VPATH' variable, you have to compile the package for one architecture at a time in the source code directory. After you have installed the package for one architecture, use `make distclean' before reconfiguring for another architecture.


Installation Names

By default, `make install' will install the package's files in `/usr/local/bin', `/usr/local/man', etc. You can specify an installation prefix other than `/usr/local' by giving `configure' the option `--prefix=PATH'.

You can specify separate installation prefixes for architecture-specific files and architecture-independent files. If you give `configure' the option `--exec-prefix=PATH', the package will use PATH as the prefix for installing programs and libraries. Documentation and other data files will still use the regular prefix.

In addition, if you use an unusual directory layout you can give options like `--bindir=PATH' to specify different values for particular kinds of files. Run `configure --help' for a list of the directories you can set and what kinds of files go in them.

Note that you should use the final `apparent' resting place of the files as the arguments to `--prefix' and `--exec_prefix' since these options often set variables that get compiled into the binaries. When you actually do `make install' to install the program, pass the `actual' resting place on the `make' line. For example, if ascend appears to live in /usr/local/bin/ascend but that is actually a symbolic link to /afs/cs/local/ascend/@sys/omega/bin/ascend, you should:

configure --prefix=/usr/local
make
make install prefix=/afs/cs/local/ascend/@sys/omega


Optional Features

For packages that use the X Window System, `configure' can usually find the X include and library files automatically, but if it doesn't, you can use the `configure' options `--x-includes=DIR' and `--x-libraries=DIR' to specify their locations.


Specifying the System Type

There may be some features `configure' can not figure out automatically, but needs to determine by the type of host the package will run on. Usually `configure' can figure that out, but if it prints a message saying it can not guess the host type, give it the `--host=TYPE' option. TYPE can either be a short name for the system type, such as `sun4', or a canonical name with three fields:

CPU-COMPANY-SYSTEM

See the file `config/config.sub' for the possible values of each field. If `config/config.sub' isn't included in this package, then this package doesn't need to know the host type.


Sharing Defaults

If you want to set default values for `configure' scripts to share, you can create a site shell script called `config.site' that gives default values for variables like `CC', `cache_file', and `prefix'. `configure' looks for `PREFIX/share/config.site' if it exists, then `PREFIX/etc/config.site' if it exists. Or, you can set the `CONFIG_SITE' environment variable to the location of the site script. A warning: not all `configure' scripts look for a site script.


Operation Controls

`configure' recognizes the following options to control how it operates.

  • --help

    Print a summary of the options to `configure', and exit.

  • --quiet
    --silent
    -q

    Do not print messages saying which checks are being made.

  • --srcdir=DIR

    Look for the package's source code in directory DIR. Usually `configure' can determine that directory automatically.

  • --version

    Print the version of Autoconf used to generate the `configure' script, and exit.

`configure' also accepts some other, not widely useful, options.




Home | Download | Documentation | About | Contact


Copyright ¨ 1997 Carnegie Mellon University. All rights reserved.
Send all questions and comments regarding this site to
ascend+www@edrc.cmu.edu.
Last modified: Mon Jul 9 12:40:03 EDT 2007