Alan thanks for the pointers with cmake.  I added the :PATH or FILEPATH where applicable and that worked in successfully  configuring everything.  There were a few random problems but I was able to work my way around them by disabling certain features.  For instance cmake could not find my GD library even though the path and file I provided was valid.  During the actual make TCL created a compiler error and there was unreferenced symbol errors which occured in the pdf library.  So I simply ignored the GD, TCL and pdf issue by disabling them or not initializing them.  However when I go to test the examples I am still recieving linker errors.  I tried this for both a static and dynamic build and the same errors are produced.  Please see the error message below.

---
--- STATIC BUILD EXAMPLE RESULTS
------------------------------------------------------------------------------------------------------------------------------
hall000s@pillbox(/tmp/examples) - 288: make
target=`echo all`; \
        list='c c++ f77 f95 tk java'; for subdir in $list; do \
          if test -d "$subdir"; then \
            echo "Making $target in $subdir"; \
            (cd $subdir && make $target); \
          fi; \
        done
Making all in c
make[1]: Entering directory `/tmp/examples/c'
/usw/ude/SunOS/bin/gcc x01c.c -o x01c -Wl,-rpath -Wl,/home/hall000s/SunOS/plplot_static/lib `PKG_CONFIG_PATH=/home/hall000s/SunOS/plplot_static/lib/pkgconfig pkg-config --cflags --libs plplotd`
ld: fatal: option -dn and -P are incompatible
ld: fatal: Flags processing errors
collect2: ld returned 1 exit status
make[1]: *** [x01c] Error 1
make[1]: Leaving directory `/tmp/examples/c'
Making all in c++
make[1]: Entering directory `/tmp/examples/c++'
/usw/ude/SunOS/bin/c++ x01cc.cc -o x01cc -Wl,-rpath -Wl,/home/hall000s/SunOS/plplot_static/lib `PKG_CONFIG_PATH=/home/hall000s/SunOS/plplot_static/lib/pkgconfig pkg-config --cflags --libs plplotd-c++`
ld: fatal: option -dn and -P are incompatible
ld: fatal: Flags processing errors
collect2: ld returned 1 exit status
make[1]: *** [x01cc] Error 1
make[1]: Leaving directory `/tmp/examples/c++'
Making all in f77
make[1]: Entering directory `/tmp/examples/f77'
/usw/ude/SunOS/bin/g95 x01f.f -o x01f -Wl,-rpath -Wl,/home/hall000s/SunOS/plplot_static/lib `PKG_CONFIG_PATH=/home/hall000s/SunOS/plplot_static/lib/pkgconfig pkg-config --cflags --libs plplotd-f77`
ld: fatal: option -dn and -P are incompatible
ld: fatal: Flags processing errors
make[1]: *** [x01f] Error 1
make[1]: Leaving directory `/tmp/examples/f77'
Making all in f95
make[1]: Entering directory `/tmp/examples/f95'
/usw/ude/SunOS/bin/g95  x01f.f90 -o x01f -Wl,-rpath -Wl,/home/hall000s/SunOS/plplot_static/lib `PKG_CONFIG_PATH=/home/hall000s/SunOS/plplot_static/lib/pkgconfig pkg-config --cflags --libs plplotd-f95`
ld: fatal: option -dn and -P are incompatible
ld: fatal: Flags processing errors
make[1]: *** [x01f] Error 1
make[1]: Leaving directory `/tmp/examples/f95'

-----
----- DYNAMIC BUILD EXAMPLES RESULTS
------------------------------------------------------------------------------------------------------------------------------------------------------------------------
hall000s@pillbox(/tmp/examples) - 290: make
target=`echo all`; \
        list='c c++ f77 f95 tk java'; for subdir in $list; do \
          if test -d "$subdir"; then \
            echo "Making $target in $subdir"; \
            (cd $subdir && make $target); \
          fi; \
        done
Making all in c
make[1]: Entering directory `/tmp/examples/c'
/usw/ude/SunOS/bin/gcc x01c.c -o x01c -Wl,-rpath -Wl,/home/hall000s/SunOS/plplot_dyn/lib `PKG_CONFIG_PATH=/home/hall000s/SunOS/plplot_dyn/lib/pkgconfig pkg-config --cflags --libs plplotd`
ld: fatal: option -dn and -P are incompatible
ld: fatal: Flags processing errors
collect2: ld returned 1 exit status
make[1]: *** [x01c] Error 1
make[1]: Leaving directory `/tmp/examples/c'
Making all in c++
make[1]: Entering directory `/tmp/examples/c++'
/usw/ude/SunOS/bin/c++ x01cc.cc -o x01cc -Wl,-rpath -Wl,/home/hall000s/SunOS/plplot_dyn/lib `PKG_CONFIG_PATH=/home/hall000s/SunOS/plplot_dyn/lib/pkgconfig pkg-config --cflags --libs plplotd-c++`
ld: fatal: option -dn and -P are incompatible
ld: fatal: Flags processing errors
collect2: ld returned 1 exit status
make[1]: *** [x01cc] Error 1
make[1]: Leaving directory `/tmp/examples/c++'
Making all in f77
make[1]: Entering directory `/tmp/examples/f77'
/usw/ude/SunOS/bin/g95 x01f.f -o x01f -Wl,-rpath -Wl,/home/hall000s/SunOS/plplot_dyn/lib `PKG_CONFIG_PATH=/home/hall000s/SunOS/plplot_dyn/lib/pkgconfig pkg-config --cflags --libs plplotd-f77`
ld: fatal: option -dn and -P are incompatible
ld: fatal: Flags processing errors
make[1]: *** [x01f] Error 1
make[1]: Leaving directory `/tmp/examples/f77'
Making all in f95
make[1]: Entering directory `/tmp/examples/f95'
/usw/ude/SunOS/bin/g95  x01f.f90 -o x01f -Wl,-rpath -Wl,/home/hall000s/SunOS/plplot_dyn/lib `PKG_CONFIG_PATH=/home/hall000s/SunOS/plplot_dyn/lib/pkgconfig pkg-config --cflags --libs plplotd-f95`
ld: fatal: option -dn and -P are incompatible
ld: fatal: Flags processing errors
make[1]: *** [x01f] Error 1
make[1]: Leaving directory `/tmp/examples/f95'

Thanks again for your help.

Scott

On 9/8/07, Alan W. Irwin <irwin@beluga.phys.uvic.ca> wrote:
On 2007-09-08 13:21-0400 Scott Hall wrote:

> I am running into a peculiar installation problem while trying to install
> PLplot-5.7.4 on Solaris.  I have been at this installation for quite awhile
> and the problems I keep running into are strange and I am not sure how to
> fix them.

