I'm working on a rust binding to the ngspice library written in C. The (hopeful) plan is to then use it in a circuit simulation program in rust.
up to now, I've just been keeping a copy of the .dll in the repo, but recently it has occurred to me that this may not be a good idea. The readme in opencv-rust for example asks users to install opencv themselves. NgSpice though, as far as I can tell, has no equivalent installation. There are separate downloads for the program (irrelevant to the binding) and the .dll/.so library files.
I've tried looking this up but google keeps misinterpreting my question... maybe I'm wording it incorrectly.
So, how should I package a .dll/.so dependency with my project: as a crate, and as an executable binary?
To answer specifically this part of the question: you shouldn't ship compiled executables with your code. Rust runs on many different platforms, and it's almost certain you won't be able to produce a (correct) executable for all of them (including all combinations of all possible environments, which arise out of libc incompatibilities, for example).