Skip to content

feature/cross-compile #8

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 117 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
117 commits
Select commit Hold shift + click to select a range
500505c
Add test
sergv Jun 18, 2025
2317a67
Rearrange genPureArgs for hsc2hs without changing semantics
sergv Jun 19, 2025
c917edc
Deduplicate arguments that hsc2hs passes to gcc and ld
sergv Jun 19, 2025
e38f45d
Add changelog
sergv Jun 19, 2025
c3b3b82
Override C compiler for testing that no duplicate arguments are passed
sergv Jun 19, 2025
20460e9
Fix typo exsting
philderbeast Jul 16, 2025
cfbe545
Merge pull request #11005 from sergv/deduplicate-hsc2hs-args
mergify[bot] Jul 17, 2025
6205b02
Merge pull request #11076 from cabalism/typo/exsting
mergify[bot] Jul 19, 2025
a6e4162
Bump counts with hlint-3.8
philderbeast Jul 18, 2025
46099cf
Typo, seach, in comment
philderbeast Jul 20, 2025
e55b866
Bump to hlint-3.10
philderbeast Jul 18, 2025
86c7153
Replace cabal project parsing with parsec implementation
jgotoh May 31, 2024
9a67ecc
Merge pull request #11081 from cabalism/typo/seach
mergify[bot] Jul 22, 2025
f548cef
Error messages: Tweak how parse errors from parsec parser are displayed
mpickering Jul 22, 2025
7daa882
Merge pull request #11082 from cabalism/bump/hlint-3.10
mergify[bot] Jul 22, 2025
8c46f48
CI: add GHC 8.6.5 to validate-old-ghcs
ulysses4ever Jul 15, 2025
6d6fc4c
Merge pull request #11074 from haskell/ulysses4ever-patch-3
mergify[bot] Jul 22, 2025
6c14a45
Mark Terminate package test as flaky wrt #11087
hasufell Jul 22, 2025
cf306c9
Typo in Makefile .PHONY target
philderbeast Jul 23, 2025
c7f6b50
Add Tikhon's key
jmct Jul 23, 2025
bcc974e
Remove Mathieu's key
jmct Jul 23, 2025
3a36880
Update Changelog for PR #11095
jmct Jul 23, 2025
0ea75fe
Merge pull request #8889 from jgotoh/parse-cabal-project-parsec
mergify[bot] Jul 25, 2025
d69248a
Merge pull request #11094 from cabalism/typo/rountrip
mergify[bot] Jul 25, 2025
621c92b
work around git locking issue on Windows
geekosaur Jul 25, 2025
671bee6
Merge pull request #11095 from jmct/master
mergify[bot] Jul 26, 2025
f2718c7
Merge pull request #11105 from geekosaur/windows-git-lock-fix
mergify[bot] Jul 26, 2025
20ddb99
Merge pull request #11088 from stable-haskell/flaky-11087
mergify[bot] Jul 27, 2025
ad989af
Typos in release script comments
philderbeast Jul 27, 2025
598b322
Skip T5634 on Alpine
hasufell Jul 7, 2025
27593dc
Merge pull request #11110 from cabalism/typos/release-binaries
mergify[bot] Jul 29, 2025
2fb8dd4
Fix typo folowing
philderbeast Jul 29, 2025
7b67d02
Follow hlint suggestions with single counts
philderbeast Jul 23, 2025
ac75d6a
Merge pull request #11112 from geekosaur/alpine-test-fail
mergify[bot] Jul 31, 2025
e97d042
Merge pull request #11113 from cabalism/typo/folowing
mergify[bot] Jul 31, 2025
9b26df8
Merge pull request #11093 from cabalism/hlint/onesies
mergify[bot] Aug 2, 2025
bf41470
Migrate release CI back to github
hasufell Nov 13, 2023
6f52802
Disable 32bit test
hasufell Jul 18, 2025
5cabbce
Add FreeBSD releases
hasufell Jul 18, 2025
def6c02
try Ubuntu 24.04 again
geekosaur Jul 12, 2025
9260dac
Reuse isAsciiAlpha, remove isNum
philderbeast Aug 3, 2025
9d8968e
update `time` to 1.15
geekosaur Aug 4, 2025
d7dca69
Show exception context on assertion failure
mpickering Jul 18, 2025
f83f91e
Merge pull request #11126 from cabalism/hlint/is-digit-is-ascii
mergify[bot] Aug 6, 2025
e2d2d20
Merge pull request #11068 from geekosaur/try-24.04-again
mergify[bot] Aug 6, 2025
b140dca
Merge pull request #11127 from geekosaur/time-1.15
mergify[bot] Aug 6, 2025
8ba636c
Merge pull request #11072 from stable-haskell/release-ci
mergify[bot] Aug 6, 2025
6221bb7
Follow hlint suggestion: Use elem, Use notElem
philderbeast Aug 4, 2025
3d16e4b
Merge pull request #11125 from haskell/wip/fix-assertion-backtrace
mergify[bot] Aug 8, 2025
6ef8193
Merge pull request #11135 from cabalism/hlint/elem-notElem
mergify[bot] Aug 9, 2025
ccc8d8e
feat(Cabal,Cabal-syntax): add per-file options to extra source files
andreabedini Mar 6, 2025
d635255
feat(Cabal): do not wrap logging by default
andreabedini Jun 5, 2025
4fea68e
feat(Cabal, Cabal-syntax): support generated cmm-sources
andreabedini Mar 13, 2025
ab8a33e
refactor(cabal-install-solver)!: remove base shim
andreabedini Mar 20, 2025
2549384
refactor(cabal-install-solver)!: remove dead code
andreabedini Mar 14, 2025
5d4445a
refactor(cabal-install,Cabal): move programDbSignature to Cabal
andreabedini Mar 19, 2025
5781faf
refactor(cabal-install): separate GenericReadyPackage from ReadyPackage
andreabedini May 8, 2025
96847e5
refactor(cabal-install): simplify the logic behind pkgsUseSharedLibr…
andreabedini Mar 21, 2025
f6e1547
refactor(cabal-install): remove independent goals
andreabedini Mar 19, 2025
5bdc2d2
refactor(cabal-install): remove base-on-base trick
andreabedini Apr 23, 2025
da4b502
refactor(cabal-install): remove storePackageDBStack
andreabedini Apr 9, 2025
65def9a
refactor(cabal-install): resolve package dbs during planning
andreabedini Apr 8, 2025
65b206a
refactor(cabal-install-solver): remove workaround for bug closed year…
andreabedini Apr 23, 2025
3e862cb
refactor(cabal-install): remove workaround for build tools listed as …
andreabedini May 5, 2025
1824f72
refactor(cabal-install): move elabInstantiatedWith and elabLinkedInst…
andreabedini May 5, 2025
155f564
feat(cabal-install-solver): introduce Stage and Toolchain
andreabedini Mar 20, 2025
4e9e693
feat(cabal-install): introduce ProjectConfigToolchain
andreabedini Apr 2, 2025
5d473cd
feat(cabal-install-solver): all of it, second part
andreabedini Mar 21, 2025
919ae6b
refactor(cabal-install): don't check for compiler support before usi…
andreabedini Jul 24, 2025
6c7c718
feat(cabal-install): add build compiler option
andreabedini Mar 20, 2025
1c2ab26
feat(cabal-install): all of it
andreabedini Mar 21, 2025
d72cbd9
feat(cabal-install): add stage to ConstraintScope and UserConstraint
andreabedini Apr 2, 2025
78f91f8
refactor(cabal-install-solver): improve messages
andreabedini Apr 23, 2025
f738a09
refactor(cabal-install): use a pretty printer in showDepResolverParams
andreabedini Apr 23, 2025
d1d3f1a
refactor(cabal-install, cabal-install-solver): avoid using "error" in…
andreabedini Jul 2, 2025
84676de
refactor(cabal-install-solver): add Show instance for Progress
andreabedini Jul 2, 2025
0d516ab
feat(cabal-install-solver): add null to ComponentDeps
andreabedini Apr 23, 2025
db463e5
feat(cabal-install-solver): add Pretty instance for SolverId
andreabedini Apr 23, 2025
dc1ae15
refactor(cabal-install): merge two almost identical functions
andreabedini Apr 28, 2025
f6af221
chore(cabal-install-solver): add comments and improve readability
andreabedini Apr 29, 2025
271f928
feat(cabal-install, cabal-install-solver): track stage in SolverId
andreabedini Jul 2, 2025
96a7fa6
fix(cabal-install): rewrite dependencyInconsistencies
andreabedini May 1, 2025
6e64745
chore(cabal-install-solver): remove traceTree
andreabedini Jun 23, 2025
c212dc1
refactor(cabal-install-solver): refactor modularResolver
andreabedini Jun 23, 2025
40d47ae
refactor(cabal-install): generalise GenericInstallPlan to arbitrary n…
andreabedini Aug 7, 2025
56def66
chore(Cabal): update reference to backpack-include field, now called …
andreabedini May 6, 2025
96af54c
feat: add a bunch of HasCallStack
andreabedini Jun 25, 2025
ad9d727
fix: use nodeKey in fromSolverInstallPlanWithProgress
andreabedini May 19, 2025
f7ac57b
propagate stage trough elaborateProjectPlanning
andreabedini May 5, 2025
43bfee6
fix(cabal-install): rewrite instantiateInstallPlan
andreabedini Aug 7, 2025
4b4b19b
refactor(cabal-install): reduce scope in ProjectPlanning
andreabedini Jul 14, 2025
cd40900
refactor(cabal-install): readability improvements
andreabedini May 20, 2025
d8671ab
fix(cabal-install): use the correct stage for setup deps
andreabedini May 27, 2025
fc27a08
refactor(cabal-install): rebuildTargets
andreabedini May 27, 2025
b3dae95
feat(cabal-install): more logging in buildAndRegisterUnpackedPackage
andreabedini May 27, 2025
5340d8c
fix(cabal-install): use the correct packagedb for setup
andreabedini Jun 25, 2025
3d5e6ef
fix(cabal-install): fix pkgsToBuildInPlaceOnly
andreabedini May 28, 2025
1f780a6
refactor(cabal-install): seprate build directories and drop -inplace
andreabedini Jul 26, 2025
46bb902
refactor(cabal-install): remove dead code
andreabedini Jul 26, 2025
befaa04
fix(Cabal): do not use GHC to configure LD
angerman May 22, 2025
6465774
feat(cabal-install): add parser for UserQualExe
andreabedini Jul 10, 2025
077f089
feat(cabal-install): add ScopeAnyExeQualifier and UserAnyExeQualifier
andreabedini Jul 10, 2025
ac4b132
feature(cabal-install): automatically copy executables into build dir…
andreabedini Jun 5, 2025
eae5c0a
refactor(cabal-install): refactor InstallPlan.problems
andreabedini Jul 28, 2025
b145546
refactor(cabal-install): use LogProgress in InstallPlan
andreabedini Aug 1, 2025
a4cc95d
feat(cabal-install): implicilty monitor our own executable to burst s…
andreabedini Aug 1, 2025
2ccb3c7
refactor(cabal-install): add more HasCallstack
andreabedini Aug 7, 2025
ae8c059
refactor(Cabal): add a stack trace to dieProgress
andreabedini Aug 7, 2025
856fc22
refactor(Cabal-syntax): Improve Graph.broken
andreabedini Aug 4, 2025
60cbabf
refactor(cabal-install): harmonise various dependency functions
andreabedini Aug 4, 2025
fe886f2
debug: log why not registering
andreabedini Aug 5, 2025
560975d
refactor(cabal-install): rename, format and comment
andreabedini Aug 5, 2025
cc598b5
refactor(cabal-install): pkgDependsOnSelfLib should not hide failures
andreabedini Aug 5, 2025
68f5207
fix(Cabal): do not print finalized package description, it loops
andreabedini Aug 6, 2025
789f393
feature(cabal-install): improve logging of setup arguments
andreabedini Aug 6, 2025
7f9a4c4
fix(Cabal): fix abi tag in case ghc's unit-id is the same as the comp…
andreabedini Aug 7, 2025
d81e915
fix(Cabal): disable logging of the response file
andreabedini Jul 30, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
25 changes: 25 additions & 0 deletions .github/actions/download/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: 'Download artifact'
description: 'Download artifacts with normalized names'
inputs:
name:
required: true
type: string
path:
required: true
type: string

