[Git][ghc/ghc][ghc-9.12] 3 commits: release engineering: update sources to make it work at all
Magnus pushed to branch ghc-9.12 at Glasgow Haskell Compiler / GHC Commits: 347c77f7 by mangoiv at 2026-06-05T10:19:58+02:00 release engineering: update sources to make it work at all - - - - - 6c4f3d68 by mangoiv at 2026-06-05T10:50:42+02:00 release candidate 9.12.5: set release to no - - - - - a0a26f80 by mangoiv at 2026-06-05T11:01:21+02:00 bootstrap plans: move to proper file name - - - - - 7 changed files: - .gitlab/rel_eng/fetch-gitlab-artifacts/fetch_gitlab.py - .gitlab/rel_eng/nix/sources.json - .gitlab/rel_eng/nix/sources.nix - .gitlab/rel_eng/upload.sh - configure.ac - hadrian/bootstrap/plan-9_12_5.json → hadrian/bootstrap/plan-9_12_4.json - hadrian/bootstrap/plan-bootstrap-9_12_5.json → hadrian/bootstrap/plan-bootstrap-9_12_4.json Changes: ===================================== .gitlab/rel_eng/fetch-gitlab-artifacts/fetch_gitlab.py ===================================== @@ -3,6 +3,7 @@ from pathlib import Path import subprocess import gitlab import json +import traceback logging.basicConfig(level=logging.INFO) @@ -154,6 +155,7 @@ def fetch_artifacts(release: str, pipeline_id: int, bindist.replace(dest) except Exception as e: logging.error(f'Error fetching job {job.name}: {e}') + traceback.print_exc() pass def main(): ===================================== .gitlab/rel_eng/nix/sources.json ===================================== @@ -1,44 +1,26 @@ { - "binutils-gdb": { - "branch": "master", - "repo": "https://sourceware.org/git/binutils-gdb.git", - "rev": "49c843e6d2d0577200e7c1d2d02855f21a3a9dde", - "type": "git" - }, - "gdb-walkers": { - "branch": "master", - "description": "Bring mdb walkers to gdb, also add other helpful commands.", - "homepage": "", - "owner": "hardenedapple", - "repo": "gdb-walkers", - "rev": "c0701c4c87852bd09e21ca313c48dd4a649cfd0d", - "sha256": "1sd61a90lg8bkddl8lp15qady1wvbjmhjgm0d3lb813nwimlka9y", - "type": "tarball", - "url": "https://github.com/hardenedapple/gdb-walkers/archive/c0701c4c87852bd09e21ca3...", - "url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz" - }, "niv": { "branch": "master", "description": "Easy dependency management for Nix projects", "homepage": "https://github.com/nmattia/niv", "owner": "nmattia", "repo": "niv", - "rev": "82e5cd1ad3c387863f0545d7591512e76ab0fc41", - "sha256": "090l219mzc0gi33i3psgph6s2pwsc8qy4lyrqjdj4qzkvmaj65a7", + "rev": "e9519949d2b39bc9574b10f6ba216d65f014874e", + "sha256": "1mv379lsy030k2kh7000xwxxz4rzqk416yvmccsgsqnczs06r678", "type": "tarball", - "url": "https://github.com/nmattia/niv/archive/82e5cd1ad3c387863f0545d7591512e76ab0f...", + "url": "https://github.com/nmattia/niv/archive/e9519949d2b39bc9574b10f6ba216d65f0148...", "url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz" }, "nixpkgs": { - "branch": "nixos-22.11", + "branch": "nixos-25.05", "description": "Nix Packages collection", "homepage": "", "owner": "NixOS", "repo": "nixpkgs", - "rev": "2d10e73416ec1449ef74aeac7faf2cf8c556ff5a", - "sha256": "00s89np0sqr3jxxp5h9nrpqy30fy4vsrmis6mmryrrmjqh09lpfv", + "rev": "ac62194c3917d5f474c1a844b6fd6da2db95077d", + "sha256": "0v6bd1xk8a2aal83karlvc853x44dg1n4nk08jg3dajqyy0s98np", "type": "tarball", - "url": "https://github.com/NixOS/nixpkgs/archive/2d10e73416ec1449ef74aeac7faf2cf8c55...", + "url": "https://github.com/NixOS/nixpkgs/archive/ac62194c3917d5f474c1a844b6fd6da2db9...", "url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz" }, "processor-trace": { @@ -47,22 +29,10 @@ "homepage": "", "owner": "01org", "repo": "processor-trace", - "rev": "c848a85c3104e2f5780741f85de5c9e65476ece2", - "sha256": "1ml8g6pm2brlcqp90yvgc780xf64d6k2km7fiqs88wvhlwsl7vzf", - "type": "tarball", - "url": "https://github.com/01org/processor-trace/archive/c848a85c3104e2f5780741f85de...", - "url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz" - }, - "rr": { - "branch": "master", - "description": "Record and Replay Framework", - "homepage": "http://rr-project.org/", - "owner": "rr-debugger", - "repo": "rr", - "rev": "e77b5f8ca4b360daffd31cf72cb6b093fa9e0b62", - "sha256": "sha256:1gxphqcv1yw2ffmjp0d2cv0mpccr00pf9jhf44rq57jqdsvlfn2c", + "rev": "911e654580e373c5a4d7e30bc84169fc3c50a128", + "sha256": "0fak9f7qh8yszb2wyygzp0j0y0wabf0k673vm4j9cl026h2vpx3z", "type": "tarball", - "url": "https://github.com/rr-debugger/rr/archive/3f87444659d1f063397fabc7791ed3b13b...", + "url": "https://github.com/01org/processor-trace/archive/911e654580e373c5a4d7e30bc84...", "url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz" } } ===================================== .gitlab/rel_eng/nix/sources.nix ===================================== @@ -10,33 +10,34 @@ let let name' = sanitizeName name + "-src"; in - if spec.builtin or true then - builtins_fetchurl { inherit (spec) url sha256; name = name'; } - else - pkgs.fetchurl { inherit (spec) url sha256; name = name'; }; + if spec.builtin or true then + builtins_fetchurl { inherit (spec) url sha256; name = name'; } + else + pkgs.fetchurl { inherit (spec) url sha256; name = name'; }; fetch_tarball = pkgs: name: spec: let name' = sanitizeName name + "-src"; in - if spec.builtin or true then - builtins_fetchTarball { name = name'; inherit (spec) url sha256; } - else - pkgs.fetchzip { name = name'; inherit (spec) url sha256; }; + if spec.builtin or true then + builtins_fetchTarball { name = name'; inherit (spec) url sha256; } + else + pkgs.fetchzip { name = name'; inherit (spec) url sha256; }; fetch_git = name: spec: let ref = - if spec ? ref then spec.ref else + spec.ref or ( if spec ? branch then "refs/heads/${spec.branch}" else - if spec ? tag then "refs/tags/${spec.tag}" else - abort "In git source '${name}': Please specify `ref`, `tag` or `branch`!"; - submodules = if spec ? submodules then spec.submodules else false; + if spec ? tag then "refs/tags/${spec.tag}" else + abort "In git source '${name}': Please specify `ref`, `tag` or `branch`!" + ); + submodules = spec.submodules or false; submoduleArg = let nixSupportsSubmodules = builtins.compareVersions builtins.nixVersion "2.4" >= 0; emptyArgWithWarning = - if submodules == true + if submodules then builtins.trace ( @@ -44,15 +45,15 @@ let + "but your nix's (${builtins.nixVersion}) builtins.fetchGit " + "does not support them" ) - {} - else {}; + { } + else { }; in - if nixSupportsSubmodules - then { inherit submodules; } - else emptyArgWithWarning; + if nixSupportsSubmodules + then { inherit submodules; } + else emptyArgWithWarning; in - builtins.fetchGit - ({ url = spec.repo; inherit (spec) rev; inherit ref; } // submoduleArg); + builtins.fetchGit + ({ url = spec.repo; inherit (spec) rev; inherit ref; } // submoduleArg); fetch_local = spec: spec.path; @@ -86,16 +87,16 @@ let hasNixpkgsPath = builtins.any (x: x.prefix == "nixpkgs") builtins.nixPath; hasThisAsNixpkgsPath = <nixpkgs> == ./.; in - if builtins.hasAttr "nixpkgs" sources - then sourcesNixpkgs - else if hasNixpkgsPath && ! hasThisAsNixpkgsPath then - import <nixpkgs> {} - else - abort - '' - Please specify either <nixpkgs> (through -I or NIX_PATH=nixpkgs=...) or - add a package called "nixpkgs" to your sources.json. - ''; + if builtins.hasAttr "nixpkgs" sources + then sourcesNixpkgs + else if hasNixpkgsPath && ! hasThisAsNixpkgsPath then + import <nixpkgs> { } + else + abort + '' + Please specify either <nixpkgs> (through -I or NIX_PATH=nixpkgs=...) or + add a package called "nixpkgs" to your sources.json. + ''; # The actual fetching function. fetch = pkgs: name: spec: @@ -115,13 +116,13 @@ let # the path directly as opposed to the fetched source. replace = name: drv: let - saneName = stringAsChars (c: if isNull (builtins.match "[a-zA-Z0-9]" c) then "_" else c) name; + saneName = stringAsChars (c: if (builtins.match "[a-zA-Z0-9]" c) == null then "_" else c) name; ersatz = builtins.getEnv "NIV_OVERRIDE_${saneName}"; in - if ersatz == "" then drv else - # this turns the string into an actual Nix path (for both absolute and - # relative paths) - if builtins.substring 0 1 ersatz == "/" then /. + ersatz else /. + builtins.getEnv "PWD" + "/${ersatz}"; + if ersatz == "" then drv else + # this turns the string into an actual Nix path (for both absolute and + # relative paths) + if builtins.substring 0 1 ersatz == "/" then /. + ersatz else /. + builtins.getEnv "PWD" + "/${ersatz}"; # Ports of functions for older nix versions @@ -132,7 +133,7 @@ let ); # https://github.com/NixOS/nixpkgs/blob/0258808f5744ca980b9a1f24fe0b1e6f0fecee... - range = first: last: if first > last then [] else builtins.genList (n: first + n) (last - first + 1); + range = first: last: if first > last then [ ] else builtins.genList (n: first + n) (last - first + 1); # https://github.com/NixOS/nixpkgs/blob/0258808f5744ca980b9a1f24fe0b1e6f0fecee... stringToCharacters = s: map (p: builtins.substring p 1 s) (range 0 (builtins.stringLength s - 1)); @@ -143,43 +144,46 @@ let concatStrings = builtins.concatStringsSep ""; # https://github.com/NixOS/nixpkgs/blob/8a9f58a375c401b96da862d969f66429def1d1... - optionalAttrs = cond: as: if cond then as else {}; + optionalAttrs = cond: as: if cond then as else { }; # fetchTarball version that is compatible between all the versions of Nix builtins_fetchTarball = { url, name ? null, sha256 }@attrs: let inherit (builtins) lessThan nixVersion fetchTarball; in - if lessThan nixVersion "1.12" then - fetchTarball ({ inherit url; } // (optionalAttrs (!isNull name) { inherit name; })) - else - fetchTarball attrs; + if lessThan nixVersion "1.12" then + fetchTarball ({ inherit url; } // (optionalAttrs (name != null) { inherit name; })) + else + fetchTarball attrs; # fetchurl version that is compatible between all the versions of Nix builtins_fetchurl = { url, name ? null, sha256 }@attrs: let inherit (builtins) lessThan nixVersion fetchurl; in - if lessThan nixVersion "1.12" then - fetchurl ({ inherit url; } // (optionalAttrs (!isNull name) { inherit name; })) - else - fetchurl attrs; + if lessThan nixVersion "1.12" then + fetchurl ({ inherit url; } // (optionalAttrs (name != null) { inherit name; })) + else + fetchurl attrs; # Create the final "sources" from the config mkSources = config: - mapAttrs ( - name: spec: - if builtins.hasAttr "outPath" spec - then abort - "The values in sources.json should not have an 'outPath' attribute" - else - spec // { outPath = replace name (fetch config.pkgs name spec); } - ) config.sources; + mapAttrs + ( + name: spec: + if builtins.hasAttr "outPath" spec + then + abort + "The values in sources.json should not have an 'outPath' attribute" + else + spec // { outPath = replace name (fetch config.pkgs name spec); } + ) + config.sources; # The "config" used by the fetchers mkConfig = { sourcesFile ? if builtins.pathExists ./sources.json then ./sources.json else null - , sources ? if isNull sourcesFile then {} else builtins.fromJSON (builtins.readFile sourcesFile) + , sources ? if sourcesFile == null then { } else builtins.fromJSON (builtins.readFile sourcesFile) , system ? builtins.currentSystem , pkgs ? mkPkgs sources system }: rec { @@ -191,4 +195,4 @@ let }; in -mkSources (mkConfig {}) // { __functor = _: settings: mkSources (mkConfig settings); } +mkSources (mkConfig { }) // { __functor = _: settings: mkSources (mkConfig settings); } ===================================== .gitlab/rel_eng/upload.sh ===================================== @@ -1,4 +1,4 @@ -#!/usr/bin/bash +#!/usr/bin/env bash #! nix-shell -i bash -p moreutils lzip zip lftp gnupg set -Eeuo pipefail ===================================== configure.ac ===================================== @@ -22,7 +22,7 @@ AC_INIT([The Glorious Glasgow Haskell Compilation System], [9.12.4], [glasgow-ha AC_CONFIG_MACRO_DIRS([m4]) # Set this to YES for a released version, otherwise NO -: ${RELEASE=YES} +: ${RELEASE=NO} # The primary version (e.g. 7.5, 7.4.1) is set in the AC_INIT line # above. If this is not a released version, then we will append the ===================================== hadrian/bootstrap/plan-9_12_5.json → hadrian/bootstrap/plan-9_12_4.json ===================================== ===================================== hadrian/bootstrap/plan-bootstrap-9_12_5.json → hadrian/bootstrap/plan-bootstrap-9_12_4.json ===================================== View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/e76917b659dc5d8cd16d319b066ab62... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/e76917b659dc5d8cd16d319b066ab62... You're receiving this email because of your account on gitlab.haskell.org.
participants (1)
-
Magnus (@MangoIV)