Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • ghc/ghc
  • bgamari/ghc
  • syd/ghc
  • ggreif/ghc
  • watashi/ghc
  • RolandSenn/ghc
  • mpickering/ghc
  • DavidEichmann/ghc
  • carter/ghc
  • harpocrates/ghc
  • ethercrow/ghc
  • mijicd/ghc
  • adamse/ghc
  • alexbiehl/ghc
  • gridaphobe/ghc
  • trofi/ghc
  • supersven/ghc
  • ppk/ghc
  • ulysses4ever/ghc
  • AndreasK/ghc
  • ghuntley/ghc
  • shayne-fletcher-da/ghc
  • fgaz/ghc
  • yav/ghc
  • osa1/ghc
  • mbbx6spp/ghc
  • JulianLeviston/ghc
  • reactormonk/ghc
  • rae/ghc
  • takenobu-hs/ghc
  • michalt/ghc
  • andrewthad/ghc
  • hsyl20/ghc
  • scottgw/ghc
  • sjakobi/ghc
  • angerman/ghc
  • RyanGlScott/ghc
  • hvr/ghc
  • howtonotwin/ghc
  • chessai/ghc
  • m-renaud/ghc
  • brprice/ghc
  • stevehartdata/ghc
  • sighingnow/ghc
  • kgardas/ghc
  • ckoparkar/ghc
  • alp/ghc
  • smaeul/ghc
  • kakkun61/ghc
  • sykloid/ghc
  • newhoggy/ghc
  • toonn/ghc
  • nineonine/ghc
  • Phyx/ghc
  • ezyang/ghc
  • tweag/ghc
  • langston/ghc
  • ndmitchell/ghc
  • rockbmb/ghc
  • artempyanykh/ghc
  • mniip/ghc
  • mynguyenbmc/ghc
  • alexfmpe/ghc
  • crockeea/ghc
  • nh2/ghc
  • vaibhavsagar/ghc
  • phadej/ghc
  • Haskell-mouse/ghc
  • lolotp/ghc
  • spacekitteh/ghc
  • michaelpj/ghc
  • mgsloan/ghc
  • HPCohen/ghc
  • tmobile/ghc
  • radrow/ghc
  • simonmar/ghc
  • _deepfire/ghc
  • Ericson2314/ghc
  • leitao/ghc
  • fumieval/ghc
  • trac-isovector/ghc
  • cblp/ghc
  • xich/ghc
  • ciil/ghc
  • erthalion/ghc
  • xldenis/ghc
  • autotaker/ghc
  • haskell-wasm/ghc
  • kcsongor/ghc
  • agander/ghc
  • Baranowski/ghc
  • trac-dredozubov/ghc
  • 23Skidoo/ghc
  • iustin/ghc
  • ningning/ghc
  • josefs/ghc
  • kabuhr/ghc
  • gallais/ghc
  • dten/ghc
  • expipiplus1/ghc
  • Pluralia/ghc
  • rohanjr/ghc
  • intricate/ghc
  • kirelagin/ghc
  • Javran/ghc
  • DanielG/ghc
  • trac-mizunashi_mana/ghc
  • pparkkin/ghc
  • bollu/ghc
  • ntc2/ghc
  • jaspervdj/ghc
  • JoshMeredith/ghc
  • wz1000/ghc
  • zkourouma/ghc
  • code5hot/ghc
  • jdprice/ghc
  • tdammers/ghc
  • J-mie6/ghc
  • trac-lantti/ghc
  • ch1bo/ghc
  • cgohla/ghc
  • lucamolteni/ghc
  • acairncross/ghc
  • amerocu/ghc
  • chreekat/ghc
  • txsmith/ghc
  • trupill/ghc
  • typetetris/ghc
  • sergv/ghc
  • fryguybob/ghc
  • erikd/ghc
  • trac-roland/ghc
  • setupminimal/ghc
  • Friede80/ghc
  • SkyWriter/ghc
  • xplorld/ghc
  • abrar/ghc
  • obsidiansystems/ghc
  • Icelandjack/ghc
  • adinapoli/ghc
  • trac-matthewbauer/ghc
  • heatsink/ghc
  • dwijnand/ghc
  • Cmdv/ghc
  • alinab/ghc
  • pepeiborra/ghc
  • fommil/ghc
  • luochen1990/ghc
  • rlupton20/ghc
  • applePrincess/ghc
  • lehins/ghc
  • ronmrdechai/ghc
  • leeadam/ghc
  • harendra/ghc
  • mightymosquito1991/ghc
  • trac-gershomb/ghc
  • lucajulian/ghc
  • Rizary/ghc
  • VictorCMiraldo/ghc
  • jamesbrock/ghc
  • andrewdmeier/ghc
  • luke/ghc
  • pranaysashank/ghc
  • cocreature/ghc
  • hithroc/ghc
  • obreitwi/ghc
  • slrtbtfs/ghc
  • kaol/ghc
  • yairchu/ghc
  • Mathemagician98/ghc
  • trac-taylorfausak/ghc
  • leungbk/ghc
  • MichaWiedenmann/ghc
  • chris-martin/ghc
  • TDecki/ghc
  • adithyaov/ghc
  • trac-gelisam/ghc
  • Lysxia/ghc
  • complyue/ghc
  • bwignall/ghc
  • sternmull/ghc
  • sonika/ghc
  • leif/ghc
  • broadwaylamb/ghc
  • myszon/ghc
  • danbroooks/ghc
  • Mechachleopteryx/ghc
  • zardyh/ghc
  • trac-vdukhovni/ghc
  • OmarKhaledAbdo/ghc
  • arrowd/ghc
  • Bodigrim/ghc
  • matheus23/ghc
  • cardenaso11/ghc
  • trac-Athas/ghc
  • mb720/ghc
  • DylanZA/ghc
  • liff/ghc
  • typedrat/ghc
  • trac-claude/ghc
  • jbm/ghc
  • Gertjan423/ghc
  • PHO/ghc
  • JKTKops/ghc
  • kockahonza/ghc
  • msakai/ghc
  • Sir4ur0n/ghc
  • barambani/ghc
  • vishnu.c/ghc
  • dcoutts/ghc
  • trac-runeks/ghc
  • trac-MaxGabriel/ghc
  • lexi.lambda/ghc
  • strake/ghc
  • spavikevik/ghc
  • JakobBruenker/ghc
  • rmanne/ghc
  • gdziadkiewicz/ghc
  • ani/ghc
  • iliastsi/ghc
  • smunix/ghc
  • judah/ghc
  • blackgnezdo/ghc
  • emilypi/ghc
  • trac-bpfoley/ghc
  • muesli4/ghc
  • trac-gkaracha/ghc
  • Kleidukos/ghc
  • nek0/ghc
  • TristanCacqueray/ghc
  • dwulive/ghc
  • mbakke/ghc
  • arybczak/ghc
  • Yang123321/ghc
  • maksbotan/ghc
  • QuietMisdreavus/ghc
  • trac-olshanskydr/ghc
  • emekoi/ghc
  • samuela/ghc
  • josephcsible/ghc
  • dramforever/ghc
  • lpsmith/ghc
  • DenisFrezzato/ghc
  • michivi/ghc
  • jneira/ghc
  • jeffhappily/ghc
  • Ivan-Yudin/ghc
  • nakaji-dayo/ghc
  • gdevanla/ghc
  • galen/ghc
  • fendor/ghc
  • yaitskov/ghc
  • rcythr/ghc
  • awpr/ghc
  • jeremyschlatter/ghc
  • Aver1y/ghc
  • mitchellvitez/ghc
  • merijn/ghc
  • tomjaguarpaw1/ghc
  • trac-NoidedSuper/ghc
  • erewok/ghc
  • trac-junji.hashimoto/ghc
  • adamwespiser/ghc
  • bjaress/ghc
  • jhrcek/ghc
  • leonschoorl/ghc
  • lukasz-golebiewski/ghc
  • sheaf/ghc
  • last-g/ghc
  • carassius1014/ghc
  • eschwartz/ghc
  • dwincort/ghc
  • felixwiemuth/ghc
  • TimWSpence/ghc
  • marcusmonteirodesouza/ghc
  • WJWH/ghc
  • vtols/ghc
  • theobat/ghc
  • BinderDavid/ghc
  • ckoparkar0/ghc
  • alexander-kjeldaas/ghc
  • dme2/ghc
  • philderbeast/ghc
  • aaronallen8455/ghc
  • rayshih/ghc
  • benkard/ghc
  • mpardalos/ghc
  • saidelman/ghc
  • leiftw/ghc
  • ca333/ghc
  • bwroga/ghc
  • nmichael44/ghc
  • trac-crobbins/ghc
  • felixonmars/ghc
  • adityagupta1089/ghc
  • hgsipiere/ghc
  • treeowl/ghc
  • alexpeits/ghc
  • CraigFe/ghc
  • dnlkrgr/ghc
  • kerckhove_ts/ghc
  • cptwunderlich/ghc
  • eiais/ghc
  • hahohihu/ghc
  • sanchayan/ghc
  • lemmih/ghc
  • sehqlr/ghc
  • trac-dbeacham/ghc
  • luite/ghc
  • trac-f-a/ghc
  • vados/ghc
  • luntain/ghc
  • fatho/ghc
  • alexbiehl-gc/ghc
  • dcbdan/ghc
  • tvh/ghc
  • liam-ly/ghc
  • timbobbarnes/ghc
  • GovanifY/ghc
  • shanth2600/ghc
  • gliboc/ghc
  • duog/ghc
  • moxonsghost/ghc
  • zander/ghc
  • masaeedu/ghc
  • georgefst/ghc
  • guibou/ghc
  • nicuveo/ghc
  • mdebruijne/ghc
  • stjordanis/ghc
  • emiflake/ghc
  • wygulmage/ghc
  • frasertweedale/ghc
  • coot/ghc
  • aratamizuki/ghc
  • tsandstr/ghc
  • mrBliss/ghc
  • Anton-Latukha/ghc
  • tadfisher/ghc
  • vapourismo/ghc
  • Sorokin-Anton/ghc
  • basile-henry/ghc
  • trac-mightybyte/ghc
  • AbsoluteNikola/ghc
  • cobrien99/ghc
  • songzh/ghc
  • blamario/ghc
  • aj4ayushjain/ghc
  • trac-utdemir/ghc
  • tangcl/ghc
  • hdgarrood/ghc
  • maerwald/ghc
  • arjun/ghc
  • ratherforky/ghc
  • haskieLambda/ghc
  • EmilGedda/ghc
  • Bogicevic/ghc
  • eddiejessup/ghc
  • kozross/ghc
  • AlistairB/ghc
  • 3Rafal/ghc
  • christiaanb/ghc
  • trac-bit/ghc
  • matsumonkie/ghc
  • trac-parsonsmatt/ghc
  • chisui/ghc
  • jaro/ghc
  • trac-kmiyazato/ghc
  • davidsd/ghc
  • Tritlo/ghc
  • I-B-3/ghc
  • lykahb/ghc
  • AriFordsham/ghc
  • turion1/ghc
  • berberman/ghc
  • christiantakle/ghc
  • zyklotomic/ghc
  • trac-ocramz/ghc
  • CSEdd/ghc
  • doyougnu/ghc
  • mmhat/ghc
  • why-not-try-calmer/ghc
  • plutotulp/ghc
  • kjekac/ghc
  • Manvi07/ghc
  • teo/ghc
  • cactus/ghc
  • CarrieMY/ghc
  • abel/ghc
  • yihming/ghc
  • tsakki/ghc
  • jessicah/ghc
  • oliverbunting/ghc
  • meld/ghc
  • friedbrice/ghc
  • Joald/ghc
  • abarbu/ghc
  • DigitalBrains1/ghc
  • sterni/ghc
  • alexDarcy/ghc
  • hexchain/ghc
  • minimario/ghc
  • zliu41/ghc
  • tommd/ghc
  • jazcarate/ghc
  • peterbecich/ghc
  • alirezaghey/ghc
  • solomon/ghc
  • mikael.urankar/ghc
  • davjam/ghc
  • int-index/ghc
  • MorrowM/ghc
  • nrnrnr/ghc
  • Sonfamm/ghc-test-only
  • afzt1/ghc
  • nguyenhaibinh-tpc/ghc
  • trac-lierdakil/ghc
  • MichaWiedenmann1/ghc
  • jmorag/ghc
  • Ziharrk/ghc
  • trac-MitchellSalad/ghc
  • juampe/ghc
  • jwaldmann/ghc
  • snowleopard/ghc
  • juhp/ghc
  • normalcoder/ghc
  • ksqsf/ghc
  • trac-jberryman/ghc
  • roberth/ghc
  • 1ntEgr8/ghc
  • epworth/ghc
  • MrAdityaAlok/ghc
  • JunmingZhao42/ghc
  • jappeace/ghc
  • trac-Gabriel439/ghc
  • alt-romes/ghc
  • HugoPeters1024/ghc
  • 10ne1/ghc-fork
  • agentultra/ghc
  • Garfield1002/ghc
  • ChickenProp/ghc
  • clyring/ghc
  • MaxHearnden/ghc
  • jumper149/ghc
  • vem/ghc
  • ketzacoatl/ghc
  • Rosuavio/ghc
  • jackohughes/ghc
  • p4l1ly/ghc
  • konsumlamm/ghc
  • shlevy/ghc
  • torsten.schmits/ghc
  • andremarianiello/ghc
  • amesgen/ghc
  • googleson78/ghc
  • InfiniteVerma/ghc
  • uhbif19/ghc
  • yiyunliu/ghc
  • raehik/ghc
  • mrkun/ghc
  • telser/ghc
  • 1Jajen1/ghc
  • slotThe/ghc
  • WinstonHartnett/ghc
  • mpilgrem/ghc
  • dreamsmasher/ghc
  • schuelermine/ghc
  • trac-Viwor/ghc
  • undergroundquizscene/ghc
  • evertedsphere/ghc
  • coltenwebb/ghc
  • oberblastmeister/ghc
  • agrue/ghc
  • lf-/ghc
  • zacwood9/ghc
  • steshaw/ghc
  • high-cloud/ghc
  • SkamDart/ghc
  • PiDelport/ghc
  • maoif/ghc
  • RossPaterson/ghc
  • CharlesTaylor7/ghc
  • ribosomerocker/ghc
  • trac-ramirez7/ghc
  • daig/ghc
  • NicolasT/ghc
  • FinleyMcIlwaine/ghc
  • lawtonnichols/ghc
  • jmtd/ghc
  • ozkutuk/ghc
  • wildsebastian/ghc
  • nikshalark/ghc
  • lrzlin/ghc
  • tobias/ghc
  • fw/ghc
  • hawkinsw/ghc
  • type-dance/ghc
  • rui314/ghc
  • ocharles/ghc
  • wavewave/ghc
  • TheKK/ghc
  • nomeata/ghc
  • trac-csabahruska/ghc
  • jonathanjameswatson/ghc
  • L-as/ghc
  • Axman6/ghc
  • barracuda156/ghc
  • trac-jship/ghc
  • jake-87/ghc
  • meooow/ghc
  • rebeccat/ghc
  • hamana55/ghc
  • Enigmage/ghc
  • kokobd/ghc
  • agevelt/ghc
  • gshen42/ghc
  • chrismwendt/ghc
  • MangoIV/ghc
  • teto/ghc
  • Sookr1/ghc
  • trac-thomasjm/ghc
  • barci2/ghc-dev
  • trac-m4dc4p/ghc
  • dixonary/ghc
  • breakerzirconia/ghc
  • alexsio27444/ghc
  • glocq/ghc
  • sourabhxyz/ghc
  • ryantrinkle/ghc
  • Jade/ghc
  • scedfaliako/ghc
  • martijnbastiaan/ghc
  • trac-george.colpitts/ghc
  • ammarbinfaisal/ghc
  • mimi.vx/ghc
  • lortabac/ghc
  • trac-zyla/ghc
  • benbellick/ghc
  • aadaa-fgtaa/ghc
  • jvanbruegge/ghc
  • archbung/ghc
  • gilmi/ghc
  • mfonism/ghc
  • alex-mckenna/ghc
  • Ei30metry/ghc
  • DiegoDiverio/ghc
  • jorgecunhamendes/ghc
  • liesnikov/ghc
  • akrmn/ghc
  • trac-simplifierticks/ghc
  • jacco/ghc
  • rhendric/ghc
  • damhiya/ghc
  • ryndubei/ghc
  • DaveBarton/ghc
  • trac-Profpatsch/ghc
  • GZGavinZhao/ghc
  • ncfavier/ghc
  • jameshaydon/ghc
  • ajccosta/ghc
  • dschrempf/ghc
  • cydparser/ghc
  • LinuxUserGD/ghc
  • elodielander/ghc
  • facundominguez/ghc
  • psilospore/ghc
  • lachrimae/ghc
  • dylan-thinnes/ghc-type-errors-plugin
  • hamishmack/ghc
  • Leary/ghc
  • lzszt/ghc
  • lyokha/ghc
  • trac-glaubitz/ghc
  • Rewbert/ghc
  • andreabedini/ghc
  • Jasagredo/ghc
  • sol/ghc
  • OlegAlexander/ghc
  • trac-sthibaul/ghc
  • avdv/ghc
  • Wendaolee/ghc
  • ur4t/ghc
  • daylily/ghc
  • boltzmannrain/ghc
  • mmzk1526/ghc
  • trac-fizzixnerd/ghc
  • soulomoon/ghc
  • rwmjones/ghc
  • j14i/ghc
  • tracsis/ghc
  • gesh/ghc
  • flip101/ghc
  • eldritch-cookie/ghc
  • LemonjamesD/ghc
  • pgujjula/ghc
  • skeuchel/ghc
  • noteed/ghc
  • gulin.serge/ghc
  • Torrekie/ghc
  • jlwoodwa/ghc
  • ayanamists/ghc
  • husong998/ghc
  • trac-edmundnoble/ghc
  • josephf/ghc
  • contrun/ghc
  • baulig/ghc
  • edsko/ghc
  • mzschr/ghc-issue-24732
  • ulidtko/ghc
  • Arsen/ghc
  • trac-sjoerd_visscher/ghc
  • crumbtoo/ghc
  • L0neGamer/ghc
  • DrewFenwick/ghc
  • benz0li/ghc
  • MaciejWas/ghc
  • jordanrule/ghc
  • trac-qqwy/ghc
  • LiamGoodacre/ghc
  • isomorpheme/ghc
  • trac-danidiaz/ghc
  • Kariim/ghc
  • MTaimoorZaeem/ghc
  • hololeap/ghc
  • ticat-fp/ghc
  • meritamen/ghc
  • criskell/ghc
  • trac-kraai/ghc
  • aergus/ghc
  • jdral/ghc
  • SamB/ghc
  • Tristian/ghc
  • ywgrit/ghc
  • KatsuPatrick/ghc
  • OsePedro/ghc
  • mpscholten/ghc
  • fp/ghc
  • zaquest/ghc
  • fangyi-zhou/ghc
  • augyg/ghc
