Git Product home page Git Product logo

Comments (3)

tniessen avatar tniessen commented on July 28, 2024

Thank you for pointing this out @Catalan-1ap. The build-wasm script requires the Emscripten Compiler Frontend (emcc) to produce the WebAssembly output. For CI and for releases, we currently use a slightly older version of the Emscripten SDK:

build-wasm:
runs-on: ubuntu-latest
env:
NODE_VERSION: 18.x
EMSDK_VERSION: 3.1.21

If you want to build the WebAssembly file locally, I would recommend to use the same version of Emscripten (3.1.21).

Unfortunately, the Emscripten SDK will also populate your PATH with an old version of Node.js, which might cause other problems. As a temporary workaround, until we figure out a better solution, you can skip the build-wasm step and use pre-built binaries instead:

$ git clone --branch v0.3.1 https://github.com/tniessen/node-pqclean.git
$ mkdir -p wasm/gen
$ curl -o wasm/gen/algorithms.json "https://unpkg.com/[email protected]/wasm/gen/algorithms.json"
$ curl -o wasm/gen/pqclean.wasm "https://unpkg.com/[email protected]/wasm/gen/pqclean.wasm"
$ npm run build-web
$ npm run test-web chrome

The last step is optional and only necessary for testing.

We will try to find a better solution to this issue. I have previously considered publishing the web distribution to npm directly to make this easier.

from node-pqclean.

Catalan-1ap avatar Catalan-1ap commented on July 28, 2024

@tniessen Thank you for your attention, pre-build binaries works
Should i close the issue?

from node-pqclean.

tniessen avatar tniessen commented on July 28, 2024

Please keep it open as a reminder for me to either update the documentation or to find a better solution :)

from node-pqclean.

Related Issues (2)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.