> So my next step was to start from scratch and gradually enable more bindings
> and drivers.  So I went back to cmake and ran this following command, also I
> am trying to create a static build, this is a requirement of my build.  I am
> building this in a separate folder from the plplot source directory.
>
> cmake -DCMAKE_INSTALL_PREFIX=/home/hall000s/SunOS/plplot                \
>      -DCMAKE_INSTALL_BINDIR=/home/hall000s/SunOS/plplot/bin
> \
>      -DCMAKE_INSTALL_DATADIR=/home/hall000s/SunOS/plplot/share         \
>      -DCMAKE_INSTALL_EXEC_PREFIX=/home/hall000s/SunOS/plplot          \
>      -DCMAKE_INSTALL_INCLUDEDIR=/home/hall000s/SunOS/plplot/include  \
>      -DCMAKE_INSTALL_INFODIR=/home/hall000s/SunOS/plplot/share/info    \
>
> -DCMAKE_INSTALL_LIBDIR=/home/hall000s/SunOS/plplot/lib                   \
>      -DCMAKE_INSTALL_MANDIR=/home/hall000s/SunOS/plplot/share/man     \
>
> -DDEFAULT_NO_DEVICES=ON
> \
>
> -DDEFAULT_NO_BINDINGS=ON
> \
>
> -DBUILD_SHARED_LIBS=OFF
> \
>
> -DPKG_CONFIG_EXECUTABLE=/bin/pkg-config
> \
>
> -DPLD_ps=ON
> \
>      ../plplot-5.7.4
>
> When the above cmake command is executed it shows the following output.
> [...]Summary of CMake build system results for PLplot
>
> Install location variables which can be set by the user:
> CMAKE_INSTALL_PREFIX:
> CMAKE_INSTALL_EXEC_PREFIX
> CMAKE_INSTALL_BINDIR       CMAKE_INSTALL_BINDIR
> CMAKE_INSTALL_DATADIR
> CMAKE_INSTALL_LIBDIR
> CMAKE_INSTALL_INCLUDEDIR
> CMAKE_INSTALL_INFODIR
> CMAKE_INSTALL_MANDIR
>
> Derived install location variables:
> DATA_DIR        /plplot5.7.4
> LIB_DIR
> INCLUDE_DIR     /plplot
> BIN_DIR         CMAKE_INSTALL_BINDIR
> TCL_DIR         /plplot5.7.4/tcl
> PYTHON_INSTDIR
> DRV_DIR         /plplot5.7.4/driversd
> DOC_DIR         /doc/plplot
> MAN_DIR
> INFO_DIR
>
> Other important CMake variables:
>
> CMAKE_SYSTEM_NAME:      SunOS
> UNIX:                   1
> WIN32:
> APPLE:
> MSVC:                           (MSVC_VERSION:  )
> MINGW:
> MSYS:
> CYGWIN:
> BORLAND:
> WATCOM:
>
> SWIG_FOUND:             FALSE
> PERL_FOUND:             YES
> X11_FOUND:              1
>
> CMAKE_BUILD_TYPE:
> CMAKE_C_COMPILER CMAKE_C_FLAGS:                 /usw/ude/SunOS/bin/gcc
> LIB_TAG:                d
>
> ENABLE_DYNDRIVERS:      OFF
> DEVICES_LIST: ps
> DRIVERS_LIST: ps
>
> Library options:
> BUILD_SHARED_LIBS:      OFF             PL_DOUBLE:      ON
>
> Optional libraries:
> HAVE_QHULL:             OFF             WITH_CSA:       ON
> HAVE_FREETYPE:                          HAVE_PTHREAD:
> HAVE_AGG:
>
> Language Bindings:
> ENABLE_f77:             OFF             ENABLE_f95:             OFF
> ENABLE_cxx:             OFF             ENABLE_java:            OFF
> ENABLE_python:          OFF             ENABLE_octave:          OFF
> ENABLE_tcl:             OFF             ENABLE_itcl:            OFF
> ENABLE_tk:              OFF             ENABLE_itk:             OFF
> ENABLE_pdl:             OFF             ENABLE_wxwidgets:       OFF
> ENABLE_gnome2:          OFF             ENABLE_pygcw:           OFF
> ENABLE_ada:             OFF
>
> Notice that it did not find my pkg-config executable even though the path I
> gave it is correct.  This occurs with some of the devices and bindings as
> well.  However if I was to use ccmake and enter the same paths that I am
> using for cmake I have success.  Has anyone ran into any problems like
> this?  I appreciate any help with this problem.

I think you are running afoul of a CMake peculiarity (which apparently is
fixed in the CVS version of CMake which should get released in the future as
the 2.6.x series).  According to the documentation (which you can look at
with cmake --help-full |less) the -D options all have to be typed (e.g., given
a type of BOOL, FILEPATH, PATH, STRING, or INTERNAL)
for cmake-2.4.x.  However, there are exceptions to this rule which I
have discovered experimentally.  For example, you don't have to specify
any type for the ON/OFF BOOL variables, and -DCMAKE_INSTALL_PREFIX.  However,
for other paths or filepaths you do have to specify PATH or FILEPATH.

So try changing your above command to the following

