From 716b9e041da0716b0942e74667d923266195fa0c Mon Sep 17 00:00:00 2001 From: coco-314 Date: Thu, 19 Mar 2026 14:05:15 +0100 Subject: [PATCH 01/59] Add Windows executable builds to the CI workflow. --- .github/workflows/build.yaml | 44 ++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 0bdb0478..add5fcd7 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -126,6 +126,50 @@ jobs: name: archives-${{ matrix.config.os }}-${{ matrix.config.arch }} path: new_release/* + windows-build: + strategy: + fail-fast: false + matrix: + config: + - { os: "windows-2022", arch: "x86_64", target: "x64" } + - { os: "windows-2022", arch: "x86", target: "x86" } + ocaml-compiler: + - 4.14.x + runs-on: ${{ matrix.config.os }} + steps: + - name: Checkout + uses: actions/checkout@v3 + with: + fetch-depth: 0 + + - name: Fetch tags + run: git fetch --tags --force origin + + - name: Install OCaml ${{ matrix.ocaml-compiler }} + uses: ocaml/setup-ocaml@v2 + with: + ocaml-compiler: ${{ matrix.ocaml-compiler }} + architecture: ${{ matrix.config.target }} + + - name: Install dependencies + run: opam install --deps-only --with-test --with-doc -y . + + - name: Build release + run: | + mkdir -p new_release + $env:OUTPUT = "$PWD\new_release" + $env:TARGETOS = "windows" + $env:TARGETARCH = "${{ matrix.config.arch }}" + $env:VERSION = "$env:GITHUB_REF_NAME" + opam exec -- bash release/release.sh + shell: pwsh + + - name: Upload archives + uses: actions/upload-artifact@v4 + with: + name: archives-windows-${{ matrix.config.arch }} + path: new_release/* + release: if: startsWith(github.ref, 'refs/tags/') needs: [linux-build, mac-build] From fb1dd7fd517f03efb2219b985da3c7cb924750e8 Mon Sep 17 00:00:00 2001 From: coco-314 Date: Thu, 19 Mar 2026 15:24:06 +0100 Subject: [PATCH 02/59] Using version 3 of action "setup-ocaml" --- .github/workflows/build.yaml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index add5fcd7..f97d4cbb 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -132,7 +132,6 @@ jobs: matrix: config: - { os: "windows-2022", arch: "x86_64", target: "x64" } - - { os: "windows-2022", arch: "x86", target: "x86" } ocaml-compiler: - 4.14.x runs-on: ${{ matrix.config.os }} @@ -146,10 +145,9 @@ jobs: run: git fetch --tags --force origin - name: Install OCaml ${{ matrix.ocaml-compiler }} - uses: ocaml/setup-ocaml@v2 + uses: ocaml/setup-ocaml@v3 with: ocaml-compiler: ${{ matrix.ocaml-compiler }} - architecture: ${{ matrix.config.target }} - name: Install dependencies run: opam install --deps-only --with-test --with-doc -y . From 155a79c593d92010cd97a48e419548d52305d93c Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Fri, 20 Mar 2026 09:32:47 +0100 Subject: [PATCH 03/59] Removing cf deps to check if it allows installing deps on Windows --- dune-project | 1 - slipshow.opam | 1 - 2 files changed, 2 deletions(-) diff --git a/dune-project b/dune-project index de9ef062..d8c7d7b9 100644 --- a/dune-project +++ b/dune-project @@ -32,7 +32,6 @@ bos lwt (inotify (= :os "linux")) - (cf-lwt (>="0.4")) astring fmt logs diff --git a/slipshow.opam b/slipshow.opam index 0cf4858b..5c00dea2 100644 --- a/slipshow.opam +++ b/slipshow.opam @@ -21,7 +21,6 @@ depends: [ "bos" "lwt" "inotify" {os = "linux"} - "cf-lwt" {>= "0.4"} "astring" "fmt" "logs" From 0028f0100716d0e0c16dd6e45386aac0554f6d5a Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Fri, 20 Mar 2026 09:51:40 +0100 Subject: [PATCH 04/59] Windows: Check if preprocessing is not working on Windows --- vendor/github.com/panglesd/lwd/lib/lwd/lwd_infix.ml | 2 -- vendor/github.com/panglesd/lwd/lib/lwd/lwd_infix.mli | 2 -- vendor/github.com/panglesd/lwd/lib/lwd/lwd_seq.ml | 4 ---- vendor/github.com/panglesd/lwd/lib/lwd/lwd_seq.mli | 5 ----- 4 files changed, 13 deletions(-) diff --git a/vendor/github.com/panglesd/lwd/lib/lwd/lwd_infix.ml b/vendor/github.com/panglesd/lwd/lib/lwd/lwd_infix.ml index 28f12a63..12935894 100644 --- a/vendor/github.com/panglesd/lwd/lib/lwd/lwd_infix.ml +++ b/vendor/github.com/panglesd/lwd/lib/lwd/lwd_infix.ml @@ -1,8 +1,6 @@ -(*BEGIN LETOP*) let (let$) : 'a Lwd.t -> ('a -> 'b) -> 'b Lwd.t = Lwd.Infix.(>|=) let (and$) : 'a Lwd.t -> 'b Lwd.t -> ('a * 'b) Lwd.t = Lwd.pair let (let$*) : 'a Lwd.t -> ('a -> 'b Lwd.t) -> 'b Lwd.t = Lwd.Infix.(>>=) -(*END*) let ($=) : 'a Lwd.var -> 'a -> unit = Lwd.set let ($<-) : 'a Lwd_table.row -> 'a -> unit = Lwd_table.set diff --git a/vendor/github.com/panglesd/lwd/lib/lwd/lwd_infix.mli b/vendor/github.com/panglesd/lwd/lib/lwd/lwd_infix.mli index a0757107..9d6fbbb8 100644 --- a/vendor/github.com/panglesd/lwd/lib/lwd/lwd_infix.mli +++ b/vendor/github.com/panglesd/lwd/lib/lwd/lwd_infix.mli @@ -1,4 +1,3 @@ -(*BEGIN LETOP*) val (let$) : 'a Lwd.t -> ('a -> 'b) -> 'b Lwd.t (** Alias to {!Lwd.map'} suitable for let-op bindings *) @@ -7,7 +6,6 @@ val (let$*) : 'a Lwd.t -> ('a -> 'b Lwd.t) -> 'b Lwd.t val (and$) : 'a Lwd.t -> 'b Lwd.t -> ('a * 'b) Lwd.t (** Alias to {!Lwd.pair} suitable for let-op bindings *) -(*END*) val ($=) : 'a Lwd.var -> 'a -> unit (** Infix alias to {!Lwd.set} *) diff --git a/vendor/github.com/panglesd/lwd/lib/lwd/lwd_seq.ml b/vendor/github.com/panglesd/lwd/lib/lwd/lwd_seq.ml index cbd48065..c6773aa5 100644 --- a/vendor/github.com/panglesd/lwd/lib/lwd/lwd_seq.ml +++ b/vendor/github.com/panglesd/lwd/lib/lwd/lwd_seq.ml @@ -1,8 +1,4 @@ -(*BEGIN INJECTIVITY*) type !+'a t = -(*ELSE*) -type +'a t = -(*END*) | Nil | Leaf of { mutable mark: int; v: 'a; } | Join of { mutable mark: int; l: 'a t; r: 'a t; } diff --git a/vendor/github.com/panglesd/lwd/lib/lwd/lwd_seq.mli b/vendor/github.com/panglesd/lwd/lib/lwd/lwd_seq.mli index f7607033..a5be682a 100644 --- a/vendor/github.com/panglesd/lwd/lib/lwd/lwd_seq.mli +++ b/vendor/github.com/panglesd/lwd/lib/lwd/lwd_seq.mli @@ -12,13 +12,8 @@ element. *) -(*BEGIN INJECTIVITY*) type !+'a t type !+'a seq = 'a t -(*ELSE*) -type +'a t -type +'a seq = 'a t -(*END*) (** The type of sequences *) From 0c7faa4140150e9229dce02ee852c97327124f0d Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sun, 5 Apr 2026 18:43:18 +0200 Subject: [PATCH 05/59] Test ci on windows --- release/release.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/release.sh b/release/release.sh index f6dcf700..e35b526e 100644 --- a/release/release.sh +++ b/release/release.sh @@ -1,7 +1,7 @@ #/usr/bin/env bash set -xeuo pipefail -archive_name=$OUTPUT/slipshow-$TARGETOS-$TARGETARCH.tar +archive_name=$OUTPUT\slipshow-$TARGETOS-$TARGETARCH.tar dune subst From 6a0e50df2a0bdc3ffd30191e81c8926375ceb0f3 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sun, 5 Apr 2026 18:45:42 +0200 Subject: [PATCH 06/59] More windows tests --- release/release.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/release.sh b/release/release.sh index e35b526e..e4ea1d75 100644 --- a/release/release.sh +++ b/release/release.sh @@ -8,4 +8,4 @@ dune subst dune build --profile release -p slipshow # Executables are symlinks, follow with -h. -tar hcf "$archive_name" -C _build/install/default bin/slipshow +tar hcf "$archive_name" -C _build\install\default bin\slipshow From 226ef3fad947847b968636dbc5612a149db22a38 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sun, 5 Apr 2026 19:04:03 +0200 Subject: [PATCH 07/59] backslashes not as escapes --- release/release.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/release/release.sh b/release/release.sh index e4ea1d75..cc1cb045 100644 --- a/release/release.sh +++ b/release/release.sh @@ -1,11 +1,11 @@ #/usr/bin/env bash set -xeuo pipefail -archive_name=$OUTPUT\slipshow-$TARGETOS-$TARGETARCH.tar +archive_name=$OUTPUT\\slipshow-$TARGETOS-$TARGETARCH.tar dune subst dune build --profile release -p slipshow # Executables are symlinks, follow with -h. -tar hcf "$archive_name" -C _build\install\default bin\slipshow +tar hcf "$archive_name" -C _build\\install\\default bin\\slipshow From bee2215046d5928a437c195cc193bae7f2020fab Mon Sep 17 00:00:00 2001 From: coco-314 Date: Wed, 8 Apr 2026 16:52:33 +0200 Subject: [PATCH 08/59] Changes to path separator handling for the various target OS of the CI --- .github/workflows/build.yaml | 11 ++++++++--- release/release.sh | 4 ++-- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f97d4cbb..b1bbfc73 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -154,11 +154,16 @@ jobs: - name: Build release run: | - mkdir -p new_release - $env:OUTPUT = "$PWD\new_release" + # create release dir (PowerShell) + New-Item -ItemPath new_release -ItemType Directory -Force | Out-Null + + # build a forward-slash path for bash (e.g. C:/...) + $out = ($PWD.Path -replace '\\','/') + '/new_release' + $env:OUTPUT = $out $env:TARGETOS = "windows" $env:TARGETARCH = "${{ matrix.config.arch }}" - $env:VERSION = "$env:GITHUB_REF_NAME" + $env:VERSION = $env:GITHUB_REF_NAME + opam exec -- bash release/release.sh shell: pwsh diff --git a/release/release.sh b/release/release.sh index cc1cb045..f6dcf700 100644 --- a/release/release.sh +++ b/release/release.sh @@ -1,11 +1,11 @@ #/usr/bin/env bash set -xeuo pipefail -archive_name=$OUTPUT\\slipshow-$TARGETOS-$TARGETARCH.tar +archive_name=$OUTPUT/slipshow-$TARGETOS-$TARGETARCH.tar dune subst dune build --profile release -p slipshow # Executables are symlinks, follow with -h. -tar hcf "$archive_name" -C _build\\install\\default bin\\slipshow +tar hcf "$archive_name" -C _build/install/default bin/slipshow From 22faaad35c215668d04a9ec97114da3f69af1360 Mon Sep 17 00:00:00 2001 From: coco-314 Date: Wed, 8 Apr 2026 18:01:59 +0200 Subject: [PATCH 09/59] Fixes the creation of a folder in the CI Windows job --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index b1bbfc73..433d80c1 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -155,7 +155,7 @@ jobs: - name: Build release run: | # create release dir (PowerShell) - New-Item -ItemPath new_release -ItemType Directory -Force | Out-Null + New-Item -Path new_release -ItemType Directory -Force | Out-Null # build a forward-slash path for bash (e.g. C:/...) $out = ($PWD.Path -replace '\\','/') + '/new_release' From 67ec52c4878ef71df64fe09934ccf572e22a7d7a Mon Sep 17 00:00:00 2001 From: coco-314 Date: Wed, 8 Apr 2026 19:09:18 +0200 Subject: [PATCH 10/59] For debug --- .github/workflows/build.yaml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 433d80c1..541f026d 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -157,6 +157,19 @@ jobs: # create release dir (PowerShell) New-Item -Path new_release -ItemType Directory -Force | Out-Null + # Access right + $utilisateur = [System.Security.Principal.WindowsIdentity]::GetCurrent().Name + icacls new_release /grant $utilisateur":F" + + # pour debug + Write-Output "Utilisateur : $utilisateur" + Write-Output "Dossier new_release" + Write-Output "===================" + Get-Acl new_release + Write-Output "Contenu du dossier courant" + Write-Output "==========================" + Get-ChildItem + # build a forward-slash path for bash (e.g. C:/...) $out = ($PWD.Path -replace '\\','/') + '/new_release' $env:OUTPUT = $out From cb093ace022c2bc10790906776575ee7b6ad2f98 Mon Sep 17 00:00:00 2001 From: coco-314 Date: Wed, 8 Apr 2026 20:11:26 +0200 Subject: [PATCH 11/59] New try --- .github/workflows/build.yaml | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 541f026d..07d7572c 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -158,20 +158,11 @@ jobs: New-Item -Path new_release -ItemType Directory -Force | Out-Null # Access right - $utilisateur = [System.Security.Principal.WindowsIdentity]::GetCurrent().Name - icacls new_release /grant $utilisateur":F" - - # pour debug - Write-Output "Utilisateur : $utilisateur" - Write-Output "Dossier new_release" - Write-Output "===================" - Get-Acl new_release - Write-Output "Contenu du dossier courant" - Write-Output "==========================" - Get-ChildItem + #$utilisateur = [System.Security.Principal.WindowsIdentity]::GetCurrent().Name + #icacls new_release /grant $utilisateur":F" # build a forward-slash path for bash (e.g. C:/...) - $out = ($PWD.Path -replace '\\','/') + '/new_release' + $out = (($PWD.Path -replace '[\\]', '/') -replace '^([a-zA-Z]):', '/$1') + '/new_release' $env:OUTPUT = $out $env:TARGETOS = "windows" $env:TARGETARCH = "${{ matrix.config.arch }}" From aed85eddc446688ad3584ae641b7c27b20ce7d46 Mon Sep 17 00:00:00 2001 From: coco-314 Date: Thu, 9 Apr 2026 11:10:18 +0200 Subject: [PATCH 12/59] Windows distribution via a ZIP file --- .github/workflows/build.yaml | 39 +++++++++++++++++++++--------------- 1 file changed, 23 insertions(+), 16 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 07d7572c..0f7b1940 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -131,7 +131,7 @@ jobs: fail-fast: false matrix: config: - - { os: "windows-2022", arch: "x86_64", target: "x64" } + - { name: "windows", os: "windows-2022", arch: "x86_64", target: "x64" } ocaml-compiler: - 4.14.x runs-on: ${{ matrix.config.os }} @@ -152,30 +152,37 @@ jobs: - name: Install dependencies run: opam install --deps-only --with-test --with-doc -y . - - name: Build release + - name: Build Windows executable run: | - # create release dir (PowerShell) - New-Item -Path new_release -ItemType Directory -Force | Out-Null + opam exec -- dune build --profile release -p slipshow + # Copie l'exécutable dans un dossier dédié + mkdir -p new_release + cp _build/install/default/bin/slipshow.exe new_release/slipshow.exe - # Access right - #$utilisateur = [System.Security.Principal.WindowsIdentity]::GetCurrent().Name - #icacls new_release /grant $utilisateur":F" + - name: Verify executables + run: | + Test-Path _build/install/default/bin/slipshow.exe + Test-Path new_release/slipshow.exe - # build a forward-slash path for bash (e.g. C:/...) - $out = (($PWD.Path -replace '[\\]', '/') -replace '^([a-zA-Z]):', '/$1') + '/new_release' - $env:OUTPUT = $out - $env:TARGETOS = "windows" - $env:TARGETARCH = "${{ matrix.config.arch }}" - $env:VERSION = $env:GITHUB_REF_NAME + - name: Install 7-Zip + run: | + choco install 7zip -y - opam exec -- bash release/release.sh - shell: pwsh + - name: Create ZIP archive slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip + run: | + $zipPath = "${{ env.ProgramFiles }}\7-Zip\7z.exe" + if (Test-Path $zipPath) { + & $zipPath a -tzip new_release/slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip new_release/slipshow.exe + } else { + Write-Error "7-Zip is not installed in the expected location: $zipPath" + exit 1 + } - name: Upload archives uses: actions/upload-artifact@v4 with: name: archives-windows-${{ matrix.config.arch }} - path: new_release/* + path: new_release/*.zip release: if: startsWith(github.ref, 'refs/tags/') From f40b490ff72a16b397b6b01faa893adc7c0e3012 Mon Sep 17 00:00:00 2001 From: coco-314 Date: Thu, 9 Apr 2026 11:48:13 +0200 Subject: [PATCH 13/59] Using native PowerShell to create the ZIP archive --- .github/workflows/build.yaml | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 0f7b1940..9f508bae 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -155,7 +155,6 @@ jobs: - name: Build Windows executable run: | opam exec -- dune build --profile release -p slipshow - # Copie l'exécutable dans un dossier dédié mkdir -p new_release cp _build/install/default/bin/slipshow.exe new_release/slipshow.exe @@ -164,20 +163,9 @@ jobs: Test-Path _build/install/default/bin/slipshow.exe Test-Path new_release/slipshow.exe - - name: Install 7-Zip - run: | - choco install 7zip -y - - name: Create ZIP archive slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip - run: | - $zipPath = "${{ env.ProgramFiles }}\7-Zip\7z.exe" - if (Test-Path $zipPath) { - & $zipPath a -tzip new_release/slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip new_release/slipshow.exe - } else { - Write-Error "7-Zip is not installed in the expected location: $zipPath" - exit 1 - } - + run: Compress-Archive -Path new_release/slipshow.exe -DestinationPath new_release/slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip + - name: Upload archives uses: actions/upload-artifact@v4 with: From 7a7bf3372b5e899a48a35be0b094d424be31d673 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Thu, 9 Apr 2026 16:11:15 +0200 Subject: [PATCH 14/59] Test to see what is responsible for the windows CI problem --- .github/workflows/build.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 9f508bae..364ae57d 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -149,6 +149,9 @@ jobs: with: ocaml-compiler: ${{ matrix.ocaml-compiler }} + - name: Install something that triggers mingw-w64-shims recompilation + run: opam install conf-mingw-w64-gcc-i686 -y + - name: Install dependencies run: opam install --deps-only --with-test --with-doc -y . From b1f52bf58e0f8ddf5ed438845bac7c9e060866fb Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Thu, 9 Apr 2026 16:40:13 +0200 Subject: [PATCH 15/59] Windows CI: Only install x86_64 packages --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 364ae57d..2c346aa2 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -150,7 +150,7 @@ jobs: ocaml-compiler: ${{ matrix.ocaml-compiler }} - name: Install something that triggers mingw-w64-shims recompilation - run: opam install conf-mingw-w64-gcc-i686 -y + run: opam install conf-mingw-w64-gmp-x86_64 conf-mingw-w64-libffi-x86_64 conf-mingw-w64-openssl-x86_64 -y - name: Install dependencies run: opam install --deps-only --with-test --with-doc -y . From dd78b120310dc3e072156ba2ac9c20d603215147 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Thu, 9 Apr 2026 16:57:49 +0200 Subject: [PATCH 16/59] Test --- .github/workflows/build.yaml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 2c346aa2..90ac9929 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -147,10 +147,14 @@ jobs: - name: Install OCaml ${{ matrix.ocaml-compiler }} uses: ocaml/setup-ocaml@v3 with: - ocaml-compiler: ${{ matrix.ocaml-compiler }} - - - name: Install something that triggers mingw-w64-shims recompilation - run: opam install conf-mingw-w64-gmp-x86_64 conf-mingw-w64-libffi-x86_64 conf-mingw-w64-openssl-x86_64 -y + cache-prefix: v3 + ocaml-compiler: 4.14 + opam-pin: false + opam-repositories: | + default: https://github.com/punchagan/opam-repository.git#f1c70a26b442142ba1c3bd040bf8621060c94912 + + # - name: Install something that triggers mingw-w64-shims recompilation + # run: opam install conf-mingw-w64-gmp-x86_64 conf-mingw-w64-libffi-x86_64 conf-mingw-w64-openssl-x86_64 -y - name: Install dependencies run: opam install --deps-only --with-test --with-doc -y . From f01e5769745075f89de1e04c3544bc123d1fda8a Mon Sep 17 00:00:00 2001 From: coco-314 Date: Fri, 10 Apr 2026 11:11:30 +0200 Subject: [PATCH 17/59] Debugging --- .github/workflows/build.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 90ac9929..9667197d 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -167,8 +167,9 @@ jobs: - name: Verify executables run: | - Test-Path _build/install/default/bin/slipshow.exe - Test-Path new_release/slipshow.exe + Write-Output "Test new_release/slipshow.exe : $(Test-Path new_release/slipshow.exe) + Write-Output "Test _build/install/default/bin/slipshow.exe : $(Test-Path _build/install/default/bin/slipshow.exe) + Get-ChildItem -Path _build/install/default/bin - name: Create ZIP archive slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip run: Compress-Archive -Path new_release/slipshow.exe -DestinationPath new_release/slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip From 02d601009f3e4d9bb107755df4467b5b837a34ef Mon Sep 17 00:00:00 2001 From: coco-314 Date: Fri, 10 Apr 2026 11:39:05 +0200 Subject: [PATCH 18/59] fix debug --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 9667197d..c4432bac 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -167,8 +167,8 @@ jobs: - name: Verify executables run: | - Write-Output "Test new_release/slipshow.exe : $(Test-Path new_release/slipshow.exe) - Write-Output "Test _build/install/default/bin/slipshow.exe : $(Test-Path _build/install/default/bin/slipshow.exe) + Write-Output "Test new_release/slipshow.exe : $(Test-Path new_release/slipshow.exe)" + Write-Output "Test _build/install/default/bin/slipshow.exe : $(Test-Path _build/install/default/bin/slipshow.exe)" Get-ChildItem -Path _build/install/default/bin - name: Create ZIP archive slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip From 0a2b1ebce7d16e2feeeae07868060802604261eb Mon Sep 17 00:00:00 2001 From: coco-314 Date: Fri, 10 Apr 2026 12:47:00 +0200 Subject: [PATCH 19/59] dune install --- .github/workflows/build.yaml | 42 +++++++++++++++++++++++++----------- 1 file changed, 30 insertions(+), 12 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index c4432bac..08322819 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -159,21 +159,39 @@ jobs: - name: Install dependencies run: opam install --deps-only --with-test --with-doc -y . - - name: Build Windows executable + # - name: Build Windows executable + # run: | + # opam exec -- dune build --profile release -p slipshow + # mkdir -p new_release + # cp _build/install/default/bin/slipshow.exe new_release/slipshow.exe + + # - name: Verify executables + # run: | + # Write-Output "Test new_release/slipshow.exe : $(Test-Path new_release/slipshow.exe)" + # Write-Output "Test _build/install/default/bin/slipshow.exe : $(Test-Path _build/install/default/bin/slipshow.exe)" + # Get-ChildItem -Path _build/install/default/bin + + # - name: Create ZIP archive slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip + # run: Compress-Archive -Path new_release/slipshow.exe -DestinationPath new_release/slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip + + - name: Build installable artifacts + run: opam exec -- dune build --profile release @install + + - name: Install into relocatable bundle + run: opam exec -- dune install --relocatable --prefix ${{ github.workspace }}/bundle slipshow + + - name: Verify bundle run: | - opam exec -- dune build --profile release -p slipshow - mkdir -p new_release - cp _build/install/default/bin/slipshow.exe new_release/slipshow.exe - - - name: Verify executables + Write-Output "Test ${{ github.workspace }}/bundle : $(Test-Path ${{ github.workspace }}/bundle)" + Get-ChildItem -Path ${{ github.workspace }}/bundle + + - name: Prepare release directory run: | - Write-Output "Test new_release/slipshow.exe : $(Test-Path new_release/slipshow.exe)" - Write-Output "Test _build/install/default/bin/slipshow.exe : $(Test-Path _build/install/default/bin/slipshow.exe)" - Get-ChildItem -Path _build/install/default/bin - + New-Item -ItemType Directory -Force -Path new_release + - name: Create ZIP archive slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip - run: Compress-Archive -Path new_release/slipshow.exe -DestinationPath new_release/slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip - + run: Compress-Archive -Path ${{ github.workspace }}/bundle/* -DestinationPath new_release/slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip + - name: Upload archives uses: actions/upload-artifact@v4 with: From 9e4192a3d5c8cfce2f13bf77be18ae224847413e Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Fri, 10 Apr 2026 15:10:31 +0200 Subject: [PATCH 20/59] CI: Add a cache to windows CI --- .github/workflows/build.yaml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 08322819..8ee744be 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -144,6 +144,14 @@ jobs: - name: Fetch tags run: git fetch --tags --force origin + - uses: actions/cache@v5 + id: wincache + with: + path: | + ~/.opam + _opam + key: windows-${{ hashFiles('*.opam') }} + - name: Install OCaml ${{ matrix.ocaml-compiler }} uses: ocaml/setup-ocaml@v3 with: @@ -157,8 +165,13 @@ jobs: # run: opam install conf-mingw-w64-gmp-x86_64 conf-mingw-w64-libffi-x86_64 conf-mingw-w64-openssl-x86_64 -y - name: Install dependencies + if: steps.wincache.outputs.cache-hit != 'true' run: opam install --deps-only --with-test --with-doc -y . + - name: Install dependencies + if: steps.wincache.outputs.cache-hit + run: opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade + # - name: Build Windows executable # run: | # opam exec -- dune build --profile release -p slipshow From d12df1e29f5b6d769f0ed563a13a96cf312303c0 Mon Sep 17 00:00:00 2001 From: coco-314 Date: Sun, 12 Apr 2026 15:57:17 +0200 Subject: [PATCH 21/59] Copy missing dlls inti bundle --- .github/workflows/build.yaml | 36 +++++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 8ee744be..18d4ca4d 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -188,7 +188,7 @@ jobs: # run: Compress-Archive -Path new_release/slipshow.exe -DestinationPath new_release/slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip - name: Build installable artifacts - run: opam exec -- dune build --profile release @install + run: opam exec -- dune build --profile release @install --ignore-promoted-rules - name: Install into relocatable bundle run: opam exec -- dune install --relocatable --prefix ${{ github.workspace }}/bundle slipshow @@ -198,6 +198,40 @@ jobs: Write-Output "Test ${{ github.workspace }}/bundle : $(Test-Path ${{ github.workspace }}/bundle)" Get-ChildItem -Path ${{ github.workspace }}/bundle + - name: Copy missing DLLs into "${{ github.workspace }}\bundle\bin" + shell: pwsh + run: | + $bundleBin = "${{ github.workspace }}\bundle\bin" + $exe = "$bundleBin\slipshow.exe" + + # Searches for DLLs in the typical Cygwin locations managed by OPAM + $searchRoots = @( + "$env:LOCALAPPDATA\opam\.cygwin\usr\bin", + "$env:LOCALAPPDATA\opam\.cygwin\bin", + "$env:LOCALAPPDATA\opam\.cygwin\root\usr\x86_64-w64-mingw32\sys-root\mingw\bin", + "C:\cygwin64\bin", + "C:\msys64\usr\bin", + "C:\msys64\mingw64\bin" + ) + ($env:PATH -split ";") + + # List of DLLs to copy + $dlls = @( + "libcrypto-3.dll", + "libssl-3.dll", + "zlib1.dll" + ) + + foreach ($dll in $dlls) { + foreach ($root in $searchRoots) { + $candidate = Join-Path $root $dll + if (Test-Path $candidate) { + Write-Output "Copying $candidate -> $bundleBin" + Copy-Item $candidate $bundleBin -Force + break + } + } + } + - name: Prepare release directory run: | New-Item -ItemType Directory -Force -Path new_release From 5e2ccf205ba1090757badc746b8184fef9da2c0d Mon Sep 17 00:00:00 2001 From: coco-314 Date: Thu, 23 Apr 2026 11:22:11 +0200 Subject: [PATCH 22/59] Instal opensll and zlib --- .github/workflows/build.yaml | 86 ++++++++++++++++-------------------- 1 file changed, 38 insertions(+), 48 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 18d4ca4d..80efe72e 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -164,6 +164,12 @@ jobs: # - name: Install something that triggers mingw-w64-shims recompilation # run: opam install conf-mingw-w64-gmp-x86_64 conf-mingw-w64-libffi-x86_64 conf-mingw-w64-openssl-x86_64 -y + - name: Install system dependencies + run: | + opam depext conf-openssl conf-zlib -y + # On s'assure que les paquets sont bien là pour la compilation + opam install conf-openssl conf-zlib -y + - name: Install dependencies if: steps.wincache.outputs.cache-hit != 'true' run: opam install --deps-only --with-test --with-doc -y . @@ -172,65 +178,49 @@ jobs: if: steps.wincache.outputs.cache-hit run: opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade - # - name: Build Windows executable - # run: | - # opam exec -- dune build --profile release -p slipshow - # mkdir -p new_release - # cp _build/install/default/bin/slipshow.exe new_release/slipshow.exe - - # - name: Verify executables - # run: | - # Write-Output "Test new_release/slipshow.exe : $(Test-Path new_release/slipshow.exe)" - # Write-Output "Test _build/install/default/bin/slipshow.exe : $(Test-Path _build/install/default/bin/slipshow.exe)" - # Get-ChildItem -Path _build/install/default/bin - - # - name: Create ZIP archive slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip - # run: Compress-Archive -Path new_release/slipshow.exe -DestinationPath new_release/slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip - - name: Build installable artifacts - run: opam exec -- dune build --profile release @install --ignore-promoted-rules - + # run: opam exec -- dune build --profile release @install --ignore-promoted-rules + run: opam exec -- dune build --profile release @install + - name: Install into relocatable bundle run: opam exec -- dune install --relocatable --prefix ${{ github.workspace }}/bundle slipshow - - name: Verify bundle + - name: Verify "${{ github.workspace }}\bundle" run: | Write-Output "Test ${{ github.workspace }}/bundle : $(Test-Path ${{ github.workspace }}/bundle)" Get-ChildItem -Path ${{ github.workspace }}/bundle - - - name: Copy missing DLLs into "${{ github.workspace }}\bundle\bin" + + - name: Copy DLLs into bundle shell: pwsh run: | $bundleBin = "${{ github.workspace }}\bundle\bin" - $exe = "$bundleBin\slipshow.exe" - - # Searches for DLLs in the typical Cygwin locations managed by OPAM - $searchRoots = @( - "$env:LOCALAPPDATA\opam\.cygwin\usr\bin", - "$env:LOCALAPPDATA\opam\.cygwin\bin", - "$env:LOCALAPPDATA\opam\.cygwin\root\usr\x86_64-w64-mingw32\sys-root\mingw\bin", - "C:\cygwin64\bin", - "C:\msys64\usr\bin", - "C:\msys64\mingw64\bin" - ) + ($env:PATH -split ";") - - # List of DLLs to copy - $dlls = @( - "libcrypto-3.dll", - "libssl-3.dll", - "zlib1.dll" - ) - - foreach ($dll in $dlls) { - foreach ($root in $searchRoots) { - $candidate = Join-Path $root $dll - if (Test-Path $candidate) { - Write-Output "Copying $candidate -> $bundleBin" - Copy-Item $candidate $bundleBin -Force - break + + # On récupère le chemin racine de Cygwin/MSYS2 utilisé par opam + $cygwinBin = opam var cygwin:root | Join-Path -ChildPath "bin" + $mingwBin = opam var cygwin:root | Join-Path -ChildPath "usr\x86_64-w64-mingw32\sys-root\mingw\bin" + + $searchPaths = @($cygwinBin, $mingwBin) + ($env:PATH -split ";") + + # Patterns pour matcher les DLL (OpenSSL 3 utilise souvent des suffixes) + $dllPatterns = @("libcrypto-3*.dll", "libssl-3*.dll", "zlib1.dll") + + foreach ($pattern in $dllPatterns) { + $found = $false + foreach ($path in $searchPaths) { + if (Test-Path $path) { + $dllFile = Get-ChildItem -Path $path -Filter $pattern | Select-Object -First 1 + if ($dllFile) { + Write-Output "Found $($dllFile.FullName), copying to $bundleBin" + Copy-Item $dllFile.FullName $bundleBin -Force + $found = $true + break + } + } + } + if (-not $found) { + Write-Warning "Could not find DLL for pattern $pattern" } - } - } + } - name: Prepare release directory run: | From d9734d6acb0521c3c2e5c8880186547363130409 Mon Sep 17 00:00:00 2001 From: coco-314 Date: Thu, 23 Apr 2026 11:46:43 +0200 Subject: [PATCH 23/59] Fix Build installable artifacts --- .github/workflows/build.yaml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 80efe72e..82d31dbe 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -179,8 +179,7 @@ jobs: run: opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade - name: Build installable artifacts - # run: opam exec -- dune build --profile release @install --ignore-promoted-rules - run: opam exec -- dune build --profile release @install + run: opam exec -- dune build --profile release @install --ignore-promoted-rules - name: Install into relocatable bundle run: opam exec -- dune install --relocatable --prefix ${{ github.workspace }}/bundle slipshow From 9393f67ff68dddfabd0145ef932efa5ea235c317 Mon Sep 17 00:00:00 2001 From: coco-314 Date: Thu, 23 Apr 2026 14:33:39 +0200 Subject: [PATCH 24/59] Test ntldd --- .github/workflows/build.yaml | 45 ++++++++++++++---------------------- 1 file changed, 17 insertions(+), 28 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 82d31dbe..819f2e46 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -189,37 +189,26 @@ jobs: Write-Output "Test ${{ github.workspace }}/bundle : $(Test-Path ${{ github.workspace }}/bundle)" Get-ChildItem -Path ${{ github.workspace }}/bundle - - name: Copy DLLs into bundle + - name: Copy required DLLs using ntldd shell: pwsh run: | $bundleBin = "${{ github.workspace }}\bundle\bin" - - # On récupère le chemin racine de Cygwin/MSYS2 utilisé par opam - $cygwinBin = opam var cygwin:root | Join-Path -ChildPath "bin" - $mingwBin = opam var cygwin:root | Join-Path -ChildPath "usr\x86_64-w64-mingw32\sys-root\mingw\bin" - - $searchPaths = @($cygwinBin, $mingwBin) + ($env:PATH -split ";") - - # Patterns pour matcher les DLL (OpenSSL 3 utilise souvent des suffixes) - $dllPatterns = @("libcrypto-3*.dll", "libssl-3*.dll", "zlib1.dll") - - foreach ($pattern in $dllPatterns) { - $found = $false - foreach ($path in $searchPaths) { - if (Test-Path $path) { - $dllFile = Get-ChildItem -Path $path -Filter $pattern | Select-Object -First 1 - if ($dllFile) { - Write-Output "Found $($dllFile.FullName), copying to $bundleBin" - Copy-Item $dllFile.FullName $bundleBin -Force - $found = $true - break - } - } - } - if (-not $found) { - Write-Warning "Could not find DLL for pattern $pattern" - } - } + $binary = "$bundleBin\slipshow.exe" + + # ntldd est disponible dans l'environnement mingw d'opam + $ntldd = (opam exec -- where ntldd 2>$null) ?? "ntldd" + Write-Output "ntldd = $ntldd" + + # Liste les DLLs non-système requises par le binaire + $deps = & $ntldd --recursive $binary 2>$null ` + | Where-Object { $_ -match "=> (.+\.dll)" -and $_ -notmatch "not found" } ` + | ForEach-Object { $matches[1].Trim() } ` + | Where-Object { $_ -notmatch "^(C:\\Windows|WINDOWS)" } + + foreach ($dll in $deps) { + Write-Output "Copying $dll" + Copy-Item $dll $bundleBin -Force -ErrorAction SilentlyContinue + } - name: Prepare release directory run: | From 94b3fb853c143ab65acb180c77e013ef67de42eb Mon Sep 17 00:00:00 2001 From: coco-314 Date: Thu, 23 Apr 2026 15:29:12 +0200 Subject: [PATCH 25/59] Copy dlls --- .github/workflows/build.yaml | 27 ++++++++++++--------------- 1 file changed, 12 insertions(+), 15 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 819f2e46..2db2d4e5 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -189,25 +189,22 @@ jobs: Write-Output "Test ${{ github.workspace }}/bundle : $(Test-Path ${{ github.workspace }}/bundle)" Get-ChildItem -Path ${{ github.workspace }}/bundle - - name: Copy required DLLs using ntldd + - name: Copy required DLLs shell: pwsh run: | $bundleBin = "${{ github.workspace }}\bundle\bin" $binary = "$bundleBin\slipshow.exe" - - # ntldd est disponible dans l'environnement mingw d'opam - $ntldd = (opam exec -- where ntldd 2>$null) ?? "ntldd" - Write-Output "ntldd = $ntldd" - - # Liste les DLLs non-système requises par le binaire - $deps = & $ntldd --recursive $binary 2>$null ` - | Where-Object { $_ -match "=> (.+\.dll)" -and $_ -notmatch "not found" } ` - | ForEach-Object { $matches[1].Trim() } ` - | Where-Object { $_ -notmatch "^(C:\\Windows|WINDOWS)" } - - foreach ($dll in $deps) { - Write-Output "Copying $dll" - Copy-Item $dll $bundleBin -Force -ErrorAction SilentlyContinue + $dlls = @("zlib1.dll", "libssl-3.dll", "libcrypto-3.dll") + + foreach ($dll in $dlls) { + $sourceFile = Get-ChildItem "$env:LOCALAPPDATA\opam\.cygwin" -Recurse -Filter $dll | + Select-Object -First 1 -ExpandProperty FullName + if (($null -ne $sourceFile) -and (Test-Path $sourceFile)) { + Copy-Item $sourceFile $bundleBin -Force + Write-Host "Library $dll copied to $bundleBin" + } else { + Write-Warning "Library $dll cannot be found : $sourceFile" + } } - name: Prepare release directory From e11736fec93bade0148d7bfd57a4b71d7dd45c02 Mon Sep 17 00:00:00 2001 From: coco-314 Date: Fri, 24 Apr 2026 13:00:21 +0200 Subject: [PATCH 26/59] Copy dlls --- .github/workflows/build.yaml | 52 ++++++++++++++++++++++++++++++------ 1 file changed, 44 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 2db2d4e5..d56ec203 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -188,23 +188,59 @@ jobs: run: | Write-Output "Test ${{ github.workspace }}/bundle : $(Test-Path ${{ github.workspace }}/bundle)" Get-ChildItem -Path ${{ github.workspace }}/bundle - - - name: Copy required DLLs + + - name: Copy required DLLs into "${{ github.workspace }}\bundle\bin" shell: pwsh run: | $bundleBin = "${{ github.workspace }}\bundle\bin" - $binary = "$bundleBin\slipshow.exe" - $dlls = @("zlib1.dll", "libssl-3.dll", "libcrypto-3.dll") - + $exe = "$bundleBin\slipshow.exe" + + # Retrieve cygwin installation folder + $cygwinpath = opam var cygwin:root + if ($null -eq $cygwinpath ) { $cygwinpath = "$env:LOCALAPPDATA\opam\.cygwin" } + Write-host "cygwinpath = $cygwinpath" + + # Searches for DLLs in the typical Cygwin locations managed by OPAM + $searchRoots = @( + "C:\cygwin64\bin", + "C:\msys64\usr\bin", + "C:\msys64\mingw64\bin" + ) + ($env:PATH -split ";") + + # List of DLLs to copy + $dlls = @( + "libcrypto-3.dll", + "libssl-3.dll", + "zlib1.dll" + ) + foreach ($dll in $dlls) { - $sourceFile = Get-ChildItem "$env:LOCALAPPDATA\opam\.cygwin" -Recurse -Filter $dll | + $found = $false + if (Test-Path $cygwinpath) { + $sourceFile = Get-ChildItem $cygwinpath -Recurse -Filter $dll | Select-Object -First 1 -ExpandProperty FullName if (($null -ne $sourceFile) -and (Test-Path $sourceFile)) { + Copy-Item $sourceFile $bundleBin -Force + Write-Host "Library $dll copied to $bundleBin" + $found = $true + } + } + + if (-not $found) { + foreach ($root in $searchRoots) { + $sourceFile = Join-Path $root $dll + if (Test-Path $sourceFile) { Copy-Item $sourceFile $bundleBin -Force Write-Host "Library $dll copied to $bundleBin" - } else { - Write-Warning "Library $dll cannot be found : $sourceFile" + $found = $true + break + } } + } + + if (-not $found) { + Write-Warning "Could not find library $dll" + } } - name: Prepare release directory From 98303a0872945a15f910694b4bee5e9b3b65b047 Mon Sep 17 00:00:00 2001 From: coco-314 Date: Fri, 24 Apr 2026 13:58:13 +0200 Subject: [PATCH 27/59] Try installer Oui --- .github/workflows/build.yaml | 76 ++++++++++++++++++++++++++++++------ 1 file changed, 64 insertions(+), 12 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index d56ec203..52c55d81 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -195,9 +195,8 @@ jobs: $bundleBin = "${{ github.workspace }}\bundle\bin" $exe = "$bundleBin\slipshow.exe" - # Retrieve cygwin installation folder - $cygwinpath = opam var cygwin:root - if ($null -eq $cygwinpath ) { $cygwinpath = "$env:LOCALAPPDATA\opam\.cygwin" } + # Retrieve Cygwin folder + $cygwinpath = "$env:LOCALAPPDATA\opam\.cygwin" Write-host "cygwinpath = $cygwinpath" # Searches for DLLs in the typical Cygwin locations managed by OPAM @@ -216,22 +215,25 @@ jobs: foreach ($dll in $dlls) { $found = $false + + # Try to find the dll into typical Cygwin locations if (Test-Path $cygwinpath) { $sourceFile = Get-ChildItem $cygwinpath -Recurse -Filter $dll | Select-Object -First 1 -ExpandProperty FullName if (($null -ne $sourceFile) -and (Test-Path $sourceFile)) { Copy-Item $sourceFile $bundleBin -Force - Write-Host "Library $dll copied to $bundleBin" + Write-Host "Library $dll copied from $sourceFile to $bundleBin" $found = $true } } if (-not $found) { + # Try to find the dll into the Cygwin folder foreach ($root in $searchRoots) { $sourceFile = Join-Path $root $dll if (Test-Path $sourceFile) { Copy-Item $sourceFile $bundleBin -Force - Write-Host "Library $dll copied to $bundleBin" + Write-Host "Library $dll copied from $sourceFile to $bundleBin" $found = $true break } @@ -243,18 +245,68 @@ jobs: } } - - name: Prepare release directory - run: | - New-Item -ItemType Directory -Force -Path new_release + # - name: Prepare release directory + # run: | + # New-Item -ItemType Directory -Force -Path new_release - - name: Create ZIP archive slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip - run: Compress-Archive -Path ${{ github.workspace }}/bundle/* -DestinationPath new_release/slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip + # - name: Create ZIP archive slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip + # run: Compress-Archive -Path ${{ github.workspace }}/bundle/* -DestinationPath new_release/slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip - - name: Upload archives + # - name: Upload archives + # uses: actions/upload-artifact@v4 + # with: + # name: archives-windows-${{ matrix.config.arch }} + # path: new_release/*.zip + + - name: Install WiX 6 (required by OUI for Windows MSI) + shell: pwsh + run: | + $wixVersion = "6.0.2" + $wixUrl = "https://github.com/wixtoolset/wix/releases/download/v${wixVersion}/wix-${wixVersion}-x64.exe" + $installer = "$env:TEMP\wix-installer.exe" + Invoke-WebRequest -Uri $wixUrl -OutFile $installer + Start-Process -FilePath $installer -ArgumentList "/quiet" -Wait + # Ajouter WiX au PATH pour la session courante + $wixPath = "$env:ProgramFiles\WiX Toolset v6.0\bin" + echo "$wixPath" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append + + - name: Install OUI via opam + run: opam install oui -y + + - name: Write oui.json + shell: pwsh + run: | + # Récupérer la version depuis le tag git (ex: v1.2.3 → 1.2.3) + $version = (git describe --tags --abbrev=0 2>$null) -replace '^v', '' + # WiX exige major.minor.patch strictement numériques ; fallback sur 0.0.1 + if ($version -notmatch '^\d+\.\d+\.\d+$') { $version = "0.0.1" } + $config = @{ + name = "slipshow" + fullname = "Slipshow" + version = $version + unique_id = "com.slipshow.slipshow" + wix_manufacturer = "Paul-Elliot" + wix_description = "Slipshow is an engine to write slips, a concept evolved from slides." + exec_files = @("bin/slipshow.exe") + } + $config | ConvertTo-Json -Depth 5 | Set-Content oui.json -Encoding UTF8 + Write-Host "oui.json generated:" + Get-Content oui.json + + - name: Lint oui.json + run: opam exec -- oui lint oui.json ${{ github.workspace }}/bundle + + - name: Generate MSI installer with OUI + run: | + New-Item -ItemType Directory -Force -Path new_release + opam exec -- oui build oui.json ${{ github.workspace }}/bundle --output-dir ${{ github.workspace }}/new_release + shell: pwsh + + - name: Upload installer uses: actions/upload-artifact@v4 with: name: archives-windows-${{ matrix.config.arch }} - path: new_release/*.zip + path: new_release/*.msi release: if: startsWith(github.ref, 'refs/tags/') From e9cc78018aad55ab11d0ae52bd7beb1f180c723e Mon Sep 17 00:00:00 2001 From: coco-314 Date: Fri, 24 Apr 2026 14:56:16 +0200 Subject: [PATCH 28/59] Try Wix installation witrh dotnet --- .github/workflows/build.yaml | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 52c55d81..a4fb4555 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -261,14 +261,12 @@ jobs: - name: Install WiX 6 (required by OUI for Windows MSI) shell: pwsh run: | - $wixVersion = "6.0.2" - $wixUrl = "https://github.com/wixtoolset/wix/releases/download/v${wixVersion}/wix-${wixVersion}-x64.exe" - $installer = "$env:TEMP\wix-installer.exe" - Invoke-WebRequest -Uri $wixUrl -OutFile $installer - Start-Process -FilePath $installer -ArgumentList "/quiet" -Wait - # Ajouter WiX au PATH pour la session courante - $wixPath = "$env:ProgramFiles\WiX Toolset v6.0\bin" - echo "$wixPath" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append + dotnet tool install --global wix --version 6.0.2 + + # Ajouter le dossier des outils .NET globaux au PATH + $dotnetToolsPath = "$env:USERPROFILE\.dotnet\tools" + echo "$dotnetToolsPath" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append + Write-Host "WiX installed, tools path: $dotnetToolsPath" - name: Install OUI via opam run: opam install oui -y From 61bbca2dab9b29fa81d7f9054d39e25043b1871e Mon Sep 17 00:00:00 2001 From: coco-314 Date: Fri, 24 Apr 2026 15:22:09 +0200 Subject: [PATCH 29/59] Fix oui installation --- .github/workflows/build.yaml | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index a4fb4555..d8635b9b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -184,7 +184,7 @@ jobs: - name: Install into relocatable bundle run: opam exec -- dune install --relocatable --prefix ${{ github.workspace }}/bundle slipshow - - name: Verify "${{ github.workspace }}\bundle" + - name: Debug - Verify "${{ github.workspace }}\bundle" run: | Write-Output "Test ${{ github.workspace }}/bundle : $(Test-Path ${{ github.workspace }}/bundle)" Get-ChildItem -Path ${{ github.workspace }}/bundle @@ -268,16 +268,19 @@ jobs: echo "$dotnetToolsPath" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append Write-Host "WiX installed, tools path: $dotnetToolsPath" - - name: Install OUI via opam - run: opam install oui -y + # - name: Install OUI via opam + # run: opam install oui -y + - name: Install OUI via opam (depuis les sources) + run: opam pin add oui https://github.com/OCamlPro/ocaml-universal-installer.git#master --no-action -y && opam install oui -y - name: Write oui.json shell: pwsh run: | - # Récupérer la version depuis le tag git (ex: v1.2.3 → 1.2.3) + # Récupérer la version depuis le tag git (ex: v1.2.3 → 1.2.3) + WiX exige major.minor.patch strictement numériques ; fallback sur 0.0.1 $version = (git describe --tags --abbrev=0 2>$null) -replace '^v', '' - # WiX exige major.minor.patch strictement numériques ; fallback sur 0.0.1 - if ($version -notmatch '^\d+\.\d+\.\d+$') { $version = "0.0.1" } + if (($version -eq $null) -ot ($version -notmatch '^\d+\.\d+\.\d+$')) { $version = "0.0.1" } + Write-host "version = $version" + $config = @{ name = "slipshow" fullname = "Slipshow" @@ -300,6 +303,11 @@ jobs: opam exec -- oui build oui.json ${{ github.workspace }}/bundle --output-dir ${{ github.workspace }}/new_release shell: pwsh + - name: Debug - Verify "${{ github.workspace }}/new_release" + run: | + Write-Output "Test ${{ github.workspace }}/new_release : $(Test-Path ${{ github.workspace }}/new_release)" + Get-ChildItem -Path ${{ github.workspace }}/new_release + - name: Upload installer uses: actions/upload-artifact@v4 with: From a5fd3a9f0cf7aa4e23c55b822cc5e8f22c50204b Mon Sep 17 00:00:00 2001 From: coco-314 Date: Fri, 24 Apr 2026 17:46:12 +0200 Subject: [PATCH 30/59] Use WIX --- .github/workflows/build.yaml | 126 +++++++++++++++++++++++++++-------- 1 file changed, 97 insertions(+), 29 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index d8635b9b..b3a5eb3f 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -270,43 +270,111 @@ jobs: # - name: Install OUI via opam # run: opam install oui -y - - name: Install OUI via opam (depuis les sources) - run: opam pin add oui https://github.com/OCamlPro/ocaml-universal-installer.git#master --no-action -y && opam install oui -y + # - name: Install OUI via opam (depuis les sources) + # run: opam pin add oui https://github.com/OCamlPro/ocaml-universal-installer.git#master --no-action -y && opam install oui -y - - name: Write oui.json + # - name: Write oui.json + # shell: pwsh + # run: | + # # Récupérer la version depuis le tag git (ex: v1.2.3 → 1.2.3) + WiX exige major.minor.patch strictement numériques ; fallback sur 0.0.1 + # $version = (git describe --tags --abbrev=0 2>$null) -replace '^v', '' + # if (($version -eq $null) -ot ($version -notmatch '^\d+\.\d+\.\d+$')) { $version = "0.0.1" } + # Write-host "version = $version" + + # $config = @{ + # name = "slipshow" + # fullname = "Slipshow" + # version = $version + # unique_id = "com.slipshow.slipshow" + # wix_manufacturer = "Paul-Elliot" + # wix_description = "Slipshow is an engine to write slips, a concept evolved from slides." + # exec_files = @("bin/slipshow.exe") + # } + # $config | ConvertTo-Json -Depth 5 | Set-Content oui.json -Encoding UTF8 + # Write-Host "oui.json generated:" + # Get-Content oui.json + + # - name: Lint oui.json + # run: opam exec -- oui lint oui.json ${{ github.workspace }}/bundle + + # - name: Generate MSI installer with OUI + # run: | + # New-Item -ItemType Directory -Force -Path new_release + # opam exec -- oui build oui.json ${{ github.workspace }}/bundle --output-dir ${{ github.workspace }}/new_release + # shell: pwsh + + # - name: Debug - Verify "${{ github.workspace }}/new_release" + # run: | + # Write-Output "Test ${{ github.workspace }}/new_release : $(Test-Path ${{ github.workspace }}/new_release)" + # Get-ChildItem -Path ${{ github.workspace }}/new_release + + - name: Prepare release directory + shell: pwsh + run: New-Item -ItemType Directory -Force -Path new_release + + - name: Get version from git tag + id: version shell: pwsh run: | - # Récupérer la version depuis le tag git (ex: v1.2.3 → 1.2.3) + WiX exige major.minor.patch strictement numériques ; fallback sur 0.0.1 $version = (git describe --tags --abbrev=0 2>$null) -replace '^v', '' - if (($version -eq $null) -ot ($version -notmatch '^\d+\.\d+\.\d+$')) { $version = "0.0.1" } - Write-host "version = $version" - - $config = @{ - name = "slipshow" - fullname = "Slipshow" - version = $version - unique_id = "com.slipshow.slipshow" - wix_manufacturer = "Paul-Elliot" - wix_description = "Slipshow is an engine to write slips, a concept evolved from slides." - exec_files = @("bin/slipshow.exe") - } - $config | ConvertTo-Json -Depth 5 | Set-Content oui.json -Encoding UTF8 - Write-Host "oui.json generated:" - Get-Content oui.json + if ($version -notmatch '^\d+\.\d+\.\d+$') { $version = "0.0.1" } + echo "VERSION=$version" | Out-File -FilePath $env:GITHUB_OUTPUT -Encoding utf8 -Append + Write-Host "Version: $version" - - name: Lint oui.json - run: opam exec -- oui lint oui.json ${{ github.workspace }}/bundle - - - name: Generate MSI installer with OUI + - name: Write WiX source file (slipshow.wxs) + shell: pwsh run: | - New-Item -ItemType Directory -Force -Path new_release - opam exec -- oui build oui.json ${{ github.workspace }}/bundle --output-dir ${{ github.workspace }}/new_release + $version = "${{ steps.version.outputs.VERSION }}" + $bundle = "${{ github.workspace }}\bundle" + + # Générer la liste des fichiers du bundle + $files = Get-ChildItem -Path "$bundle\bin" -File + $fileEntries = ($files | ForEach-Object { + $id = $_.Name -replace '[^a-zA-Z0-9]', '_' + " " + }) -join "`n" + + $wxs = @" + + + + + + + + + + + + + + + $fileEntries + + + + + + + + "@ + + $wxs | Set-Content slipshow.wxs -Encoding UTF8 + Write-Host "slipshow.wxs generated" + Get-Content slipshow.wxs + + - name: Build MSI with WiX shell: pwsh - - - name: Debug - Verify "${{ github.workspace }}/new_release" run: | - Write-Output "Test ${{ github.workspace }}/new_release : $(Test-Path ${{ github.workspace }}/new_release)" - Get-ChildItem -Path ${{ github.workspace }}/new_release + $version = "${{ steps.version.outputs.VERSION }}" + wix build slipshow.wxs -o "new_release\slipshow-windows-x64-${version}.msi" + Write-Host "MSI generated:" + Get-ChildItem new_release - name: Upload installer uses: actions/upload-artifact@v4 From 7f1d3a65f671d64f0521ffe93d2f68b68f14706a Mon Sep 17 00:00:00 2001 From: coco-314 Date: Sat, 25 Apr 2026 10:08:17 +0200 Subject: [PATCH 31/59] Comment version getter --- .github/workflows/build.yaml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index b3a5eb3f..b4c94c77 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -313,11 +313,13 @@ jobs: run: New-Item -ItemType Directory -Force -Path new_release - name: Get version from git tag + continue-on-error: true id: version shell: pwsh run: | - $version = (git describe --tags --abbrev=0 2>$null) -replace '^v', '' - if ($version -notmatch '^\d+\.\d+\.\d+$') { $version = "0.0.1" } + # $version = (git describe --tags --abbrev=0 2>$null) -replace '^v', '' + # if ($version -notmatch '^\d+\.\d+\.\d+$') { $version = "0.0.1" } + $version = "0.0.1" echo "VERSION=$version" | Out-File -FilePath $env:GITHUB_OUTPUT -Encoding utf8 -Append Write-Host "Version: $version" From ea4a88f8ca69f70b5405ed1dc1100d0c652f6143 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 10:38:20 +0200 Subject: [PATCH 32/59] Start from a simplified workflow file --- .github/workflows/build.yaml | 216 +---------------------------------- 1 file changed, 2 insertions(+), 214 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index b4c94c77..f64c450b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -161,15 +161,6 @@ jobs: opam-repositories: | default: https://github.com/punchagan/opam-repository.git#f1c70a26b442142ba1c3bd040bf8621060c94912 - # - name: Install something that triggers mingw-w64-shims recompilation - # run: opam install conf-mingw-w64-gmp-x86_64 conf-mingw-w64-libffi-x86_64 conf-mingw-w64-openssl-x86_64 -y - - - name: Install system dependencies - run: | - opam depext conf-openssl conf-zlib -y - # On s'assure que les paquets sont bien là pour la compilation - opam install conf-openssl conf-zlib -y - - name: Install dependencies if: steps.wincache.outputs.cache-hit != 'true' run: opam install --deps-only --with-test --with-doc -y . @@ -178,211 +169,8 @@ jobs: if: steps.wincache.outputs.cache-hit run: opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade - - name: Build installable artifacts - run: opam exec -- dune build --profile release @install --ignore-promoted-rules - - - name: Install into relocatable bundle - run: opam exec -- dune install --relocatable --prefix ${{ github.workspace }}/bundle slipshow - - - name: Debug - Verify "${{ github.workspace }}\bundle" - run: | - Write-Output "Test ${{ github.workspace }}/bundle : $(Test-Path ${{ github.workspace }}/bundle)" - Get-ChildItem -Path ${{ github.workspace }}/bundle - - - name: Copy required DLLs into "${{ github.workspace }}\bundle\bin" - shell: pwsh - run: | - $bundleBin = "${{ github.workspace }}\bundle\bin" - $exe = "$bundleBin\slipshow.exe" - - # Retrieve Cygwin folder - $cygwinpath = "$env:LOCALAPPDATA\opam\.cygwin" - Write-host "cygwinpath = $cygwinpath" - - # Searches for DLLs in the typical Cygwin locations managed by OPAM - $searchRoots = @( - "C:\cygwin64\bin", - "C:\msys64\usr\bin", - "C:\msys64\mingw64\bin" - ) + ($env:PATH -split ";") - - # List of DLLs to copy - $dlls = @( - "libcrypto-3.dll", - "libssl-3.dll", - "zlib1.dll" - ) - - foreach ($dll in $dlls) { - $found = $false - - # Try to find the dll into typical Cygwin locations - if (Test-Path $cygwinpath) { - $sourceFile = Get-ChildItem $cygwinpath -Recurse -Filter $dll | - Select-Object -First 1 -ExpandProperty FullName - if (($null -ne $sourceFile) -and (Test-Path $sourceFile)) { - Copy-Item $sourceFile $bundleBin -Force - Write-Host "Library $dll copied from $sourceFile to $bundleBin" - $found = $true - } - } - - if (-not $found) { - # Try to find the dll into the Cygwin folder - foreach ($root in $searchRoots) { - $sourceFile = Join-Path $root $dll - if (Test-Path $sourceFile) { - Copy-Item $sourceFile $bundleBin -Force - Write-Host "Library $dll copied from $sourceFile to $bundleBin" - $found = $true - break - } - } - } - - if (-not $found) { - Write-Warning "Could not find library $dll" - } - } - - # - name: Prepare release directory - # run: | - # New-Item -ItemType Directory -Force -Path new_release - - # - name: Create ZIP archive slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip - # run: Compress-Archive -Path ${{ github.workspace }}/bundle/* -DestinationPath new_release/slipshow-${{ matrix.config.name }}-${{ matrix.config.target }}.zip - - # - name: Upload archives - # uses: actions/upload-artifact@v4 - # with: - # name: archives-windows-${{ matrix.config.arch }} - # path: new_release/*.zip - - - name: Install WiX 6 (required by OUI for Windows MSI) - shell: pwsh - run: | - dotnet tool install --global wix --version 6.0.2 - - # Ajouter le dossier des outils .NET globaux au PATH - $dotnetToolsPath = "$env:USERPROFILE\.dotnet\tools" - echo "$dotnetToolsPath" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append - Write-Host "WiX installed, tools path: $dotnetToolsPath" - - # - name: Install OUI via opam - # run: opam install oui -y - # - name: Install OUI via opam (depuis les sources) - # run: opam pin add oui https://github.com/OCamlPro/ocaml-universal-installer.git#master --no-action -y && opam install oui -y - - # - name: Write oui.json - # shell: pwsh - # run: | - # # Récupérer la version depuis le tag git (ex: v1.2.3 → 1.2.3) + WiX exige major.minor.patch strictement numériques ; fallback sur 0.0.1 - # $version = (git describe --tags --abbrev=0 2>$null) -replace '^v', '' - # if (($version -eq $null) -ot ($version -notmatch '^\d+\.\d+\.\d+$')) { $version = "0.0.1" } - # Write-host "version = $version" - - # $config = @{ - # name = "slipshow" - # fullname = "Slipshow" - # version = $version - # unique_id = "com.slipshow.slipshow" - # wix_manufacturer = "Paul-Elliot" - # wix_description = "Slipshow is an engine to write slips, a concept evolved from slides." - # exec_files = @("bin/slipshow.exe") - # } - # $config | ConvertTo-Json -Depth 5 | Set-Content oui.json -Encoding UTF8 - # Write-Host "oui.json generated:" - # Get-Content oui.json - - # - name: Lint oui.json - # run: opam exec -- oui lint oui.json ${{ github.workspace }}/bundle - - # - name: Generate MSI installer with OUI - # run: | - # New-Item -ItemType Directory -Force -Path new_release - # opam exec -- oui build oui.json ${{ github.workspace }}/bundle --output-dir ${{ github.workspace }}/new_release - # shell: pwsh - - # - name: Debug - Verify "${{ github.workspace }}/new_release" - # run: | - # Write-Output "Test ${{ github.workspace }}/new_release : $(Test-Path ${{ github.workspace }}/new_release)" - # Get-ChildItem -Path ${{ github.workspace }}/new_release - - - name: Prepare release directory - shell: pwsh - run: New-Item -ItemType Directory -Force -Path new_release - - - name: Get version from git tag - continue-on-error: true - id: version - shell: pwsh - run: | - # $version = (git describe --tags --abbrev=0 2>$null) -replace '^v', '' - # if ($version -notmatch '^\d+\.\d+\.\d+$') { $version = "0.0.1" } - $version = "0.0.1" - echo "VERSION=$version" | Out-File -FilePath $env:GITHUB_OUTPUT -Encoding utf8 -Append - Write-Host "Version: $version" - - - name: Write WiX source file (slipshow.wxs) - shell: pwsh - run: | - $version = "${{ steps.version.outputs.VERSION }}" - $bundle = "${{ github.workspace }}\bundle" - - # Générer la liste des fichiers du bundle - $files = Get-ChildItem -Path "$bundle\bin" -File - $fileEntries = ($files | ForEach-Object { - $id = $_.Name -replace '[^a-zA-Z0-9]', '_' - " " - }) -join "`n" - - $wxs = @" - - - - - - - - - - - - - - - $fileEntries - - - - - - - - "@ - - $wxs | Set-Content slipshow.wxs -Encoding UTF8 - Write-Host "slipshow.wxs generated" - Get-Content slipshow.wxs - - - name: Build MSI with WiX - shell: pwsh - run: | - $version = "${{ steps.version.outputs.VERSION }}" - wix build slipshow.wxs -o "new_release\slipshow-windows-x64-${version}.msi" - Write-Host "MSI generated:" - Get-ChildItem new_release - - - name: Upload installer - uses: actions/upload-artifact@v4 - with: - name: archives-windows-${{ matrix.config.arch }} - path: new_release/*.msi + - name: Try building + run: opam exec -- dune build release: if: startsWith(github.ref, 'refs/tags/') From 2e9c5d0d3f2b24db0b5b4e5b6ca3dc289c438b07 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 10:59:30 +0200 Subject: [PATCH 33/59] Ignore promoted rules --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f64c450b..c7c47ab6 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -170,7 +170,7 @@ jobs: run: opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade - name: Try building - run: opam exec -- dune build + run: opam exec -- dune build --ignore-promoted-rules release: if: startsWith(github.ref, 'refs/tags/') From 496d77ff11deed708cee591a92133101827ef1e8 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 11:16:51 +0200 Subject: [PATCH 34/59] Test caching --- .github/workflows/build.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index c7c47ab6..fe340e2b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -169,6 +169,7 @@ jobs: if: steps.wincache.outputs.cache-hit run: opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade + # Just to test caching - name: Try building run: opam exec -- dune build --ignore-promoted-rules From 9df40fdcd2b90032e1c59549775f67cb5129dce2 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 12:54:50 +0200 Subject: [PATCH 35/59] Try installing wix, oui and running oui --- .github/workflows/build.yaml | 12 +++++++++++- oui.json | 9 +++++++++ 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 oui.json diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index fe340e2b..9b5ff1c3 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -168,11 +168,21 @@ jobs: - name: Install dependencies if: steps.wincache.outputs.cache-hit run: opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade - # Just to test caching - name: Try building run: opam exec -- dune build --ignore-promoted-rules + - name: Install WiX 6 (required by OUI for Windows MSI) + shell: pwsh + run: | + dotnet tool install --global wix --version 6.0.2 + + - name: install oui + run: opam install oui + + - name: run installer + run: mkdir -p bundle/bin/slipshow/ && cp _build/install/bin/slipshow* bundle/bin && oui build oui.json bundle + release: if: startsWith(github.ref, 'refs/tags/') needs: [linux-build, mac-build] diff --git a/oui.json b/oui.json new file mode 100644 index 00000000..ef9807e7 --- /dev/null +++ b/oui.json @@ -0,0 +1,9 @@ +{ + "name": "slipshow", + "fullname": "slipshow.org", + "version": "0.0.1", + "wix_description": "TODO slipshow.", + "wix_manufacturer": "peada@free.fr", + "exec_files": ["bin/slipshow"], + "unique_id": "slipshow" +} From d5e1ffc18c6817bc9d70100f08dbca5b1aa3be40 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 13:01:33 +0200 Subject: [PATCH 36/59] Use 5.4 for windows builds Otherwise oui cannot be installed? --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 9b5ff1c3..841afd6d 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -156,7 +156,7 @@ jobs: uses: ocaml/setup-ocaml@v3 with: cache-prefix: v3 - ocaml-compiler: 4.14 + ocaml-compiler: 5.4 opam-pin: false opam-repositories: | default: https://github.com/punchagan/opam-repository.git#f1c70a26b442142ba1c3bd040bf8621060c94912 From e701526c8b489644d29a31856c728675a5b3e632 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 13:02:24 +0200 Subject: [PATCH 37/59] Windows CI: Execute oui in an opam environment --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 841afd6d..5526c805 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -181,7 +181,7 @@ jobs: run: opam install oui - name: run installer - run: mkdir -p bundle/bin/slipshow/ && cp _build/install/bin/slipshow* bundle/bin && oui build oui.json bundle + run: mkdir -p bundle/bin/slipshow/ && cp _build/install/bin/slipshow* bundle/bin && opal exec -- oui build oui.json bundle release: if: startsWith(github.ref, 'refs/tags/') From 10aee216f0053b84f4c798f0ab7aee11f789c9a9 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 13:08:22 +0200 Subject: [PATCH 38/59] Windows CI: generate a cache for 5.4 --- .github/workflows/build.yaml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 5526c805..6476ce41 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -150,7 +150,7 @@ jobs: path: | ~/.opam _opam - key: windows-${{ hashFiles('*.opam') }} + key: windows-${{ hashFiles('*.opam') }}-5.4 - name: Install OCaml ${{ matrix.ocaml-compiler }} uses: ocaml/setup-ocaml@v3 @@ -177,11 +177,11 @@ jobs: run: | dotnet tool install --global wix --version 6.0.2 - - name: install oui - run: opam install oui + # - name: install oui + # run: opam install oui - - name: run installer - run: mkdir -p bundle/bin/slipshow/ && cp _build/install/bin/slipshow* bundle/bin && opal exec -- oui build oui.json bundle + # - name: run installer + # run: mkdir -p bundle/bin/slipshow/ && cp _build/install/bin/slipshow* bundle/bin && opal exec -- oui build oui.json bundle release: if: startsWith(github.ref, 'refs/tags/') From 52e0b69fc1fd58045b36ab36575a5d798dad5c0e Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 14:18:12 +0200 Subject: [PATCH 39/59] Windows CI: reacivate oui install and run --- .github/workflows/build.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 6476ce41..c08dd36b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -177,11 +177,11 @@ jobs: run: | dotnet tool install --global wix --version 6.0.2 - # - name: install oui - # run: opam install oui + - name: install oui + run: opam install oui - # - name: run installer - # run: mkdir -p bundle/bin/slipshow/ && cp _build/install/bin/slipshow* bundle/bin && opal exec -- oui build oui.json bundle + - name: run installer + run: mkdir -p bundle/bin/slipshow/ && cp _build/install/bin/slipshow* bundle/bin && opal exec -- oui build oui.json bundle release: if: startsWith(github.ref, 'refs/tags/') From 8bc2f9d216011ce8a521c65ccde36e10dbb830f3 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 14:25:01 +0200 Subject: [PATCH 40/59] Windows CI: Check opam-client version --- .github/workflows/build.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index c08dd36b..f05b4ee9 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -177,6 +177,12 @@ jobs: run: | dotnet tool install --global wix --version 6.0.2 + - name: check opam-client version + run: opam show opam-client + + - name: check opam-client version + run: opam update && opam show opam-client + - name: install oui run: opam install oui From 8e3f4528db14043331d56451f1fe175cadae8aac Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 14:35:42 +0200 Subject: [PATCH 41/59] stop using punchagan's repository --- .github/workflows/build.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f05b4ee9..e00e143c 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -158,8 +158,6 @@ jobs: cache-prefix: v3 ocaml-compiler: 5.4 opam-pin: false - opam-repositories: | - default: https://github.com/punchagan/opam-repository.git#f1c70a26b442142ba1c3bd040bf8621060c94912 - name: Install dependencies if: steps.wincache.outputs.cache-hit != 'true' From 92d37603b801f093c3dd0ce27d4f12dad351ea13 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 14:44:12 +0200 Subject: [PATCH 42/59] WIndows CI: invalidate cache --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index e00e143c..1fa8fcfa 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -150,7 +150,7 @@ jobs: path: | ~/.opam _opam - key: windows-${{ hashFiles('*.opam') }}-5.4 + key: windows-${{ hashFiles('*.opam') }}-ocaml.5.4 - name: Install OCaml ${{ matrix.ocaml-compiler }} uses: ocaml/setup-ocaml@v3 From a3a30e7fae964c41a24fd89e5c5039d58fff9799 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 15:10:54 +0200 Subject: [PATCH 43/59] Fix path --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 1fa8fcfa..98b3f40e 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -185,7 +185,7 @@ jobs: run: opam install oui - name: run installer - run: mkdir -p bundle/bin/slipshow/ && cp _build/install/bin/slipshow* bundle/bin && opal exec -- oui build oui.json bundle + run: mkdir -p bundle/bin/slipshow/ && cp _build/install/default/bin/slipshow* bundle/bin && opal exec -- oui build oui.json bundle release: if: startsWith(github.ref, 'refs/tags/') From 3f2742a753a086352adae5e5730710f9674514aa Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 15:29:33 +0200 Subject: [PATCH 44/59] =?UTF-8?q?=F0=9F=A4=A6=20and=20let's=20populate=20t?= =?UTF-8?q?he=20cache?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/build.yaml | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 98b3f40e..da228340 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -175,17 +175,11 @@ jobs: run: | dotnet tool install --global wix --version 6.0.2 - - name: check opam-client version - run: opam show opam-client + # - name: install oui + # run: opam install oui - - name: check opam-client version - run: opam update && opam show opam-client - - - name: install oui - run: opam install oui - - - name: run installer - run: mkdir -p bundle/bin/slipshow/ && cp _build/install/default/bin/slipshow* bundle/bin && opal exec -- oui build oui.json bundle + # - name: run installer + # run: mkdir -p bundle/bin/slipshow/ && cp _build/install/default/bin/slipshow* bundle/bin && opam exec -- oui build oui.json bundle release: if: startsWith(github.ref, 'refs/tags/') From 099ddcef5087c1e7ee3cfc910fe99675b7a05f14 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 15:57:19 +0200 Subject: [PATCH 45/59] Reinvalidate cache? --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index da228340..4df35913 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -155,7 +155,7 @@ jobs: - name: Install OCaml ${{ matrix.ocaml-compiler }} uses: ocaml/setup-ocaml@v3 with: - cache-prefix: v3 + cache-prefix: v4 ocaml-compiler: 5.4 opam-pin: false From 9c26ecfd661a983a830b51152dfeaab2d8ad9ba5 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 16:16:11 +0200 Subject: [PATCH 46/59] Win CI: Install depext only first --- .github/workflows/build.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 4df35913..e985c07c 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -159,6 +159,10 @@ jobs: ocaml-compiler: 5.4 opam-pin: false + - name: Install dependencies + if: steps.wincache.outputs.cache-hit != 'true' + run: opam install --depext-only --deps-only --with-test --with-doc -y . + - name: Install dependencies if: steps.wincache.outputs.cache-hit != 'true' run: opam install --deps-only --with-test --with-doc -y . From 9eb016fa020b31c579cbcb0fc6c0c4452ada2edf Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 16:26:12 +0200 Subject: [PATCH 47/59] Install conf package first --- .github/workflows/build.yaml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index e985c07c..5f33f1c2 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -161,7 +161,19 @@ jobs: - name: Install dependencies if: steps.wincache.outputs.cache-hit != 'true' - run: opam install --depext-only --deps-only --with-test --with-doc -y . + run: opam install conf-gmp + + - name: Install dependencies + if: steps.wincache.outputs.cache-hit != 'true' + run: opam install conf-libssl + + - name: Install dependencies + if: steps.wincache.outputs.cache-hit != 'true' + run: opam install conf-pkg-config + + - name: Install dependencies + if: steps.wincache.outputs.cache-hit != 'true' + run: opam install conf-gmp-powm-sec - name: Install dependencies if: steps.wincache.outputs.cache-hit != 'true' From b6d5ed2e14681baad7414e4b44d1e62d7ac65447 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 16:41:53 +0200 Subject: [PATCH 48/59] reactivate oui install and run --- .github/workflows/build.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 5f33f1c2..2e420d3d 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -191,11 +191,11 @@ jobs: run: | dotnet tool install --global wix --version 6.0.2 - # - name: install oui - # run: opam install oui + - name: install oui + run: opam install oui - # - name: run installer - # run: mkdir -p bundle/bin/slipshow/ && cp _build/install/default/bin/slipshow* bundle/bin && opam exec -- oui build oui.json bundle + - name: run installer + run: mkdir -p bundle/bin/slipshow/ && cp _build/install/default/bin/slipshow* bundle/bin && opam exec -- oui build oui.json bundle release: if: startsWith(github.ref, 'refs/tags/') From 02466f1a74483c22166befc7ac7d09970c95a9ea Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 21:51:09 +0200 Subject: [PATCH 49/59] Add wix extension --- .github/workflows/build.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 2e420d3d..5be2c266 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -190,6 +190,8 @@ jobs: shell: pwsh run: | dotnet tool install --global wix --version 6.0.2 + wix extension add WixToolset.UI.wixext + wix extension add WixToolset.Util.wixext - name: install oui run: opam install oui From 3b272b037010f31d747dddf4e6e638194588ce79 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 22:05:49 +0200 Subject: [PATCH 50/59] Switch to wix 7 --- .github/workflows/build.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 5be2c266..7a759558 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -189,7 +189,8 @@ jobs: - name: Install WiX 6 (required by OUI for Windows MSI) shell: pwsh run: | - dotnet tool install --global wix --version 6.0.2 + dotnet tool install --global wix --version 7.0.0 + wix eula accept wix7 wix extension add WixToolset.UI.wixext wix extension add WixToolset.Util.wixext From 395b6fa917bdd41e81379e69fa0426b76039050a Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 22:24:29 +0200 Subject: [PATCH 51/59] Windows CI: upload installer --- .github/workflows/build.yaml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 7a759558..3fd22271 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -200,6 +200,13 @@ jobs: - name: run installer run: mkdir -p bundle/bin/slipshow/ && cp _build/install/default/bin/slipshow* bundle/bin && opam exec -- oui build oui.json bundle + - name: upload archives + # if: startsWith(github.ref, 'refs/tags/') + uses: actions/upload-artifact@v4 + with: + name: archives-windows + path: *.msi + release: if: startsWith(github.ref, 'refs/tags/') needs: [linux-build, mac-build] From 9f3d810b30b51d6f42cdaeaae46133b2f7aeb665 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 22:28:16 +0200 Subject: [PATCH 52/59] Fix syntax error ? --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 3fd22271..061dd1d7 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -198,14 +198,14 @@ jobs: run: opam install oui - name: run installer - run: mkdir -p bundle/bin/slipshow/ && cp _build/install/default/bin/slipshow* bundle/bin && opam exec -- oui build oui.json bundle + run: mkdir -p bundle/bin/slipshow/ && cp _build/install/default/bin/slipshow* bundle/bin && opam exec -- oui build oui.json bundle && mkdir -p installer-file && cp slipshow*.msi installer-file/ - name: upload archives # if: startsWith(github.ref, 'refs/tags/') uses: actions/upload-artifact@v4 with: name: archives-windows - path: *.msi + path: installer-file/* release: if: startsWith(github.ref, 'refs/tags/') From 8169d3694ec844b83af1c30db9dee4aee613ec4f Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 23:36:42 +0200 Subject: [PATCH 53/59] Trying to remove i686 version but without much hope --- .github/workflows/build.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 061dd1d7..b88a235b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -181,7 +181,9 @@ jobs: - name: Install dependencies if: steps.wincache.outputs.cache-hit - run: opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade + run: C:\.opam\.cygwin\setup-x86_64.exe "--root" "C:\\.opam\\.cygwin\\root" "--quiet-mode" "noinput" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--no-version-check" "--no-write-registry" "--packages" "mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf" "--symlink-type" "native" "--upgrade-also" "--only-site" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\.opam\\.cygwin\\cache" + #opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade + # Just to test caching - name: Try building run: opam exec -- dune build --ignore-promoted-rules From c127e0498a5d05d1ea4835c051c4b977dfc41ed0 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 23:42:42 +0200 Subject: [PATCH 54/59] Even less hope --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index b88a235b..492d28e2 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -181,7 +181,7 @@ jobs: - name: Install dependencies if: steps.wincache.outputs.cache-hit - run: C:\.opam\.cygwin\setup-x86_64.exe "--root" "C:\\.opam\\.cygwin\\root" "--quiet-mode" "noinput" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--no-version-check" "--no-write-registry" "--packages" "mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf" "--symlink-type" "native" "--upgrade-also" "--only-site" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\.opam\\.cygwin\\cache" + run: C:\.opam\.cygwin\setup-x86_64.exe "--root" "C:\\.opam\\.cygwin\\root" "--quiet-mode" "noinput" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--no-version-check" "--no-write-registry" "--packages" "mingw64-x86_64-gcc-core,mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf" "--symlink-type" "native" "--upgrade-also" "--only-site" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\.opam\\.cygwin\\cache" #opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade # Just to test caching From 10533dbafe6212c3b1cda2de4b921339a249f587 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 23:54:22 +0200 Subject: [PATCH 55/59] Win CI: Installing opam by myself --- .github/workflows/build.yaml | 87 ++++++++++++++++++++---------------- 1 file changed, 48 insertions(+), 39 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 492d28e2..c7804329 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -144,45 +144,54 @@ jobs: - name: Fetch tags run: git fetch --tags --force origin - - uses: actions/cache@v5 - id: wincache - with: - path: | - ~/.opam - _opam - key: windows-${{ hashFiles('*.opam') }}-ocaml.5.4 - - - name: Install OCaml ${{ matrix.ocaml-compiler }} - uses: ocaml/setup-ocaml@v3 - with: - cache-prefix: v4 - ocaml-compiler: 5.4 - opam-pin: false - - - name: Install dependencies - if: steps.wincache.outputs.cache-hit != 'true' - run: opam install conf-gmp - - - name: Install dependencies - if: steps.wincache.outputs.cache-hit != 'true' - run: opam install conf-libssl - - - name: Install dependencies - if: steps.wincache.outputs.cache-hit != 'true' - run: opam install conf-pkg-config - - - name: Install dependencies - if: steps.wincache.outputs.cache-hit != 'true' - run: opam install conf-gmp-powm-sec - - - name: Install dependencies - if: steps.wincache.outputs.cache-hit != 'true' - run: opam install --deps-only --with-test --with-doc -y . - - - name: Install dependencies - if: steps.wincache.outputs.cache-hit - run: C:\.opam\.cygwin\setup-x86_64.exe "--root" "C:\\.opam\\.cygwin\\root" "--quiet-mode" "noinput" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--no-version-check" "--no-write-registry" "--packages" "mingw64-x86_64-gcc-core,mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf" "--symlink-type" "native" "--upgrade-also" "--only-site" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\.opam\\.cygwin\\cache" - #opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade + # - uses: actions/cache@v5 + # id: wincache + # with: + # path: | + # ~/.opam + # _opam + # key: windows-${{ hashFiles('*.opam') }}-ocaml.5.4 + + # - name: Install OCaml ${{ matrix.ocaml-compiler }} + # uses: ocaml/setup-ocaml@v3 + # with: + # cache-prefix: v4 + # ocaml-compiler: 5.4 + # opam-pin: false + + # - name: Install dependencies + # if: steps.wincache.outputs.cache-hit != 'true' + # run: opam install conf-gmp + + # - name: Install dependencies + # if: steps.wincache.outputs.cache-hit != 'true' + # run: opam install conf-libssl + + # - name: Install dependencies + # if: steps.wincache.outputs.cache-hit != 'true' + # run: opam install conf-pkg-config + + # - name: Install dependencies + # if: steps.wincache.outputs.cache-hit != 'true' + # run: opam install conf-gmp-powm-sec + + # - name: Install dependencies + # if: steps.wincache.outputs.cache-hit != 'true' + # run: opam install --deps-only --with-test --with-doc -y . + + # - name: Install dependencies + # if: steps.wincache.outputs.cache-hit + # run: C:\.opam\.cygwin\setup-x86_64.exe "--root" "C:\\.opam\\.cygwin\\root" "--quiet-mode" "noinput" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--no-version-check" "--no-write-registry" "--packages" "mingw64-x86_64-gcc-core,mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf" "--symlink-type" "native" "--upgrade-also" "--only-site" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\.opam\\.cygwin\\cache" + # #opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade + + - name: Install OCaml + run: winget install Git.Git OCaml.opam + + - name: opam init + run: opam init --auto-setup --bare --cygwin-internal-install --enable-shell-hook + + - name: install deps + run: opam install . --deps-only # Just to test caching - name: Try building From facaffb5402f74d409de1cc2ef63015fe71e51c1 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sat, 25 Apr 2026 23:58:34 +0200 Subject: [PATCH 56/59] v5 --- .github/workflows/build.yaml | 63 +++++++++++++++++------------------- 1 file changed, 29 insertions(+), 34 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index c7804329..98ca697e 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -151,47 +151,42 @@ jobs: # ~/.opam # _opam # key: windows-${{ hashFiles('*.opam') }}-ocaml.5.4 + - name: Install dependencies + if: steps.wincache.outputs.cache-hit + run: C:\.opam\.cygwin\setup-x86_64.exe "--root" "C:\\.opam\\.cygwin\\root" "--quiet-mode" "noinput" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--no-version-check" "--no-write-registry" "--packages" "mingw64-i686-gcc-core,mingw64-i686-gmp,mingw64-i686-libffi,mingw64-i686-openssl,mingw64-x86_64-gcc-core,mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf" "--symlink-type" "native" "--upgrade-also" "--only-site" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\.opam\\.cygwin\\cache" + #opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade - # - name: Install OCaml ${{ matrix.ocaml-compiler }} - # uses: ocaml/setup-ocaml@v3 - # with: - # cache-prefix: v4 - # ocaml-compiler: 5.4 - # opam-pin: false - - # - name: Install dependencies - # if: steps.wincache.outputs.cache-hit != 'true' - # run: opam install conf-gmp - - # - name: Install dependencies - # if: steps.wincache.outputs.cache-hit != 'true' - # run: opam install conf-libssl - - # - name: Install dependencies - # if: steps.wincache.outputs.cache-hit != 'true' - # run: opam install conf-pkg-config + - name: Install OCaml ${{ matrix.ocaml-compiler }} + uses: ocaml/setup-ocaml@v3 + with: + cache-prefix: v5 + ocaml-compiler: 5.4 + opam-pin: false - # - name: Install dependencies - # if: steps.wincache.outputs.cache-hit != 'true' - # run: opam install conf-gmp-powm-sec + - name: Install dependencies + if: steps.wincache.outputs.cache-hit != 'true' + run: opam install conf-gmp - # - name: Install dependencies - # if: steps.wincache.outputs.cache-hit != 'true' - # run: opam install --deps-only --with-test --with-doc -y . + - name: Install dependencies + if: steps.wincache.outputs.cache-hit != 'true' + run: opam install conf-libssl - # - name: Install dependencies - # if: steps.wincache.outputs.cache-hit - # run: C:\.opam\.cygwin\setup-x86_64.exe "--root" "C:\\.opam\\.cygwin\\root" "--quiet-mode" "noinput" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--no-version-check" "--no-write-registry" "--packages" "mingw64-x86_64-gcc-core,mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf" "--symlink-type" "native" "--upgrade-also" "--only-site" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\.opam\\.cygwin\\cache" - # #opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade + - name: Install dependencies + if: steps.wincache.outputs.cache-hit != 'true' + run: opam install conf-pkg-config - - name: Install OCaml - run: winget install Git.Git OCaml.opam + - name: Install dependencies + if: steps.wincache.outputs.cache-hit != 'true' + run: opam install conf-gmp-powm-sec - - name: opam init - run: opam init --auto-setup --bare --cygwin-internal-install --enable-shell-hook + - name: Install dependencies + if: steps.wincache.outputs.cache-hit != 'true' + run: opam install --deps-only --with-test --with-doc -y . - - name: install deps - run: opam install . --deps-only + - name: Install dependencies + if: steps.wincache.outputs.cache-hit + run: C:\.opam\.cygwin\setup-x86_64.exe "--root" "C:\\.opam\\.cygwin\\root" "--quiet-mode" "noinput" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--no-version-check" "--no-write-registry" "--packages" "mingw64-i686-gcc-core,mingw64-i686-gmp,mingw64-i686-libffi,mingw64-i686-openssl,mingw64-x86_64-gcc-core,mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf" "--symlink-type" "native" "--upgrade-also" "--only-site" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\.opam\\.cygwin\\cache" + #opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade # Just to test caching - name: Try building From 978b0e15b1a56f004dc14318ff75777ca2b3fbdf Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sun, 26 Apr 2026 00:14:15 +0200 Subject: [PATCH 57/59] Revert "Trying to remove i686 version but without much hope" This reverts commit 8169d3694ec844b83af1c30db9dee4aee613ec4f. --- .github/workflows/build.yaml | 37 +++++++++++++++++++++--------------- 1 file changed, 22 insertions(+), 15 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 98ca697e..65006c84 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -144,22 +144,18 @@ jobs: - name: Fetch tags run: git fetch --tags --force origin - # - uses: actions/cache@v5 - # id: wincache - # with: - # path: | - # ~/.opam - # _opam - # key: windows-${{ hashFiles('*.opam') }}-ocaml.5.4 - - name: Install dependencies - if: steps.wincache.outputs.cache-hit - run: C:\.opam\.cygwin\setup-x86_64.exe "--root" "C:\\.opam\\.cygwin\\root" "--quiet-mode" "noinput" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--no-version-check" "--no-write-registry" "--packages" "mingw64-i686-gcc-core,mingw64-i686-gmp,mingw64-i686-libffi,mingw64-i686-openssl,mingw64-x86_64-gcc-core,mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf" "--symlink-type" "native" "--upgrade-also" "--only-site" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\.opam\\.cygwin\\cache" - #opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade + - uses: actions/cache@v5 + id: wincache + with: + path: | + ~/.opam + _opam + key: windows-${{ hashFiles('*.opam') }}-ocaml.5.4 - name: Install OCaml ${{ matrix.ocaml-compiler }} uses: ocaml/setup-ocaml@v3 with: - cache-prefix: v5 + cache-prefix: v4 ocaml-compiler: 5.4 opam-pin: false @@ -185,13 +181,24 @@ jobs: - name: Install dependencies if: steps.wincache.outputs.cache-hit - run: C:\.opam\.cygwin\setup-x86_64.exe "--root" "C:\\.opam\\.cygwin\\root" "--quiet-mode" "noinput" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--no-version-check" "--no-write-registry" "--packages" "mingw64-i686-gcc-core,mingw64-i686-gmp,mingw64-i686-libffi,mingw64-i686-openssl,mingw64-x86_64-gcc-core,mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf" "--symlink-type" "native" "--upgrade-also" "--only-site" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\.opam\\.cygwin\\cache" - #opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade - + run: opam install --deps-only --with-test --depext-only --with-doc -y . && opam upgrade # Just to test caching - name: Try building run: opam exec -- dune build --ignore-promoted-rules + - name: Uninstall 32-bit packages + run: > + C:\.opam\.cygwin\setup-x86_64.exe + --root "C:\.opam\.cygwin\root" + --quiet-mode + --uninstall + --packages mingw64-i686-gcc-core,mingw64-i686-gmp,mingw64-i686-libffi,mingw64-i686-openssl + #mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf + + - name: Install 64-bit packages + run: > + C:\.opam\.cygwin\setup-x86_64.exe "--root" "C:\\.opam\\.cygwin\\root" "--quiet-mode" "noinput" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--no-version-check" "--no-write-registry" "--packages" "mingw64-x86_64-gcc-core" "--symlink-type" "native" "--upgrade-also" "--only-site" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\.opam\\.cygwin\\cache" + - name: Install WiX 6 (required by OUI for Windows MSI) shell: pwsh run: | From 0aedf2d5a752e6ece0400810b70eb44ed6ef6185 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sun, 26 Apr 2026 00:19:45 +0200 Subject: [PATCH 58/59] typo --- .github/workflows/build.yaml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 65006c84..2130ea45 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -191,8 +191,7 @@ jobs: C:\.opam\.cygwin\setup-x86_64.exe --root "C:\.opam\.cygwin\root" --quiet-mode - --uninstall - --packages mingw64-i686-gcc-core,mingw64-i686-gmp,mingw64-i686-libffi,mingw64-i686-openssl + --remove-packages mingw64-i686-gcc-core,mingw64-i686-gmp,mingw64-i686-libffi,mingw64-i686-openssl #mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf - name: Install 64-bit packages From 253eef6cf08ccd0e5736c2e0104f32137da55ab1 Mon Sep 17 00:00:00 2001 From: Paul-Elliot Date: Sun, 26 Apr 2026 00:25:33 +0200 Subject: [PATCH 59/59] Descend into madness --- .github/workflows/build.yaml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 2130ea45..c3eb050c 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -194,6 +194,16 @@ jobs: --remove-packages mingw64-i686-gcc-core,mingw64-i686-gmp,mingw64-i686-libffi,mingw64-i686-openssl #mingw64-x86_64-gmp,mingw64-x86_64-libffi,mingw64-x86_64-openssl,pkgconf + - name: Try depexts + run: opam list --required-by slipshow --external --recursive + + - name: Nuke 32-bit cygwin dlls + run: | + $bad_path = "C:\.opam\.cygwin\root\usr\i686-w64-mingw32\sys-root\mingw\bin" + if (Test-Path $bad_path) { + Remove-Item -Path "$bad_path\*.dll" -Force + } + - name: Install 64-bit packages run: > C:\.opam\.cygwin\setup-x86_64.exe "--root" "C:\\.opam\\.cygwin\\root" "--quiet-mode" "noinput" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--no-version-check" "--no-write-registry" "--packages" "mingw64-x86_64-gcc-core" "--symlink-type" "native" "--upgrade-also" "--only-site" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\.opam\\.cygwin\\cache"