mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-07-29 11:41:22 +03:00
trying to conciliate --with-python= requirements and RPM builds, a PITA
* configure.in libxml.spec.in python/Makefile.am: trying to conciliate --with-python= requirements and RPM builds, a PITA really... Daniel
This commit is contained in:
@ -1,3 +1,9 @@
|
|||||||
|
Wed May 14 14:56:46 EDT 2003 Daniel Veillard <daniel@veillard.com>
|
||||||
|
|
||||||
|
* configure.in libxml.spec.in python/Makefile.am: trying
|
||||||
|
to conciliate --with-python= requirements and RPM builds,
|
||||||
|
a PITA really...
|
||||||
|
|
||||||
Tue May 13 18:30:34 EDT 2003 Daniel Veillard <daniel@veillard.com>
|
Tue May 13 18:30:34 EDT 2003 Daniel Veillard <daniel@veillard.com>
|
||||||
|
|
||||||
* HTMLparser.c: oops last commit introduced a memory leak.
|
* HTMLparser.c: oops last commit introduced a memory leak.
|
||||||
|
@ -251,6 +251,7 @@ PYTHON=
|
|||||||
PYTHON_VERSION=
|
PYTHON_VERSION=
|
||||||
PYTHON_INCLUDES=
|
PYTHON_INCLUDES=
|
||||||
PYTHON_SITE_PACKAGES=
|
PYTHON_SITE_PACKAGES=
|
||||||
|
pythondir=
|
||||||
AC_ARG_WITH(python,
|
AC_ARG_WITH(python,
|
||||||
[ --with-python[[=DIR]] build Python bindings if found])
|
[ --with-python[[=DIR]] build Python bindings if found])
|
||||||
if test "$with_python" != "no" ; then
|
if test "$with_python" != "no" ; then
|
||||||
@ -299,6 +300,12 @@ if test "$with_python" != "no" ; then
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
if test "$with_python" != ""
|
||||||
|
then
|
||||||
|
pythondir='$(PYTHON_SITE_PACKAGES)'
|
||||||
|
else
|
||||||
|
pythondir='$(libdir)/python${PYTHON_VERSION}/site-packages'
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
AM_CONDITIONAL(WITH_PYTHON, test "$PYTHON_INCLUDES" != "")
|
AM_CONDITIONAL(WITH_PYTHON, test "$PYTHON_INCLUDES" != "")
|
||||||
if test "$PYTHON_INCLUDES" != ""
|
if test "$PYTHON_INCLUDES" != ""
|
||||||
@ -307,6 +314,7 @@ then
|
|||||||
else
|
else
|
||||||
PYTHON_SUBDIR=
|
PYTHON_SUBDIR=
|
||||||
fi
|
fi
|
||||||
|
AC_SUBST(pythondir)
|
||||||
AC_SUBST(PYTHON_SUBDIR)
|
AC_SUBST(PYTHON_SUBDIR)
|
||||||
|
|
||||||
dnl
|
dnl
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
Summary: Library providing XML and HTML support
|
Summary: Library providing XML and HTML support
|
||||||
Name: libxml2
|
Name: libxml2
|
||||||
Version: @VERSION@
|
Version: @VERSION@
|
||||||
Release: 1
|
Release: 667
|
||||||
License: MIT
|
License: MIT
|
||||||
Group: Development/Libraries
|
Group: Development/Libraries
|
||||||
Source: ftp://xmlsoft.org/libxml2-%{version}.tar.gz
|
Source: ftp://xmlsoft.org/libxml2-%{version}.tar.gz
|
||||||
@ -73,26 +73,6 @@ rm -fr %{buildroot}
|
|||||||
|
|
||||||
%makeinstall
|
%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_INCLUDES="%{prefix}/include/python$py_version" \
|
|
||||||
PYTHON_VERSION="$py_version"; \
|
|
||||||
%makeinstall PYTHON="%{prefix}/bin/python$py_version" \
|
|
||||||
PYTHON_INCLUDES="%{prefix}/include/python$py_version" \
|
|
||||||
PYTHON_VERSION="$py_version" )
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
%clean
|
%clean
|
||||||
rm -fr %{buildroot}
|
rm -fr %{buildroot}
|
||||||
|
|
||||||
|
@ -31,7 +31,6 @@ mylibs = \
|
|||||||
|
|
||||||
all-local: libxml2.py
|
all-local: libxml2.py
|
||||||
|
|
||||||
pythondir = $(libdir)/python${PYTHON_VERSION}/site-packages
|
|
||||||
python_LTLIBRARIES = libxml2mod.la
|
python_LTLIBRARIES = libxml2mod.la
|
||||||
|
|
||||||
libxml2mod_la_SOURCES = libxml.c types.c libxml2-py.c
|
libxml2mod_la_SOURCES = libxml.c types.c libxml2-py.c
|
||||||
@ -41,9 +40,9 @@ libxml2.py: $(srcdir)/libxml.py $(srcdir)/libxml2class.py
|
|||||||
cat $(srcdir)/libxml.py $(srcdir)/libxml2class.py > libxml2.py
|
cat $(srcdir)/libxml.py $(srcdir)/libxml2class.py > libxml2.py
|
||||||
|
|
||||||
install-data-local:
|
install-data-local:
|
||||||
$(mkinstalldirs) $(DESTDIR)$(libdir)/python${PYTHON_VERSION}/site-packages
|
$(mkinstalldirs) $(DESTDIR)$(pythondir)
|
||||||
@INSTALL@ -m 0644 libxml2.py $(DESTDIR)$(libdir)/python${PYTHON_VERSION}/site-packages
|
@INSTALL@ -m 0644 libxml2.py $(DESTDIR)$(pythondir)
|
||||||
@INSTALL@ -m 0644 drv_libxml2.py $(DESTDIR)$(libdir)/python${PYTHON_VERSION}/site-packages
|
@INSTALL@ -m 0644 drv_libxml2.py $(DESTDIR)$(pythondir)
|
||||||
$(mkinstalldirs) $(DESTDIR)$(DOCS_DIR)
|
$(mkinstalldirs) $(DESTDIR)$(DOCS_DIR)
|
||||||
@(for doc in $(DOCS) ; \
|
@(for doc in $(DOCS) ; \
|
||||||
do @INSTALL@ -m 0644 $$doc $(DESTDIR)$(DOCS_DIR) ; done)
|
do @INSTALL@ -m 0644 $$doc $(DESTDIR)$(DOCS_DIR) ; done)
|
||||||
|
Reference in New Issue
Block a user