public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/log4cxx] epel9: Skip 2GB-message test on 32-bit architectures
@ 2026-07-03 10:06 Till Hofmann
  0 siblings, 0 replies; only message in thread
From: Till Hofmann @ 2026-07-03 10:06 UTC (permalink / raw)
  To: git-commits

            A new commit has been pushed.

            Repo   : rpms/log4cxx
            Branch : epel9
            Commit : e27d33ad25de6fb83b575b9e3e1b679d5366dcd9
            Author : Till Hofmann <thofmann@fedoraproject.org>
            Date   : 2026-07-03T12:05:57+02:00
            Stats  : +25/-1 in 2 file(s)
            URL    : https://src.fedoraproject.org/rpms/log4cxx/c/e27d33ad25de6fb83b575b9e3e1b679d5366dcd9?branch=epel9

            Log:
            Skip 2GB-message test on 32-bit architectures

test2GbMessageFormatting allocates a LogString slightly larger than
2GB, which cannot succeed in a 32-bit process address space and fails
the i686 build with a basic_string::_M_create exception rather than a
real functional bug.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
(cherry picked from commit ec593a4ee57ac81ce659e849715efe2b82166f7b)

---
diff --git a/log4cxx-1.7.0-skip-2gb-test-on-32bit.patch b/log4cxx-1.7.0-skip-2gb-test-on-32bit.patch
new file mode 100644
index 0000000..f956389
--- /dev/null
+++ b/log4cxx-1.7.0-skip-2gb-test-on-32bit.patch
@@ -0,0 +1,21 @@
+--- a/src/test/cpp/patternlayouttest.cpp	2026-07-03 08:52:48.586698382 +0200
++++ b/src/test/cpp/patternlayouttest.cpp	2026-07-03 08:52:55.522953067 +0200
+@@ -40,6 +40,7 @@
+ #include "logunit.h"
+ #include <log4cxx/spi/loggerrepository.h>
+ #include <log4cxx/helpers/stringhelper.h>
++#include <cstdint>
+ 
+ 
+ #define REGEX_STR(x) x
+@@ -63,7 +64,10 @@
+ LOGUNIT_CLASS(PatternLayoutTest)
+ {
+ 	LOGUNIT_TEST_SUITE(PatternLayoutTest);
++#if UINTPTR_MAX > 0xFFFFFFFF
++	// Allocating a > 2GB LogString is only feasible in a 64-bit address space
+ 	LOGUNIT_TEST(test2GbMessageFormatting);
++#endif
+ 	LOGUNIT_TEST(test1);
+ 	LOGUNIT_TEST(test2);
+ 	LOGUNIT_TEST(test3);

diff --git a/log4cxx.spec b/log4cxx.spec
index 0465694..80bdb9b 100644
--- a/log4cxx.spec
+++ b/log4cxx.spec
@@ -8,6 +8,9 @@ Summary: A port to C++ of the Log4j project
 License: Apache-2.0
 URL: http://logging.apache.org/log4cxx/index.html
 Source0: http://www.apache.org/dist/logging/log4cxx/%{version}/apache-%{name}-%{version}.tar.gz
+# test2GbMessageFormatting allocates a >2GB string, which cannot succeed in a
+# 32-bit address space; skip it there instead of failing the whole test suite
+Patch0: %{name}-1.7.0-skip-2gb-test-on-32bit.patch
 
 BuildRequires: apr-devel
 BuildRequires: apr-util-devel
@@ -39,7 +42,7 @@ Documentation for %{name}.
 
 
 %prep
-%autosetup -n apache-%{name}-%{version}
+%autosetup -n apache-%{name}-%{version} -p1
 
 %build
 %cmake -DBUILD_SITE=ON

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2026-07-03 10:06 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-07-03 10:06 [rpms/log4cxx] epel9: Skip 2GB-message test on 32-bit architectures Till Hofmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox