diff --git a/libxslt-1.1.37.tar.xz b/libxslt-1.1.37.tar.xz deleted file mode 100644 index c4073daee96bd122e293ccca5a2afc717858d35c..0000000000000000000000000000000000000000 Binary files a/libxslt-1.1.37.tar.xz and /dev/null differ diff --git a/libxslt-1.1.39.tar.xz b/libxslt-1.1.39.tar.xz new file mode 100644 index 0000000000000000000000000000000000000000..66a4bdde7d05642a1c8a93b6cd08f8c27c3d731b Binary files /dev/null and b/libxslt-1.1.39.tar.xz differ diff --git a/libxslt.spec b/libxslt.spec index 2f627874329bc9c3ea12b8bb6bf7db7d23cf5e81..d3974b2beae9b42e34553355008657fe60d551d7 100644 --- a/libxslt.spec +++ b/libxslt.spec @@ -1,8 +1,7 @@ -%define anolis_release 1 Name: libxslt Summary: Library providing the Gnome XSLT engine -Version: 1.1.37 -Release: %{anolis_release}%{?dist} +Version: 1.1.39 +Release: 6%{?dist} License: MIT URL: https://gitlab.gnome.org/GNOME/libxslt @@ -10,9 +9,18 @@ Source0: https://download.gnome.org/sources/%{name}/1.1/%{name}-%{version Provides: xsltproc = %{version}-%{release} +BuildRequires: autoconf +BuildRequires: automake +BuildRequires: libtool BuildRequires: make BuildRequires: gcc BuildRequires: pkgconfig(libxml-2.0) >= 2.6.27 +BuildRequires: python3-devel + +# Fedora specific patches +Patch0: multilib.patch +# https://bugzilla.redhat.com/show_bug.cgi?id=1467435 +Patch1: multilib2.patch %description This C library allows to transform XML files into other XML files @@ -20,82 +28,90 @@ This C library allows to transform XML files into other XML files mechanism. To use it you need to have a version of libxml2 >= 2.6.27 installed. The xsltproc command is a command line interface to the XSLT engine -%package doc -Summary: Documentation files for %{name} -Requires: %{name} = %{version}-%{release} -BuildArch: noarch - -%description doc -The %{name}-doc package contains documentation files for %{name}. - %package devel Summary: Development libraries and header files for %{name} -Requires: %{name} = %{version}-%{release} +Requires: %{name}%{?_isa} = %{version}-%{release} +Requires: libgpg-error-devel%{?_isa} %description devel The %{name}-devel package contains libraries and header files for developing applications that use %{name}. +%if 0%{?fedora} +# Upstream package has not been ported to Python 3. I have +# converted this section so it could be used to compile the +# Python 3 bindings one day once that has happened, but +# commented it out. - RWMJ 2019-09-10 %package -n python3-libxslt Summary: Python 3 bindings for %{name} -BuildRequires: python3-devel BuildRequires: python3-libxml2 -Requires: %{name} = %{version}-%{release} +Requires: %{name}%{?_isa} = %{version}-%{release} Requires: python3-libxml2 %{?python_provide:%python_provide python3-%{name}} - + %description -n python3-libxslt The libxslt-python package contains a module that permits applications written in the Python programming language to use the interface supplied by the libxslt library to apply XSLT transformations. - + This library allows to parse sytlesheets, uses the libxml2-python to load and save XML and HTML files. Direct access to XPath and the XSLT transformation context are possible to extend the XSLT language with XPath functions written in Python. +%endif %prep %autosetup -p1 chmod 644 python/tests/* %build -%configure --disable-static --disable-silent-rules --with-python=yes --with-crypto=no +autoreconf -vfi +#export PYTHON=%{__python3} +#%configure --disable-static --disable-silent-rules --with-python +%configure \ + --disable-static \ + --disable-silent-rules \ +%if 0%{?fedora} + --with-python=yes \ +%else + --with-python=no \ +%endif + --with-crypto=no %make_build %install %make_install +find %{buildroot} -name '*.la' -print -delete +# multiarch crazyness on timestamp differences +touch -m --reference=%{buildroot}%{_includedir}/libxslt/xslt.h %{buildroot}%{_bindir}/xslt-config rm -vrf %{buildroot}%{_docdir} -%generate_compatibility_deps - %check %make_build tests +%ldconfig_scriptlets + %files -%dir %{abidir} %license Copyright +%doc AUTHORS NEWS README.md FEATURES %{_bindir}/xsltproc %{_libdir}/libxslt.so.* %{_libdir}/libexslt.so.* %{_libdir}/libxslt-plugins/ %{_mandir}/man1/xsltproc.1* -%{abidir}/libxslt.dump -%{abidir}/libexslt.dump - -%files doc -%doc AUTHORS NEWS README FEATURES %files devel %doc doc/libxslt-api.xml -%doc doc/libxslt-refs.xml %doc doc/EXSLT/libexslt-api.xml -%doc doc/EXSLT/libexslt-refs.xml %doc %{_mandir}/man3/libxslt.3* %doc %{_mandir}/man3/libexslt.3* +#%doc doc/*.html doc/html doc/*.gif doc/*.png +#%doc doc/images %doc doc/tutorial %doc doc/tutorial2 -%{_datadir}/gtk-doc/* -%{_libdir}/cmake/libxslt +#%%doc doc/EXSLT +%{_datadir}/gtk-doc/ +%{_libdir}/cmake/libxslt/ %{_libdir}/libxslt.so %{_libdir}/libexslt.so %{_libdir}/xsltConf.sh @@ -105,8 +121,8 @@ rm -vrf %{buildroot}%{_docdir} %{_libdir}/pkgconfig/libxslt.pc %{_libdir}/pkgconfig/libexslt.pc %{_bindir}/xslt-config -%{abidir}/xslt-config-option.list +%if 0%{?fedora} %files -n python3-libxslt %{python3_sitelib}/libxslt.py* %{python3_sitearch}/libxsltmod.so @@ -115,9 +131,12 @@ rm -vrf %{buildroot}%{_docdir} %doc python/tests/*.py %doc python/tests/*.xml %doc python/tests/*.xsl -%{abidir}/libxsltmod.dump +%endif %changelog +* Wed Feb 19 2025 Liwei Ge - 1.1.39-6 +- Sync up CentOS stream libxsl-1.1.39-6 (tdawson@redhat.com) + * Sun Nov 27 2022 Funda Wang - 1.1.37-1 - New version 1.1.37 - Reenable python as upstream does @@ -127,4 +146,3 @@ rm -vrf %{buildroot}%{_docdir} * Thu Apr 07 2022 mgb01105731 - 1.1.35-1 - Init from upstream version 1.1.35 - diff --git a/multilib.patch b/multilib.patch new file mode 100644 index 0000000000000000000000000000000000000000..94715d24250d990db80c506b358e3339cd092538 --- /dev/null +++ b/multilib.patch @@ -0,0 +1,24 @@ +*** XSLT/xslt-config.in.orig 2006-06-06 17:32:23.000000000 +0200 +--- XSLT/xslt-config.in 2006-06-06 17:32:48.000000000 +0200 +*************** +*** 4,10 **** + exec_prefix=@exec_prefix@ + exec_prefix_set=no + includedir=@includedir@ +! libdir=@libdir@ + + usage() + { +--- 4,15 ---- + exec_prefix=@exec_prefix@ + exec_prefix_set=no + includedir=@includedir@ +! if [ "`ldd /bin/sh | grep lib64`" = "" ] +! then +! libdir=${exec_prefix}/lib +! else +! libdir=${exec_prefix}/lib64 +! fi + + usage() + { diff --git a/multilib2.patch b/multilib2.patch new file mode 100644 index 0000000000000000000000000000000000000000..22ffe7e298295578001b67f860a32f7042438f6a --- /dev/null +++ b/multilib2.patch @@ -0,0 +1,28 @@ +diff -urN libxslt-1.1.32/libxslt/xsltconfig.h.in libxslt-1.1.32.completemultilib/libxslt/xsltconfig.h.in +--- libxslt-1.1.32/libxslt/xsltconfig.h.in 2017-10-26 07:55:47.000000000 +0000 ++++ libxslt-1.1.32.completemultilib/libxslt/xsltconfig.h.in 2019-05-06 11:35:57.948191169 +0000 +@@ -120,7 +120,11 @@ + #ifndef WITH_MODULES + #define WITH_MODULES + #endif +-#define LIBXSLT_DEFAULT_PLUGINS_PATH() "@LIBXSLT_DEFAULT_PLUGINS_PATH@" ++#ifdef __LP64__ ++#define LIBXSLT_DEFAULT_PLUGINS_PATH() "/usr/lib64/libxslt-plugins" ++#else ++#define LIBXSLT_DEFAULT_PLUGINS_PATH() "/usr/lib/libxslt-plugins" ++#endif + #endif + + /** +diff -urN libxslt-1.1.32/xslt-config.in libxslt-1.1.32.completemultilib/xslt-config.in +--- libxslt-1.1.32/xslt-config.in 2015-05-10 14:11:30.000000000 +0000 ++++ libxslt-1.1.32.completemultilib/xslt-config.in 2019-05-06 11:34:59.670592304 +0000 +@@ -65,7 +65,7 @@ + ;; + + --plugins) +- echo @LIBXSLT_DEFAULT_PLUGINS_PATH@ ++ echo ${libdir}/libxslt-plugins + exit 0 + ;; +