diff options
author | Nikolay Amiantov <ab@fmap.me> | 2018-03-23 01:18:07 +0300 |
---|---|---|
committer | Nikolay Amiantov <ab@fmap.me> | 2018-03-23 02:37:02 +0300 |
commit | 7a77439b03ba2b0b1967b9f9b9c556719a9a25f4 (patch) | |
tree | afd2130c9849b9015405379aed7bc3c84742c0ec /pkgs/development/libraries/libgpg-error | |
parent | 077dedbf241a3a644cc3d28ff2f7befdb2b0d200 (diff) | |
download | nixlib-7a77439b03ba2b0b1967b9f9b9c556719a9a25f4.tar nixlib-7a77439b03ba2b0b1967b9f9b9c556719a9a25f4.tar.gz nixlib-7a77439b03ba2b0b1967b9f9b9c556719a9a25f4.tar.bz2 nixlib-7a77439b03ba2b0b1967b9f9b9c556719a9a25f4.tar.lz nixlib-7a77439b03ba2b0b1967b9f9b9c556719a9a25f4.tar.xz nixlib-7a77439b03ba2b0b1967b9f9b9c556719a9a25f4.tar.zst nixlib-7a77439b03ba2b0b1967b9f9b9c556719a9a25f4.zip |
libgpg-error: fix on ARM
Diffstat (limited to 'pkgs/development/libraries/libgpg-error')
-rw-r--r-- | pkgs/development/libraries/libgpg-error/default.nix | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/pkgs/development/libraries/libgpg-error/default.nix b/pkgs/development/libraries/libgpg-error/default.nix index c138364ff289..2fcf6701ab8f 100644 --- a/pkgs/development/libraries/libgpg-error/default.nix +++ b/pkgs/development/libraries/libgpg-error/default.nix @@ -1,7 +1,7 @@ -{ stdenv, buildPackages, fetchurl, gettext -, hostPlatform, genPosixLockObjOnly ? false +{ stdenv, lib, fetchpatch, buildPackages, fetchurl, gettext +, genPosixLockObjOnly ? false }: let - genPosixLockObjOnlyAttrs = stdenv.lib.optionalAttrs genPosixLockObjOnly { + genPosixLockObjOnlyAttrs = lib.optionalAttrs genPosixLockObjOnly { buildPhase = '' cd src make gen-posix-lock-obj @@ -24,9 +24,17 @@ in stdenv.mkDerivation (rec { sha256 = "0jfsfnh9bxlxiwxws60yah4ybjw2hshmvqp31pri4m4h8ivrbnry"; }; + patches = [ + # Fix builds on ARM, AArch64 + (fetchpatch { + url = "https://github.com/gpg/libgpg-error/commit/791177de023574223eddf7288eb7c5a0721ac623.patch"; + sha256 = "0vqfw0ak1j37wf6sk9y9vmdyk3kxdxkldhs0bv2waa76s11cmdx0"; + }) + ]; + postPatch = '' sed '/BUILD_TIMESTAMP=/s/=.*/=1970-01-01T00:01+0000/' -i ./configure - '' + stdenv.lib.optionalString stdenv.hostPlatform.isMusl '' + '' + lib.optionalString stdenv.hostPlatform.isMusl '' ln -s lock-obj-pub.x86_64-pc-linux-musl.h src/syscfg/lock-obj-pub.linux-musl.h ''; @@ -39,7 +47,7 @@ in stdenv.mkDerivation (rec { nativeBuildInputs = [ gettext ]; postConfigure = - stdenv.lib.optionalString stdenv.isSunOS + lib.optionalString stdenv.isSunOS # For some reason, /bin/sh on OpenIndiana leads to this at the end of the # `config.status' run: # ./config.status[1401]: shift: (null): bad number |