mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2026-05-04 20:06:43 +02:00
main/e2fsprogs: fix build with musl 1.2.4+
ref: https://github.com/tytso/e2fsprogs/pull/144 ref: https://github.com/tytso/e2fsprogs/pull/150
This commit is contained in:
parent
55484e5ebe
commit
d4b111b41c
@ -2,7 +2,7 @@
|
||||
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
|
||||
pkgname=e2fsprogs
|
||||
pkgver=1.47.0
|
||||
pkgrel=4
|
||||
pkgrel=5
|
||||
pkgdesc="Standard Ext2/3/4 filesystem utilities"
|
||||
url="https://e2fsprogs.sourceforge.net/"
|
||||
arch="all"
|
||||
@ -21,7 +21,9 @@ subpackages="
|
||||
$pkgname-libs
|
||||
$pkgname-extra
|
||||
"
|
||||
source="$pkgname-$pkgver.tar.gz::https://github.com/tytso/e2fsprogs/archive/v$pkgver.tar.gz"
|
||||
source="$pkgname-$pkgver.tar.gz::https://github.com/tytso/e2fsprogs/archive/v$pkgver.tar.gz
|
||||
lfs64.patch
|
||||
"
|
||||
|
||||
case $CHOST in
|
||||
riscv64*)
|
||||
@ -119,4 +121,5 @@ extra() {
|
||||
|
||||
sha512sums="
|
||||
9cb895f7deed8ee513595b7c232db8345cb7e54e6cbb33e6eeab31c860c892cbc9d721756ac1429e6731e219e1c6aacc25075d517e979397c66bf764bc8bc9fa e2fsprogs-1.47.0.tar.gz
|
||||
9b97f91529844ad04a613d61ef762951859640d2677b4e37648ecc7cfbfc0b4831e8f3e49ad952fc16267d53e6e7c6cf588350a3e36edc2e22779f43d9ef17cf lfs64.patch
|
||||
"
|
||||
|
||||
42
main/e2fsprogs/lfs64.patch
Normal file
42
main/e2fsprogs/lfs64.patch
Normal file
@ -0,0 +1,42 @@
|
||||
From 92f8226c3cf7d84a4937766420a411e68771dfc2 Mon Sep 17 00:00:00 2001
|
||||
From: Mike Cui <cuicui@gmail.com>
|
||||
Date: Sun, 7 May 2023 02:46:47 -0700
|
||||
Subject: [PATCH] ext2fs: Use 64-bit lseek when SIZEOF_OFF_T is 64bits
|
||||
|
||||
musl-1.2.4 no longer defines lseek64, and since off_t is always 64-bits,
|
||||
autoconf decides to not pass in -D_FILE_OFFSET_BITS=64 when compiling,
|
||||
and this results in a compilation failure.
|
||||
|
||||
Instead of checking _FILE_OFFSET_BITS=64, let's just check if
|
||||
SIZEOF_OFF_T is SIZEOF_LONG_LONG. Also, SIZEOF_LONG is irrelevant.
|
||||
---
|
||||
lib/blkid/llseek.c | 2 +-
|
||||
lib/ext2fs/llseek.c | 2 +-
|
||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/lib/blkid/llseek.c b/lib/blkid/llseek.c
|
||||
index 59298646f..f24e40b1f 100644
|
||||
--- a/lib/blkid/llseek.c
|
||||
+++ b/lib/blkid/llseek.c
|
||||
@@ -50,7 +50,7 @@ extern long long llseek(int fd, long long offset, int origin);
|
||||
|
||||
#else /* ! HAVE_LLSEEK */
|
||||
|
||||
-#if SIZEOF_LONG == SIZEOF_LONG_LONG
|
||||
+#if SIZEOF_OFF_T == SIZEOF_LONG_LONG
|
||||
|
||||
#define llseek lseek
|
||||
|
||||
diff --git a/lib/ext2fs/llseek.c b/lib/ext2fs/llseek.c
|
||||
index 45f21d09d..713312aa8 100644
|
||||
--- a/lib/ext2fs/llseek.c
|
||||
+++ b/lib/ext2fs/llseek.c
|
||||
@@ -51,7 +51,7 @@ extern long long llseek (int fd, long long offset, int origin);
|
||||
|
||||
#else /* ! HAVE_LLSEEK */
|
||||
|
||||
-#if SIZEOF_LONG == SIZEOF_LONG_LONG || _FILE_OFFSET_BITS+0 == 64
|
||||
+#if SIZEOF_OFF_T == SIZEOF_LONG_LONG
|
||||
|
||||
#define my_llseek lseek
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user