-
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathpost-install.js
More file actions
22 lines (15 loc) · 793 Bytes
/
Copy pathpost-install.js
File metadata and controls
22 lines (15 loc) · 793 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
const {exec} = require("child_process");
if (process.platform === "linux") {
const cmd = "export vOCC=$(export VERSION_FILE=/usr/include/opencascade/Standard_Version.hxx && grep -i \"#define OCC_VERSION_COMPLETE\" $VERSION_FILE | awk '{gsub(/\"/, \"\", $0); print $3}') && (cd lib/binding && echo 'linux libs directory' && pwd && ls * && echo $vOCC)";
// apt-get install libTBB
/* "(cd node_modules/node-occ/lib/binding && pwd && ls *.so.$vOCC) && ldconfig $pathToBinding && ldd occ.node"*/
exec(cmd, (error, stdout, stderr) => {
console.log(`stdout: ${stdout}`);
if (error) {
console.log(error);
console.log("ERROR!!!", error.code);
} else {
console.log("done post install rename libs");
}
});
}