From cdaf4de866002343f4011bb05c71f764258948a7 Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Thu, 17 Nov 2022 09:21:50 +0100 Subject: [PATCH] Fix configure.ac/configure glitch (#2141801) --- liblognorm-configure-glitch.patch | 93 +++++++++++++++++++++++++++++++ liblognorm.spec | 10 +++- 2 files changed, 102 insertions(+), 1 deletion(-) create mode 100644 liblognorm-configure-glitch.patch diff --git a/liblognorm-configure-glitch.patch b/liblognorm-configure-glitch.patch new file mode 100644 index 0000000..71f920c --- /dev/null +++ b/liblognorm-configure-glitch.patch @@ -0,0 +1,93 @@ +Submitted to Adiscon via ticket system. See: + + + +diff --git a/configure b/configure +index 759bf0e49cb5d1fa..4b33ab400b380818 100755 +--- a/configure ++++ b/configure +@@ -14231,10 +14231,9 @@ fi + # Checks for libraries. + save_LIBS=$LIBS + LIBS= +-as_ac_Search=`$as_echo "ac_cv_search_clock_getm4_defn(2.69)" | $as_tr_sh` +-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_getm4_defn(2.69)" >&5 +-$as_echo_n "checking for library containing clock_getm4_defn(2.69)... " >&6; } +-if eval \${$as_ac_Search+:} false; then : ++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5 ++$as_echo_n "checking for library containing clock_gettime... " >&6; } ++if ${ac_cv_search_clock_gettime+:} false; then : + $as_echo_n "(cached) " >&6 + else + ac_func_search_save_LIBS=$LIBS +@@ -14247,16 +14246,16 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext + #ifdef __cplusplus + extern "C" + #endif +-char clock_getm4_defn(2.69) (); ++char clock_gettime (); + int + main () + { +-return clock_getm4_defn(2.69) (); ++return clock_gettime (); + ; + return 0; + } + _ACEOF +-for ac_lib in '' 2.68time; do ++for ac_lib in '' rt; do + if test -z "$ac_lib"; then + ac_res="none required" + else +@@ -14264,29 +14263,28 @@ for ac_lib in '' 2.68time; do + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : +- eval "$as_ac_Search=\$ac_res" ++ ac_cv_search_clock_gettime=$ac_res + fi + rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext +- if eval \${$as_ac_Search+:} false; then : ++ if ${ac_cv_search_clock_gettime+:} false; then : + break + fi + done +-if eval \${$as_ac_Search+:} false; then : ++if ${ac_cv_search_clock_gettime+:} false; then : + + else +- eval "$as_ac_Search=no" ++ ac_cv_search_clock_gettime=no + fi + rm conftest.$ac_ext + LIBS=$ac_func_search_save_LIBS + fi +-eval ac_res=\$$as_ac_Search +- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +-$as_echo "$ac_res" >&6; } +-eval ac_res=\$$as_ac_Search ++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5 ++$as_echo "$ac_cv_search_clock_gettime" >&6; } ++ac_res=$ac_cv_search_clock_gettime + if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +- rt ++ + fi + + LIBS=$save_LIBS +diff --git a/configure.ac b/configure.ac +index aad4993f242291a1..b4f791f7cac47a7d 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -38,7 +38,7 @@ m4_ifdef([AX_IS_RELEASE], [ + # Checks for libraries. + save_LIBS=$LIBS + LIBS= +-AC_SEARCH_LIBS(clock_getm4_defn([AC_AUTOCONF_VERSION]), [2.68]time, rt) ++AC_SEARCH_LIBS(clock_gettime, rt) + LIBS=$save_LIBS + + # Checks for header files. diff --git a/liblognorm.spec b/liblognorm.spec index a358330..f5d62a6 100644 --- a/liblognorm.spec +++ b/liblognorm.spec @@ -2,7 +2,7 @@ Name: liblognorm Version: 2.0.6 -Release: 5%{?dist} +Release: 6%{?dist} Summary: Fast samples-based log normalization library License: LGPLv2+ URL: http://www.liblognorm.com @@ -15,6 +15,7 @@ BuildRequires: libestr-devel BuildRequires: pcre-devel Patch0: liblognorm-2.0.6-rhbz2105934-sphinx5.patch +Patch1: liblognorm-configure-glitch.patch %description Briefly described, liblognorm is a tool to normalize log data. @@ -57,8 +58,12 @@ log files. %setup -q %patch0 -p1 -b .sphinx5 +%patch1 -p1 -b .configure-glitch %build +# Prevent rebuild of the configure script. +touch configure aclocal.m4 Makefile.in config.h.in + %configure --enable-regexp --enable-docs --docdir=%{htmldir} --includedir=%{_includedir}/%{name}/ @@ -92,6 +97,9 @@ rm %{buildroot}%{htmldir}/{objects.inv,.buildinfo} %changelog +* Thu Nov 17 2022 Florian Weimer - 2.0.6-6 +- Fix configure.ac/configure glitch (#2141801) + * Thu Jul 21 2022 Fedora Release Engineering - 2.0.6-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild