gnat16Packages.{gprbuild{,-boot},gnatcoll-core}: fix build (#523094)
This commit is contained in:
@@ -30,11 +30,11 @@ stdenv.mkDerivation rec {
|
||||
};
|
||||
|
||||
patches = [
|
||||
# Fix compilation with GNAT 12 https://github.com/AdaCore/gnatcoll-core/issues/88
|
||||
# Fix compilation with GNAT 16
|
||||
(fetchpatch2 {
|
||||
name = "gnatcoll-core-gnat-12.patch";
|
||||
url = "https://github.com/AdaCore/gnatcoll-core/commit/515db1c9f1eea8095f2d9ff9570159a78c981ec6.patch";
|
||||
sha256 = "1ghnkhp5fncb7qcmf59kyqvy0sd0pzf1phnr2z7b4ljwlkbmcp36";
|
||||
name = "gnatcoll-core-gnat-16.patch";
|
||||
url = "https://github.com/AdaCore/gnatcoll-core/commit/b266466e0a05b30615ec43d72782c345470455b9.patch?full_index=1";
|
||||
hash = "sha256-rG0D1y2dbXA2M2Arnto+f7iAhg3yCfTPDbDRN+pMJKQ=";
|
||||
})
|
||||
];
|
||||
|
||||
|
||||
@@ -86,6 +86,9 @@ let
|
||||
patches = [
|
||||
# Disable Coq related targets which are missing in the fsf-15 branch
|
||||
./0001-fix-install-fsf-15.patch
|
||||
|
||||
# Suppress warnings on aarch64: https://github.com/AdaCore/spark2014/issues/54
|
||||
./0002-mute-aarch64-warnings.patch
|
||||
];
|
||||
commit_date = "2025-06-10";
|
||||
};
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
stdenv,
|
||||
lib,
|
||||
fetchFromGitHub,
|
||||
fetchpatch2,
|
||||
gnat,
|
||||
which,
|
||||
xmlada, # for src
|
||||
@@ -36,6 +37,20 @@ stdenv.mkDerivation {
|
||||
which
|
||||
];
|
||||
|
||||
# Fix compilation with GNAT 16
|
||||
patches = lib.optionals (lib.versionAtLeast gnat.version "16") [
|
||||
# gpr-compilation-process.adb:44:29: error: operator for type "String" is not declared in "Env_Maps"
|
||||
(fetchpatch2 {
|
||||
url = "https://github.com/AdaCore/gprbuild/commit/6421e350274b3018a26bd058b1c90d033b053f71.patch?full_index=1";
|
||||
hash = "sha256-u9bmr8abmthlyHoeqW5nS2CnaxXmbx6WVwhemxVtw+0=";
|
||||
})
|
||||
# gpr-compilation-protocol.adb:981:13: error: "time_t" is undefined
|
||||
(fetchpatch2 {
|
||||
url = "https://github.com/AdaCore/gprbuild/commit/6b6be939d69d534beb7faca17664d7a1ffa9c81e.patch?full_index=1";
|
||||
hash = "sha256-YUjBvA4bBsrCB46o5WVHOZR6qOf2bkMg+A9qlystDbc=";
|
||||
})
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
# The Makefile uses gprbuild to build gprbuild which
|
||||
# we can't do at this point, delete it to prevent the
|
||||
|
||||
@@ -47,11 +47,13 @@ stdenv.mkDerivation {
|
||||
NIX_LDFLAGS = "-headerpad_max_install_names";
|
||||
};
|
||||
|
||||
# Fixes gprbuild being linked statically always. Based on the AUR's patch:
|
||||
# https://aur.archlinux.org/cgit/aur.git/plain/0001-Makefile-build-relocatable-instead-of-static-binary.patch?h=gprbuild&id=bac524c76cd59c68fb91ef4dfcbe427357b9f850
|
||||
patches = lib.optionals (!stdenv.hostPlatform.isStatic) [
|
||||
./gprbuild-relocatable-build.patch
|
||||
];
|
||||
patches =
|
||||
gprbuild-boot.patches
|
||||
# Fixes gprbuild being linked statically always. Based on the AUR's patch:
|
||||
# https://aur.archlinux.org/cgit/aur.git/plain/0001-Makefile-build-relocatable-instead-of-static-binary.patch?h=gprbuild&id=bac524c76cd59c68fb91ef4dfcbe427357b9f850
|
||||
++ lib.optionals (!stdenv.hostPlatform.isStatic) [
|
||||
./gprbuild-relocatable-build.patch
|
||||
];
|
||||
|
||||
buildFlags = [
|
||||
"all"
|
||||
|
||||
Reference in New Issue
Block a user