Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH 01/11] binutils: backport a patch to address failures when time64.inc is in use
@ 2023-04-26  9:50 Alexander Kanavin
  2023-04-26  9:50 ` [PATCH 02/11] time64.inc: add glibc-testsuite to 'special cases' Alexander Kanavin
                   ` (9 more replies)
  0 siblings, 10 replies; 38+ messages in thread
From: Alexander Kanavin @ 2023-04-26  9:50 UTC (permalink / raw)
  To: openembedded-core; +Cc: Alexander Kanavin

Signed-off-by: Alexander Kanavin <alex@linutronix.de>
---
 .../binutils/binutils-2.40.inc                |  1 +
 .../binutils/binutils/fix-time64.patch        | 94 +++++++++++++++++++
 2 files changed, 95 insertions(+)
 create mode 100644 meta/recipes-devtools/binutils/binutils/fix-time64.patch

diff --git a/meta/recipes-devtools/binutils/binutils-2.40.inc b/meta/recipes-devtools/binutils/binutils-2.40.inc
index 93631ca3d7f..ad2c9f9da14 100644
--- a/meta/recipes-devtools/binutils/binutils-2.40.inc
+++ b/meta/recipes-devtools/binutils/binutils-2.40.inc
@@ -35,5 +35,6 @@ SRC_URI = "\
      file://0014-configure-remove-dependencies-on-gmp-and-mpfr-when-g.patch \
      file://0015-Remove-duplicate-pe-dll.o-entry-deom-targ_extra_ofil.patch \
      file://0016-CVE-2023-25586.patch \
+     file://fix-time64.patch \
 "
 S  = "${WORKDIR}/git"
diff --git a/meta/recipes-devtools/binutils/binutils/fix-time64.patch b/meta/recipes-devtools/binutils/binutils/fix-time64.patch
new file mode 100644
index 00000000000..0bfc977fd4e
--- /dev/null
+++ b/meta/recipes-devtools/binutils/binutils/fix-time64.patch
@@ -0,0 +1,94 @@
+From f6f19a39ecfe962cb8a05522c27f513308687a74 Mon Sep 17 00:00:00 2001
+From: Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
+Date: Thu, 16 Feb 2023 19:00:47 -0800
+Subject: [PATCH] gprofng: PR30036 Build failure on aarch64 w/ glibc: symbol
+ `pwrite64' is already defined
+
+gprofng/ChangeLog
+2023-02-16  Vladimir Mezentsev  <vladimir.mezentsev@oracle.com>
+
+	PR gprofng/30036
+	* libcollector/iotrace.c: Define creat64 and pwrite64 only when
+	__USE_LARGEFILE64 and __USE_FILE_OFFSET64 are not defined.
+	* libcollector/mmaptrace.c: Likewise for mmap64.
+
+Upstream-Status: Backport [https://sourceware.org/git/?p=binutils-gdb.git;a=commitdiff;h=f6f19a39ecfe962cb8a05522c27f513308687a74]
+Signed-off-by: Alexander Kanavin <alex@linutronix.de>
+---
+ gprofng/libcollector/iotrace.c   | 15 ++++++++-------
+ gprofng/libcollector/mmaptrace.c |  2 +-
+ 2 files changed, 9 insertions(+), 8 deletions(-)
+
+diff --git a/gprofng/libcollector/iotrace.c b/gprofng/libcollector/iotrace.c
+index af90cc31f1a..d8439b02b3a 100644
+--- a/gprofng/libcollector/iotrace.c
++++ b/gprofng/libcollector/iotrace.c
+@@ -1441,7 +1441,7 @@ creat (const char *path, mode_t mode)
+ }
+ 
+ /*------------------------------------------------------------- creat64 */
+-#if WSIZE(32)
++#if WSIZE(32) && !defined(__USE_LARGEFILE64)
+ int
+ creat64 (const char *path, mode_t mode)
+ {
+@@ -2476,7 +2476,7 @@ __collector_pwrite_2_1 (int fildes, const void *buf, size_t nbyte, off_t offset)
+   return ret;
+ }
+ 
+-#else
++#endif
+ ssize_t
+ pwrite (int fildes, const void *buf, size_t nbyte, off_t offset)
+ {
+@@ -2497,11 +2497,10 @@ pwrite (int fildes, const void *buf, size_t nbyte, off_t offset)
+   POP_REENTRANCE (guard);
+   return ret;
+ }
+-#endif
+ 
+ /*------------------------------------------------------------- pwrite64 */
+-#if WSIZE(32)
+-#if !defined(__MUSL_LIBC) && ARCH(Intel)
++#if WSIZE(32) && ARCH(Intel)
++#if !defined(__MUSL_LIBC)
+ // map interposed symbol versions
+ 
+ SYMVER_ATTRIBUTE (__collector_pwrite64_2_2, pwrite64@GLIBC_2.2)
+@@ -2547,8 +2546,9 @@ __collector_pwrite64_2_1 (int fildes, const void *buf, size_t nbyte, off64_t off
+   POP_REENTRANCE (guard);
+   return ret;
+ }
++#endif
+ 
+-#else
++#if !defined(__USE_FILE_OFFSET64)
+ ssize_t
+ pwrite64 (int fildes, const void *buf, size_t nbyte, off64_t offset)
+ {
+@@ -2570,7 +2570,8 @@ pwrite64 (int fildes, const void *buf, size_t nbyte, off64_t offset)
+   return ret;
+ }
+ #endif
+-#endif /* SIZE(32) */
++
++#endif /* SIZE(32)  && ARCH(Intel) */
+ 
+ /*------------------------------------------------------------- fgets */
+ char*
+diff --git a/gprofng/libcollector/mmaptrace.c b/gprofng/libcollector/mmaptrace.c
+index 61613c21560..221b4e2d176 100644
+--- a/gprofng/libcollector/mmaptrace.c
++++ b/gprofng/libcollector/mmaptrace.c
+@@ -1494,7 +1494,7 @@ mmap (void *start, size_t length, int prot, int flags, int fd, off_t offset)
+ }
+ 
+ /*------------------------------------------------------------- mmap64 */
+-#if WSIZE(32)       /* mmap64 only defined for non-64-bit */
++#if WSIZE(32) && !defined(__USE_FILE_OFFSET64)
+ 
+ void *
+ mmap64 (void *start, size_t length, int prot, int flags, int fd, off64_t offset)
+-- 
+2.31.1
+
-- 
2.30.2



^ permalink raw reply related	[flat|nested] 38+ messages in thread

end of thread, other threads:[~2023-05-04  3:37 UTC | newest]

Thread overview: 38+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-04-26  9:50 [PATCH 01/11] binutils: backport a patch to address failures when time64.inc is in use Alexander Kanavin
2023-04-26  9:50 ` [PATCH 02/11] time64.inc: add glibc-testsuite to 'special cases' Alexander Kanavin
2023-04-26  9:50 ` [PATCH 03/11] strace: exclude from x86 (32 bit) ptests Alexander Kanavin
2023-04-26  9:50 ` [PATCH 04/11] lttng-tools: " Alexander Kanavin
2023-04-26  9:50 ` [PATCH 05/11] bitbake.conf: set minimum required kernel to 5.15 Alexander Kanavin
2023-04-27  7:03   ` [OE-core] " Khem Raj
2023-04-27  7:20     ` Alexander Kanavin
2023-04-27  7:30       ` Chen, Qi
2023-04-27  7:31         ` Alexander Kanavin
     [not found]         ` <1759BA367C1A63D1.32698@lists.openembedded.org>
