[vtk-developers] VTK packaging and OS X
Prabhu Ramachandran
prabhu at aero.iitm.ernet.in
Thu Dec 7 13:51:54 EST 2000
hi,
>>>>> "Andrew" == Andrew Cunningham <andrewc at vasci.com> writes:
>> As I had written a while back, I had desired to improve some of
>> the VTK makefiles in order to ease packaging/installing VTK.
Andrew> It would be nice if the changes you are making handled Mac
Andrew> OS X as well.
Well, the changes I made aren't that great. All they basically do is
make docs with doxygen, install the headers, docs, and examples at
locations chosen by the user in user.make. So, if Mac OS X has decent
sh, find, cp utilities, the changes should work just fine. I decided
against doing more configure magic because as it is configure has a
little too many options. Besides, putting things in user.make makes
things a bit more flexible.
Andrew> I must admit to some ignorance of the how the
Andrew> "./configure" mechanism is maintained and updated to
Andrew> include "new" operating systems.
Me too. :) I dont know too much about autoconf etc.
<snip>
Andrew> - there is no "-lm" needed on a C++ link ( In fact -lm
Andrew> will cause a link to fail) - dynamic libraries are .dylib
Andrew> ( not .so, or .sl) - the archive and dynamic library
Andrew> creation tool is "libtool"
Oh, these can be added in configure. As I see it, this is how it
works. Look in the file configure.in. configure is a sh script. So
in configure.in the variable $system is set using the 'uname' program.
So see what the Mac OS X reports when you run uname and add a the
required lines to configure.in (in Step 4). It looks like (in the
current CVS tree it is at line 431).
# Step 4: set configuration options based on system name and version.
fullSrcDir=`cd $srcdir; pwd`
case $system in
AIX-*)
# AIX: can't link shared library extensions unless Tcl and Tk are
# also shared libraries.
SHLIB_CFLAGS=""
SHLIB_LD_LIBS='${LIBS}'
SHLIB_SUFFIX="..o"
DL_LIBS=""
AC_CHECK_LIB(ld,printf, DL_LIBS="-lld")
VTK_SHLIB_LINK_FLAGS=""
;;
etc. etc.
So add a case for whatever is appropriate and set whatever you want
here. The variable $system is set using the following
system=`uname -s`-`uname -r`
Once you add everything to configure.in you can run autoconf to
generate the configure file.
Hope this helps.
prabhu
More information about the vtk-developers
mailing list