runs:
using: "composite"
steps:
- name: Normalise name
run: |
name=${{ inputs.name }}
echo "NAME=${name//\//_}" >> "$GITHUB_ENV"
shell: bash

- name: Download artifact
uses: actions/download-artifact@v4
with:
name: ${{ env.NAME }}
path: ${{ inputs.path }}

33 changes: 33 additions & 0 deletions .github/actions/upload/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: 'Upload artifact'
description: 'Upload artifacts with normalized names'
inputs:
if-no-files-found:
default: 'error'
type: string
name:
required: true
type: string
path:
required: true
type: string
retention-days:
default: 0
type: number

runs:
using: "composite"
steps:
- name: Normalise name
run: |
name=${{ inputs.name }}
echo "NAME=${name//\//_}" >> "$GITHUB_ENV"
shell: bash

- name: Upload artifact
uses: actions/upload-artifact@v4
with:
if-no-files-found: ${{ inputs.if-no-files-found }}
retention-days: ${{ inputs.retention-days }}
name: ${{ env.NAME }}
path: ${{ inputs.path }}

55 changes: 55 additions & 0 deletions .github/scripts/build.bash
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
set -eux

uname -a
uname -p
uname
pwd
env

if [ "${RUNNER_OS}" = Windows ] ; then
ext=".exe"
else
ext=""
fi

