Skip to content

Commit ed26da6

Browse files
committed
[ change ] Replace WASM git submodules with cabal source-repository-package for network
1 parent 270a9bf commit ed26da6

File tree

6 files changed

+3
-16
lines changed

6 files changed

+3
-16
lines changed

.github/workflows/wasm.yaml

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ jobs:
2121
- uses: actions/checkout@v4
2222
with:
2323
path: als
24-
submodules: true
2524

2625
- name: Compute cache key
2726
run: echo "CI_CACHE_KEY=${{ runner.os }}-${{ runner.arch }}-${{ env.GHC_WASM_META_COMMIT_HASH }}-flavor-${{ env.GHC_WASM_META_FLAVOUR }}" >> "$GITHUB_ENV"
@@ -109,11 +108,7 @@ jobs:
109108
- name: Build dependencies
110109
working-directory: './als'
111110
run: |
112-
# Setup network submodule autotools
113-
cd wasm-submodules/network
114-
autoreconf -i
115-
cd ../..
116-
# Build all dependencies (cabal git deps + network submodule)
111+
# Build all dependencies (all from cabal git deps and Hackage)
117112
wasm32-wasi-cabal build --dependencies-only
118113
119114
- name: Build als

.gitmodules

Lines changed: 0 additions & 4 deletions
This file was deleted.

BUILDING_WASM.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
# How to build for WASM
22

33
1. Setup a working ghc (tested with v9.10) with WASM backend and wasm32-wasi-cabal.
4-
2. `cd` into `wasm-submodules/network` and run `autoreconf -i`.
5-
3. In the project root, run `cp cabal.project{.wasm32,}`, and then `wasm32-wasi-cabal build`.
4+
2. In the project root, run `cp cabal.project{.wasm32,}`, and then `wasm32-wasi-cabal build`.
65

7-
Note: This project uses a hybrid approach - most dependencies use cabal's git handling, but the network package remains as a git submodule due to autotools requirements.
6+
Note: This project uses cabal's `source-repository-package` declarations to fetch git dependencies instead of git submodules.
87

98
The process might output the following:
109

cabal.project

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
packages:
22
.
3-
wasm-submodules/network
43

54
source-repository-package
65
type: git

cabal.project.wasm32

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
packages:
22
.
3-
wasm-submodules/network
43

54
source-repository-package
65
type: git

wasm-submodules/network

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)