summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Veillard <veillard@src.gnome.org>2005-10-02 09:52:09 +0000
committerDaniel Veillard <veillard@src.gnome.org>2005-10-02 09:52:09 +0000
commit67232e9682e74fc129ad771bfdf98ddc4f50e061 (patch)
tree0675d2d0268045a61ebcf307a862d15f6cbd2fc3
parenta46f8145d092a582b66fac04108bec04eee248e2 (diff)
downloadlibxslt-67232e9682e74fc129ad771bfdf98ddc4f50e061.tar.gz
applied patch from Joel Reed to ease plugin integration Daniel
* configure.in libxslt/Makefile.am libxslt/xsltconfig.h.in libxslt.spec.in tests/plugins/Makefile.am xslt-config.in: applied patch from Joel Reed to ease plugin integration Daniel
-rw-r--r--ChangeLog6
-rw-r--r--configure.in2
-rw-r--r--libxslt.spec.in1
-rw-r--r--libxslt/Makefile.am3
-rw-r--r--libxslt/xsltconfig.h.in2
-rw-r--r--tests/plugins/Makefile.am21
-rw-r--r--xslt-config.in6
7 files changed, 28 insertions, 13 deletions
diff --git a/ChangeLog b/ChangeLog
index 43e6b6d9..2f5c88e1 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+Sun Oct 2 11:52:44 CEST 2005 Daniel Veillard <daniel@veillard.com>
+
+ * configure.in libxslt/Makefile.am libxslt/xsltconfig.h.in
+ libxslt.spec.in tests/plugins/Makefile.am xslt-config.in: applied
+ patch from Joel Reed to ease plugin integration
+
Thu Sep 22 21:51:22 HKT 2005 William Brack <wbrack@mmm.com.hk>
* libxslt/pattern.c: fixed problem in internal XPath compilation
diff --git a/configure.in b/configure.in
index 0163dd54..99ac9f69 100644
--- a/configure.in
+++ b/configure.in
@@ -480,7 +480,7 @@ dnl setup default module path
dnl
module_prefix=$prefix
test "x$module_prefix" = xNONE && module_prefix=$ac_default_prefix
-LIBXSLT_DEFAULT_PLUGINS_PATH="\"$module_prefix/lib/libxslt/$LIBXSLT_MAJOR_VERSION.$LIBXSLT_MINOR_VERSION\""
+LIBXSLT_DEFAULT_PLUGINS_PATH="$module_prefix/lib/libxslt-plugins"
AC_SUBST(LIBXSLT_DEFAULT_PLUGINS_PATH)
dnl
diff --git a/libxslt.spec.in b/libxslt.spec.in
index f64f9f9e..12120ca3 100644
--- a/libxslt.spec.in
+++ b/libxslt.spec.in
@@ -85,6 +85,7 @@ rm -fr %{buildroot}
%doc doc/EXSLT
%doc %{_mandir}/man1/xsltproc.1*
%{_libdir}/lib*.so.*
+%{_libdir}/libxslt-plugins
%{prefix}/bin/xsltproc
%files devel
diff --git a/libxslt/Makefile.am b/libxslt/Makefile.am
index c0dc1a3b..fb9f95f0 100644
--- a/libxslt/Makefile.am
+++ b/libxslt/Makefile.am
@@ -59,3 +59,6 @@ EXTRA_DIST = $(man_MANS) trio.h triodef.h
xsltproc: all
@(cd ../xsltproc ; $(MAKE))
+
+install-exec-hook:
+ $(mkinstalldirs) "$(libdir)/libxslt-plugins"
diff --git a/libxslt/xsltconfig.h.in b/libxslt/xsltconfig.h.in
index 5b84765d..5e5687e8 100644
--- a/libxslt/xsltconfig.h.in
+++ b/libxslt/xsltconfig.h.in
@@ -116,7 +116,7 @@ extern "C" {
#ifndef WITH_MODULES
#define WITH_MODULES
#endif
-#define LIBXSLT_DEFAULT_PLUGINS_PATH() @LIBXSLT_DEFAULT_PLUGINS_PATH@
+#define LIBXSLT_DEFAULT_PLUGINS_PATH() "@LIBXSLT_DEFAULT_PLUGINS_PATH@"
#endif
/**
diff --git a/tests/plugins/Makefile.am b/tests/plugins/Makefile.am
index da727287..b008f622 100644
--- a/tests/plugins/Makefile.am
+++ b/tests/plugins/Makefile.am
@@ -1,9 +1,5 @@
## Process this file with automake to produce Makefile.in
-# somewhat unconventional pkglibdir, but noinst_LTLIBRARIES
-# never build DSOs (afaik). NOTE: must be defined outside the AM_CONDITIONAL
-pkglibdir=$(shell pwd)/plugin
-
$(top_builddir)/xsltproc/xsltproc:
@(cd ../../../xsltproc ; $(MAKE) xsltproc)
@@ -11,12 +7,17 @@ EXTRA_DIST = plugin.out plugin.xml plugin.xsl
INCLUDES = -I$(top_srcdir) -I../../libxslt $(LIBXML_CFLAGS) $(LIBXSLT_CFLAGS)
-noinst_LTLIBRARIES = xmlsoft_org_xslt_testplugin.la
+EXTRA_LTLIBRARIES = xmlsoft_org_xslt_testplugin.la
+
+# our rpath is a rather unorthodox location as we
+# don't want to pollute $(DESTDIR) with the test plugin
+
+plugindir=$(shell pwd)/.libs/
xmlsoft_org_xslt_testplugin_la_CFLAGS = -DMODULE_COMPILE $(LIBXML_CFLAGS) $(LIBXSLT_CFLAGS)
xmlsoft_org_xslt_testplugin_la_SOURCES = testplugin.c
xmlsoft_org_xslt_testplugin_la_LIBADD = $(top_builddir)/libxslt/libxslt.la $(EXTRA_LIBS)
-xmlsoft_org_xslt_testplugin_la_LDFLAGS = -module -avoid-version
+xmlsoft_org_xslt_testplugin_la_LDFLAGS = -module -avoid-version -rpath $(plugindir)
all:
@@ -24,12 +25,10 @@ if WITH_MODULES
test-logall:
@echo '## Running plugin tests'
- @echo '## Note: installing xmlsoft_org_xslt_testplugin.so'
- @echo '## to $(pkglibdir)'
-test tests: $(top_builddir)/xsltproc/xsltproc test-logall install-pkglibLTLIBRARIES
- @LD_LIBRARY_PATH=$(top_builddir)/libxslt/.libs:$(LD_LIBRARY_PATH) \
- LIBXSLT_PLUGINS_PATH=./plugin \
+test tests: $(top_builddir)/xsltproc/xsltproc test-logall $(EXTRA_LTLIBRARIES)
+ @LD_LIBRARY_PATH=$(plugindir):$(top_builddir)/libxslt/.libs:$(LD_LIBRARY_PATH) \
+ LIBXSLT_PLUGINS_PATH=$(plugindir) \
$(top_builddir)/xsltproc/xsltproc plugin.xsl plugin.xml > plugin.res
@diff plugin.out plugin.res
@rm plugin.res
diff --git a/xslt-config.in b/xslt-config.in
index fb614bae..a1e1fb57 100644
--- a/xslt-config.in
+++ b/xslt-config.in
@@ -17,6 +17,7 @@ Known values for OPTION are:
--exec-prefix=DIR change XSLT executable prefix [default $exec_prefix]
--libs print library linking information
--cflags print pre-processor and compiler flags
+ --plugins print plugin directory
--help display this help and exit
--version output version information
EOF
@@ -63,6 +64,11 @@ while test $# -gt 0; do
exit 0
;;
+ --plugins)
+ echo @LIBXSLT_DEFAULT_PLUGINS_PATH@
+ exit 0
+ ;;
+
--help)
usage 0
;;