ghcup --no-verbose install ghc --set --install-targets "${GHC_TARGETS}" "${GHC_VERSION}"

cabal update
cabal user-config diff
cabal user-config init -f
"ghc-${GHC_VERSION}" --info
"ghc" --info

# shellcheck disable=SC2206
args=(
-w "ghc-$GHC_VERSION"
--disable-profiling
--enable-executable-stripping
--project-file=cabal.release.project
${ADD_CABAL_ARGS}
)

cabal v2-build "${args[@]}" cabal-install

mkdir -p "out"
# shellcheck disable=SC2154
cp "$(cabal list-bin "${args[@]}" cabal-install:exe:cabal)" "out/cabal$ext"
cp dist-newstyle/cache/plan.json "out/plan.json"
cd "out/"

# create tarball/zip
TARBALL_PREFIX="cabal-install-$("./cabal" --numeric-version)"
case "${TARBALL_EXT}" in
zip)
zip "${TARBALL_PREFIX}-${ARTIFACT}.${TARBALL_EXT}" "cabal${ext}" plan.json
;;
tar.xz)
tar caf "${TARBALL_PREFIX}-${ARTIFACT}.${TARBALL_EXT}" "cabal${ext}" plan.json
;;
*)
fail "Unknown TARBALL_EXT: ${TARBALL_EXT}"
;;
esac

