Difference between revisions of "Main Page"
(Put cmake invocation into its own sub-section and add section for Post-CMake processing) |
m (→cmake invocation) |
||
Line 45: | Line 45: | ||
-DCMAKE_VERBOSE_MAKEFILE=ON ../plplot_cmake >& cmake.out | -DCMAKE_VERBOSE_MAKEFILE=ON ../plplot_cmake >& cmake.out | ||
− | Note an empty build directory called build_dir is used to insure a clean start, and ../plplot_cmake is a freshly checked out source tree (which remains clean because you never actually create any files in that directory tree). To start fresh, simply execute "cd build_dir; rm -rf *". Of course, this is an extremely dangerous command (since it removes everything in the current directory and all subdirectories), but you should be okay so long as you cd to the correct directory before executing the "rm" command. | + | Check the cmake.out file for any configuration issues. Note an empty build directory called build_dir is used to insure a clean start, and ../plplot_cmake is a freshly checked out source tree (which remains clean because you never actually create any files in that directory tree). To start fresh, simply execute "cd build_dir; rm -rf *". Of course, this is an extremely dangerous command (since it removes everything in the current directory and all subdirectories), but you should be okay so long as you cd to the correct directory before executing the "rm" command. |
===== Post-CMake processing ===== | ===== Post-CMake processing ===== |
Revision as of 14:57, 31 August 2006
This is the (un-)official Wiki for PLplot. It should provide additional information to complement the PLplot documentation.
Contents
- 1 Building PLplot
- 1.1 Building PLplot with our traditional ABS
- 1.2 Building PLplot with our new CBS
- 1.2.1 Unix
- 1.2.1.1 (Optional) set environment variables to help CMake find system components that are installed in non-standard locations
- 1.2.1.2 (Optional) set environment variables to specify the compilers and compiler flags
- 1.2.1.3 cmake invocation
- 1.2.1.4 Post-CMake processing
- 1.2.1.5 Specifics for various Unix platforms
- 1.2.2 Windows
- 1.2.1 Unix
- 2 Edit Wiki pages
Building PLplot
Our traditional Autotools Build System (ABS) may be used to configure the PLplot build on Unix platforms. Alternatively, our new CMake Build System (CBS) may be used to configure the PLplot build on both Unix and Windows platforms.
Building PLplot with our traditional ABS
Building PLplot with our new CBS
Download the appropriate package of CMake for your system (Website) - at least version 2.4.3 - and unpack it.
Unix
(Optional) set environment variables to help CMake find system components that are installed in non-standard locations
Here is one particular example (which must be executed before the cmake invocation discussed below).
export PKG_CONFIG_PATH=/home/software/libLASi/install/lib/pkgconfig export CMAKE_LIBRARY_PATH=/home/software/autotools/install/lib:/home/software/cgmlib/cd1.3 export CMAKE_INCLUDE_PATH=/home/software/autotools/install/include:/home/software/cgmlib/cd1.3
In these special cases, PKG_CONFIG_PATH helps CMake to use the pkg-config command for a non-standard libLASi install location; CMAKE_LIBRARY_PATH helps CMake to find libltdl and libcd in non-standard install locations; and CMAKE_INCLUDE_PATH helps CMake to find the headers for libltdl and libcd in non-standard install locations.
(Optional) set environment variables to specify the compilers and compiler flags
Here is one particular example (which must be executed before the cmake invocation discussed below).
export CC="gcc -O2"
export CXX="g++ -O2"
export FC="g77 -O2"
Note a better option is to set CMAKE_BUILD_TYPE to one of Debug, Release, RelWithDebInfo, or MinSizeRel. If you don't set this variable and don't set the environment variables above, then by default no compiler options (i.e., no optimization and no debugging symbols) are used for gcc-related compilers for our CBS which makes for very fast builds, but slow execution.
cmake invocation
mkdir build_dir
cd build_dir
cmake -DCMAKE_INSTALL_PREFIX=/my/prefix \
-DCMAKE_VERBOSE_MAKEFILE=ON ../plplot_cmake >& cmake.out
Check the cmake.out file for any configuration issues. Note an empty build directory called build_dir is used to insure a clean start, and ../plplot_cmake is a freshly checked out source tree (which remains clean because you never actually create any files in that directory tree). To start fresh, simply execute "cd build_dir; rm -rf *". Of course, this is an extremely dangerous command (since it removes everything in the current directory and all subdirectories), but you should be okay so long as you cd to the correct directory before executing the "rm" command.
Post-CMake processing
The PLplot build and install follows the cmake invocation. The installed tree can be tested with the PLplot install-tree test for a large variety of PLplot device drivers. In addition, build-tree tests may be done with the "ctest" command. Note, these tests are limited to just the psc (colour postscript) device and can only be performed if cmake is invoked with the -DBUILD_TEST=ON option (which roughly doubles the build time because all the examples must be built).
Specifics for various Unix platforms
Windows
- Configure PLplot for Visual CXX
- Configure PLplot for MinGW/CLI
- Configure PLplot for cygwin
- Configure PLplot for Borland CXX 5.5 (free command line tools)
Edit Wiki pages
Consult the User's Guide for information on using the wiki software. More information can be found here: