I have a dependency with the sqlite3 package.
By default, upon install, the sqlite3 package downloads and uses a pre-packaged version of the sqlite3 engine. This can sometimes be a problem when using sqlite3 extensions so there is an option to install it with :
npm install --build-from-source --sqlite=/path/to/sqlite sqlite3
both "--build-from-source" and "--sqlite" are options that are handled by the sqlite3 package.
Now how can I tell package.json to install my dependency with those options ?
with
"dependencies": {
"sqlite3": "*"
}
obviously i get the equivalent to
npm install sqlite3
but I cannot find a way to force the --build-from-source and --sqlite options for the sqlite3 package
An alternative is to use the scripts member and setup the install script under the preinstall or postinstall hook: