From ada71b3bb5b5e39f8cbe50f64d3b12c7b945f58e Mon Sep 17 00:00:00 2001 From: Daniel Veillard Date: Thu, 15 May 2003 20:28:53 +0000 Subject: [PATCH] fixing portability bug #113002 on HP-UX cleanup of --with-python like for * xsltproc/xsltproc.c: fixing portability bug #113002 on HP-UX * configure.in libxslt.spec.in python/Makefile.am: cleanup of --with-python like for libxml2 Daniel --- ChangeLog | 6 +++ configure.in | 8 +++ doc/libxslt-api.xml | 128 ++++++++++++++++++++++---------------------- libxslt.spec.in | 19 ------- python/Makefile.am | 5 +- xsltproc/xsltproc.c | 4 ++ 6 files changed, 84 insertions(+), 86 deletions(-) diff --git a/ChangeLog b/ChangeLog index ac9b98cf..ffa983de 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Thu May 15 16:26:34 EDT 2003 Daniel Veillard + + * xsltproc/xsltproc.c: fixing portability bug #113002 on HP-UX + * configure.in libxslt.spec.in python/Makefile.am: cleanup + of --with-python like for libxml2 + Thu May 15 11:45:00 HKT 2003 William Brack * libxslt/xsltutils.c: fixing bug #112995, a problem with diff --git a/configure.in b/configure.in index 25513155..ea9b1407 100644 --- a/configure.in +++ b/configure.in @@ -151,6 +151,7 @@ PYTHON= PYTHON_VERSION= PYTHON_INCLUDES= PYTHON_SITE_PACKAGES= +pythondir= AC_ARG_WITH(python, [ --with-python[=DIR] Build Python bindings if found]) if test "$with_python" != "no" ; then if test -x "$with_python/bin/python" @@ -206,6 +207,12 @@ except: print 0"` fi fi fi + if test "$with_python" != "" + then + pythondir='$(PYTHON_SITE_PACKAGES)' + else + pythondir='$(libdir)/python${PYTHON_VERSION}/site-packages' + fi fi AM_CONDITIONAL(WITH_PYTHON, test "$PYTHON_INCLUDES" != "") if test "$PYTHON_INCLUDES" != "" @@ -214,6 +221,7 @@ then else PYTHON_SUBDIR= fi +AC_SUBST(pythondir) AC_SUBST(PYTHON_SUBDIR) dnl diff --git a/doc/libxslt-api.xml b/doc/libxslt-api.xml index 3c16033c..68c1c8cf 100644 --- a/doc/libxslt-api.xml +++ b/doc/libxslt-api.xml @@ -1,14 +1,16 @@ - - - - - - - - + + + + + + + + + + @@ -20,40 +22,11 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + @@ -122,24 +95,49 @@ - - - - - - - + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + @@ -337,11 +335,13 @@ - - - - - + + + + + + + diff --git a/libxslt.spec.in b/libxslt.spec.in index 62d707d0..6d5444d1 100644 --- a/libxslt.spec.in +++ b/libxslt.spec.in @@ -61,25 +61,6 @@ rm -fr %{buildroot} %makeinstall -# -# this is a bit ugly but tries to generate the bindings for all versions -# of python installed -# -for i in %{prefix}/include/python* -do - py_version=`echo $i | sed "s+%{prefix}/include/python++"` - if test -x %{prefix}/bin/python$py_version - then - echo generating bindings for Python $py_version - (cd python ; make clean ; \ - make PYTHON="%{prefix}/bin/python$py_version" \ - PYTHON_VERSION="$py_version"; \ -%makeinstall PYTHON="%{prefix}/bin/python$py_version" \ - PYTHON_VERSION="$py_version" \ - prefix=$RPM_BUILD_ROOT%{prefix}) - fi -done - %clean rm -fr %{buildroot} diff --git a/python/Makefile.am b/python/Makefile.am index 4e785ef6..597984d1 100644 --- a/python/Makefile.am +++ b/python/Makefile.am @@ -33,7 +33,6 @@ mylibs = \ all-local: libxslt.py -pythondir = $(libdir)/python${PYTHON_VERSION}/site-packages python_LTLIBRARIES = libxsltmod.la libxsltmod_la_SOURCES = libxslt.c types.c libxslt-py.c @@ -43,8 +42,8 @@ libxslt.py: $(srcdir)/libxsl.py $(srcdir)/libxsltclass.py cat $(srcdir)/libxsl.py $(srcdir)/libxsltclass.py > libxslt.py install-data-local: - $(mkinstalldirs) $(DESTDIR)$(libdir)/python${PYTHON_VERSION}/site-packages - @INSTALL@ -m 0644 libxslt.py $(DESTDIR)$(libdir)/python${PYTHON_VERSION}/site-packages + $(mkinstalldirs) $(DESTDIR)$(pythondir) + @INSTALL@ -m 0644 libxslt.py $(DESTDIR)$(pythondir) $(mkinstalldirs) $(DESTDIR)$(DOCS_DIR) @(for doc in $(DOCS) ; \ do @INSTALL@ -m 0644 $$doc $(DESTDIR)$(DOCS_DIR) ; done) diff --git a/xsltproc/xsltproc.c b/xsltproc/xsltproc.c index e15fbb4a..9f2ebe97 100644 --- a/xsltproc/xsltproc.c +++ b/xsltproc/xsltproc.c @@ -73,6 +73,10 @@ #endif #endif /* WIN32 */ +#ifdef HAVE_SYS_TIMEB_H +#include +#endif + #ifndef HAVE_STAT # ifdef HAVE__STAT /* MS C library seems to define stat and _stat. The definition