polyml*: fix build w/glibc-2.34

Failing Hydra build: https://hydra.nixos.org/build/156205993
This commit is contained in:
Maximilian Bosch 2021-10-17 19:04:58 +02:00
parent 0bdcc48485
commit 29e14f8a72
No known key found for this signature in database
GPG key ID: 091DBF4D1FC46B8E
3 changed files with 27 additions and 3 deletions

View file

@ -1,4 +1,4 @@
{lib, stdenv, fetchurl, autoreconfHook}:
{lib, stdenv, fetchurl, autoreconfHook, fetchpatch }:
let
version = "5.6";
@ -12,6 +12,14 @@ stdenv.mkDerivation {
substituteInPlace configure.ac --replace stdc++ c++
'';
patches = [
# glibc 2.34 compat
(fetchpatch {
url = "https://src.fedoraproject.org/rpms/polyml/raw/4d8868ca5a1ce3268f212599a321f8011c950496/f/polyml-pthread-stack-min.patch";
sha256 = "1h5ihg2sxld9ymrl3f2mpnbn2242ka1fsa0h4gl9h90kndvg6kby";
})
];
buildInputs = lib.optional stdenv.isDarwin autoreconfHook;
src = fetchurl {

View file

@ -1,4 +1,4 @@
{ lib, stdenv, fetchFromGitHub, autoreconfHook, gmp, libffi }:
{ lib, stdenv, fetchFromGitHub, autoreconfHook, gmp, libffi, fetchpatch }:
stdenv.mkDerivation rec {
pname = "polyml";
@ -8,7 +8,15 @@ stdenv.mkDerivation rec {
substituteInPlace configure.ac --replace stdc++ c++
'';
patches = [ ./5.7-new-libffi-FFI_SYSV.patch ];
patches = [
./5.7-new-libffi-FFI_SYSV.patch
# glibc 2.34 compat
(fetchpatch {
url = "https://src.fedoraproject.org/rpms/polyml/raw/4d8868ca5a1ce3268f212599a321f8011c950496/f/polyml-pthread-stack-min.patch";
sha256 = "1h5ihg2sxld9ymrl3f2mpnbn2242ka1fsa0h4gl9h90kndvg6kby";
})
];
buildInputs = [ libffi gmp ];

View file

@ -12,6 +12,14 @@ stdenv.mkDerivation rec {
nativeBuildInputs = lib.optional stdenv.isDarwin autoreconfHook;
patches = [
# glibc 2.34 compat
(fetchpatch {
url = "https://src.fedoraproject.org/rpms/polyml/raw/4d8868ca5a1ce3268f212599a321f8011c950496/f/polyml-pthread-stack-min.patch";
sha256 = "1h5ihg2sxld9ymrl3f2mpnbn2242ka1fsa0h4gl9h90kndvg6kby";
})
];
configureFlags = [
"--enable-shared"
"--with-system-libffi"