2023-04-27  7:39           ` Alexander Kanavin
2023-04-27  7:48       ` Khem Raj
2023-04-27  7:54         ` Alexander Kanavin
2023-04-29 19:27           ` Khem Raj
2023-04-30  5:42             ` Alexander Kanavin
2023-05-02  8:41             ` Alexander Kanavin
2023-05-02 15:01               ` Khem Raj
2023-05-04  0:36                 ` Khem Raj
2023-05-04  1:14                   ` Khem Raj
2023-05-04  3:37                     ` Khem Raj
2023-04-26  9:50 ` [PATCH 06/11] python3-pytest: add missing tomllib runtime dependency Alexander Kanavin
2023-04-26  9:50 ` [PATCH 07/11] time64.inc: add a comment about how to simulate Y2038 Alexander Kanavin
2023-04-26  9:50 ` [PATCH 08/11] oeqa/sdk/assimp: run only when zlib is in the SDK Alexander Kanavin
2023-04-26  9:50 ` [PATCH 09/11] defaultsetup: Enable largefile and 64bit time_t support systemwide Alexander Kanavin
2023-04-26  9:50 ` [PATCH 10/11] insane.bbclass: simplify exceptions for 32 bit time API check Alexander Kanavin
2023-04-29 19:23   ` [OE-core] " Khem Raj
2023-04-30  4:49     ` Alexander Kanavin
2023-04-30  5:15       ` Khem Raj
2023-04-30  5:34         ` Alexander Kanavin
2023-05-01  0:23           ` Khem Raj
2023-05-01  1:34             ` Alexander Kanavin
     [not found]             ` <175AE10D5735A1BE.29517@lists.openembedded.org>
2023-05-01  8:35               ` Alexander Kanavin
2023-05-01 19:20                 ` Khem Raj
2023-04-26  9:50 ` [PATCH 11/11] insane.bbclass: enable 32 bit time API check on affected architectures Alexander Kanavin
2023-04-26 21:18   ` [OE-core] " Luca Ceresoli
2023-04-27  7:30     ` Alexander Kanavin
2023-04-28  3:20   ` Khem Raj
2023-04-28  7:05     ` Alexander Kanavin
     [not found]     ` <175A0763DEAA3E73.26969@lists.openembedded.org>
2023-04-28  7:57       ` Alexander Kanavin

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