Forum OpenACS Q&A: PG Driver compilation (ns.h, nsdb.h, nstcl.h)

Having trouble compiling the postgres-aolserver driver.  It can't find
files ns.h, nsdb.h, or nstcl.h  I've looked and can't find them
either.  Anyone know where these headers were supposed to come into
the equation?  I used the  Redhat-RPM install for Postgres and
installed the devel package and tcl package too... I've looked through
the sources of aolserver and can't seem to find them.  Any help would
be appreciated...tim
Here's a list of all of the include files from the source directory after untarring:
1055 nsadmin@localhost:/usr/local/aolserver >find . | egrep '.h$'
./aolserver3_0/include/ns.h
./aolserver3_0/include/nsextmsg.h
./aolserver3_0/include/nspd.h
./aolserver3_0/include/nsthread.h
./aolserver3_0/include/tcl.h
./aolserver3_0/include/tcl76.h
./aolserver3_0/include/tcl82.h
./aolserver3_0/include/tcl83.h
./aolserver3_0/include/tclDecls.h
./aolserver3_0/nsd/getopt.h
./aolserver3_0/nsd/nsd.h
./aolserver3_0/nsext/nsextmsg.h
./aolserver3_0/nspd/pd.h
./aolserver3_0/nsssl2/ssl.h
./aolserver3_0/nsssl2/ssltcl.h
./aolserver3_0/nsssl2/x509.h
./aolserver3_0/nssybpd/exutils.h
./aolserver3_0/nssybpd/nssyb.h
./aolserver3_0/tcl7.6/compat/dirent.h
./aolserver3_0/tcl7.6/compat/dirent2.h
./aolserver3_0/tcl7.6/compat/dlfcn.h
./aolserver3_0/tcl7.6/compat/float.h
./aolserver3_0/tcl7.6/compat/limits.h
./aolserver3_0/tcl7.6/compat/stdlib.h
./aolserver3_0/tcl7.6/compat/string.h
./aolserver3_0/tcl7.6/compat/tclErrno.h
./aolserver3_0/tcl7.6/compat/unistd.h
./aolserver3_0/tcl7.6/generic/tcl.h
./aolserver3_0/tcl7.6/generic/tclInt.h
./aolserver3_0/tcl7.6/generic/tclPatch.h
./aolserver3_0/tcl7.6/generic/tclPort.h
./aolserver3_0/tcl7.6/generic/tclRegexp.h
./aolserver3_0/tcl7.6/unix/tclUnixPort.h
./aolserver3_0/tcl8.3.0/compat/dirent.h
./aolserver3_0/tcl8.3.0/compat/dirent2.h
./aolserver3_0/tcl8.3.0/compat/dlfcn.h
./aolserver3_0/tcl8.3.0/compat/float.h
./aolserver3_0/tcl8.3.0/compat/limits.h
./aolserver3_0/tcl8.3.0/compat/stdlib.h
./aolserver3_0/tcl8.3.0/compat/string.h
./aolserver3_0/tcl8.3.0/compat/tclErrno.h
./aolserver3_0/tcl8.3.0/compat/unistd.h
./aolserver3_0/tcl8.3.0/generic/regcustom.h
./aolserver3_0/tcl8.3.0/generic/regerrs.h
./aolserver3_0/tcl8.3.0/generic/regex.h
./aolserver3_0/tcl8.3.0/generic/regguts.h
./aolserver3_0/tcl8.3.0/generic/tcl.h
./aolserver3_0/tcl8.3.0/generic/tclCompile.h
./aolserver3_0/tcl8.3.0/generic/tclDecls.h
./aolserver3_0/tcl8.3.0/generic/tclInitScript.h
./aolserver3_0/tcl8.3.0/generic/tclInt.h
./aolserver3_0/tcl8.3.0/generic/tclIntDecls.h
./aolserver3_0/tcl8.3.0/generic/tclIntPlatDecls.h
./aolserver3_0/tcl8.3.0/generic/tclMath.h
./aolserver3_0/tcl8.3.0/generic/tclPlatDecls.h
./aolserver3_0/tcl8.3.0/generic/tclPort.h
./aolserver3_0/tcl8.3.0/generic/tclRegexp.h
./aolserver3_0/tcl8.3.0/unix/tclUnixPort.h
./aolserver3_0/tcl8.3.0/unix/tclUnixThrd.h
./aolserver3_0/tcl8.3.0/win/tclWinInt.h
./aolserver3_0/tcl8.3.0/win/tclWinPort.h
./aolserver3_0/tcl8.3.0/win/tclWinThrd.h
./aolserver3_0/thread/thread.h                 
Just to expand on what Dan has added above,  the header files are contained in the source dist. of aolserver,  note that they are not distributed in the binary distribution of aolserver.

The easiest way I have found of compiling the driver is to first extract the aolserver source file into the ~nsadmin directory,  next copy the driver-2.3 directory into ~nsadmin,  next edit the makefile under driver-2.3 to reflect the location of your postgres libs and aolserver home directory.  Once you have saved the changes,  type make, which ultimately should produce a file postgres.so which I then copy off to a temp directory.  Then clean out all files from ~nsadmin and extract the binary aolserver distribution,  making a copy of postgres.so that is in your temp directory and placing it in ~nsadmin/bin.  Finally configure your nsd.tcl to load the driver...

HTH

what i did for this was yank the include directory from an aolserver2.3 installation which did have all three of the aforementioned files.  it compiled perfectly once i did that.