640 results
Show changes
Commits on Source (5342)
Showing
with 3766 additions and 1440 deletions
--command sh -c "HADRIAN_ARGS=-j ./hadrian/ghci -j"
--command sh -c "HADRIAN_ARGS=-j exec ./hadrian/ghci-multi -j"
--reload compiler
--reload ghc
--reload includes
--restart hadrian/ghci
--restart hadrian/ghci-multi
5eecb20a0368b599d03930e2dbb0e91540de4cb2
......@@ -2,3 +2,4 @@
# don't convert anything on checkout
* text=auto eol=lf
mk/win32-tarballs.md5sum text=auto eol=LF
testsuite/tests/parser/should_run/T25375.hs text=auto eol=crlf
......@@ -35,6 +35,7 @@ Thumbs.db
__pycache__
.mypy_cache
*.SYMDEF*
a.out
log
tags
......@@ -62,6 +63,7 @@ _*
.hadrian_ghci
.hadrian_ghci_multi/
.hie-bios
hadrian/bootstrap/jq-bin
# -----------------------------------------------------------------------------
# Ignore any overlapped darcs repos and back up files
......@@ -166,8 +168,12 @@ _darcs/
/libraries/ghc-boot/ghc-boot.cabal
/libraries/ghc-boot-th/GNUmakefile
/libraries/ghc-boot-th/ghc-boot-th.cabal
/libraries/ghc-boot-th-next/ghc-boot-th-next.cabal
/libraries/ghc-boot-th/ghc.mk
/libraries/ghc-heap/ghc-heap.cabal
/libraries/ghc-internal/ghc-internal.cabal
/libraries/ghc-experimental/ghc-experimental.cabal
/libraries/base/base.cabal
/libraries/ghci/GNUmakefile
/libraries/ghci/ghci.cabal
/libraries/ghci/ghc.mk
......
......@@ -2,7 +2,7 @@ variables:
GIT_SSL_NO_VERIFY: "1"
# Commit of ghc/ci-images repository from which to pull Docker images
DOCKER_REV: a9297a370025101b479cfd4977f8f910814e03ab
DOCKER_REV: 94df7d589f0ded990826bc7a4d7f5a40d6055a4f
# Sequential version number of all cached things.
# Bump to invalidate GitLab CI cache.
......@@ -22,6 +22,9 @@ variables:
GIT_SUBMODULE_STRATEGY: "normal"
# GitLab recommends using https:, not ssh:, to clone submodules. See #25528.
GIT_SUBMODULE_FORCE_HTTPS: 1
# Makes ci.sh isolate CABAL_DIR
HERMETIC: "YES"
......@@ -101,10 +104,10 @@ workflow:
# which versions of GHC to allow bootstrap with
.bootstrap_matrix : &bootstrap_matrix
matrix:
- GHC_VERSION: 9.6.4
DOCKER_IMAGE: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10-ghc9_6:$DOCKER_REV"
- GHC_VERSION: 9.8.1
DOCKER_IMAGE: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10-ghc9_8:$DOCKER_REV"
DOCKER_IMAGE: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb12-ghc9_8:$DOCKER_REV"
- GHC_VERSION: 9.10.1
DOCKER_IMAGE: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb12-ghc9_10:$DOCKER_REV"
# Allow linters to fail on draft MRs.
# This must be explicitly transcluded in lint jobs which
......@@ -216,7 +219,7 @@ include: '.gitlab/jobs.yaml'
ghc-linters:
stage: tool-lint
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10:$DOCKER_REV"
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb12:$DOCKER_REV"
extends: .lint-params
variables:
BUILD_FLAVOUR: default
......@@ -256,7 +259,7 @@ typecheck-testsuite:
# accommodate, e.g., haddock changes not yet upstream) but not on `master` or
# Marge jobs.
.lint-submods:
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10:$DOCKER_REV"
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb12:$DOCKER_REV"
extends: .lint-params
variables:
BUILD_FLAVOUR: default
......@@ -274,7 +277,7 @@ typecheck-testsuite:
# accommodate, e.g., haddock changes not yet upstream) but not on `master` or
# Marge jobs.
lint-author:
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10:$DOCKER_REV"
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb12:$DOCKER_REV"
extends: .lint-params
variables:
BUILD_FLAVOUR: default
......@@ -289,7 +292,7 @@ lint-author:
- *drafts-can-fail-lint
lint-ci-config:
image: nixos/nix:2.14.1
image: nixos/nix:2.25.2
extends: .lint
# We don't need history/submodules in this job
variables:
......@@ -297,6 +300,18 @@ lint-ci-config:
GIT_SUBMODULE_STRATEGY: none
before_script:
- echo "experimental-features = nix-command flakes" >> /etc/nix/nix.conf
# Note [Nix-in-Docker]
# ~~~~~~~~~~~~~~~~~~~~
# The nixos/nix default config is max-jobs=1 and cores=$(logical
# cores num) which doesn't play nice with our $CPUS convention. We
# fix it before invoking any nix build to avoid oversubscribing
# while allowing a reasonable degree of parallelism.
# FIXME: Disabling build-users-group=nixbld is a workaround for a Nix-in-Docker issue. See
# https://gitlab.haskell.org/ghc/head.hackage/-/issues/38#note_560487 for
# discussion.
- echo "cores = $CPUS" >> /etc/nix/nix.conf
- echo "max-jobs = $CPUS" >> /etc/nix/nix.conf
- nix run nixpkgs#gnused -- -i -e 's/ nixbld//' /etc/nix/nix.conf
script:
- nix run .gitlab/generate-ci#generate-jobs
# 1 if .gitlab/generate_jobs changed the output of the generated config
......@@ -343,7 +358,7 @@ lint-submods-branch:
.lint-params:
needs: []
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10:$DOCKER_REV"
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb12:$DOCKER_REV"
extends: .lint
before_script:
- export PATH="/opt/toolchain/bin:$PATH"
......@@ -384,7 +399,7 @@ hadrian-ghc-in-ghci:
- job: lint-linters
- job: lint-submods
optional: true
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10:$DOCKER_REV"
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb12:$DOCKER_REV"
before_script:
# workaround for docker permissions
- sudo chown ghc:ghc -R .
......@@ -394,8 +409,8 @@ hadrian-ghc-in-ghci:
- x86_64-linux
script:
- git clean -xdf && git submodule foreach git clean -xdf
- .gitlab/ci.sh setup
- .gitlab/ci.sh configure
- . .gitlab/ci.sh setup
- . .gitlab/ci.sh configure
# Enable -Werror when building hadrian
- "echo 'package hadrian' > hadrian/cabal.project.local"
- "echo ' ghc-options: -Werror' >> hadrian/cabal.project.local"
......@@ -429,7 +444,12 @@ hadrian-multi:
# workaround for docker permissions
- sudo chown ghc:ghc -R .
variables:
GHC_FLAGS: "-Werror -Wwarn=deprecations"
GHC_FLAGS: "-Werror=-Wno-error=incomplete-record-selectors -Wwarn=deprecations -Wwarn=unused-imports"
# -Wno-error=incomplete-record-selectors is present because -Wall now
# includes -Wincomplete-record-selectors, and hadrian-multi has many, many
# warnings about incomplete record selectors. A better fix would be to
# remove the use of incomplete record selectors, since each of them represents
# a potential crash.
CONFIGURE_ARGS: --enable-bootstrap-with-devel-snapshot
tags:
- x86_64-linux
......@@ -448,8 +468,8 @@ hadrian-multi:
- export HC=$root/bin/ghc
# This GHC means, use this GHC to configure with
- export GHC=$root/bin/ghc
- .gitlab/ci.sh setup
- .gitlab/ci.sh configure
- . .gitlab/ci.sh setup
- . .gitlab/ci.sh configure
# Now GHC means, use this GHC for hadrian
- export GHC=$BOOT_HC
- export CORES="$(mk/detect-cpu-count.sh)"
......@@ -475,29 +495,24 @@ stack-hadrian-build:
extends: hadrian-ghc-in-ghci
stage: quick-build
script:
- .gitlab/ci.sh setup
- .gitlab/ci.sh configure
- . .gitlab/ci.sh setup
- . .gitlab/ci.sh configure
- hadrian/build-stack --version
####################################
# Testing reinstallable ghc codepath
####################################
# As documented on the original ticket #19896, this feature already has a long
# way to go before it can actually be used. Meanwhile, parts of it have
# bit-rotted, possibly related to some Cabal change. The job is disabled for
# now.
#
# test-cabal-reinstall-x86_64-linux-deb10:
# extends: nightly-x86_64-linux-deb10-validate
# stage: full-build
# variables:
# REINSTALL_GHC: "yes"
# BUILD_FLAVOUR: validate
# TEST_ENV: "x86_64-linux-deb10-cabal-install"
# rules:
# - if: $NIGHTLY
# - if: '$CI_MERGE_REQUEST_LABELS =~ /.*test-reinstall.*/'
test-cabal-reinstall-x86_64-linux-deb10:
extends: nightly-x86_64-linux-deb10-validate
stage: full-build
variables:
REINSTALL_GHC: "yes"
BUILD_FLAVOUR: validate
TEST_ENV: "x86_64-linux-deb10-cabal-install"
rules:
- if: $NIGHTLY
- if: '$CI_MERGE_REQUEST_LABELS =~ /.*test-reinstall.*/'
########################################
# Testing ABI is invariant across builds
......@@ -535,11 +550,11 @@ abi-test-nightly:
doc-tarball:
stage: packaging
needs:
- job: x86_64-linux-deb10-numa-slow-validate
- job: x86_64-linux-deb12-numa-slow-validate
optional: true
- job: nightly-x86_64-linux-deb10-validate
- job: nightly-x86_64-linux-deb12-validate
optional: true
- job: release-x86_64-linux-deb10-release
- job: release-x86_64-linux-deb12-release
optional: true
- job: x86_64-windows-validate
......@@ -551,23 +566,28 @@ doc-tarball:
tags:
- x86_64-linux
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10:$DOCKER_REV"
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb12:$DOCKER_REV"
dependencies: null
variables:
LINUX_BINDIST: "ghc-x86_64-linux-deb10.tar.xz"
LINUX_BINDIST: "ghc-x86_64-linux-deb12.tar.xz"
WINDOWS_BINDIST: "ghc-x86_64-windows.tar.xz"
artifacts:
expose_as: "Documentation Preview"
paths:
- haddock.html.tar.xz
- docs/haddock/
- libraries.html.tar.xz
- docs/libraries/
- users_guide.html.tar.xz
- index.html
- "*.pdf"
- docs/users_guide/
- docs/index.html
- Haddock.pdf
- users_guide.pdf
script:
- |
mv "ghc-x86_64-linux-deb10-numa-slow-validate.tar.xz" "$LINUX_BINDIST" \
|| mv "ghc-x86_64-linux-deb10-validate.tar.xz" "$LINUX_BINDIST" \
|| mv "ghc-x86_64-linux-deb10-release.tar.xz" "$LINUX_BINDIST" \
mv "ghc-x86_64-linux-deb12-numa-slow-validate.tar.xz" "$LINUX_BINDIST" \
|| mv "ghc-x86_64-linux-deb12-validate.tar.xz" "$LINUX_BINDIST" \
|| mv "ghc-x86_64-linux-deb12-release.tar.xz" "$LINUX_BINDIST" \
|| true
mv "ghc-x86_64-windows-validate.tar.xz" "$WINDOWS_BINDIST" \
|| mv "ghc-x86_64-windows-release.tar.xz" "$WINDOWS_BINDIST" \
......@@ -582,8 +602,8 @@ doc-tarball:
fi
- rm -Rf docs
- bash -ex distrib/mkDocs/mkDocs $LINUX_BINDIST $WINDOWS_BINDIST
- mv docs/*.tar.xz docs/*.pdf .
- ls -lh
- mv docs/*.tar.xz docs/index.html .
hackage-doc-tarball:
stage: packaging
......@@ -595,7 +615,7 @@ hackage-doc-tarball:
- job: source-tarball
tags:
- x86_64-linux
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10:$DOCKER_REV"
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb12:$DOCKER_REV"
dependencies: null
variables:
# Don't clone the git repo..
......@@ -611,8 +631,8 @@ hackage-doc-tarball:
script:
- cd ghc*/
- mv .gitlab/rel_eng/upload_ghc_libs.py .
- .gitlab/ci.sh setup
- .gitlab/ci.sh configure
- . .gitlab/ci.sh setup
- . .gitlab/ci.sh configure
- ./upload_ghc_libs.py prepare --bindist ghc*linux/
- mv .upload-libs/docs ../hackage_docs
rules:
......@@ -621,17 +641,19 @@ hackage-doc-tarball:
source-tarball:
stage: full-build
needs:
- hadrian-ghc-in-ghci
tags:
- x86_64-linux
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10:$DOCKER_REV"
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb12:$DOCKER_REV"
dependencies: []
artifacts:
paths:
- ghc-*.tar.xz
script:
- sudo chown ghc:ghc -R .
- ./boot
- ./configure
- . .gitlab/ci.sh setup
- . .gitlab/ci.sh configure
- ./hadrian/build source-dist
- mv _build/source-dist/*.xz .
rules:
......@@ -642,6 +664,8 @@ source-tarball:
generate-hadrian-bootstrap-sources:
stage: full-build
needs:
- hadrian-ghc-in-ghci
tags:
- x86_64-linux
image: "$DOCKER_IMAGE"
......@@ -665,7 +689,7 @@ package-hadrian-bootstrap-sources:
tags:
- x86_64-linux
needs: ["generate-hadrian-bootstrap-sources"]
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10:$DOCKER_REV"
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb12:$DOCKER_REV"
artifacts:
paths:
- hadrian-bootstrap-sources-all.tar.gz
......@@ -697,7 +721,10 @@ test-bootstrap:
- .gitlab/ci.sh setup
# Bootstrapping should not depend on HAPPY or ALEX so set them to false
# so the build fails if they are invoked.
- export HAPPY=/bin/false; export ALEX=/bin/false
- unset HAPPY; unset ALEX
# Check the commands are not available, parens are crucial to start a subshell
- (! command -v alex --version)
- (! command -v happy --version)
- .gitlab/ci.sh configure
- .gitlab/ci.sh build_hadrian
- .gitlab/ci.sh test_hadrian
......@@ -706,7 +733,7 @@ test-bootstrap:
variables:
# Don't record performance benchmarks
TEST_ENV: ""
BIN_DIST_NAME: "ghc-x86_64-deb10-linux"
BIN_DIST_NAME: "ghc-x86_64-deb12-linux"
BUILD_FLAVOUR: "validate"
NO_BOOT: "1"
rules:
......@@ -755,16 +782,16 @@ test-bootstrap:
hackage-lint:
needs:
- job: x86_64-linux-deb10-numa-slow-validate
- job: x86_64-linux-deb12-numa-slow-validate
optional: true
artifacts: false
- job: nightly-x86_64-linux-deb10-numa-slow-validate
- job: nightly-x86_64-linux-deb12-numa-slow-validate
optional: true
artifacts: false
- job: nightly-aarch64-linux-deb10-validate
- job: nightly-aarch64-linux-deb12-validate
optional: true
artifacts: false
- job: aarch64-linux-deb10-validate
- job: aarch64-linux-deb12-validate
optional: true
artifacts: false
extends: .hackage
......@@ -779,10 +806,10 @@ hackage-lint:
hackage-label-lint:
needs:
- job: x86_64-linux-deb10-numa-slow-validate
- job: x86_64-linux-deb12-numa-slow-validate
optional: true
artifacts: false
- job: aarch64-linux-deb10-validate
- job: aarch64-linux-deb12-validate
optional: true
artifacts: false
extends: .hackage
......@@ -796,10 +823,10 @@ hackage-label-lint:
# affects the total allocation numbers for the simplifier portion significantly.
nightly-hackage-lint:
needs:
- job: nightly-x86_64-linux-deb10-numa-slow-validate
- job: nightly-x86_64-linux-deb12-numa-slow-validate
optional: true
artifacts: false
- job: nightly-aarch64-linux-deb10-validate
- job: nightly-aarch64-linux-deb12-validate
optional: true
artifacts: false
rules:
......@@ -816,7 +843,7 @@ nightly-hackage-perf:
- job: nightly-x86_64-linux-fedora33-release
optional: true
artifacts: false
- job: nightly-aarch64-linux-deb10-validate
- job: nightly-aarch64-linux-deb12-validate
optional: true
artifacts: false
rules:
......@@ -835,7 +862,7 @@ release-hackage-lint:
- job: release-x86_64-linux-fedora33-release
optional: true
artifacts: false
- job: release-aarch64-linux-deb10-release+no_split_sections
- job: release-aarch64-linux-deb12-release+no_split_sections
optional: true
artifacts: false
rules:
......@@ -868,9 +895,9 @@ release-hackage-lint:
.test-primops-validate-template:
needs:
- job: x86_64-linux-deb10-validate+debug_info
- job: x86_64-linux-deb12-validate
artifacts: false
- job: aarch64-linux-deb10-validate
- job: aarch64-linux-deb12-validate
artifacts: false
- job: aarch64-darwin-validate
artifacts: false
......@@ -882,13 +909,17 @@ test-primops-label:
extends: .test-primops-validate-template
rules:
- if: '$CI_MERGE_REQUEST_LABELS =~ /.*test-primops.*/'
# We do not use *.full-ci here since that would imply running in nightly
# where we do not have the normal validate jobs. We have the -nightly job
# below to handle this case.
- if: '$CI_MERGE_REQUEST_LABELS =~ /.*full-ci.*/'
test-primops-nightly:
extends: .test-primops
needs:
- job: nightly-x86_64-linux-deb10-validate
- job: nightly-x86_64-linux-deb12-validate
artifacts: false
- job: nightly-aarch64-linux-deb10-validate
- job: nightly-aarch64-linux-deb12-validate
artifacts: false
- job: nightly-aarch64-darwin-validate
artifacts: false
......@@ -1027,6 +1058,7 @@ abi-test:
- out
rules:
- *full-ci
- if: '$CI_MERGE_REQUEST_LABELS =~ /.*test-abi.*/'
############################################################
......@@ -1054,7 +1086,7 @@ pages:
<meta charset="UTF-8">
<meta http-equiv="refresh" content="1; url=doc/">
EOF
- cp -f index.html public/doc
- cp -f docs/index.html public/doc
rules:
# N.B. only run this on ghc/ghc since the deployed pages are quite large
# and we only serve GitLab Pages for ghc/ghc.
......@@ -1072,7 +1104,7 @@ pages:
project-version:
stage: packaging
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10:$DOCKER_REV"
image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb12:$DOCKER_REV"
tags:
- x86_64-linux
variables:
......@@ -1092,7 +1124,7 @@ project-version:
.ghcup-metadata:
stage: deploy
image: nixos/nix:2.14.1
image: nixos/nix:2.25.2
dependencies: null
tags:
- x86_64-linux
......@@ -1101,6 +1133,10 @@ project-version:
GIT_SUBMODULE_STRATEGY: "none"
before_script:
- echo "experimental-features = nix-command flakes" >> /etc/nix/nix.conf
# FIXME: See Note [Nix-in-Docker]
- echo "cores = $CPUS" >> /etc/nix/nix.conf
- echo "max-jobs = $CPUS" >> /etc/nix/nix.conf
- nix run nixpkgs#gnused -- -i -e 's/ nixbld//' /etc/nix/nix.conf
- nix-channel --update
- cat version.sh
# Calculate the project version
......@@ -1123,7 +1159,7 @@ ghcup-metadata-nightly:
needs:
- job: nightly-x86_64-linux-fedora33-release
artifacts: false
- job: nightly-x86_64-linux-centos7-validate
- job: nightly-x86_64-linux-ubuntu22_04-validate
artifacts: false
- job: nightly-x86_64-linux-ubuntu20_04-validate
artifacts: false
......@@ -1139,21 +1175,31 @@ ghcup-metadata-nightly:
artifacts: false
- job: nightly-x86_64-linux-alpine3_12-validate
artifacts: false
- job: nightly-x86_64-linux-alpine3_20-validate
artifacts: false
- job: nightly-x86_64-linux-deb9-validate
artifacts: false
- job: nightly-i386-linux-deb10-validate
artifacts: false
- job: nightly-i386-linux-deb12-validate
artifacts: false
- job: nightly-x86_64-linux-deb10-validate
artifacts: false
- job: nightly-aarch64-linux-deb10-validate
artifacts: false
- job: nightly-x86_64-linux-deb11-validate
artifacts: false
- job: nightly-x86_64-linux-deb12-validate
artifacts: false
- job: nightly-aarch64-linux-deb12-validate
artifacts: false
- job: nightly-aarch64-linux-alpine3_18-validate
artifacts: false
- job: source-tarball
artifacts: false
- job: project-version
script:
- nix shell --extra-experimental-features nix-command -f .gitlab/rel_eng -c ghcup-metadata --metadata ghcup-0.0.7.yaml --date="$(date -d $CI_PIPELINE_CREATED_AT +%Y-%m-%d)" --pipeline-id="$CI_PIPELINE_ID" --version="$ProjectVersion" > "metadata_test.yaml"
- nix shell -f .gitlab/rel_eng -c ghcup-metadata --metadata ghcup-0.0.7.yaml --date="$(date -d $CI_PIPELINE_CREATED_AT +%Y-%m-%d)" --pipeline-id="$CI_PIPELINE_ID" --version="$ProjectVersion" > "metadata_test.yaml"
rules:
- if: $NIGHTLY
......@@ -1191,7 +1237,8 @@ ghcup-metadata-release:
# No explicit needs for release pipeline as we assume we need everything and everything will pass.
extends: .ghcup-metadata
script:
- nix shell --extra-experimental-features nix-command -f .gitlab/rel_eng -c ghcup-metadata --release-mode --metadata ghcup-0.0.7.yaml --date="$(date -d $CI_PIPELINE_CREATED_AT +%Y-%m-%d)" --pipeline-id="$CI_PIPELINE_ID" --version="$ProjectVersion" > "metadata_test.yaml"
- nix shell -f .gitlab/rel_eng -c ghcup-metadata --release-mode --metadata ghcup-0.0.7.yaml --date="$(date -d $CI_PIPELINE_CREATED_AT +%Y-%m-%d)" --pipeline-id="$CI_PIPELINE_ID" --version="$ProjectVersion" --fragment
- nix shell -f .gitlab/rel_eng -c ghcup-metadata --release-mode --metadata ghcup-0.0.7.yaml --date="$(date -d $CI_PIPELINE_CREATED_AT +%Y-%m-%d)" --pipeline-id="$CI_PIPELINE_ID" --version="$ProjectVersion" > "metadata_test.yaml"
rules:
- if: '$RELEASE_JOB == "yes"'
......@@ -1202,10 +1249,17 @@ ghcup-metadata-release:
UPSTREAM_PROJECT_ID: "$CI_PROJECT_ID"
UPSTREAM_PIPELINE_ID: "$CI_PIPELINE_ID"
RELEASE_JOB: "$RELEASE_JOB"
# Do not inherit global variables (such as CONFIGURE_ARGS) as these take
# precedence over the variables defined in the downstream job.
inherit:
variables: false
trigger:
project: "ghc/ghcup-ci"
branch: "upstream-testing"
strategy: "depend"
forward:
yaml_variables: true
pipeline_variables: false
ghcup-metadata-testing-nightly:
needs:
......
# Where the GitLab happens
## Updating PERF_NOTES_PUSH_CREDENTIALS
This CI variable is used by test-metrics.sh to push performance data as a git
note to https://gitlab.haskell.org/ghc/ghc-performance-notes.
The current token will expire on 2025-07-02.
### STEPS
Set and fetch the updated token:
```
GITLAB_WRITE=<Your Gitlab API token>
one_year_later="$(date --date='1 year' --iso-8601)"
curl -X POST --header "PRIVATE-TOKEN: $GITLAB_WRITE" -H "Content-Type: application/json" \
--data '{"name":"test-metrics.sh", "scopes":["write_repository"], "expires_at":"$one_year_later"}' \
https://gitlab.haskell.org/api/v4/projects/117/access_tokens \
| jq .token
```
Update the variable:
```
GITLAB_WRITE=<Your Gitlab API token>
NEW_VALUE=<Output from the above>
curl --fail-with-body --request PUT --header "PRIVATE-TOKEN: $GITLAB_WRITE" \
"https://gitlab.haskell.org/api/v4/projects/1/variables/PERF_NOTES_PUSH_CREDENTIALS" \
--form "value=$NEW_VALUE"
```
......@@ -7,7 +7,8 @@
set -Eeuo pipefail
# Configuration:
HACKAGE_INDEX_STATE="2023-10-05T11:38:51Z"
# N.B. You may want to also update the index-state in hadrian/cabal.project.
HACKAGE_INDEX_STATE="2025-01-27T17:45:32Z"
MIN_HAPPY_VERSION="1.20"
MIN_ALEX_VERSION="3.2.6"
......@@ -325,13 +326,19 @@ function fetch_cabal() {
local base_url="https://downloads.haskell.org/~cabal/cabal-install-$v/"
case "$(uname)" in
Darwin) cabal_url="$base_url/cabal-install-$v-x86_64-apple-darwin17.7.0.tar.xz" ;;
FreeBSD) cabal_url="$base_url/cabal-install-$v-x86_64-freebsd13.tar.xz" ;;
FreeBSD) cabal_url="$base_url/cabal-install-$v-x86_64-freebsd14.tar.xz" ;;
*) fail "don't know where to fetch cabal-install for $(uname)"
esac
echo "Fetching cabal-install from $cabal_url"
curl "$cabal_url" > cabal.tar.xz
tmp="$(tar -tJf cabal.tar.xz | head -n1)"
$TAR -xJf cabal.tar.xz
mv cabal "$toolchain/bin"
# Check if the bindist has directory structure
if [[ "$tmp" = "cabal" ]]; then
mv cabal "$toolchain/bin"
else
mv "$tmp/cabal" "$toolchain/bin"
fi
;;
esac
end_section "fetch cabal"
......@@ -403,6 +410,12 @@ function configure() {
else
args+=("--disable-numa")
fi
if [[ -n ${HAPPY:-} ]]; then
args+=("HAPPY=$HAPPY")
fi
if [[ -n ${ALEX:-} ]]; then
args+=("ALEX=$ALEX")
fi
start_section "configuring"
# See https://stackoverflow.com/questions/7577052 for a rationale for the
......@@ -411,8 +424,6 @@ function configure() {
--enable-tarballs-autodownload \
"${args[@]+"${args[@]}"}" \
GHC="$GHC" \
HAPPY="$HAPPY" \
ALEX="$ALEX" \
|| ( cat config.log; fail "configure failed" )
end_section "configuring"
}
......@@ -427,7 +438,9 @@ function push_perf_notes() {
return
fi
if [ -n "${CROSS_TARGET:-}" ] && [ "${CROSS_EMULATOR:-}" != "js-emulator" ]; then
# TODO: Remove this check, see #25299
# It is easy to forget to update this when testing a new cross platform
if [[ -n "${CROSS_TARGET:-}" ]] && [[ "${CROSS_TARGET:-}" != *"javascript"* ]] && [[ "${CROSS_TARGET:-}" != *"wasm"* ]]; then
info "Can't test cross-compiled build."
return
fi
......@@ -556,7 +569,7 @@ function install_bindist() {
run ${CONFIGURE_WRAPPER:-} ./configure \
--prefix="$instdir" \
"${args[@]+"${args[@]}"}"
"${args[@]+"${args[@]}"}" || fail "bindist configure failed"
make_install_destdir "$TOP"/destdir "$instdir"
# And check the `--info` of the installed compiler, sometimes useful in CI log.
"$instdir"/bin/ghc --info
......@@ -675,12 +688,25 @@ function test_hadrian() {
}
function summarise_hi_files() {
for iface in $(find . -type f -name "*.hi" | sort); do echo "$iface $($HC --show-iface $iface | grep " ABI hash:")"; done | tee $OUT/abis
for iface in $(find . -type f -name "*.hi" | sort); do echo "$iface $($HC --show-iface $iface | grep " interface hash:")"; done | tee $OUT/interfaces
for iface in $(find . -type f -name "*.hi" | sort); do
fname="$OUT/$(dirname $iface)"
mkdir -p $fname
$HC --show-iface $iface > "$OUT/$iface"
hi_files=$(find . -type f -name "*.hi" | sort)
for iface in $hi_files; do echo "$iface $($HC --show-iface "$iface" | grep " ABI hash:")"; done | tee $OUT/abis
for iface in $hi_files; do echo "$iface $($HC --show-iface "$iface" | grep " interface hash:")"; done | tee $OUT/interfaces
for iface in $hi_files; do
fname="$OUT/$(dirname "$iface")"
mkdir -p "$fname"
$HC --show-iface "$iface" > "$OUT/$iface"
done
}
function summarise_o_files() {
OBJDUMP=$(if test "$(uname)" == "Darwin"; then echo "objdump -m"; else echo "objdump"; fi)
o_files=$(find . -type f -name "*.o" | sort)
for o in $o_files; do
fname="$OUT/objs/$(dirname "$o")"
mkdir -p "$fname"
# To later compare object dumps except for the first line which prints the file path
$OBJDUMP --all-headers "$o" | tail -n+2 > "$OUT/objs/$o.all-headers"
$OBJDUMP --disassemble-all "$o" | tail -n+2 > "$OUT/objs/$o.disassemble-all"
done
}
......@@ -695,11 +721,13 @@ function cabal_abi_test() {
start_section "Cabal test: $OUT"
mkdir -p "$OUT"
run "$HC" \
"$HC" \
-hidir tmp -odir tmp -fforce-recomp -haddock \
-iCabal/Cabal/src -XNoPolyKinds Distribution.Simple -j"$cores" \
"$@" 2>&1 | tee $OUT/log
-fobject-determinism \
"$@" 2>&1 | sed '1d' | tee $OUT/log
summarise_hi_files
summarise_o_files
popd
end_section "Cabal test: $OUT"
}
......@@ -744,12 +772,40 @@ function check_interfaces(){
for line in $(echo "$difference" | tr ' ' '\n' | grep ".hi" | sort | uniq); do
diff "$1/$line" "$2/$line"
done
fail "$3"
fail "$4"
fi
}
function check_objects(){
# Big fast check
if diff -r "$1" "$2"
then
echo "Objects are the same"
else
echo "--------------------------------------------------------------------------------"
echo "Comparing all objects (1. headers, 2. disassembly). Stopping at first failure..."
echo "--------------------------------------------------------------------------------"
pushd "$1" >/dev/null
OBJ_DUMPS=$(find . -type f -name "*.all-headers" -or -name "*.disassemble-all")
popd >/dev/null
for dump in $OBJ_DUMPS
do
if diff "$1/$dump" "$2/$dump"
then
fail "Mismatched object: $dump"
fi
done
fail "Some objects are mismatched, but theres no diff with --all-headers or --disassemble-all. Perhaps try objdump -s"
fi
}
function abi_test() {
for i in {1..20}; do info "iteration $i"; run_abi_test; done
for i in {1..10}; do info "iteration $i"; run_abi_test; done
}
function run_abi_test() {
......@@ -757,10 +813,12 @@ function run_abi_test() {
fail "HC not set"
fi
mkdir -p out
OUT="$PWD/out/run1" DIR=$(mktemp -d XXXX-looooooooong) cabal_abi_test -O0
OUT="$PWD/out/run2" DIR=$(mktemp -d XXXX-short) cabal_abi_test -O0
OUT="$PWD/out/run1" DIR=$(mktemp -d XXXX-looooooooong) cabal_abi_test -O1 -haddock
# Count uniques in reverse one of the runs to get more non-determinism exposed
OUT="$PWD/out/run2" DIR=$(mktemp -d XXXX-short) cabal_abi_test -O1 -haddock -dunique-increment=-1 -dinitial-unique=16777215
check_interfaces out/run1 out/run2 abis "Mismatched ABI hash"
check_interfaces out/run1 out/run2 interfaces "Mismatched interface hashes"
check_objects out/run1 out/run2
}
function save_test_output() {
......@@ -902,7 +960,7 @@ if [ "${CI_COMMIT_BRANCH:-}" == "master" ] && [ "${CI_PROJECT_PATH:-}" == "ghc/
fi
fi
if [ -n "${IGNORE_PERF_FAILURES:-}" ]; then
RUNTEST_ARGS="--ignore-perf-failures=$IGNORE_PERF_FAILURES"
RUNTEST_ARGS=( "${RUNTEST_ARGS[@]:-}" "--ignore-perf-failures=$IGNORE_PERF_FAILURES" )
fi
if [[ -z ${BIGNUM_BACKEND:-} ]]; then BIGNUM_BACKEND=gmp; fi
......
......@@ -17,10 +17,10 @@
"homepage": "",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "73de017ef2d18a04ac4bfd0c02650007ccb31c2a",
"sha256": "1v9sy2i2dy3qksx4mf81gwzfl0jzpqccfkzq7fjxgq832f9d255i",
"rev": "2893f56de08021cffd9b6b6dfc70fd9ccd51eb60",
"sha256": "1anwxmjpm21msnnlrjdz19w31bxnbpn4kgf93sn3npihi7wf4a8h",
"type": "tarball",
"url": "https://github.com/nixos/nixpkgs/archive/73de017ef2d18a04ac4bfd0c02650007ccb31c2a.tar.gz",
"url": "https://github.com/nixos/nixpkgs/archive/2893f56de08021cffd9b6b6dfc70fd9ccd51eb60.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
}
}
......@@ -36,6 +36,7 @@ let
"AR=/usr/bin/ar"
"LLC=${llvm}/bin/llc"
"OPT=${llvm}/bin/opt"
"LLVMAS=${llvm_clang}/bin/clang"
"CONF_CC_OPTS_STAGE2=--target=${targetTriple}"
"CONF_CXX_OPTS_STAGE2=--target=${targetTriple}"
"CONF_GCC_LINKER_OPTS_STAGE2=--target=${targetTriple}"
......@@ -97,6 +98,7 @@ let
fonts = with pkgs; makeFontsConf { fontDirectories = [ dejavu_fonts ]; };
llvm = pkgs.llvm_15;
llvm_clang = pkgs.llvmPackages_15.clang-unwrapped;
in
pkgs.writeTextFile {
name = "toolchain";
......@@ -112,6 +114,7 @@ pkgs.writeTextFile {
export GHC="${ghc}/bin/ghc"
export LLC="${llvm}/bin/llc"
export OPT="${llvm}/bin/opt"
export LLVMAS="${llvm_clang}/bin/clang"
export SPHINXBUILD="${pkgs.python3Packages.sphinx}/bin/sphinx-build"
export CABAL_INSTALL="${pkgs.cabal-install}/bin/cabal"
export CABAL="$CABAL_INSTALL"
......
......@@ -5,11 +5,11 @@
"systems": "systems"
},
"locked": {
"lastModified": 1687709756,
"narHash": "sha256-Y5wKlQSkgEK2weWdOu4J3riRd+kV/VCgHsqLNTTWQ/0=",
"lastModified": 1710146030,
"narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "dbabf0ca0c0c4bce6ea5eaf65af5cb694d2082c7",
"rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a",
"type": "github"
},
"original": {
......@@ -20,11 +20,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1687886075,
"narHash": "sha256-PeayJDDDy+uw1Ats4moZnRdL1OFuZm1Tj+KiHlD67+o=",
"lastModified": 1724334015,
"narHash": "sha256-5sfvc0MswIRNdRWioUhG58rGKGn2o90Ck6l6ClpwQqA=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "a565059a348422af5af9026b5174dc5c0dcefdae",
"rev": "6d204f819efff3d552a88d0a44b5aaaee172b784",
"type": "github"
},
"original": {
......
This diff is collapsed.
{-# OPTIONS_GHC -Wall -Wno-missing-fields #-}
import GHC.Unit.Types (stringToUnitId)
import GHC hiding (parseModule)
import GHC.Data.StringBuffer
import GHC.Driver.Config.Parser
......@@ -26,7 +27,8 @@ fakeSettings =
sToolSettings = ToolSettings {},
sTargetPlatform =
genericPlatform,
sPlatformMisc = PlatformMisc {}
sPlatformMisc = PlatformMisc {},
sUnitSettings = UnitSettings { unitSettings_baseUnitId = stringToUnitId "base" }
}
fakeDynFlags :: DynFlags
......
This diff is collapsed.
......@@ -7,7 +7,12 @@ expectations. Also please answer the following question in your MR description:*
Please take a few moments to address the following points:
* [ ] if your MR may break existing programs (e.g. touches `base` or causes the
* [ ] if your MR touches `base` (or touches parts of `ghc-internal` used
or re-exported by `base`) more substantially than just amending comments
or documentation, you likely need to raise a
[CLC proposal](https://github.com/haskell/core-libraries-committee#base-package)
before merging it.
* [ ] if your MR may break existing programs (e.g. causes the
compiler to reject programs), please describe the expected breakage and add
the ~"user-facing" label. This will run ghc/head.hackage> to characterise
the effect of your change on Hackage.
......
Thank your for your contribution to Haddock!
* [ ] This MR relates to \<ticket number>
* [ ] I have read the [CONTRIBUTING](./utils/haddock/CONTRIBUTING.md) guide
* [ ] I have inserted a CHANGELOG entry if this warrants it
* [ ] I have squashed my commits
* [ ] I have added tests if necessary
* [ ] I have updated the documentation
If you have any questions don't hesitate to open your merge request and inquire
in a comment. If your patch isn't quite done yet please do add prefix your MR
title with `Draft:`.
Once your change is ready please remove the `Draft:` tag and wait for review. If
no one has offered a review in a few days then please leave a comment mentioning
@triagers and apply the ~"Blocked on Review" label.
......@@ -19,14 +19,15 @@ def job_triple(job_name):
'release-x86_64-windows-release': 'x86_64-unknown-mingw32',
'release-x86_64-windows-int_native-release': 'x86_64-unknown-mingw32-int_native',
'release-x86_64-linux-rocky8-release': 'x86_64-rocky8-linux',
'release-x86_64-linux-ubuntu22_04-release': 'x86_64-ubuntu22_04-linux',
'release-x86_64-linux-ubuntu20_04-release': 'x86_64-ubuntu20_04-linux',
'release-x86_64-linux-ubuntu18_04-release': 'x86_64-ubuntu18_04-linux',
'release-x86_64-linux-fedora38-release': 'x86_64-fedora38-linux',
'release-x86_64-linux-fedora33-release+debug_info': 'x86_64-fedora33-linux-dwarf',
'release-x86_64-linux-fedora33-release': 'x86_64-fedora33-linux',
'release-x86_64-linux-fedora38-release': 'x86_64-fedora38-linux',
'release-x86_64-linux-fedora27-release': 'x86_64-fedora27-linux',
'release-x86_64-linux-deb11-release': 'x86_64-deb11-linux',
'release-x86_64-linux-deb12-release': 'x86_64-deb12-linux',
'release-x86_64-linux-deb11-release': 'x86_64-deb11-linux',
'release-x86_64-linux-deb10-release+debug_info': 'x86_64-deb10-linux-dwarf',
'release-x86_64-linux-deb10-release': 'x86_64-deb10-linux',
'release-x86_64-linux-deb9-release': 'x86_64-deb9-linux',
......@@ -34,13 +35,15 @@ def job_triple(job_name):
'release-x86_64-linux-alpine3_12-release+fully_static': 'x86_64-alpine3_12-linux-static',
'release-x86_64-linux-alpine3_12-release': 'x86_64-alpine3_12-linux',
'release-x86_64-linux-alpine3_12-int_native-release+fully_static': 'x86_64-alpine3_12-linux-static-int_native',
'release-x86_64-linux-alpine3_18-release': 'x86_64-alpine3_18-linux',
'release-x86_64-linux-alpine3_20-release': 'x86_64-alpine3_20-linux',
'release-x86_64-darwin-release': 'x86_64-apple-darwin',
'release-i386-linux-deb9-release': 'i386-deb9-linux',
'release-i386-linux-deb12-release': 'i386-deb12-linux',
'release-i386-linux-deb10-release': 'i386-deb10-linux',
'release-i386-linux-deb9-release': 'i386-deb9-linux',
'release-armv7-linux-deb10-release': 'armv7-deb10-linux',
'release-aarch64-linux-deb10-release': 'aarch64-deb10-linux',
'release-aarch64-linux-deb11-release': 'aarch64-deb11-linux',
'release-aarch64-linux-deb12-release': 'aarch64-deb12-linux',
'release-aarch64-linux-alpine3_18-release+no_split_sections': 'aarch64-alpine3_18-linux',
'release-aarch64-darwin-release': 'aarch64-apple-darwin',
......@@ -129,7 +132,7 @@ def fetch_artifacts(release: str, pipeline_id: int,
for f in doc_files:
subprocess.run(['tar', '-xf', f, '-C', dest])
logging.info(f'extracted docs {f} to {dest}')
index_path = destdir / 'index.html'
index_path = destdir / 'docs' / 'index.html'
index_path.replace(dest / 'index.html')
elif job.name == 'hackage-doc-tarball':
dest = dest_dir / 'hackage_docs'
......
......@@ -36,6 +36,7 @@ import os
import yaml
import gitlab
from urllib.request import urlopen
from urllib.parse import urlparse
import hashlib
import sys
import json
......@@ -66,6 +67,7 @@ class Artifact(NamedTuple):
download_name: str
output_name: str
subdir: str
anchor_name: str
# Platform spec provides a specification which is agnostic to Job
# PlatformSpecs are converted into Artifacts by looking in the jobs-metadata.json file.
......@@ -76,13 +78,15 @@ class PlatformSpec(NamedTuple):
source_artifact = Artifact('source-tarball'
, 'ghc-{version}-src.tar.xz'
, 'ghc-{version}-src.tar.xz'
, 'ghc-{version}' )
, 'ghc-{version}'
, 'ghc{version}-src')
test_artifact = Artifact('source-tarball'
, 'ghc-{version}-testsuite.tar.xz'
, 'ghc-{version}-testsuite.tar.xz'
, 'ghc-{version}' )
, 'ghc-{version}/testsuite'
, 'ghc{version}-testsuite')
def debian(arch, n):
def debian(n, arch='x86_64'):
return linux_platform(arch, "{arch}-linux-deb{n}".format(arch=arch, n=n))
def darwin(arch):
......@@ -92,20 +96,20 @@ def darwin(arch):
windowsArtifact = PlatformSpec ( 'x86_64-windows'
, 'ghc-{version}-x86_64-unknown-mingw32' )
def centos(n):
return linux_platform("x86_64", "x86_64-linux-centos{n}".format(n=n))
def centos(n, arch='x86_64'):
return linux_platform(arch, "{arch}-linux-centos{n}".format(n=n,arch=arch))
def fedora(n):
return linux_platform("x86_64", "x86_64-linux-fedora{n}".format(n=n))
def fedora(n, arch='x86_64'):
return linux_platform(arch, "{arch}-linux-fedora{n}".format(n=n,arch=arch))
def alpine(n):
return linux_platform("x86_64", "x86_64-linux-alpine{n}".format(n=n))
def alpine(n, arch='x86_64'):
return linux_platform(arch, "{arch}-linux-alpine{n}".format(n=n,arch=arch))
def rocky(n):
return linux_platform("x86_64", "x86_64-linux-rocky{n}".format(n=n))
def rocky(n, arch='x86_64'):
return linux_platform(arch, "{arch}-linux-rocky{n}".format(n=n,arch=arch))
def ubuntu(n):
return linux_platform("x86_64", "x86_64-linux-ubuntu{n}".format(n=n))
def ubuntu(n, arch='x86_64'):
return linux_platform(arch, "{arch}-linux-ubuntu{n}".format(n=n,arch=arch))
def linux_platform(arch, opsys):
return PlatformSpec( opsys, 'ghc-{version}-{arch}-unknown-linux'.format(version="{version}", arch=arch) )
......@@ -113,8 +117,7 @@ def linux_platform(arch, opsys):
base_url = 'https://gitlab.haskell.org/api/v4/projects/1/jobs/{job_id}/artifacts/{artifact_name}'
hash_cache = {}
hash_cache = {} # type: Dict[str, str]
# Download a URL and return its hash
def download_and_hash(url):
......@@ -132,6 +135,8 @@ def download_and_hash(url):
hash_cache[url] = digest
return digest
uri_to_anchor_cache=dict()
# Make the metadata for one platform.
def mk_one_metadata(release_mode, version, job_map, artifact):
job_id = job_map[artifact.job_name].id
......@@ -156,14 +161,22 @@ def mk_one_metadata(release_mode, version, job_map, artifact):
eprint(f"Bindist URL: {url}")
eprint(f"Download URL: {final_url}")
#Download and hash from the release pipeline, this must not change anyway during upload.
# Download and hash from the release pipeline, this must not change anyway during upload.
h = download_and_hash(url)
res = { "dlUri": final_url
, "dlSubdir": artifact.subdir.format(version=version)
, "dlOutput": artifact.output_name.format(version=version)
, "dlHash" : h }
# Only add dlOutput if it is inconsistent with the filename inferred from the URL
output = artifact.output_name.format(version=version)
if Path(urlparse(final_url).path).name != output:
res["dlOutput"] = output
eprint(res)
# add the uri to the anchor name cache so we can lookup an anchor for this uri
uri_to_anchor_cache[final_url] = artifact.anchor_name
return res
# Turns a platform into an Artifact respecting pipeline_type
......@@ -174,7 +187,8 @@ def mk_from_platform(pipeline_type, platform):
return Artifact(info['name']
, f"{info['jobInfo']['bindistName']}.tar.xz"
, "ghc-{version}-{pn}.tar.xz".format(version="{version}", pn=platform.name)
, platform.subdir)
, platform.subdir
, f"ghc{{version}}-{platform.name}")
# Generate the new metadata for a specific GHC mode etc
......@@ -183,21 +197,27 @@ def mk_new_yaml(release_mode, version, date, pipeline_type, job_map):
eprint("\n=== " + platform.name + " " + ('=' * (75 - len(platform.name))))
return mk_one_metadata(release_mode, version, job_map, mk_from_platform(pipeline_type, platform))
# Here are all the bindists we can distribute
ubuntu1804 = mk(ubuntu("18_04"))
ubuntu2004 = mk(ubuntu("20_04"))
ubuntu2204 = mk(ubuntu("22_04"))
rocky8 = mk(rocky("8"))
# Here are all the bindists we can distribute
centos7 = mk(centos(7))
fedora33 = mk(fedora(33))
darwin_x86 = mk(darwin("x86_64"))
darwin_arm64 = mk(darwin("aarch64"))
windows = mk(windowsArtifact)
alpine3_12 = mk(alpine("3_12"))
deb9 = mk(debian("x86_64", 9))
deb10 = mk(debian("x86_64", 10))
deb11 = mk(debian("x86_64", 11))
deb10_arm64 = mk(debian("aarch64", 10))
deb10_i386 = mk(debian("i386", 10))
alpine3_20 = mk(alpine("3_20"))
alpine3_18_arm64 = mk(alpine("3_18", arch='aarch64'))
deb9 = mk(debian(9, "x86_64"))
deb10 = mk(debian(10, "x86_64"))
deb11 = mk(debian(11, "x86_64"))
deb12 = mk(debian(12, "x86_64"))
deb10_arm64 = mk(debian(10, "aarch64"))
deb12_arm64 = mk(debian(12, "aarch64"))
deb10_i386 = mk(debian(10, "i386"))
deb12_i386 = mk(debian(12, "i386"))
source = mk_one_metadata(release_mode, version, job_map, source_artifact)
test = mk_one_metadata(release_mode, version, job_map, test_artifact)
......@@ -206,34 +226,49 @@ def mk_new_yaml(release_mode, version, date, pipeline_type, job_map):
# developers want.
a64 = { "Linux_Debian": { "< 10": deb9
, "(>= 10 && < 11)": deb10
, ">= 11": deb11
, "( >= 10 && < 11 )": deb10
, "( >= 11 && < 12 )": deb11
, ">= 12": deb12
, "unknown_versioning": deb11 }
, "Linux_Ubuntu" : { "unknown_versioning": ubuntu2004
, "( >= 16 && < 19 )": ubuntu1804
, "( >= 16 && < 18 )": deb9
, "( >= 18 && < 19 )": ubuntu1804
, "( >= 19 && < 21 )": ubuntu2004
, "( >= 21 )": ubuntu2204
}
, "Linux_Mint" : { "< 20": ubuntu1804
, ">= 20": ubuntu2004 }
, ">= 20": ubuntu2004
, "unknown_versioning": ubuntu2004 }
, "Linux_CentOS" : { "( >= 7 && < 8 )" : centos7
, "unknown_versioning" : centos7 }
, "Linux_Fedora" : { ">= 33": fedora33
, "unknown_versioning": centos7 }
, "Linux_RedHat" : { "unknown_versioning": centos7 }
#MP: Replace here with Rocky8 when that job is in the pipeline
, "Linux_RedHat" : { "< 9": centos7
, ">= 9": fedora33
, "unknown_versioning": fedora33 }
, "Linux_UnknownLinux" : { "unknown_versioning": rocky8 }
, "Darwin" : { "unknown_versioning" : darwin_x86 }
, "Windows" : { "unknown_versioning" : windows }
, "Linux_Alpine" : { "unknown_versioning": alpine3_12 }
, "Linux_Alpine" : { "( >= 3.12 && < 3.20 )": alpine3_12
, ">= 3.20": alpine3_20
, "unknown_versioning": alpine3_12 }
}
a32 = { "Linux_Debian": { "unknown_versioning": deb10_i386 }
a32 = { "Linux_Debian": { "( >= 10 && < 12 )": deb10_i386
, ">= 12": deb12_i386
, "unknown_versioning": deb10_i386 }
, "Linux_Ubuntu": { "unknown_versioning": deb10_i386 }
, "Linux_Mint" : { "unknown_versioning": deb10_i386 }
, "Linux_UnknownLinux" : { "unknown_versioning": deb10_i386 }
}
arm64 = { "Linux_UnknownLinux": { "unknown_versioning": deb10_arm64 }
, "Linux_Alpine" : { "unknown_versioning": alpine3_18_arm64 }
, "Linux_Debian": { "( >= 10 && < 12 )": deb10_arm64
, "( >= 12 )": deb12_arm64
, "unknown_versioning": deb10_arm64
}
, "Darwin": { "unknown_versioning": darwin_arm64 }
}
......@@ -273,6 +308,19 @@ def setNightlyTags(ghcup_metadata):
ghcup_metadata['ghcupDownloads']['GHC'][version]["viTags"].append("Nightly")
def mk_dumper(version):
class CustomAliasDumper(yaml.Dumper):
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
def generate_anchor(self, node):
if isinstance(node, yaml.MappingNode):
node_dict = { k.value : v.value for (k,v) in node.value }
if 'dlUri' in node_dict:
return uri_to_anchor_cache[node_dict['dlUri']].format(version=version.replace('.',''))
return super().generate_anchor(node)
return CustomAliasDumper
def main() -> None:
......@@ -308,7 +356,7 @@ def main() -> None:
new_yaml = mk_new_yaml(args.release_mode, args.version, args.date, pipeline_type, job_map)
if args.fragment:
print(yaml.dump({ args.version : new_yaml }))
print(yaml.dump({ args.version : new_yaml }, Dumper=mk_dumper(args.version)))
else:
with open(args.metadata, 'r') as file:
......
......@@ -9,21 +9,22 @@ usage :
%.gz : %.xz
echo "[xz->gz] $< to $@..."
xz -c $< | gzip -c > $@
xz -cd $< | gzip -c > $@
%.bz2 : %.xz
echo "[xz->bz2] $< to $@..."
xz -c $< | bzip2 -c > $@
xz -cd $< | bzip2 -c > $@
%.lz : %.xz
echo "[xz->lz] $< to $@..."
xz -c $< | lzip -c > $@
xz -cd $< | lzip -c > $@
%.zip : %.tar.xz
echo "[tarxz->zip] $< to $@..."
tmp="$(mktemp tmp.XXX)" && \
tmp="$$(mktemp -d tmp.XXX)" && \
tar -C "$$tmp" -xf $< && \
cd "$$tmp" && \
zip -9 -r $@ * && \
zip -9 -r ../$@ * && \
cd .. && \
rm -R "$$tmp"
......@@ -6,9 +6,9 @@ set -Eeuo pipefail
# This is a script for preparing and uploading a release of GHC.
#
# Usage,
# 1. Update $ver
# 2. Set $SIGNING_KEY to your key id (prefixed with '=')
# 3. Create a directory and place the source and binary tarballs there
# 1. Set $SIGNING_KEY to your key id (prefixed with '=')
# 2. Create a directory named after the release name (e.g. 9.6.1-rc1 or 9.6.1)
# 3. Place the source and binary tarballs in this directory
# 4. Run this script from that directory
#
# You can also invoke the script with an argument to perform only
......@@ -34,10 +34,10 @@ set -Eeuo pipefail
: ${SIGNING_KEY:="=Benjamin Gamari <ben@well-typed.com>"}
# Infer release name from directory name
# Infer friendly release name from directory name
: ${rel_name:=$(basename $(pwd))}
# Infer version from tarball names
# Infer project version from tarball names
: ${ver:=$(ls ghc-*.tar.* | sed -ne 's/ghc-\([0-9]\+\.[0-9]\+\.[0-9]\+\(\.[0-9]\+\)\?\).\+/\1/p' | head -n1)}
if [ -z "$ver" ]; then echo "Failed to infer \$ver"; exit 1; fi
......@@ -59,8 +59,10 @@ usage() {
echo " prepare_docs prepare the documentation directory"
echo " upload_docs upload documentation downloads.haskell.org"
echo " upload upload the tarballs and documentation to downloads.haskell.org"
echo " set_symlink <symlink>"
echo " set the given symlink (e.g. latest) to the current version"
echo " purge_all purge entire release from the CDN"
echo " purge_file file purge a given file from the CDN"
echo " purge_file <file> purge a given file from the CDN"
echo " verify verify the signatures in this directory"
echo
}
......@@ -78,6 +80,7 @@ function hash_files() {
echo $(find -maxdepth 1 \
-iname '*.xz' \
-o -iname '*.lz' \
-o -iname '*.gz' \
-o -iname '*.bz2' \
-o -iname '*.zip' \
)
......@@ -145,7 +148,7 @@ function purge_all() {
curl -X PURGE http://downloads.haskell.org/~ghc/$dir
curl -X PURGE http://downloads.haskell.org/~ghc/$dir/
for i in *; do
purge_file $i
purge_file "$i"
done
}
......@@ -158,43 +161,14 @@ function purge_file() {
)
for dir in ${dirs[@]}; do
curl -X PURGE http://downloads.haskell.org/$dir/$i
curl -X PURGE http://downloads.haskell.org/$dir/$i/
curl -X PURGE http://downloads.haskell.org/$dir/$i/docs/
curl -X PURGE http://downloads.haskell.org/$dir/$1
curl -X PURGE http://downloads.haskell.org/$dir/$1/
curl -X PURGE http://downloads.haskell.org/$dir/$1/docs/
done
}
function prepare_docs() {
echo "THIS COMMAND IS DEPRECATED, THE DOCS FOLDER SHOULD BE PREPARED BY THE FETCH SCRIPT"
local tmp
rm -Rf docs
if [ -z "$GHC_TREE" ]; then
tmp="$(mktemp -d)"
tar -xf "ghc-$ver-src.tar.xz" -C "$tmp"
GHC_TREE="$tmp/ghc-$ver"
fi
mkdocs="$GHC_TREE/distrib/mkDocs/mkDocs"
if [ ! -e "$mkdocs" ]; then
echo "Couldn't find GHC mkDocs at $mkdocs."
echo "Perhaps you need to override GHC_TREE?"
rm -Rf "$tmp"
exit 1
fi
windows_bindist="$(ls ghc-$ver-x86_64-unknown-mingw32.tar.xz | head -n1)"
linux_bindist="$(ls ghc-$ver-x86_64-deb9-linux.tar.xz | head -n1)"
echo "Windows bindist: $windows_bindist"
echo "Linux bindist: $linux_bindist"
$ENTER_FHS_ENV $mkdocs $linux_bindist $windows_bindist
if [ -d "$tmp" ]; then rm -Rf "$tmp"; fi
mkdir -p docs/html
tar -Jxf "$linux_bindist"
cp -R "ghc-$ver/docs/users_guide/build-html/users_guide docs/html/users_guide"
#cp -R ghc-$ver/utils/haddock/doc/haddock docs/html/haddock
rm -R "ghc-$ver"
tar -Jxf docs/libraries.html.tar.xz -C docs/html
mv docs/index.html docs/html
}
function recompress() {
......@@ -213,7 +187,7 @@ function recompress() {
needed+=( "$(basename $i .tar.xz).zip" )
done
recompress-all -l ${needed[@]}
recompress-all -j10 ${needed[@]}
}
function upload_docs() {
......@@ -228,6 +202,14 @@ function upload_docs() {
"$GHC_TREE/.gitlab/rel_eng/upload_ghc_libs.py" upload --docs=hackage_docs ${args[@]}
}
function set_symlink() {
local SYMLINK="$1"
# Check to make sure that the indicated version actually exists.
curl "https://downloads.haskell.org/ghc/$ver" > /dev/null || (echo "$ver doesn't exist"; exit 1)
echo -e "rm ghc/$SYMLINK\nln -s $ver ghc/$SYMLINK" | sftp ghc@downloads-origin.haskell.org
curl -X PURGE "http://downloads.haskell.org/~ghc/$SYMLINK"
}
if [ "x$1" == "x" ]; then
recompress
gen_hashes
......
......@@ -93,6 +93,19 @@ def prep_ghc():
build_copy_file(PACKAGES['ghc'], 'GHC/Platform/Constants.hs')
build_copy_file(PACKAGES['ghc'], 'GHC/Settings/Config.hs')
def prep_ghc_boot_th():
# Drop references to `ghc-internal` from `hs-source-dirs` as Hackage rejects
# out-of-sdist references and this packages is only uploaded for documentation
# purposes.
modify_file(PACKAGES['ghc-boot-th'], 'ghc-boot-th.cabal',
lambda s: s.replace('../ghc-internal/src', '')
.replace('GHC.Internal.TH.Lib', '')
.replace('GHC.Internal.TH.Syntax', '')
.replace('GHC.Internal.ForeignSrcLang', '')
.replace('GHC.Internal.LanguageExtensions', '')
.replace('GHC.Internal.Lexeme', '')
)
PACKAGES = {
pkg.name: pkg
for pkg in [
......@@ -105,9 +118,10 @@ PACKAGES = {
Package('template-haskell', Path("libraries/template-haskell"), no_prep),
Package('ghc-heap', Path("libraries/ghc-heap"), no_prep),
Package('ghc-boot', Path("libraries/ghc-boot"), prep_ghc_boot),
Package('ghc-boot-th', Path("libraries/ghc-boot-th"), no_prep),
Package('ghc-boot-th', Path("libraries/ghc-boot-th"), prep_ghc_boot_th),
Package('ghc-compact', Path("libraries/ghc-compact"), no_prep),
Package('ghc', Path("compiler"), prep_ghc),
Package('ghci', Path("libraries/ghci"), no_prep),
]
}
# Dict[str, Package]
......