cmake -DCMAKE_INSTALL_PREFIX=/home/hall000s/SunOS/plplot \
-DCMAKE_INSTALL_BINDIR:PATH=/home/hall000s/SunOS/plplot/bin \
-DCMAKE_INSTALL_DATADIR:PATH=/home/hall000s/SunOS/plplot/share         \
-DCMAKE_INSTALL_EXEC_PREFIX:PATH=/home/hall000s/SunOS/plplot          \
-DCMAKE_INSTALL_INCLUDEDIR:PATH=/home/hall000s/SunOS/plplot/include  \
-DCMAKE_INSTALL_INFODIR:PATH=/home/hall000s/SunOS/plplot/share/info    \
-DCMAKE_INSTALL_LIBDIR:PATH=/home/hall000s/SunOS/plplot/lib \
-DCMAKE_INSTALL_MANDIR:PATH=/home/hall000s/SunOS/plplot/share/man     \
-DDEFAULT_NO_DEVICES=ON \
-DDEFAULT_NO_BINDINGS=ON \
-DBUILD_SHARED_LIBS=OFF \
-DPKG_CONFIG_EXECUTABLE:FILEPATH=/bin/pkg-config \
-DPLD_ps=ON \
../plplot-5.7.4

You can check the cache file CMakeCache.txt , for any other variable types
you might need.

N.B. While you are getting used to cmake, be sure to make a clean start
every time by running the above command in an empty build directory.  Also,
never use a source tree where cmake has been run by accident since that
convinces all future invocations of cmake to always use a build in the
source tree.  To assure this is not a problem, use a freshly unpacked
source tree and then from then on always invoke cmake from a separate
build tree (as above).  Finally, completely remove the install tree before
running cmake to make sure there is nothing stale there that will screw
up your installed examples test.

Here is a further suggestion about the above invocation of cmake.  Above,
you are specifying a lot of stuff that happens by default.  If you drop
those unnnecessary options, then the above cmake command boils down to

cmake -DCMAKE_INSTALL_PREFIX=/home/hall000s/SunOS/plplot \
-DDEFAULT_NO_DEVICES=ON \
-DDEFAULT_NO_BINDINGS=ON \
-DBUILD_SHARED_LIBS=OFF \
-DPKG_CONFIG_EXECUTABLE:FILEPATH=/bin/pkg-config \
-DPLD_ps=ON \
../plplot-5.7.4

You can even drop -DPKG_CONFIG_EXECUTABLE:FILEPATH=/bin/pkg-config if /bin
is on your PATH.  The reason for this simplification is
cmake/modules/FindPkgConfig.cmake uses the cmake "find_program" command to
find pkg-config, and that command does the right thing (i.e., checks for
programmes in all directories in the PATH by default).

ccmake is useful to give you an idea of the annotated options, but it is not
really necessary since those annotations also show up in the cache file,
CMakeCache.txt.  Also, I personally find ccmake confusing since there is
always a question whether it is using stale cache file results or not.  If
you always invoke cmake in an empty build tree, then by definition there are
no stale cache problems.

I think this is our first cmake build report on solaris so we are much
interested in your results and will help as much as we can. It appears from
the rest of your message (not quoted) that you are running into troubles
with the installed examples test for a static build so it would be
interesting to see if those troubles extend to the shared build case as well
(which is tested a lot more than the static build case).  To do a shared
build, simply specify -DBUILD_SHARED_LIBS=ON, and also specify a separate
installation prefix to keep that shared install tree separate from your
desired static install tree.  Also, I have to say that your approach of
simplifying the PLplot build as much as possible with no interfaces and no
device drivers other than ps is the right way to debug what is going on. But
you do have to remember to always invoke cmake in an empty build tree to
avoid stale cache issues and also you should remove the install tree before
invoking cmake to avoid stale installation files.

Good luck and keep us posted how it goes.

Alan
__________________________
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state implementation
for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
package (plplot.org); the libLASi project ( unifont.org/lasi); the Loads of
Linux Links project (loll.sf.net); and the Linux Brochure Project
(lbproject.sf.net).
__________________________

Linux-powered Science
__________________________