[xslt] [PATCH] plugin cleanups for fedora-extras
- From: joel reed <joelwreed comcast net>
- To: xslt gnome org
- Subject: [xslt] [PATCH] plugin cleanups for fedora-extras
- Date: Sun, 2 Oct 2005 00:23:18 -0400
The attached patch changes libxslt.spec.in such that libxslt is said to own
$(libdir)/libxslt-plugins, the default plugin directory.
A new option "xslt-config --plugins" will report the default plugin directory,
so that plugins can configure their installation thusly.
I also cleaned up tests/plugins/Makefile.am, it no longer makes use of automake
internal variables.
Files Changed:
libxslt-1.1.15/configure.in
libxslt-1.1.15/libxslt/Makefile.am
libxslt-1.1.15/libxslt/xsltconfig.h.in
libxslt-1.1.15/libxslt.spec.in
libxslt-1.1.15/tests/plugins/Makefile.am
libxslt-1.1.15/xslt-config.in
This work is being done in preparation for resubmitting
libxslt-plugin-dates-and-times and libxslt-plugin-regexp to fedora-extras,
with libxslt now properly owning the plugin directory.
jr
diff -up -urN libxslt-1.1.15-orig/configure.in libxslt-1.1.15/configure.in
--- libxslt-1.1.15-orig/configure.in 2005-09-04 18:19:44.000000000 -0400
+++ libxslt-1.1.15/configure.in 2005-10-01 23:48:38.000000000 -0400
@@ -476,7 +476,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 -up -urN libxslt-1.1.15-orig/libxslt/Makefile.am libxslt-1.1.15/libxslt/Makefile.am
--- libxslt-1.1.15-orig/libxslt/Makefile.am 2005-01-17 10:23:20.000000000 -0500
+++ libxslt-1.1.15/libxslt/Makefile.am 2005-10-01 23:12:29.000000000 -0400
@@ -59,3 +59,6 @@ EXTRA_DIST = $(man_MANS) trio.h triodef.
xsltproc: all
@(cd ../xsltproc ; $(MAKE))
+
+install-exec-hook:
+ $(mkinstalldirs) "$(libdir)/libxslt-plugins"
diff -up -urN libxslt-1.1.15-orig/libxslt/xsltconfig.h.in libxslt-1.1.15/libxslt/xsltconfig.h.in
--- libxslt-1.1.15-orig/libxslt/xsltconfig.h.in 2005-01-09 09:17:39.000000000 -0500
+++ libxslt-1.1.15/libxslt/xsltconfig.h.in 2005-10-01 22:00:22.000000000 -0400
@@ -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
/**
Binary files libxslt-1.1.15-orig/libxslt-1.1.15.tar.gz and libxslt-1.1.15/libxslt-1.1.15.tar.gz differ
diff -up -urN libxslt-1.1.15-orig/libxslt.spec.in libxslt-1.1.15/libxslt.spec.in
--- libxslt-1.1.15-orig/libxslt.spec.in 2005-09-04 18:57:30.000000000 -0400
+++ libxslt-1.1.15/libxslt.spec.in 2005-10-01 11:31:00.000000000 -0400
@@ -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 -up -urN libxslt-1.1.15-orig/tests/plugins/Makefile.am libxslt-1.1.15/tests/plugins/Makefile.am
--- libxslt-1.1.15-orig/tests/plugins/Makefile.am 2005-08-09 16:11:11.000000000 -0400
+++ libxslt-1.1.15/tests/plugins/Makefile.am 2005-10-01 23:03:05.000000000 -0400
@@ -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 plugi
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 -up -urN libxslt-1.1.15-orig/xslt-config.in libxslt-1.1.15/xslt-config.in
--- libxslt-1.1.15-orig/xslt-config.in 2002-02-11 08:59:51.000000000 -0500
+++ libxslt-1.1.15/xslt-config.in 2005-10-01 23:51:32.000000000 -0400
@@ -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
;;
[Date Prev][
Date Next] [Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]