From 05ee529d68986f5db286675655c86cf4715cbd01 Mon Sep 17 00:00:00 2001 From: Marcin Krol Date: Mon, 25 Feb 2019 12:12:13 +0100 Subject: [PATCH 1/4] - release 2 --- apr-util.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apr-util.spec b/apr-util.spec index 38e2fcc..3f8450d 100644 --- a/apr-util.spec +++ b/apr-util.spec @@ -19,7 +19,7 @@ Summary: A companion library to Apache Portable Runtime Summary(pl.UTF-8): Biblioteka towarzysząca Apache Portable Runtime Name: apr-util Version: 1.6.1 -Release: 1 +Release: 2 Epoch: 1 License: Apache v2.0 Group: Libraries -- 2.44.0 From 58436a316af11beedda1308f5097c993c1ca6dfb Mon Sep 17 00:00:00 2001 From: Marcin Krol Date: Mon, 4 Apr 2022 19:25:39 +0200 Subject: [PATCH 2/4] - release 5 --- apr-util-flags.patch | 11 ++++++----- apr-util-link.patch | 17 ++++++++--------- apr-util.spec | 6 +++--- 3 files changed, 17 insertions(+), 17 deletions(-) diff --git a/apr-util-flags.patch b/apr-util-flags.patch index c4c39ed..9f7ffcf 100644 --- a/apr-util-flags.patch +++ b/apr-util-flags.patch @@ -1,10 +1,11 @@ ---- apr-util-1.3.9/configure.in~ 2010-08-03 10:09:13.537864637 +0200 -+++ apr-util-1.3.9/configure.in 2010-08-03 10:17:48.184690019 +0200 -@@ -216,6 +216,7 @@ +diff -urNp -x '*.orig' apr-util-1.6.1.org/configure.in apr-util-1.6.1/configure.in +--- apr-util-1.6.1.org/configure.in 2021-10-09 23:46:59.125014825 +0200 ++++ apr-util-1.6.1/configure.in 2021-10-09 23:46:59.218348038 +0200 +@@ -277,6 +277,7 @@ APR_ADDTO(APRUTIL_LIBS, [$APR_LIBS]) AC_SUBST(APRUTIL_EXPORT_LIBS) AC_SUBST(APRUTIL_PRIV_INCLUDES) +APRUTIL_INCLUDES="$APRUTIL_INCLUDES -I/usr/include/apr" AC_SUBST(APRUTIL_INCLUDES) - AC_SUBST(APRUTIL_LDFLAGS) - AC_SUBST(APRUTIL_LIBS) + + APR_REMOVEFROM(APRUTIL_LDFLAGS,[-L/usr/lib]) diff --git a/apr-util-link.patch b/apr-util-link.patch index d85fac4..057bc89 100644 --- a/apr-util-link.patch +++ b/apr-util-link.patch @@ -1,8 +1,9 @@ ---- apr-util-0.9.4/configure.in.orig 2004-04-18 23:20:56.000000000 +0200 -+++ apr-util-0.9.4/configure.in 2004-04-18 23:25:35.447213680 +0200 -@@ -98,7 +98,12 @@ - APU_FIND_EXPAT - APU_FIND_ICONV +diff -urNp -x '*.orig' apr-util-1.6.1.org/configure.in apr-util-1.6.1/configure.in +--- apr-util-1.6.1.org/configure.in 2017-04-02 19:57:23.000000000 +0200 ++++ apr-util-1.6.1/configure.in 2021-10-09 23:46:58.615015473 +0200 +@@ -172,7 +172,12 @@ APU_FIND_ICONV + dnl Enable DSO build; must be last: + APU_CHECK_UTIL_DSO +save_LIBS="$LIBS" +LIBS= @@ -13,11 +14,9 @@ AC_MSG_CHECKING(if system crypt() function is threadsafe) if test "x$apu_crypt_threadsafe" = "x1"; then AC_DEFINE(APU_CRYPT_THREADSAFE, 1, [Define if the system crypt() function is threadsafe]) ---- apr-util-1.5.4/configure.in~ 2016-04-08 22:47:59.000000000 +0200 -+++ apr-util-1.5.4/configure.in 2016-04-08 22:50:43.902956204 +0200 -@@ -227,6 +227,11 @@ AC_SUBST(APRUTIL_EXPORT_LIBS) +@@ -273,6 +278,11 @@ APR_ADDTO(APRUTIL_LIBS, [$APR_LIBS]) + AC_SUBST(APRUTIL_EXPORT_LIBS) AC_SUBST(APRUTIL_PRIV_INCLUDES) - APRUTIL_INCLUDES="$APRUTIL_INCLUDES -I/usr/include/apr" AC_SUBST(APRUTIL_INCLUDES) + +APR_REMOVEFROM(APRUTIL_LDFLAGS,[-L/usr/lib]) diff --git a/apr-util.spec b/apr-util.spec index 3f8450d..ff1ac31 100644 --- a/apr-util.spec +++ b/apr-util.spec @@ -13,13 +13,13 @@ %bcond_without openssl # without OpenSSL crypto module %bcond_without tests # don't perform "make check" -%define dbver db47 +%define dbver db53 Summary: A companion library to Apache Portable Runtime Summary(pl.UTF-8): Biblioteka towarzysząca Apache Portable Runtime Name: apr-util Version: 1.6.1 -Release: 2 +Release: 5 Epoch: 1 License: Apache v2.0 Group: Libraries @@ -32,7 +32,7 @@ Patch3: %{name}-flags.patch URL: http://apr.apache.org/ BuildRequires: apr-devel >= 1:1.6.0 BuildRequires: autoconf >= 2.59 -BuildRequires: db-devel >= 4.7 +BuildRequires: db-devel >= 5.3 BuildRequires: expat-devel %{?with_freetds:BuildRequires: freetds-devel} BuildRequires: libtool -- 2.44.0 From f31ad4e11f1d29af01770514f34a77857ddb5825 Mon Sep 17 00:00:00 2001 From: Marcin Krol Date: Wed, 19 Jul 2023 14:35:24 +0200 Subject: [PATCH 3/4] - updated to 1.6.3 --- apr-util-libtool.patch | 11 ----------- apr-util-link.patch | 14 +++++++++++--- apr-util.spec | 9 ++++----- 3 files changed, 15 insertions(+), 19 deletions(-) delete mode 100644 apr-util-libtool.patch diff --git a/apr-util-libtool.patch b/apr-util-libtool.patch deleted file mode 100644 index d88d5d3..0000000 --- a/apr-util-libtool.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- apr-util-1.3.4/Makefile.in~ 2008-06-13 12:27:19.000000000 +0300 -+++ apr-util-1.3.4/Makefile.in 2008-08-25 17:08:58.625899912 +0300 -@@ -23,7 +23,7 @@ - INSTALL_DATA = @INSTALL_DATA@ - - APU_MODULES = @APU_MODULES@ --LINK_MODULE = $(LIBTOOL) $(LTFLAGS) --mode=link $(CC) $(LT_LDFLAGS) $(ALL_CFLAGS) $(ALL_LDFLAGS) $(APRUTIL_LDFLAGS) -release $(APRUTIL_MAJOR_VERSION) -module -rpath $(APU_DSO_LIBDIR) -+LINK_MODULE = $(LIBTOOL) $(LTFLAGS) --mode=link --tag=CC $(CC) $(LT_LDFLAGS) $(ALL_CFLAGS) $(ALL_LDFLAGS) $(APRUTIL_LDFLAGS) -release $(APRUTIL_MAJOR_VERSION) -module -rpath $(APU_DSO_LIBDIR) - APU_DSO_LIBDIR = @APU_DSO_LIBDIR@ - - LT_VERSION = @APU_LTVERSION@ diff --git a/apr-util-link.patch b/apr-util-link.patch index 057bc89..4886975 100644 --- a/apr-util-link.patch +++ b/apr-util-link.patch @@ -1,16 +1,24 @@ diff -urNp -x '*.orig' apr-util-1.6.1.org/configure.in apr-util-1.6.1/configure.in --- apr-util-1.6.1.org/configure.in 2017-04-02 19:57:23.000000000 +0200 +++ apr-util-1.6.1/configure.in 2021-10-09 23:46:58.615015473 +0200 -@@ -172,7 +172,12 @@ APU_FIND_ICONV +@@ -175,14 +175,19 @@ APU_FIND_ICONV dnl Enable DSO build; must be last: APU_CHECK_UTIL_DSO +save_LIBS="$LIBS" +LIBS= AC_SEARCH_LIBS(crypt, crypt ufc) -+APR_ADDTO(APRUTIL_EXPORT_LIBS, [$LIBS]) -+APR_ADDTO(APRUTIL_LIBS, [$LIBS]) + case "$ac_cv_search_crypt" in + "no"|"none required") + ;; + *) +- APR_ADDTO(APRUTIL_LIBS, [$ac_cv_search_crypt]) ++ APR_ADDTO(APRUTIL_EXPORT_LIBS, [$LIBS]) ++ APR_ADDTO(APRUTIL_LIBS, [$LIBS]) + ;; + esac +LIBS="$save_LIBS $LIBS" ++ AC_MSG_CHECKING(if system crypt() function is threadsafe) if test "x$apu_crypt_threadsafe" = "x1"; then AC_DEFINE(APU_CRYPT_THREADSAFE, 1, [Define if the system crypt() function is threadsafe]) diff --git a/apr-util.spec b/apr-util.spec index ff1ac31..9a4b8b4 100644 --- a/apr-util.spec +++ b/apr-util.spec @@ -18,16 +18,15 @@ Summary: A companion library to Apache Portable Runtime Summary(pl.UTF-8): Biblioteka towarzysząca Apache Portable Runtime Name: apr-util -Version: 1.6.1 -Release: 5 +Version: 1.6.3 +Release: 1 Epoch: 1 License: Apache v2.0 Group: Libraries Source0: http://www.apache.org/dist/apr/%{name}-%{version}.tar.bz2 -# Source0-md5: 8ff5dc36fa39a2a3db1df196d3ed6086 +# Source0-md5: b6e8c9b31d938fe5797ceb0d1ff2eb69 Patch0: %{name}-link.patch Patch1: %{name}-config-noldap.patch -Patch2: %{name}-libtool.patch Patch3: %{name}-flags.patch URL: http://apr.apache.org/ BuildRequires: apr-devel >= 1:1.6.0 @@ -223,7 +222,6 @@ Statyczna biblioteka apr-util. %setup -q %patch0 -p1 %patch1 -p1 -%patch2 -p1 %patch3 -p1 echo ' @@ -246,6 +244,7 @@ echo ' ' > config.layout %build +PYTHON=%{__python3} \ ./buildconf \ --with-apr=%{_datadir}/apr -- 2.44.0 From 0ae3a29a383e29d4f6eabf0411b6a627828d9299 Mon Sep 17 00:00:00 2001 From: Marcin Krol Date: Mon, 1 Apr 2024 16:30:08 +0200 Subject: [PATCH 4/4] - fix building with MySQL 8.x --- apr-util.spec | 8 +++++--- mysql8.patch | 27 +++++++++++++++++++++++++++ 2 files changed, 32 insertions(+), 3 deletions(-) create mode 100644 mysql8.patch diff --git a/apr-util.spec b/apr-util.spec index 9a4b8b4..641e713 100644 --- a/apr-util.spec +++ b/apr-util.spec @@ -19,7 +19,7 @@ Summary: A companion library to Apache Portable Runtime Summary(pl.UTF-8): Biblioteka towarzysząca Apache Portable Runtime Name: apr-util Version: 1.6.3 -Release: 1 +Release: 2 Epoch: 1 License: Apache v2.0 Group: Libraries @@ -28,6 +28,7 @@ Source0: http://www.apache.org/dist/apr/%{name}-%{version}.tar.bz2 Patch0: %{name}-link.patch Patch1: %{name}-config-noldap.patch Patch3: %{name}-flags.patch +Patch4: mysql8.patch URL: http://apr.apache.org/ BuildRequires: apr-devel >= 1:1.6.0 BuildRequires: autoconf >= 2.59 @@ -35,7 +36,7 @@ BuildRequires: db-devel >= 5.3 BuildRequires: expat-devel %{?with_freetds:BuildRequires: freetds-devel} BuildRequires: libtool -%{?with_mysql:BuildRequires: mysql-devel} +%{?with_mysql:BuildRequires: mysql-devel >= 8.0.35} %{?with_nss:BuildRequires: nss-devel} %{?with_ldap:BuildRequires: openldap-devel >= 2.3.0} %{?with_openssl:BuildRequires: openssl-devel} @@ -223,6 +224,7 @@ Statyczna biblioteka apr-util. %patch0 -p1 %patch1 -p1 %patch3 -p1 +%patch4 -p0 echo ' @@ -263,7 +265,7 @@ PYTHON=%{__python3} \ %{?with_nss:--with-nss} \ %{?with_openssl:--with-openssl} \ %{!?with_freetds:--without-freetds} \ - %{?with_mysql:--with-mysql=%{_prefix}} \ + %{?with_mysql:--with-mysql} \ %{!?with_odbc:--without-odbc} \ %{?with_oracle:--with-oracle} \ %{!?with_pgsql:--without-pgsql} \ diff --git a/mysql8.patch b/mysql8.patch new file mode 100644 index 0000000..d771e69 --- /dev/null +++ b/mysql8.patch @@ -0,0 +1,27 @@ +https://bz.apache.org/bugzilla/show_bug.cgi?id=62631 + +--- dbd/apr_dbd_mysql.c 2014-09-16 11:45:15.000000000 +0000 ++++ dbd/apr_dbd_mysql.c 2018-08-11 20:25:13.202562000 +0000 +@@ -47,6 +47,13 @@ + #include "apr_strings.h" + #include "apr_lib.h" + #include "apr_buckets.h" ++/* MySQL 8.0 replaces my_bool with C99 bool. Earlier versions of MySQL had ++* a typedef to char. Gem users reported failures on big endian systems when ++* using C99 bool types with older MySQLs due to mismatched behavior. */ ++#ifndef HAVE_TYPE_MY_BOOL ++#include ++typedef bool my_bool; ++#endif + + #include "apr_dbd_internal.h" + +@@ -1262,7 +1262,7 @@ + + static void dbd_mysql_init(apr_pool_t *pool) + { +-#if MYSQL_VERSION_ID < 100000 ++#if MYSQL_VERSION_ID < 80002 + my_init(); + #endif + mysql_thread_init(); -- 2.44.0