From 1c7ad24915d20f5dbb2360ccb9235b1158ede770 Mon Sep 17 00:00:00 2001 From: Martin Heidegger Date: Tue, 29 Mar 2016 00:56:45 +0900 Subject: [PATCH 1/3] Added error when libstdc++ is missing and info how to resolve --- package.json | 3 ++- postinstall.sh | 12 ++++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) create mode 100755 postinstall.sh diff --git a/package.json b/package.json index 19dee3ecb..06cd363c6 100644 --- a/package.json +++ b/package.json @@ -88,6 +88,7 @@ "rebuild": "node generate && node-gyp configure build", "recompileDebug": "node-gyp configure --debug build", "rebuildDebug": "node generate && node-gyp configure --debug build", - "xcodeDebug": "node-gyp configure -- -f xcode" + "xcodeDebug": "node-gyp configure -- -f xcode", + "postinstall": "./postinstall.sh" } } diff --git a/postinstall.sh b/postinstall.sh new file mode 100755 index 000000000..bf637981f --- /dev/null +++ b/postinstall.sh @@ -0,0 +1,12 @@ +#!/usr/bin/env bash + +if [ -n "$(node lib/nodegit.js 2>&1 | grep libstdc++)" ]; then + echo "[ERROR] Seems like you the latest libstdc++ is missing on your system!" + echo "" + echo "On Ubuntu you can install it using:" + echo "" + echo "$ sudo add-apt-repository ppa:ubuntu-toolchain-r/test" + echo "$ sudo apt-get update" + echo "$ sudo apt-get install libstdc++-4.9-dev" + exit 1 +fi \ No newline at end of file From 601cacb67a19a49d5266b3122684e7d62ae6d94b Mon Sep 17 00:00:00 2001 From: Martin Heidegger Date: Tue, 29 Mar 2016 01:10:08 +0900 Subject: [PATCH 2/3] Fixed package.json for windows --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 06cd363c6..0a5f1bf26 100644 --- a/package.json +++ b/package.json @@ -89,6 +89,6 @@ "recompileDebug": "node-gyp configure --debug build", "rebuildDebug": "node generate && node-gyp configure --debug build", "xcodeDebug": "node-gyp configure -- -f xcode", - "postinstall": "./postinstall.sh" + "postinstall": "bash postinstall.sh" } } From a606a99ecc1f8a88ebac3b4da257bfb6422dce36 Mon Sep 17 00:00:00 2001 From: Martin Heidegger Date: Tue, 29 Mar 2016 01:57:22 +0900 Subject: [PATCH 3/3] Grammatical fix in error message and EOL --- postinstall.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/postinstall.sh b/postinstall.sh index bf637981f..b3fd35fab 100755 --- a/postinstall.sh +++ b/postinstall.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash if [ -n "$(node lib/nodegit.js 2>&1 | grep libstdc++)" ]; then - echo "[ERROR] Seems like you the latest libstdc++ is missing on your system!" + echo "[ERROR] Seems like the latest libstdc++ is missing on your system!" echo "" echo "On Ubuntu you can install it using:" echo "" @@ -9,4 +9,4 @@ if [ -n "$(node lib/nodegit.js 2>&1 | grep libstdc++)" ]; then echo "$ sudo apt-get update" echo "$ sudo apt-get install libstdc++-4.9-dev" exit 1 -fi \ No newline at end of file +fi