#
# configure script for vtk source directory
#
AC_INIT(vtkActor.cxx)

TKWIDGET=""
AC_ARG_WITH(tkwidget,
         [  --with-tkwidget           build the vtkTkRenderWidget class],
	 if test "$withval" = yes; then
	 TKWIDGET=vtkTkRenderWidget.o
         fi)
AC_SUBST(TKWIDGET)

AC_ARG_WITH(shared,
         [  --with-shared               create shared libraries],
         [vtk_shared_ok=$withval], [vtk_shared_ok=no])

AC_ARG_WITH(patented,
         [  --with-patented           include the patented classes],
	 if test "$withval" = yes -a "$vtk_shared_ok" != no; then
         USE_GRAPHICS_PATENTED_PYTHON_TARGET="libVTKGraphicsPython${SHLIB_SUFFIX} : ../patented/libVTKPatented${SHLIB_SUFFIX}"
         USE_GRAPHICS_PATENTED_TCL_TARGET="libVTKGraphicsTcl${SHLIB_SUFFIX} : ../patented/libVTKPatented${SHLIB_SUFFIX}"
         USE_GRAPHICS_PATENTED_LIBS="-L\${VTK_OBJ}/patented -lVTKPatented"
         fi,)

AC_SUBST(USE_GRAPHICS_PATENTED_PYTHON_TARGET)
AC_SUBST(USE_GRAPHICS_PATENTED_TCL_TARGET)
AC_SUBST(USE_GRAPHICS_PATENTED_LIBS)

if test ! -r targets.make
then
    echo "Copying $srcdir/targets.make to build directory"
    cp $srcdir/targets.make targets.make || exit 1
fi

# option for handling BSD style makefile includes
#
AC_ARG_WITH(bsdmake,
         [  --with-bsdmake            uses bsd style makefile includes],
	 if test "$withval" = yes; then
         MAKEINCLUDE=".include"
         MAKEQUOTE='"'
         fi,
         MAKEINCLUDE="include"
         MAKEQUOTE='')
AC_SUBST(MAKEINCLUDE)
AC_SUBST(MAKEQUOTE)

AC_CONFIG_SUBDIRS(python tcl java examplesCxx)

dnl Checks for library functions.
AC_OUTPUT(Makefile)


