Merge pull request #253133 from jiegec/libunwind

libunwind: 1.6.2 -> 1.7.2
This commit is contained in:
Peder Bergebakken Sundt 2024-01-11 20:02:22 +01:00 committed by GitHub
commit 43d0e3ff33
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,22 +1,16 @@
{ stdenv, lib, fetchurl, fetchpatch, autoreconfHook, xz, buildPackages }:
{ stdenv, lib, fetchFromGitHub, fetchpatch, autoreconfHook, xz, buildPackages }:
stdenv.mkDerivation rec {
pname = "libunwind";
version = "1.6.2";
version = "1.7.2";
src = fetchurl {
url = "mirror://savannah/libunwind/${pname}-${version}.tar.gz";
sha256 = "sha256-SmrsZmmR+0XQiJxErt6K1usQgHHDVU/N/2cfnJR5SXY=";
src = fetchFromGitHub {
owner = "libunwind";
repo = "libunwind";
rev = "v${version}";
hash = "sha256-z5YCue0zadQnMEbGFniFvDjXNy6dSHQDQnXRXS6Uh/Y=";
};
patches = [
# Fix for aarch64 and non-4K pages. Remove once upgraded past 1.6.2.
(fetchpatch {
url = "https://github.com/libunwind/libunwind/commit/e85b65cec757ef589f28957d0c6c21c498a03bdf.patch";
sha256 = "1lnlygvhqrdrjgw303pg2k2k4ms4gaghpjsgmhk47q83vy1yjwfg";
})
];
postPatch = if (stdenv.cc.isClang || stdenv.hostPlatform.isStatic) then ''
substituteInPlace configure.ac --replace "-lgcc_s" ""
'' else lib.optionalString stdenv.hostPlatform.isMusl ''
@ -46,7 +40,7 @@ stdenv.mkDerivation rec {
description = "A portable and efficient API to determine the call-chain of a program";
maintainers = with maintainers; [ orivej ];
# https://github.com/libunwind/libunwind#libunwind
platforms = [ "aarch64-linux" "armv5tel-linux" "armv6l-linux" "armv7a-linux" "armv7l-linux" "i686-freebsd13" "i686-linux" "mips64el-linux" "mipsel-linux" "powerpc64-linux" "powerpc64le-linux" "riscv64-linux" "x86_64-freebsd13" "x86_64-linux" "x86_64-solaris" ];
platforms = [ "aarch64-linux" "armv5tel-linux" "armv6l-linux" "armv7a-linux" "armv7l-linux" "i686-freebsd13" "i686-linux" "mips64el-linux" "mipsel-linux" "powerpc64-linux" "powerpc64le-linux" "riscv64-linux" "loongarch64-linux" "x86_64-freebsd13" "x86_64-linux" "x86_64-solaris" ];
license = licenses.mit;
};
}