Skip to content

Test Windows library changes #37

Closed

Description

@MatthewLM

In preparation for adding MuSig2 as required in #36, the build scripts have been updated. This has not been tested on Windows. The following needs to be tested on the 36-dlcs branch:

  • coinlib/bin/build_windows.dart produces a DLL that passes all tests.
  • coinlib/bin/build_windows_crosscompile.dart produces a DLL that passes all tests.
  • coinlib/bin/build_wsl.dart produces a DLL that passes all tests.
  • The coinlib_flutter/example app builds and runs on Windows.

Activity

  1. MatthewLM commented on Oct 16, 2025

    @MatthewLM
    CollaboratorAuthor

    The completed MuSig2 implementation is available on the v5.0.0 branch now. Windows support can be tested on that. coinlib_flutter and the example app will need temporary path dependencies to the coinlib local path to be tested prior to release.

  2. soosho commented on Jul 14, 2026

    @soosho
    Contributor

    Tested this on Windows 10 x64 against the v5.0.0 branch.

    Didn't have VS 2022, Docker, or a WSL distro handy, so I couldn't run the three build scripts you listed directly. Instead I built the secp256k1 DLL with CMake + LLVM-MinGW (MinGW Makefiles generator, x86_64-w64-mingw32-gcc). That worked fine and dropped the DLL into the right spot under build/.

    Ran the Dart tests against it -- all 327 passed with no failures.

    The MuSig2, Schnorr, Taproot, and transaction tests all look good on Windows.

  3. MatthewLM commented on Jul 15, 2026

    @MatthewLM
    CollaboratorAuthor

    @soosho Thanks for running a test of a DLL.

    I will need to confirm that at least one of the build scripts are working to include in v5.0.0. I can remove any scripts that are not tested. I also need to confirm that the flutter build is working. Otherwise I will need to drop Windows support.

  4. soosho commented on Jul 15, 2026

    @soosho
    Contributor

    Did a full Windows test pass against v5.0.0. Here's what I found:

    build_windows.dart -- works after fixing a small bug. The DLL output path was wrong in the script (it had src/RelWithDebInfo but VS puts the DLL in bin/RelWithDebInfo). Fixed that and it builds clean with MSVC. All 327 Dart tests pass against the DLL.

    build_windows_crosscompile.dart -- works. Docker pulls debian, installs mingw-w64, cross-compiles the DLL. 327/327 tests pass.

    build_wsl.dart -- my WSL install got stuck and died during the mingw-w64 apt install, so I couldn't finish this one. But it's the same approach as the Docker crosscompile (mingw-w64 on Linux targeting Windows), just running natively instead of containerized. The Docker one covers this path.

    coinlib_flutter example -- builds and runs on Windows. Flutter 3.38.5 + VS BuildTools 2022, local path deps set up, flutter build windows passes, app launches without crashing, secp256k1.dll bundled correctly in the output.

    Also wrote a build_windows_mingw.dart script as a fallback that works without Visual Studio -- just CMake and LLVM-MinGW. Same DLL, same 327/327. Could be useful for people who don't want to install the full VS toolchain.

  5. MatthewLM commented on Jul 15, 2026

    @MatthewLM
    CollaboratorAuthor

    @soosho Thank you. build_wsl.dart can be dropped. Are you able to submit a PR for the build_windows.dart fix and the build_windows_mingw.dart addition?

  6. soosho commented on Jul 15, 2026

    @soosho
    Contributor

    PR up at #43 — just the path fix and the MinGW script.

  7. soosho commented on Jul 16, 2026

    @soosho
    Contributor

    Got WSL sorted too — build_wsl.dart produces a valid DLL, 327/327 pass. So all build scripts confirmed on Windows now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions