home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 1999 March / PCWK3A99.iso / Linux / DDD331 / DDD-3_1_.000 / DDD-3_1_ / ddd-3.1.1 / INSTALL < prev    next >
Encoding:
Text File  |  1998-12-01  |  18.9 KB  |  540 lines

  1. Installing DDD                    -*- text -*-
  2. **************
  3.  
  4. For compiling and installing DDD on a system, please follow these
  5. instructions.
  6.  
  7.  
  8. Build Requirements
  9. ==================
  10.  
  11. To build a complete DDD from sources, you need:
  12.  
  13.    * The GNU C++ compiler (2.7.2 or later), including a matching
  14.      C++ I/O runtime library (libstdc++ or libg++).
  15.  
  16.      Some other C++ compilers have been reported to compile DDD as well:
  17.  
  18.      - Sun CC:  safe.
  19.      - SGI CC:  safe if full ISO C++ is supported (including `bool').
  20.                 Earlier versions are unsafe: DDD may compile, but
  21.                 crashes after a few interactions.
  22.      - DEC CXX: safe if full ISO C++ is supported (including `bool').
  23.      - AIX xlC: safe if full ISO C++ is supported (including `bool').
  24.                 Earlier versions are unsafe: they introduce some minor errors.
  25.      - Cfront 3.0: does not compile DDD.
  26.  
  27.      To avoid any risks, we strongly recommend to use the GNU C++ compiler.
  28.  
  29.    * A Motif Widget library.  Either
  30.  
  31.      - LessTif, 0.87 or later, or
  32.      - OSF/Motif (1.2 or later).
  33.  
  34.      Best results are obtained with OSF/Motif 2.0 and later.  We
  35.      recommend to use OSF/Motif or the most recent LessTif release,
  36.      available from `http://www.lesstif.org/'.
  37.  
  38.      LessTif should be used in (default) Motif 1.2 compatibility mode.
  39.      The Motif 2.0 compatibility mode of LessTif is still incomplete.
  40.  
  41.    * The X window library (Xlib) and X toolkit library (Xt), X11R4 or
  42.      later.  Best results are obtained with X11R6.3 and later.
  43.  
  44.    * A `make' program.  We recommend GNU make.
  45.  
  46.  
  47. We also recommend the following (optional) packages:
  48.  
  49.    * The XPM library (3.2 or later).  The XPM library brings support
  50.      for multi-color icons and logos.  Without XPM, DDD will use
  51.      monochrome icons.
  52.  
  53.    * The Athena Widget library (from X11R5 or later).  Having the
  54.      Athena Widget library is convenient for supporting panners - a
  55.      kind of two-dimensional scrollbar.
  56.  
  57.  
  58.  
  59. Execution Requirements
  60. ======================
  61.  
  62. To run DDD, you need:
  63.  
  64.    * An X server.  Without X, DDD does not run.
  65.  
  66.      If you are running a UNIX system, you certainly have X.  For
  67.      Windows systems, free X servers are available.  See the DDD FAQ
  68.      under `http://www.cs.tu-bs.de/softech/ddd/' for useful links.
  69.  
  70.    * A command-line debugger (the so-called `inferior' debugger).
  71.  
  72.      - To debug binary executables, best results are achieved with
  73.        GDB, the GNU debugger.  (GDB 4.x is required; we recommend GDB
  74.        4.17 or later.)  Using GDB, you can debug programs written in
  75.        C, C++, GNU Java (`guavac'), GNU Ada (`gnat'), GNU Fortran
  76.        (`g77') and GNU Modula-2.
  77.  
  78.      - As an alternative to GDB, DDD also supports the DBX debugger as
  79.        found on SUN, DEC, AIX, and IRIX systems.  This is useful if
  80.        you use a compiler that is better supported by DBX than by GDB.
  81.        DDD adapts automatically to a wide range of DBX variants.
  82.  
  83.      - As another alternative, DDD may also support the XDB debugger
  84.        as found on HP-UX systems.  XDB usage has been tested for C
  85.        programs only, but may work for other languages as well.
  86.  
  87.        Note that XDB support is no longer maintained in this DDD
  88.        release.  You can use HP's Wildebeest (WDB) instead, a free GDB
  89.        port to HP-UX (`http://www.hp.com/lang/tools/Debuggers/WDB/').
  90.  
  91.      - To debug Java bytecode programs, DDD supports JDB, the Java
  92.        Debugger, as of JDK 1.1 and later.
  93.  
  94.      - To debug Python programs, DDD supports PYDB, a PDB extension.
  95.        PYDB is included in the DDD distribution.
  96.  
  97.      - To debug Perl programs, DDD supports the Perl debugger as of Perl
  98.        5.003 and later.
  99.  
  100.  
  101. The following recommended helper applications should be in the user path:
  102.  
  103.    * An X terminal emulator program (`xterm' or likewise).  DDD needs
  104.      this for running programs in the separate execution window.
  105.  
  106.    * The GNU `info' program as well as various info files.
  107.  
  108.      - `info -f gdb' should show the GDB Manual.  DDD uses this to
  109.        display the GDB Reference.
  110.  
  111.      - `info -f libc' should show libc documentation.  DDD uses this
  112.        give online help on the various signals.
  113.  
  114.    * The `xfontsel' font selection program.  With `xfontsel', you can
  115.      select fonts interactively.
  116.  
  117.    * The `gnuplot' program, version 3.5 or later.  DDD uses `gnuplot'
  118.      to plot array and history data.
  119.  
  120.  
  121. Basic Installation
  122. ==================
  123.  
  124. Basically, to build DDD from sources, you enter two commands:
  125.  
  126.     $ ./configure
  127.     $ make
  128.  
  129. The `configure' shell script attempts to guess correct values for
  130. various system-dependent variables used during compilation.  It uses
  131. those values to create a `Makefile' in each directory of the DDD
  132. package.  It also creates some `.h' files containing system-dependent
  133. definitions.  Finally, it creates a shell script `config.status' that
  134. you can run in the future to recreate the current configuration, a
  135. file `config.cache' that saves the results of its tests to speed up
  136. reconfiguring, and a file `config.log' containing compiler output
  137. (useful mainly for debugging `configure').
  138.  
  139. If you need to do unusual things to compile the DDD package, please
  140. try to figure out how `configure' could check whether to do them, and
  141. mail us diffs or instructions to so they can be considered for the next
  142. release.  If at some point `config.cache' contains results you don't
  143. want to keep, you may remove or edit it.
  144.  
  145. The file `configure.in' is used to create `configure' by a program
  146. called `autoconf'.  You only need `configure.in' if you want to change
  147. it or regenerate `configure' using a newer version of `autoconf'.
  148.  
  149. The simplest way to compile DDD is:
  150.  
  151.   1. See the DDD WWW page, `http://www.cs.tu-bs.de/softech/ddd/',
  152.      for recent release notes.
  153.  
  154.   2. See the file `PROBLEMS' for known problems during build and
  155.      possible system-specific installation procedures.
  156.  
  157.   3. If you want to use DDD with LessTif, get a recent LessTif release
  158.      from `http://www.lesstif.org' and see the local `patches/'
  159.      subdirectory for patches to be applied.
  160.  
  161.   4. `cd' to the directory containing the DDD package source code
  162.      (that is, the directory named `ddd-<release>', *not* `ddd') and
  163.      type
  164.      
  165.     $ ./configure
  166.     
  167.      to configure DDD for your system.  If you're using `csh' on an
  168.      old version of System V, you might need to type
  169.  
  170.     % sh ./configure
  171.     
  172.      instead to prevent `csh' from trying to execute `configure' itself.
  173.      If you're building DDD on Windows using CYGWIN, type
  174.      
  175.     $ bash ./configure
  176.  
  177.      instead.
  178.  
  179.      Running `configure' takes awhile.  While running, it prints some
  180.      messages telling which features it is checking for.
  181.  
  182.      If `configure' reports an error or some bad result, check the
  183.      files `config.log' and `ddd/config.log' for diagnostics.
  184.  
  185.   5. Check the `Makefile', `Ddd', and `config.h' files generated by
  186.      `configure'.  Most settings should be guessed correctly by the
  187.      `configure' program.  You may, however, wish to edit the
  188.      settings, or re-run `configure' with special options.
  189.  
  190.      Frequently used `configure' options include `--program-prefix=x'
  191.      to have DDD installed as `xddd' (to avoid confusion with existing
  192.      `ddd' programs) or the `--with-motif...', `--with-athena...',
  193.      `--with-x...'  options used to specify the locations of Motif and
  194.      Athena widgets or the X libraries.  These and other `configure'
  195.      options are decribed below.
  196.  
  197.      If you have multiple library versions installed (for instance,
  198.      multiple X11 releases or releases from different sources), you
  199.      may also have to supply their locations.  See `Optional
  200.      features', below.
  201.  
  202.   6. Now type
  203.   
  204.     $ make
  205.     
  206.      to build DDD.  Any modern MAKE flavors should do, but for
  207.      incremental reconstruction, GNU MAKE is required on most
  208.      systems.  Please report any bugs and problems to
  209.      the DDD maintainers <ddd-bugs@ips.cs.tu-bs.de>.
  210.  
  211.   7. Building DDD takes awhile.  While DDD is being built, you may
  212.      wish to read and/or print the documentation shipped with DDD.
  213.      See the "Documentation" section, below.
  214.  
  215.      Please check the `make' output for compiler warnings.  Normally,
  216.      DDD should build without any warnings.  If you encounter
  217.      warnings, these may indicate actual problems in DDD code.
  218.  
  219.      Warnings that can be ignored safely include warnings about code
  220.      not being reached and warnings about unused, uninitialized, or
  221.      shadowed variables.
  222.  
  223.      However, GCC warnings that *must never be ignored* include:
  224.  
  225.     - `implicit declaration of function F'
  226.     - `cannot pass objects of type T through `...''
  227.  
  228.      If you encounter such a warning, GCC will generate unusable code.
  229.      Abort compilation and fix the problem.
  230.  
  231.      If you find a warning can be avoided by changing DDD code, send a
  232.      bug report to the DDD maintainers <ddd-bugs@ips.cs.tu-bs.de>,
  233.      including a context diff (`diff -c5') between the original and
  234.      the changed file.
  235.  
  236.   8. For a simple check, type
  237.   
  238.     $ make check
  239.     
  240.      This creates a sample C++ program `cxxtest' and then runs DDD
  241.      on it by invoking `./ddd cxxtest'.  Enjoy!
  242.  
  243.   9. If DDD crashes immediately after startup or after a few
  244.      interactions, first check your configuration (the output of
  245.      `./ddd --configuration') for version mismatches.  Also check
  246.      whether libraries and include files have matching versions.
  247.  
  248.      Then, see the `PROBLEMS' and `BUGS' files for known problems.  If
  249.      the problem is not listed, report it to the DDD maintainers
  250.      <ddd-bugs@ips.cs.tu-bs.de>.  If you need help and assistance, see
  251.      the DDD WWW page `http://www.cs.tu-bs.de/softech/ddd/' for
  252.      patches, people, and pointers.
  253.  
  254.  10. Optionally, type
  255.  
  256.     $ make strip
  257.     
  258.      to reduce the size of the `ddd' executable by stripping the
  259.      debugging information.
  260.  
  261.  11. Please consider sharing your DDD binary with other people lacking
  262.      Motif or a sane build environment.  As the DDD maintainers have
  263.      access to a limited number of systems only, they cannot produce
  264.      binaries for every single configuration.  For details, see
  265.      `ftp://ftp.ips.cs.tu-bs.de/pub/local/softech/ddd/bin/'.
  266.  
  267.  12. Type
  268.  
  269.     $ make install
  270.     
  271.      This installs the DDD executable `ddd' in some public place
  272.      (usually in `/usr/local/bin/') and the DDD manual page `ddd.1'
  273.      (in `/usr/local/man/man1/').  See `Installation Names', below,
  274.      on how to configure DDD to use other locations and names.
  275.  
  276.  13. If you have a `Ddd' app-defaults file installed from a previous
  277.      DDD version, this file will *override* the built-in DDD settings
  278.      and cause major problems.  Remove it.
  279.  
  280.  14. Like every good X citizen, DDD comes with an application defaults
  281.      file, named `ddd/Ddd'.  By default, this file is already compiled
  282.      into DDD, so you need not install it.
  283.  
  284.      In fact, we **STRONGLY RECOMMEND** not to install it; there is a
  285.      whole slew of version-skew problems associated with app-defaults
  286.      files, which are best avoided by simply not using them.  See step
  287.      13, above, and the comment at the beginning of `Ddd' for details.
  288.  
  289.      If you absolutely want to install it (or if you configured DDD
  290.      such that `Ddd' is not compiled into DDD), copy `Ddd' to a place
  291.      where app-defaults files are commonly found.
  292.  
  293.  15. You can remove the program binaries, libraries and object files
  294.      from the source directory by typing
  295.      
  296.     $ make clean
  297.  
  298.      To also remove the Makefiles, the header files containing
  299.      system-dependent definitions, and `config.status' (all the files
  300.      that `configure' created), type
  301.      
  302.     $ make distclean
  303.  
  304.      To also remove the system-independent derived files included in
  305.      the DDD distribution for your convenience (such as LEX and YACC
  306.      output), type
  307.      
  308.     $ make realclean
  309.  
  310.      instead.  (There is also `make ultraclean' that removes *every*
  311.      derived file; don't use it unless you know what you do.)
  312.  
  313.  16. You can remove DDD from your system by typing
  314.  
  315.     $ make uninstall
  316.  
  317.      This undoes all effects of a previous `make install'.
  318.  
  319.  
  320. Installation Details
  321. ====================
  322.  
  323. Compilers and Options
  324. ---------------------
  325.  
  326. Some systems require unusual options for compilation or linking that
  327. the `configure' script does not know about.  You can give `configure'
  328. initial values for variables by setting them in the environment.
  329. Using a Bourne-compatible shell, you can do that on the command line
  330. like this:
  331.  
  332.      CXX=/usr/egcs/bin/g++ CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure
  333.  
  334. Or on systems that have the `env' program, you can do it like this:
  335.  
  336.      env CXXCPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure
  337.  
  338. Options set this way include:
  339.  
  340. `CC'
  341.      The name of the C compiler
  342.  
  343. `CPPFLAGS'
  344.      Preprocessing flags used by the C compiler
  345.  
  346. `CFLAGS'
  347.      Compilation flags used by the C compiler
  348.  
  349. `CXX'
  350.      The name of the C++ compiler
  351.  
  352. `CXXCPPFLAGS'
  353.      Preprocessing flags used by the C++ compiler
  354.  
  355. `CXXFLAGS'
  356.      Compilation flags used by the C++ compiler
  357.  
  358. `LDFLAGS'
  359.      Linker flags used by both the C and C++ compiler
  360.  
  361.  
  362. Using a Different Build Directory
  363. ---------------------------------
  364.  
  365. You can compile the DDD package in a different directory from the one
  366. containing the source code.  Doing so allows you to compile it on more
  367. than one kind of computer at the same time.  To do this, you must use
  368. a version of `make' that supports the `VPATH' variable, such as GNU
  369. `make'.  `cd' to the directory where you want the object files and
  370. executables to go and run the `configure' script.  `configure'
  371. automatically checks for the source code in the directory that
  372. `configure' is in and in `..'.
  373.  
  374.  
  375. Installation Names
  376. ------------------
  377.  
  378. By default, `make install' will install the DDD files in
  379. `/usr/local/bin', `/usr/local/man', etc.  You can specify an
  380. installation prefix other than `/usr/local' by giving `configure' the
  381. option `--prefix=PATH'.
  382.  
  383. You can specify separate installation prefixes for
  384. architecture-specific files and architecture-independent files.  If
  385. you give `configure' the option `--exec-prefix=PATH', the package will
  386. use PATH as the prefix for installing programs and libraries.
  387. Documentation and other data files will still use the regular prefix.
  388.  
  389. You can cause DDD to be installed with an extra prefix or suffix on
  390. its name by giving `configure' the option `--program-prefix=PREFIX' or
  391. `--program-suffix=SUFFIX'.
  392.  
  393.  
  394. External Packages
  395. -----------------
  396.  
  397. By default, `configure' will configure DDD to use all supported
  398. external packages available on your system.
  399.  
  400. In some cases, `configure' may require additional information about
  401. these packages:
  402.  
  403. * `configure' can usually find the X include and library files
  404.   automatically, but if it doesn't, you can use the `configure'
  405.   options `--x-includes=DIR' and `--x-libraries=DIR' to specify their
  406.   locations.
  407.  
  408. * If `configure' doesn't find the Motif include and library files
  409.   automatically, you can use the `configure' options
  410.   `--with-motif-includes=DIR' and `--with-motif-libraries=DIR' to
  411.   specify their locations.
  412.  
  413. * If `configure' doesn't find the Athena include and library files
  414.   automatically, you can use the `configure' options
  415.   `--with-athena-includes=DIR' and `--with-athena-libraries=DIR' to
  416.   specify their locations.
  417.  
  418. * If `configure' doesn't find the XPM include and library files
  419.   automatically, you can use the `configure' options
  420.   `--with-xpm-includes=DIR' and `--with-xpm-libraries=DIR' to specify
  421.   their locations.
  422.  
  423.  
  424. You can also configure DDD to *ignore* some external packages:
  425.  
  426. * If you wish to disable Athena widgets and rely on Motif widgets alone,
  427.   you can use the `configure' option `--without-athena'.
  428.  
  429. * Likewise, `--without-xpm' disables XPM support.
  430.  
  431. * There is also a `--without-motif' option.  Don't use it; DDD will
  432.   not compile without Motif.
  433.  
  434.  
  435. Optional Features
  436. -----------------
  437.  
  438. By default, `configure' will configure DDD to use all supported
  439. optional DDD features.  There are two optional features.
  440.  
  441. * You can configure DDD such that the `Ddd' application defaults file
  442.   will not be compiled into the DDD executable.  This reduces the size
  443.   of the DDD executable by about 330 kBytes.  
  444.  
  445.   Note that this option requires you to install the application
  446.   defaults file in a place where DDD will find it.  This option will
  447.   also cause trouble if
  448.   - you want to maintain multiple DDD versions or 
  449.   - you upgrade to a new DDD version without removing or changing the
  450.     application defaults file.
  451.  
  452.   To disable the builtin application defaults file, use the `configure'
  453.   option `--disable-builtin-app-defaults'.
  454.  
  455.  
  456. * You can configure DDD such that the DDD manual will not be compiled
  457.   into the DDD executable.  This reduces the size of the DDD executable
  458.   by about 80 kBytes.
  459.  
  460.   `Help->DDD Reference' will then invoke `man ddd' to get the DDD
  461.   manual.  Note that this option only works well if man uses GNU
  462.   `groff' to format manual pages (such as `man' on Linux).  Be sure to
  463.   remove or update the manual page when upgrading to a new DDD version.
  464.  
  465.   To disable the builtin DDD manual, use the `configure' option
  466.   `--disable-builtin-manual'.
  467.  
  468.  
  469.  
  470. Specifying the System Type
  471. --------------------------
  472.  
  473. There may be some features `configure' can not figure out
  474. automatically, but needs to determine by the type of host DDD will run
  475. on.  Usually `configure' can figure that out, but if it prints a
  476. message saying it can not guess the host type, give it the
  477. `--host=TYPE' option.  TYPE can either be a short name for the system
  478. type, such as `sun4', or a canonical name with three fields:
  479.  
  480.      CPU-COMPANY-SYSTEM
  481.  
  482. See the file `config.sub' for the possible values of each field.
  483.  
  484.  
  485. Sharing Defaults
  486. ----------------
  487.  
  488. If you want to set default values for `configure' scripts to share,
  489. you can create a site shell script called `config.site' that gives
  490. default values for variables like `CC', `cache_file', and `prefix'.
  491. `configure' looks for `PREFIX/share/config.site' if it exists, then
  492. `PREFIX/etc/config.site' if it exists.  Or, you can set the
  493. `CONFIG_SITE' environment variable to the location of the site script.
  494. A warning: not all `configure' scripts look for a site script.
  495.  
  496.  
  497. Operation Controls
  498. ------------------
  499.  
  500. `configure' recognizes the following options to control how it
  501. operates.
  502.  
  503. `--cache-file=FILE'
  504.      Save the results of the tests in FILE instead of `config.cache'.
  505.      Set FILE to `/dev/null' to disable caching, for debugging
  506.      `configure'.
  507.  
  508. `--help'
  509.      Print a summary of the options to `configure', and exit.
  510.  
  511. `--quiet'
  512. `--silent'
  513. `-q'
  514.      Do not print messages saying which checks are being made.
  515.  
  516. `--srcdir=DIR'
  517.      Look for the DDD source code in directory DIR.  Usually
  518.      `configure' can determine that directory automatically.
  519.  
  520. `--version'
  521.      Print the version of Autoconf used to generate the `configure'
  522.      script, and exit.
  523.  
  524. `configure' also accepts some other, not widely useful, options.
  525.  
  526.  
  527.  
  528. Documentation
  529. =============
  530.  
  531. The DDD Manual, contained in the file `ddd/ddd.man', is the official
  532. DDD reference.  Note that DDD also has various on-line facilities.
  533.  
  534. A DDD manual in PostScript format (including several screen shots), as
  535. well as other documents related to DDD are contained in the `./doc'
  536. directory.  See the `./doc/README' file for details.
  537.  
  538.  
  539. $Id: INSTALL,v 1.63 1998/12/01 11:07:33 zeller Exp $
  540.