From e83e773f8766eb445ba3a26191cc5bbe0694b659 Mon Sep 17 00:00:00 2001 From: Ivan FB Date: Sat, 30 May 2026 09:47:52 +0200 Subject: [PATCH 1/8] ci: disable Windows core.autocrlf so nimble checksums match nimble.lock MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Windows Git defaults to core.autocrlf=true. When nimble clones dependency packages into nimbledeps/, the LF→CRLF conversion changes the SHA1 of the source tree relative to the Linux-computed checksums in nimble.lock. nimble then treats every cached package as invalid and re-downloads on each invocation; in PR #3919 the re-download of bearssl_pkey_decoder during `nimble wakunode2` hung until the 6h job timeout. Set core.autocrlf=false / core.eol=lf globally before checkout so every package nimble clones keeps LF endings and matches the Linux SHA1s. This also obsoletes the targeted sed patch for the nim checksum, which is removed. Co-Authored-By: Claude Opus 4.7 --- .github/workflows/windows-build.yml | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/.github/workflows/windows-build.yml b/.github/workflows/windows-build.yml index 50f1602cd..2b149c930 100644 --- a/.github/workflows/windows-build.yml +++ b/.github/workflows/windows-build.yml @@ -24,6 +24,20 @@ jobs: MSYSTEM: MINGW64 steps: + - name: Configure Git to keep LF line endings + # Windows Git defaults to core.autocrlf=true, which converts LF→CRLF when + # nimble clones dependency packages into nimbledeps/. The CRLF conversion + # changes the SHA1 of the package source tree relative to the + # Linux-computed checksums stored in nimble.lock, so nimble decides the + # local copy is invalid and re-downloads on every subsequent invocation + # — and these retries can hang indefinitely on Windows runners. + # Disabling autocrlf globally makes nimble's child git clones produce + # the same tree (and SHA1) as on Linux. + shell: pwsh + run: | + git config --global core.autocrlf false + git config --global core.eol lf + - name: Checkout code uses: actions/checkout@v4 @@ -80,14 +94,6 @@ jobs: cd /tmp && nimble install "nimble@${{ env.NIMBLE_VERSION }}" -y echo "$HOME/.nimble/bin" >> $GITHUB_PATH - - name: Patch nimble.lock for Windows nim checksum - # nimble.exe uses Windows Git (core.autocrlf=true by default), which converts LF→CRLF - # on checkout. This changes the SHA1 of the nim package source tree relative to the - # Linux-computed checksum stored in nimble.lock. Patch the lock file with the - # Windows-computed checksum before nimble reads it. - run: | - sed -i 's/68bb85cbfb1832ce4db43943911b046c3af3caab/a092a045d3a427d127a5334a6e59c76faff54686/g' nimble.lock - - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true' run: | From dd9220492b35baada18d4376d1e8db0da16d4a9d Mon Sep 17 00:00:00 2001 From: Ivan FB Date: Tue, 2 Jun 2026 08:57:08 +0200 Subject: [PATCH 2/8] ci: set core.autocrlf=false inside MSYS2 shell too The earlier autocrlf fix ran in a pwsh step, which only configures Git for Windows. nimble clones its dependency packages from the MSYS2 shell, whose git reads a separate global config, so autocrlf stayed enabled there. That kept altering dependency source trees, breaking their SHA1 match against nimble.lock (e.g. the nim package), so nimble re-downloaded and hung. Repeat the setting in an MSYS2-shell step so nimble's own git clones produce Linux-identical trees. Co-Authored-By: Claude Opus 4.8 --- .github/workflows/windows-build.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.github/workflows/windows-build.yml b/.github/workflows/windows-build.yml index 2b149c930..cb4670d6a 100644 --- a/.github/workflows/windows-build.yml +++ b/.github/workflows/windows-build.yml @@ -66,6 +66,17 @@ jobs: mingw-w64-x86_64-clang mingw-w64-x86_64-nasm + - name: Configure Git in MSYS2 to keep LF line endings + # The autocrlf=false above only configures Git for Windows. nimble clones + # its dependency packages from within the MSYS2 shell, whose git reads a + # separate global config ($HOME/.gitconfig under the MSYS2 root). Without + # repeating the setting here, CRLF conversion still alters dependency + # source trees, so their SHA1 no longer matches nimble.lock and nimble + # re-downloads (and hangs) on every invocation. + run: | + git config --global core.autocrlf false + git config --global core.eol lf + - name: Manually install nasm run: | bash scripts/install_nasm_in_windows.sh From 80a4e6c132ae5c87f6971ebba773032b0ce62ad0 Mon Sep 17 00:00:00 2001 From: Ivan FB Date: Tue, 2 Jun 2026 08:57:34 +0200 Subject: [PATCH 3/8] ci: bump nimbledeps cache key to evict poisoned cache The Linux nimbledeps cache held a corrupt lsquic/nimblemeta.json (invalid JSON), so restoring it made `make wakunode2` fail parsing it while a fresh lsquic download in the same run was fine. The key is derived from nimble.lock, which is unchanged, so the poison persisted across runs. Add a v2 salt to the key to force a clean rebuild of the cache. Co-Authored-By: Claude Opus 4.8 --- .github/workflows/ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9ddf904ef..3bcc46e0c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -89,7 +89,7 @@ jobs: path: | nimbledeps/ nimble.paths - key: ${{ runner.os }}-nimbledeps-nimble${{ env.NIMBLE_VERSION }}-${{ hashFiles('nimble.lock', 'BearSSL.mk', 'Nat.mk') }} + key: ${{ runner.os }}-nimbledeps-v2-nimble${{ env.NIMBLE_VERSION }}-${{ hashFiles('nimble.lock', 'BearSSL.mk', 'Nat.mk') }} - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true' @@ -142,7 +142,7 @@ jobs: path: | nimbledeps/ nimble.paths - key: ${{ runner.os }}-nimbledeps-nimble${{ env.NIMBLE_VERSION }}-${{ hashFiles('nimble.lock', 'BearSSL.mk', 'Nat.mk') }} + key: ${{ runner.os }}-nimbledeps-v2-nimble${{ env.NIMBLE_VERSION }}-${{ hashFiles('nimble.lock', 'BearSSL.mk', 'Nat.mk') }} - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true' @@ -207,7 +207,7 @@ jobs: path: | nimbledeps/ nimble.paths - key: ${{ runner.os }}-nimbledeps-nimble${{ env.NIMBLE_VERSION }}-${{ hashFiles('nimble.lock', 'BearSSL.mk', 'Nat.mk') }} + key: ${{ runner.os }}-nimbledeps-v2-nimble${{ env.NIMBLE_VERSION }}-${{ hashFiles('nimble.lock', 'BearSSL.mk', 'Nat.mk') }} - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true' From a42cf994f94049176695178c1a944cf73772cbba Mon Sep 17 00:00:00 2001 From: Ivan FB Date: Tue, 2 Jun 2026 09:32:53 +0200 Subject: [PATCH 4/8] ci: strip nim/nimble from lock before nimble setup Restores a fix that was dropped in e5b46e5e and re-exposed when cda01971 reintroduced nim/nimble into nimble.lock: the nim package never matches its Linux-computed checksum on Windows because nim's own .gitattributes forces line endings on parts of its tree, so the SHA1 differs regardless of core.autocrlf. autocrlf alone therefore cannot fix the nim mismatch. Remove nim/nimble from the lock before `nimble setup` (they are provided by the toolchain installed in CI, not real project deps). Added to the Windows workflow, which never had it, and restored in ci.yml's setup steps since the cache-key bump now forces those to run on a fresh tree. Co-Authored-By: Claude Opus 4.8 --- .github/workflows/ci.yml | 33 +++++++++++++++++++++++++++++ .github/workflows/windows-build.yml | 13 ++++++++++++ 2 files changed, 46 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3bcc46e0c..29cd7adf4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -94,6 +94,17 @@ jobs: - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true' run: | + # nim and nimble have unstable cross-platform checksums (their source + # trees check out differently per OS), so strip them from the lock + # before setup to avoid spurious mismatches; the toolchain installed + # above provides them, they are not resolved as project deps. + python3 -c " + import json + lock = json.load(open('nimble.lock')) + for key in ['nim', 'nimble']: + lock['packages'].pop(key, None) + json.dump(lock, open('nimble.lock', 'w'), indent=2) + " nimble setup --localdeps -y make rebuild-nat-libs-nimbledeps make rebuild-bearssl-nimbledeps @@ -147,6 +158,17 @@ jobs: - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true' run: | + # nim and nimble have unstable cross-platform checksums (their source + # trees check out differently per OS), so strip them from the lock + # before setup to avoid spurious mismatches; the toolchain installed + # above provides them, they are not resolved as project deps. + python3 -c " + import json + lock = json.load(open('nimble.lock')) + for key in ['nim', 'nimble']: + lock['packages'].pop(key, None) + json.dump(lock, open('nimble.lock', 'w'), indent=2) + " nimble setup --localdeps -y make rebuild-nat-libs-nimbledeps make rebuild-bearssl-nimbledeps @@ -212,6 +234,17 @@ jobs: - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true' run: | + # nim and nimble have unstable cross-platform checksums (their source + # trees check out differently per OS), so strip them from the lock + # before setup to avoid spurious mismatches; the toolchain installed + # above provides them, they are not resolved as project deps. + python3 -c " + import json + lock = json.load(open('nimble.lock')) + for key in ['nim', 'nimble']: + lock['packages'].pop(key, None) + json.dump(lock, open('nimble.lock', 'w'), indent=2) + " nimble setup --localdeps -y make rebuild-nat-libs-nimbledeps make rebuild-bearssl-nimbledeps diff --git a/.github/workflows/windows-build.yml b/.github/workflows/windows-build.yml index cb4670d6a..c17c604ce 100644 --- a/.github/workflows/windows-build.yml +++ b/.github/workflows/windows-build.yml @@ -109,6 +109,19 @@ jobs: if: steps.cache-nimbledeps.outputs.cache-hit != 'true' run: | export PATH="$GITHUB_WORKSPACE/.nim_runtime/bin:$HOME/.nimble/bin:$PATH" + # nim and nimble have unstable cross-platform checksums: their source + # trees check out differently per OS (nim ships a .gitattributes that + # forces line endings on some files), so their SHA1 never matches the + # Linux-computed values in nimble.lock on Windows — even with autocrlf + # disabled. Strip them from the lock before setup; they are provided by + # the toolchain installed above, not resolved as project deps. + python -c " + import json + lock = json.load(open('nimble.lock')) + for key in ['nim', 'nimble']: + lock['packages'].pop(key, None) + json.dump(lock, open('nimble.lock', 'w'), indent=2) + " nimble setup --localdeps -y make rebuild-nat-libs-nimbledeps CC=gcc make rebuild-bearssl-nimbledeps CC=gcc From 83f962c3c85e0c081025b48b1138dd14ae07f062 Mon Sep 17 00:00:00 2001 From: Ivan FB Date: Tue, 2 Jun 2026 14:04:42 +0200 Subject: [PATCH 5/8] ci: use --useSystemNim instead of editing nimble.lock MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Stripping nim from the lock breaks nimble 0.22.3: 41 packages list nim in their dependencies, so removing the nim entry makes resolution fail with "key not found: nim". nimble already has the right knob — --useSystemNim ("Use system nim and ignore nim from the lock") — which skips the locked nim (no download, no checksum) while still verifying every other locked dependency, and uses the nim the CI already installed. This is the proper fix for the Windows checksum mismatch: nim's tree checks out differently per platform, so its locked checksum is unreliable there. Verified locally with nimble 0.22.3 (exit 0, system nim used, lock left untouched). Co-Authored-By: Claude Opus 4.8 --- .github/workflows/ci.yml | 51 +++++++++-------------------- .github/workflows/windows-build.yml | 22 +++++-------- 2 files changed, 23 insertions(+), 50 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 29cd7adf4..922901f27 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -94,18 +94,11 @@ jobs: - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true' run: | - # nim and nimble have unstable cross-platform checksums (their source - # trees check out differently per OS), so strip them from the lock - # before setup to avoid spurious mismatches; the toolchain installed - # above provides them, they are not resolved as project deps. - python3 -c " - import json - lock = json.load(open('nimble.lock')) - for key in ['nim', 'nimble']: - lock['packages'].pop(key, None) - json.dump(lock, open('nimble.lock', 'w'), indent=2) - " - nimble setup --localdeps -y + # Use system nim instead of the nim pinned in nimble.lock: nim's + # source tree checksums differently across platforms, so the locked + # checksum is unreliable. --useSystemNim skips the locked nim while + # still verifying every other locked dependency. + nimble setup --localdeps -y --useSystemNim make rebuild-nat-libs-nimbledeps make rebuild-bearssl-nimbledeps touch nimbledeps/.nimble-setup @@ -158,18 +151,11 @@ jobs: - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true' run: | - # nim and nimble have unstable cross-platform checksums (their source - # trees check out differently per OS), so strip them from the lock - # before setup to avoid spurious mismatches; the toolchain installed - # above provides them, they are not resolved as project deps. - python3 -c " - import json - lock = json.load(open('nimble.lock')) - for key in ['nim', 'nimble']: - lock['packages'].pop(key, None) - json.dump(lock, open('nimble.lock', 'w'), indent=2) - " - nimble setup --localdeps -y + # Use system nim instead of the nim pinned in nimble.lock: nim's + # source tree checksums differently across platforms, so the locked + # checksum is unreliable. --useSystemNim skips the locked nim while + # still verifying every other locked dependency. + nimble setup --localdeps -y --useSystemNim make rebuild-nat-libs-nimbledeps make rebuild-bearssl-nimbledeps touch nimbledeps/.nimble-setup @@ -234,18 +220,11 @@ jobs: - name: Install nimble deps if: steps.cache-nimbledeps.outputs.cache-hit != 'true' run: | - # nim and nimble have unstable cross-platform checksums (their source - # trees check out differently per OS), so strip them from the lock - # before setup to avoid spurious mismatches; the toolchain installed - # above provides them, they are not resolved as project deps. - python3 -c " - import json - lock = json.load(open('nimble.lock')) - for key in ['nim', 'nimble']: - lock['packages'].pop(key, None) - json.dump(lock, open('nimble.lock', 'w'), indent=2) - " - nimble setup --localdeps -y + # Use system nim instead of the nim pinned in nimble.lock: nim's + # source tree checksums differently across platforms, so the locked + # checksum is unreliable. --useSystemNim skips the locked nim while + # still verifying every other locked dependency. + nimble setup --localdeps -y --useSystemNim make rebuild-nat-libs-nimbledeps make rebuild-bearssl-nimbledeps touch nimbledeps/.nimble-setup diff --git a/.github/workflows/windows-build.yml b/.github/workflows/windows-build.yml index c17c604ce..059cc954f 100644 --- a/.github/workflows/windows-build.yml +++ b/.github/workflows/windows-build.yml @@ -109,20 +109,14 @@ jobs: if: steps.cache-nimbledeps.outputs.cache-hit != 'true' run: | export PATH="$GITHUB_WORKSPACE/.nim_runtime/bin:$HOME/.nimble/bin:$PATH" - # nim and nimble have unstable cross-platform checksums: their source - # trees check out differently per OS (nim ships a .gitattributes that - # forces line endings on some files), so their SHA1 never matches the - # Linux-computed values in nimble.lock on Windows — even with autocrlf - # disabled. Strip them from the lock before setup; they are provided by - # the toolchain installed above, not resolved as project deps. - python -c " - import json - lock = json.load(open('nimble.lock')) - for key in ['nim', 'nimble']: - lock['packages'].pop(key, None) - json.dump(lock, open('nimble.lock', 'w'), indent=2) - " - nimble setup --localdeps -y + # Use the CI-installed system nim instead of the nim pinned in + # nimble.lock. nim's source tree checks out differently on Windows + # (its .gitattributes forces line endings on some files), so its + # checksum never matches the Linux-computed value in the lock — not + # even with autocrlf disabled. --useSystemNim makes nimble ignore the + # locked nim (no download, no checksum) while still verifying every + # other locked dependency. + nimble setup --localdeps -y --useSystemNim make rebuild-nat-libs-nimbledeps CC=gcc make rebuild-bearssl-nimbledeps CC=gcc touch nimbledeps/.nimble-setup From eadd7dcc06cdd835d4aee6ccc539e771fd43d655 Mon Sep 17 00:00:00 2001 From: Ivan FB Date: Tue, 2 Jun 2026 14:57:51 +0200 Subject: [PATCH 6/8] ci: set NIM_PARAMS=-d:disableMarchNative for container image build The docker image build compiled secp256k1 with -march=native and failed. waku.nimble's getNimParams reads the NIM_PARAMS env var, not NIMFLAGS, so the -d:disableMarchNative passed via NIMFLAGS on the make line never reached `nim c` and config.nims applied -march=native. #3916 added NIM_PARAMS to ci.yml but missed container-image.yml; set it here too. Co-Authored-By: Claude Opus 4.8 --- .github/workflows/container-image.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/container-image.yml b/.github/workflows/container-image.yml index 0ff427d87..618d77aa3 100644 --- a/.github/workflows/container-image.yml +++ b/.github/workflows/container-image.yml @@ -15,6 +15,11 @@ env: NPROC: 2 MAKEFLAGS: "-j${NPROC}" NIMFLAGS: "--parallelBuild:${NPROC}" + # nim builds read compile flags from NIM_PARAMS (getNimParams in waku.nimble), + # not NIMFLAGS, so -d:disableMarchNative must live here or config.nims applies + # -march=native and secp256k1 fails to compile (see #3916, which set this in + # ci.yml but missed this workflow). + NIM_PARAMS: "-d:disableMarchNative" NIM_VERSION: '2.2.4' NIMBLE_VERSION: '0.22.3' From 1e87fb714e2938f479af84d2ff52744c2cc3fd87 Mon Sep 17 00:00:00 2001 From: Ivan FB Date: Tue, 2 Jun 2026 22:01:30 +0200 Subject: [PATCH 7/8] ci: route all nimble build tasks through --useSystemNim MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The Windows build hung for 6h (until Actions cancelled it) at `nimble wakunode2`, on "Downloading nim-lang/Nim.git using git". `nimble setup` runs with --localdeps, so the locked nim is never placed in nimbledeps/. Every later `nimble ` re-resolves deps, finds nim missing, and clones the full Nim repo from git — a fetch that completes on Linux/macOS but blocks forever on the MSYS2 runner. --useSystemNim cannot be set from inside waku.nimble: it is a nimble CLI flag governing the dependency resolution that wraps the task, and the .nimble file is evaluated as part of that step. So fix it at the single place every task is invoked — the Makefile NIMBLE variable. NIMBLE resolves nimble via PATH rather than $(HOME)/.nimble/bin: on the MSYS2 Windows runner that absolute path does not hold the binary (it is on PATH via the workflow's GITHUB_PATH), so a hardcoded path fails with "No such file or directory". Bare `nimble` works on every platform. clean and the global nph install stay bare; they resolve no project deps. Co-Authored-By: Claude Opus 4.8 --- Makefile | 53 ++++++++++++++++++++++++++++++----------------------- 1 file changed, 30 insertions(+), 23 deletions(-) diff --git a/Makefile b/Makefile index ea1bf66f0..a9d1cb2fe 100644 --- a/Makefile +++ b/Makefile @@ -24,7 +24,14 @@ export PATH := $(HOME)/.nimble/bin:$(PATH) # NIM binary location NIM_BINARY := $(shell which nim 2>/dev/null) NPH := $(HOME)/.nimble/bin/nph -NIMBLE := $(HOME)/.nimble/bin/nimble +# Resolve nimble via PATH (not an absolute path): on the MSYS2 Windows runner +# $(HOME)/.nimble/bin does not hold the binary, so a hardcoded path is "not +# found", whereas PATH is populated for every platform (see export PATH above +# and the workflow's GITHUB_PATH). --useSystemNim makes every invocation reuse +# the nim already on PATH: nimble re-resolves the locked deps before each task, +# and since setup runs with --localdeps the locked nim is never installed, so +# without this nimble re-clones nim-lang/Nim — a fetch that hangs on Windows. +NIMBLE := nimble --useSystemNim NIMBLEDEPS_STAMP := nimbledeps/.nimble-setup # Compilation parameters @@ -204,7 +211,7 @@ clean: | clean-librln testcommon: | build-deps build echo -e $(BUILD_MSG) "build/$@" && \ - nimble testcommon + $(NIMBLE) testcommon ########## ## Waku ## @@ -213,47 +220,47 @@ testcommon: | build-deps build testwaku: | build-deps build rln-deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble test + $(NIMBLE) test wakunode2: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble wakunode2 + $(NIMBLE) wakunode2 benchmarks: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble benchmarks + $(NIMBLE) benchmarks testwakunode2: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble testwakunode2 + $(NIMBLE) testwakunode2 example2: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble example2 + $(NIMBLE) example2 chat2: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble chat2 + $(NIMBLE) chat2 chat2mix: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble chat2mix + $(NIMBLE) chat2mix rln-db-inspector: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble rln_db_inspector + $(NIMBLE) rln_db_inspector chat2bridge: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble chat2bridge + $(NIMBLE) chat2bridge liteprotocoltester: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble liteprotocoltester + $(NIMBLE) liteprotocoltester lightpushwithmix: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble lightpushwithmix + $(NIMBLE) lightpushwithmix api_example: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ @@ -261,12 +268,12 @@ api_example: | build-deps build deps librln build/%: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$*" && \ - nimble buildone $* + $(NIMBLE) buildone $* compile-test: | build-deps build deps librln echo -e $(BUILD_MSG) "$(TEST_FILE)" "\"$(TEST_NAME)\"" && \ - nimble buildTest $(TEST_FILE) && \ - nimble execTest $(TEST_FILE) "\"$(TEST_NAME)\"" + $(NIMBLE) buildTest $(TEST_FILE) && \ + $(NIMBLE) execTest $(TEST_FILE) "\"$(TEST_NAME)\"" ################ ## Waku tools ## @@ -277,11 +284,11 @@ tools: networkmonitor wakucanary wakucanary: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble wakucanary + $(NIMBLE) wakucanary networkmonitor: | build-deps build deps librln echo -e $(BUILD_MSG) "build/$@" && \ - nimble networkmonitor + $(NIMBLE) networkmonitor ############ ## Format ## @@ -327,7 +334,7 @@ clean: docs: | build deps echo -e $(BUILD_MSG) "build/$@" && \ - nimble doc --run --index:on --project --out:.gh-pages waku/waku.nim waku.nims + $(NIMBLE) doc --run --index:on --project --out:.gh-pages waku/waku.nim waku.nims coverage: echo -e $(BUILD_MSG) "build/$@" && \ @@ -424,10 +431,10 @@ else ifeq ($(detected_OS),Linux) endif libwaku: | build-deps librln - nimble --verbose libwaku$(BUILD_COMMAND) waku.nimble + $(NIMBLE) --verbose libwaku$(BUILD_COMMAND) waku.nimble liblogosdelivery: | build-deps librln - nimble --verbose liblogosdelivery$(BUILD_COMMAND) waku.nimble + $(NIMBLE) --verbose liblogosdelivery$(BUILD_COMMAND) waku.nimble logosdelivery_example: | build liblogosdelivery @echo -e $(BUILD_MSG) "build/$@" @@ -502,7 +509,7 @@ endif build-libwaku-for-android-arch: ifneq ($(findstring /nix/store,$(LIBRLN_FILE)),) mkdir -p $(CURDIR)/build/android/$(ABIDIR)/ - CPU=$(CPU) ABIDIR=$(ABIDIR) ANDROID_ARCH=$(ANDROID_ARCH) ANDROID_COMPILER=$(ANDROID_COMPILER) ANDROID_TOOLCHAIN_DIR=$(ANDROID_TOOLCHAIN_DIR) nimble libWakuAndroid + CPU=$(CPU) ABIDIR=$(ABIDIR) ANDROID_ARCH=$(ANDROID_ARCH) ANDROID_COMPILER=$(ANDROID_COMPILER) ANDROID_TOOLCHAIN_DIR=$(ANDROID_TOOLCHAIN_DIR) $(NIMBLE) libWakuAndroid else ./scripts/build_rln_android.sh $(CURDIR)/build $(LIBRLN_BUILDDIR) $(LIBRLN_VERSION) $(CROSS_TARGET) $(ABIDIR) endif @@ -559,7 +566,7 @@ else endif build-libwaku-for-ios-arch: - IOS_SDK=$(IOS_SDK) IOS_ARCH=$(IOS_ARCH) IOS_SDK_PATH=$(IOS_SDK_PATH) nimble libWakuIOS + IOS_SDK=$(IOS_SDK) IOS_ARCH=$(IOS_ARCH) IOS_SDK_PATH=$(IOS_SDK_PATH) $(NIMBLE) libWakuIOS libwaku-ios-device: IOS_ARCH=arm64 libwaku-ios-device: IOS_SDK=iphoneos From 5ccc273ca5bfcf410967edc5292c475cac83c431 Mon Sep 17 00:00:00 2001 From: Ivan FB Date: Wed, 3 Jun 2026 11:58:34 +0200 Subject: [PATCH 8/8] deps: pin nim-ffi to the locked 0.1.3 revision nim-ffi was required by bare git URL with no version, so a fresh nimble resolution (as triggered by the bumped nimbledeps cache key) ignored the nimble.lock pin and floated it to HEAD (0.1.4). nim-ffi 0.1.4 changed declareLibrary to take a second `libType` argument, so library/declare_lib.nim fails to compile with a type mismatch and libwaku/liblogosdelivery break. Pinning the require to the same commit nimble.lock records keeps the version-less git dependency deterministic across clean resolves, matching the API the current code targets. Mirrors the existing nim-sds pin style. Co-Authored-By: Claude Opus 4.8 --- waku.nimble | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/waku.nimble b/waku.nimble index da5b87eb6..05bac2ba1 100644 --- a/waku.nimble +++ b/waku.nimble @@ -59,7 +59,7 @@ requires "nim >= 2.2.4", "unittest2" # Packages not on nimble (use git URLs) -requires "https://github.com/logos-messaging/nim-ffi" +requires "https://github.com/logos-messaging/nim-ffi#06111de155253b34e47ed2aaed1d61d08d62cc1b" requires "https://github.com/logos-messaging/nim-sds.git#2e9a7683f0e180bf112135fae3a3803eed8490d4"