https://github.com/danchitnis/ngspice
Ngspice development tools for browser (WASM), Linux and Windows
https://github.com/danchitnis/ngspice
docker emscripten ngspice wasm
Last synced: 10 months ago
JSON representation
Ngspice development tools for browser (WASM), Linux and Windows
- Host: GitHub
- URL: https://github.com/danchitnis/ngspice
- Owner: danchitnis
- License: mit
- Created: 2020-09-09T01:55:16.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2025-06-27T22:45:32.000Z (about 1 year ago)
- Last Synced: 2025-06-27T23:29:27.929Z (about 1 year ago)
- Topics: docker, emscripten, ngspice, wasm
- Language: HTML
- Homepage: https://danchitnis.github.io/ngspice/emcc/
- Size: 3.94 MB
- Stars: 25
- Watchers: 4
- Forks: 6
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## [Live Demo 🚀](https://danchitnis.github.io/ngspice/emcc/)
# ngspice container tools

Docker environment to build [ngspice](https://sourceforge.net/p/ngspice/ngspice/ci/master/tree/) from source with a focus on command-line operations
## WASM
We use [Emscripten](https://emscripten.org/) to compile the ngspice codebased into [WASM](https://webassembly.org/) to run client-side inside [compatible browsers](https://caniuse.com/?search=wasm).
First clone the repository:
```bash
git clone https://github.com/danchitnis/ngspice.git
cd ngspice
```
Build the [Docker](https://www.docker.com/) image:
```bash
cd emcc
docker build -t ngspice:emcc .
```
Run the Docker image:
```bash
docker run -it -v $(realpath .):/mnt ngspice:emcc
```
This will create a new directory `build` which has the generated JS and WASM runtime files.
## Linux

First clone the repository:
```bash
git clone https://github.com/danchitnis/ngspice.git
cd ngspice
```
Build the [Docker](https://www.docker.com/) image:
```bash
cd linux
sudo docker build -t ngspice:linux .
```
Run the Docker image:
```bash
docker run -it -v $(realpath .):/mnt ngspice:linux
```
This will create a new directory `build` which contains the generated `ngspice` executable
## Windows
TBA
## GUI debug container
TBA
Notice that the docker image is based on [container-xrdp](https://github.com/danchitnis/container-xrdp)
## Ngspice mirror

https://github.com/danchitnis/ngspice-sf-mirror
## Details
See: https://sourceforge.net/p/ngspice/patches/99/
## Contributions
[ngspice](https://sourceforge.net/p/ngspice/ngspice/ci/master/tree/)
[Emscripten](https://emscripten.org/)
[SPICE3f5](https://ptolemy.berkeley.edu/projects/embedded/pubs/downloads/spice/spice.html)