IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 3584


Ignore:
Timestamp:
Mar 30, 2005, 4:29:34 PM (21 years ago)
Author:
desonia
Message:

updated to current build procedures.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/mainpage.dox

    r3041 r3584  
    2525
    2626The installed code for psLib consists of header files and binary libraries in
    27 the form of static (libpslib.a) and shared (libpslib.so or libpslib.dylib,
    28 depending on operating system.) Assuming these components have been built and
    29 installed in the standard library path, psLib may be used within a program by
    30 including the line #include <pslib.h> and linking using the '-lpslib' option
    31 while linking.
     27the form of static and/or shared library, depending on the configuration options.
     28To assist in using the library, a script "pslib-config" is supplied that
     29provides the compiler and linker options.
    3230
    3331
    34 @section extinstall Required 3rd Party Libraries
     32@section extinstall 3rd Party Libraries
    3533
    3634Before building psLib from source, several 3rd party software libraries must
     
    3836 - GNU Scientific Library (GSL)
    3937     - Available at http://www.gnu.org/software/gsl
    40      - Compatibility tested with version is 1.4
     38     - Compatibility tested with version 1.4
    4139 - Fastest Fourier Transform in the West (FFTW), version 3, with single-precison float support
    4240     - Available at http://www.fftw.org
     
    4543 - C Flexible Image Transport System Input output (CFITSIO), version 2.480 or later
    4644     - Available at http://heasarc.gsfc.nasa.gov/docs/software/fitsio
    47      - Compatibility tested with version is 2.490
    48      - Versions earlier than 2.480 will not work as new functionality introduced in 2.480 is exercised
    49  - Doxygen Documentation System
    50      - Available at http://www.doxygen.org
    51      - Compatibility tested with version 1.3.6
    52      - The optional companion package, GraphViz (a.k.a., the 'dot' command), is recommended to enable header-file dependency diagrams
    53  - SLALIB
    54      - Available at http://star-www.rl.ac.uk/
    55      - Compatibility tested with package version number 2.4-12
    56      - We tested with the Fortran version of the library; this may cause an additional step to get things to link on untested systems/compilers, as there is no one standard for how the function-names appear in the library to C code.  The default way that psLib uses is all-lower case with a trailing '_', but one may need to add to CFLAGS in src/Makefile.Globals the following:
    57          - '-DFORTRAN_UNDERSCORE_PREFIX' if a '_' needs to be prefixed to the function names,
    58          - '-DFORTRAN_DOUBLE_UNDERSCORE_SUFFIX' if two the names needs two trailing '_'s., and/or
    59          - '-DFORTRAN_UPPERCASE' if the names appear as uppercase.
     45     - Compatibility tested with version 2.490, requires at least 2.480
    6046 - Gnome XML C parser and toolkit (libxml2)
    6147     - Available at http://www.xmlsoft.org
    62      - Compatibility tested with version 2-2.6.16-3
     48     - Compatibility tested with version 2.6.12 and 2.6.16
     49
     50Though not required to build the base library, several 3rd party software
     51libraries are needed for particular functionality.
     52 - Doxygen Documentation System
     53     - Required for creation of documentation
     54     - Available at http://www.doxygen.org
     55     - Compatibility tested with version 1.3.2 and 1.3.8
     56     - The optional companion package, GraphViz (a.k.a., the 'dot' command), is recommended to enable header-file dependency diagrams
     57 - MySQL
     58     - Required for database functionality
     59     - Available at http://dev.mysql.com
     60     - Compatibility tested with version 4.1.10a, requires at least 4.1.2
     61     - A server running locally is required for testing.
     62 - Autoconf/Automake
     63     - Required only if making from CVS
     64     - Available at http://www.gnu.org/software/autoconf and http://www.gnu.org/software/automake
     65     - Compatibility tested with version 2.59 (autoconf) and 1.9.2 (automake)
    6366
    6467We recommend using the particular versions listed as compatibility tested, as
     
    6871functionality is compatible with the tested version.
    6972
    70 @section install How to Build from Source
     73
     74@section obtain How to Obtain the Source
    7175
    7276Tested versions of psLib are put into a tar file and can be downloaded from:
     
    7579
    7680Though MHPCC recommends using the released packaged tar files descibed above,
    77 both daily development snapshots and direct CVS access is available.  The daily
    78 snapshots are available at
     81both recent daily development snapshots and direct CVS access is available.
     82The recent daily snapshots are available at:
    7983
    8084https://mhpcc.pan-starrs.org/code/snapshots
     
    9498where:
    9599  - USERNAME is your login name on the server
    96   - RELEASEBRANCH is the desired release branch, e.g. rel1, rel2, rel3, or rel4.
     100  - RELEASEBRANCH is the desired release branch, e.g. rel5.
    97101
    98102
    99 @section build How to Build the psLib library
     103@section build How to Build and Test the psLib library
    100104
     105The source uses autoconf/automake to build control the build process.  If, and
     106only if, the source came from CVS or a CVS snapshot, the configuration script
     107will have to be made via:
     108<pre>
     109$ cd psLib
     110$ make -f Makefile.cvs
     111</pre>
     112<i>This creates the configure script and Makefile templates.</i>
    101113
    102 The source should build using the Makefile in the psLib/src directory.  The
    103 recommended steps are:
     114The recommended steps to build the library are:
    104115<pre>
    105 $ cd psLib/src
     116$ cd psLib
     117$ ./configure
    106118$ make
     119$ make check
    107120$ make install
    108121</pre>
    109 <i>This builds and installs files to psLib/lib and psLib/include.</i>
     122<i>This builds, tests, and installs the library.</i>
    110123
    111 The make system of psLib allows users to specify specific locations for some of the
    112 third party libraries (see "Required 3rd Party Libraries" for a list).  If
    113 a location is not specified, the cooresponding library is assumed to be in
    114 the standard library paths, e.g., /usr or /usr/local.  The following are the
    115 environment variables that can be set before the make process above to force
    116 the location of the third-party libraries:
    117   - sladir: Location of SLALIB
    118       - e.g., <pre>export sladir=/usr/local/star</pre>
    119   - xml2config: Location of the xml2-config configuration executable
    120       - e.g., <pre>export xml2config=/usr/bin/xml2-config</pre>
     124The configure step allows users to specify specific locations for the third
     125party libraries (see "3rd Party Libraries" for a list), disabling of select
     126functionality (e.g., database and perl module), installation location, etc.
     127An enumeration of the options for configure, and the default values, can be
     128obtained via "./configure --help".
    121129
    122 Also, the installation location of the library can be set using environment
    123 variables.  The following are the supported variables for installation:
    124   - prefix: the installation prefix (default: current psLib directory)
    125       - e.g., <pre>export prefix=/usr/local</pre>
    126   - mandir: The man page installation location (default: $prefix/man)
    127   - includedir: The installation location for the header files (default: $prefix/include)
    128   - testbindir: Location for the test executables (default: $prefix/testbin)
    129   - libexecdir: Location for the library files (default: $prefix/lib)
    130   - TIME_CONFIG_FILE: Location of the 'psTime.config' configuration file (default: $(prefix)/config/psTime.config)
    131 
    132 @section run How to Build and Run Tests
    133 
    134 Since psLib is a library, there is no executable, per se. However, to test the
    135 installation, users may execute the unit test suite.  To build the unit test
     130Though 'make check' compiles and runs the test suite, one can also use custom
     131scripts to run all the tests and just a particular test.  To run the unit test
    136132suite, do the following:
    137133<pre>
    138134$ cd psLib/test
    139 $ make
    140 $ make install
    141 </pre>
    142 <i>This builds and installs the unit test files to the psLib/testbin directory.</i>
    143 
    144 To run the unit test suite, do the following:
    145 <pre>
    146 $ cd psLib/testbin
    147135$ ./FullUnitTest
    148136</pre>
    149 or to run a particular test
     137
     138This has the advantage over 'make check' in that it does not stop when a test
     139fails and it collects some very basic statistics on the results.  To run a
     140particular test, do the following:
    150141<pre>
    151 $ ./runTest testfilename
     142$ runTest testfilename
    152143</pre>
    153 
    154 Note: one can also fun the FullUnitTest from anywhere within psLib/test
    155 without performing the above 'make installtests' command first.  To do this,
    156 one needs to first set the PSLIB_ROOT environment variable to the top psLib
    157 directory 'psLib'.  FullUnitTest will search for tests in the subdirectories
    158 the the execution directory, perform a build of them (via 'make'), and run them.
    159 This can be useful if one wants to tweak the test code and doesn't desire to
    160 perform an install of all the tests each time the test file is touched.
    161144
    162145
     
    166149documentation embedded in the code using the following commands:
    167150<pre>
    168 $ cd psLib/src
     151$ cd psLib
    169152$ make docs
    170153</pre>
    171 <i>This places documentation in psLib/docs.</i>
     154<i>This places documentation in PREFIX/docs/psLib, where PREFIX is set using
     155the configure script.</i>
    172156
    173157Also, a prebuilt set of code documentation for both the releases and last
Note: See TracChangeset for help on using the changeset viewer.