rm "cabal${ext}" plan.json

34 changes: 34 additions & 0 deletions .github/scripts/test.bash
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
set -eux

env
pwd
ls -lah

cd out
case "${TARBALL_EXT}" in
zip)
unzip ./cabal-install-*-"${ARTIFACT}.${TARBALL_EXT}"
;;
tar.xz)
tar xf ./cabal-install-*-"${ARTIFACT}.${TARBALL_EXT}"
;;
*)
fail "Unknown TARBALL_EXT: ${TARBALL_EXT}"
;;
esac
cd ..

ghcup --no-verbose install ghc --set --install-targets "${GHC_TEST_TARGETS}" "${GHC_TEST_VERSION}"

cabal update

# TODO: we want to avoid building here... we should just
# be using the previously built 'cabal-tests' binary
# Also see https://github.com/haskell/cabal/issues/11048
cabal run -w "ghc-${GHC_TEST_VERSION}" ${ADD_CABAL_ARGS} cabal-testsuite:cabal-tests -- \
--with-cabal "$(pwd)/out/cabal" \
--intree-cabal-lib "$(pwd)" \
--test-tmp "$(pwd)/testdb" \
--skip-setup-tests \
-j "$(nproc || sysctl -n hw.ncpu || getconf _NPROCESSORS_ONLN || echo 1)"

2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
- uses: actions/checkout@v4
- uses: haskell-actions/hlint-setup@v2
with:
version: "3.8"
version: "3.10"
- uses: haskell-actions/hlint-run@v2
with:
path: "."
Expand Down
87 changes: 87 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
name: Build and release

on:
push:
tags:
- 'v*'
- 'cabal-install-*'
pull_request:
types: [opened, synchronize, reopened, labeled]
branches:
- master
schedule:
- cron: '0 0 * * *'
workflow_dispatch:

permissions:
pull-requests: read

env:
BUILD_LABEL: "run release build"

jobs:
check-pr-labels:
name: check PR labels
runs-on: ubuntu-latest
outputs:
run_release_workflow: ${{ steps.gen_output.outputs.run_release_workflow }}
steps:
- id: gen_output
run: |
if [ "${{ github.event.action }}" == 'labeled' ] ; then
if [ ${{ github.event.label.name == '${{ env.BUILD_LABEL }}' }} ] ; then
echo run_release_workflow="yes" >> "$GITHUB_OUTPUT"
else
echo run_release_workflow="no" >> "$GITHUB_OUTPUT"
fi
elif [ "${{ github.event_name }}" = 'pull_request' ] ; then
run_it=$(if gh api --jq '.labels.[].name' /repos/${{ github.repository }}/pulls/${{ github.event.number }} | grep --quiet '^${{ env.BUILD_LABEL }}$' ; then printf "%s" "yes" ; else printf "%s" "no" ; fi)
echo "${run_it}"
echo run_release_workflow="${run_it}" >> "$GITHUB_OUTPUT"
else
echo run_release_workflow="yes" >> "$GITHUB_OUTPUT"
fi
shell: bash
env:
GH_TOKEN: ${{ github.token }}

release-workflow:
needs: ["check-pr-labels"]
if: ${{ needs.check-pr-labels.outputs.run_release_workflow == 'yes' }}
uses: ./.github/workflows/reusable-release.yml
with:
branches: '["${{ github.ref }}"]'

release:
name: release
needs: [ "release-workflow" ]
runs-on: ubuntu-latest
if: ${{ startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' }}
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Download artifacts
uses: actions/download-artifact@v4
with:
pattern: artifacts-*
merge-multiple: true
path: ./out

- name: Install requirements
run: |
sudo apt-get update && sudo apt-get install -y tar xz-utils
shell: bash

- name: build sdists
run: |
cabal sdist -o out all
shell: bash

- name: Release
uses: softprops/action-gh-release@v1
with:
draft: true
files: |
./out/*

Loading
Loading