dnl Zebra, Index Data ApS, 1995-2006
-dnl $Id: configure.ac,v 1.34 2006-10-16 11:03:47 adam Exp $
+dnl $Id: configure.ac,v 1.35 2006-11-03 23:17:08 adam Exp $
dnl
AC_PREREQ(2.59)
AC_INIT([idzebra],[2.0.4],[adam@indexdata.dk])
AC_MSG_ERROR([YAZ development libraries required])
fi
YAZ_DOC
-dnl ----- libXSLT
-AC_SUBST(XSLT_LIBS)
-AC_SUBST(XSLT_CFLAGS)
-xsltdir=yes
-AC_ARG_WITH(xslt,[[ --with-xslt[=PREFIX] use libxslt in PREFIX]],xsltdir=$withval)
-if test "$xsltdir" = "yes"; then
- for d in /usr /usr/local; do
- if test -x $d/bin/xslt-config; then
- xsltdir=$d
- fi
- done
-fi
-if test "$xsltdir" != "no"; then
- AC_MSG_CHECKING(for libXSLT)
-
- if test -x $xsltdir/bin/xslt-config; then
- XSLT_VER=`$xsltdir/bin/xslt-config --version`
- AC_MSG_RESULT($XSLT_VER)
- have_xslt_version=`echo "$XSLT_VER" | awk 'BEGIN { FS = "."; } { printf "%d", ([$]1 * 1000 + [$]2) * 1000 + [$]3;}'`
- if test $have_xslt_version -lt 1001011; then
- AC_MSG_WARN([libXSLT too old. Use 1.1.11 or later.])
- XSLT_VER=""
- else
- XSLT_LIBS=`$xsltdir/bin/xslt-config --libs`
- XSLT_CFLAGS=`$xsltdir/bin/xslt-config --cflags`
- AC_DEFINE(HAVE_XSLT)
- fi
- else
- AC_MSG_RESULT(Not found)
- fi
-fi
dnl ------ Look for Tcl
dnl See if user has specified location of tclConfig.sh; otherwise
dnl see if tclConfig.sh exists in same prefix lcoation as tclsh; otherwise
def="disabled"
fi
ZEBRA_MODULE(grs-xml,[$def], [ --enable-mod-grs-xml XML filter (Expat based)])
-if test "$XSLT_VER"; then
- def="shared"
-else
- def="disabled"
-fi
+oldCPPFLAGS="$CPPFLAGS"
+CPPFLAGS="$CPPFLAGS $YAZINC"
+AC_PREPROC_IFELSE(
+ [AC_LANG_PROGRAM([[#include <stdio.h>]],
+ [[
+#if YAZ_HAVE_XSLT
+#else
+#error no xslt
+#endif
+]])],
+ [def="shared"],
+ [def="disabled"])
+CPPFLAGS=$oldCPPFLAGS
+
ZEBRA_MODULE(alvis,[$def], [ --enable-mod-alvis ALVIS filter (Requires libxslt)])
dnl ------ ANSI C Header files
AC_STDC_HEADERS
-## $Id: Makefile.am,v 1.55 2006-09-22 10:18:08 adam Exp $
+## $Id: Makefile.am,v 1.56 2006-11-03 23:17:08 adam Exp $
aux_libs = \
../rset/libidzebra-rset.la \
mod_alvis_la_SOURCES = alvis.c
mod_alvis_la_LDFLAGS = -rpath $(modlibdir) -module -avoid-version
-mod_alvis_la_LADD = $(XSLT_LIBS)
+mod_alvis_la_LADD =
mod_alvis_la_LIBADD = $(zebralib) $(mod_alvis_la_LADD)
modlib_LTLIBRARIES = $(SHARED_MODULE_LA)
AM_CPPFLAGS = -I$(srcdir)/../include $(YAZINC) \
-DDEFAULT_PROFILE_PATH=\"$(pkgdatadir)/tab\" \
- $(TCL_INCLUDE) $(XSLT_FLAGS) $(XSLT_CFLAGS)
+ $(TCL_INCLUDE)
LDADD = $(zebralib) $(YAZLALIB)
-/* $Id: alvis.c,v 1.3 2006-08-22 13:39:26 adam Exp $
+/* $Id: alvis.c,v 1.4 2006-11-03 23:17:08 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
#include <libxslt/transform.h>
#include <libxslt/xsltutils.h>
+#if YAZ_HAVE_EXSLT
+#include <libexslt/exslt.h>
+#endif
+
#include <idzebra/util.h>
#include <idzebra/recctrl.h>
tinfo->doc = 0;
tinfo->schemas = 0;
+#if YAZ_HAVE_EXSLT
+ exsltRegisterAll();
+#endif
+
#if ENABLE_INPUT_CALLBACK
xmlRegisterDefaultInputCallbacks();
xmlRegisterInputCallbacks(zebra_xmlInputMatchCallback,