From 0a42c6413cfa92f206049075431957eab4b68286 Mon Sep 17 00:00:00 2001 From: Marcel Blum Date: Sat, 5 Feb 2022 22:59:52 -0500 Subject: [PATCH 1/4] stop npmignoring files needed for manual build --- .npmignore | 3 --- 1 file changed, 3 deletions(-) diff --git a/.npmignore b/.npmignore index 02ab0058..34bd5146 100644 --- a/.npmignore +++ b/.npmignore @@ -7,7 +7,6 @@ docs/.vuepress/dist/ logs/ node_modules/ prebuilds/ -libuiohook/ .github/ CMakeFiles/ docs/ @@ -19,8 +18,6 @@ test/ *.log npm-debug.log* stacktrace* -/binding.gyp -/uiohook.gyp .lintignore .eslintrc.json .prettierrc.json From 1fd69fb52c1309a1b2bed6acc6f45a631a423390 Mon Sep 17 00:00:00 2001 From: Marcel Blum Date: Sat, 5 Feb 2022 23:09:15 -0500 Subject: [PATCH 2/4] manual build docs clarifications/corrections --- docs/manual-build.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/manual-build.md b/docs/manual-build.md index 56528d13..2e265c9f 100644 --- a/docs/manual-build.md +++ b/docs/manual-build.md @@ -5,11 +5,11 @@ This is not required for regular users. You should follow this page only if you ::: ::: tip WARNING -When you run `npm run build`, it will try to download a prebuilt for your platform/target, and sometime fail if you are building for a recent target. You can safely ignore this step and the associated warning. +When you run `npm run build`, it will try to download a prebuild for your platform/target, and sometimes fail if you are building for a recent target with no prebuild yet available. You can safely ignore this step and the associated warning. ::: -You can build own modules directly in your node_modules under the project. Go to ~/my_project/node_modules/iohook path via terminal. -Or you can just clone iohook repository and working on it, then copy binnary files to project's node_modules or change download path in iohook and make you own version of module. +You can build directly in your project's node_modules. Go to the ~/my_project/node_modules/iohook path via terminal. +Or you can just clone the iohook repository and work there, then copy the binary files to your project's node_modules/iohook/builds/ or change the download path in iohook and make your own version of the module. Before start, you need install required dependencies for build: @@ -29,7 +29,7 @@ Before start, you need install required dependencies for build: ## Windows -- Install: `msys2` with `autotools`, `pkg-config`, `libtool`, `gcc`, `clang`, `glib`, `C++ Build Tools` +- The build tools that are included with the Node.js for Windows installer are required, or manually install `windows-build-tools` - `npm install` - `npm run build` From 0f3da529c4582dbd07f9802c5ef457323210c8d3 Mon Sep 17 00:00:00 2001 From: Marcel Blum Date: Sat, 5 Feb 2022 23:15:42 -0500 Subject: [PATCH 3/4] clearer instructions for manual build if prebuild download fails --- install.js | 1 + 1 file changed, 1 insertion(+) diff --git a/install.js b/install.js index 9c9b3d3e..1dc3ee0e 100644 --- a/install.js +++ b/install.js @@ -75,6 +75,7 @@ function install(runtime, abi, platform, arch, cb) { ); console.error('Try to build for your platform manually:'); console.error('# cd node_modules/iohook;'); + console.error('# npm install'); console.error('# npm run build'); console.error(''); } From c7b90f115b78da2026343948c86223aeabc7d148 Mon Sep 17 00:00:00 2001 From: Marcel Blum Date: Sun, 6 Feb 2022 01:03:41 -0500 Subject: [PATCH 4/4] ok to ignore binding.gyp uiohook.gyp --- .npmignore | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.npmignore b/.npmignore index 34bd5146..6817195e 100644 --- a/.npmignore +++ b/.npmignore @@ -18,6 +18,8 @@ test/ *.log npm-debug.log* stacktrace* +/binding.gyp +/uiohook.gyp .lintignore .eslintrc.json .prettierrc.json