Going 4.0.0
This commit is contained in:
parent
110d80dd59
commit
193931995c
|
@ -1,9 +1,10 @@
|
||||||
sudo: false
|
sudo: true
|
||||||
|
dist: trusty
|
||||||
|
|
||||||
language: node_js
|
language: node_js
|
||||||
|
|
||||||
node_js:
|
node_js:
|
||||||
- "8.11.1"
|
- "8.11.4"
|
||||||
|
|
||||||
|
|
||||||
addons:
|
addons:
|
||||||
|
@ -20,7 +21,7 @@ before_install:
|
||||||
export CXX="clang++-3.5";
|
export CXX="clang++-3.5";
|
||||||
export CC="clang-3.5";
|
export CC="clang-3.5";
|
||||||
fi;
|
fi;
|
||||||
- npm install -g npm@5.6.0
|
- npm install -g npm@6.4.0
|
||||||
|
|
||||||
|
|
||||||
install:
|
install:
|
||||||
|
|
|
@ -6,6 +6,8 @@ This is a part of [Node3D](https://github.com/node-3d) project.
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
|
> npm i -s addon-tools-raub
|
||||||
|
|
||||||
|
|
||||||
## Synopsis
|
## Synopsis
|
||||||
|
|
||||||
|
@ -15,7 +17,7 @@ Helpers for Node.js addons and dependency packages:
|
||||||
* `EventEmitter` C++ implementation.
|
* `EventEmitter` C++ implementation.
|
||||||
* C++ macros and shortcuts.
|
* C++ macros and shortcuts.
|
||||||
* Crossplatform commands for GYP: `cp`, `rm`, `mkdir`.
|
* Crossplatform commands for GYP: `cp`, `rm`, `mkdir`.
|
||||||
* Regarded platforms: win x32/x64, linux x32/x64, mac x64.
|
* Regarded platforms: win x32/x64, linux x64, mac x64.
|
||||||
|
|
||||||
Useful links: [V8 Ref](https://v8.paulfryzel.com/docs/master/),
|
Useful links: [V8 Ref](https://v8.paulfryzel.com/docs/master/),
|
||||||
[Nan Docs](https://github.com/nodejs/nan#api),
|
[Nan Docs](https://github.com/nodejs/nan#api),
|
||||||
|
@ -136,7 +138,6 @@ would encourage you to abide by the following rules:
|
||||||
|
|
||||||
* bin-win32
|
* bin-win32
|
||||||
* bin-win64
|
* bin-win64
|
||||||
* bin-linux32
|
|
||||||
* bin-linux64
|
* bin-linux64
|
||||||
* bin-mac64
|
* bin-mac64
|
||||||
|
|
||||||
|
@ -515,7 +516,7 @@ NAN_METHOD(test) {
|
||||||
...
|
...
|
||||||
```
|
```
|
||||||
|
|
||||||
NOTE: The conversion from `Nan::Utf8String` to `std::string` (via `char *`)
|
> Note: The conversion from `Nan::Utf8String` to `std::string` (via `char *`)
|
||||||
is possible with unary `*` operator.
|
is possible with unary `*` operator.
|
||||||
|
|
||||||
</details>
|
</details>
|
||||||
|
|
12
index.js
12
index.js
|
@ -18,8 +18,16 @@ const prefixName = name => `bin-${name}`;
|
||||||
const getPlatformDir = platform => {
|
const getPlatformDir = platform => {
|
||||||
switch (platform) {
|
switch (platform) {
|
||||||
case 'win32' : return process.arch === 'x64' ? 'win64' : 'win32';
|
case 'win32' : return process.arch === 'x64' ? 'win64' : 'win32';
|
||||||
case 'linux' : return process.arch === 'x64' ? 'linux64' : 'linux32';
|
case 'linux' :
|
||||||
case 'darwin' : return 'mac64';
|
if (process.arch === 'x32') {
|
||||||
|
throw new Error('Linux x32 not supported since 4.0.0.');
|
||||||
|
}
|
||||||
|
return 'linux64';
|
||||||
|
case 'darwin' :
|
||||||
|
if (process.arch === 'x32') {
|
||||||
|
throw new Error('Mac x32 not supported.');
|
||||||
|
}
|
||||||
|
return 'mac64';
|
||||||
default : throw new Error(`Platform "${platform}" is not supported.`);
|
default : throw new Error(`Platform "${platform}" is not supported.`);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"author": "Luis Blanco <luisblanco1337@gmail.com>",
|
"author": "Luis Blanco <luisblanco1337@gmail.com>",
|
||||||
"name": "addon-tools-raub",
|
"name": "addon-tools-raub",
|
||||||
"version": "3.0.0",
|
"version": "4.0.0",
|
||||||
"description": "Helpers for Node.js addons and dependency packages",
|
"description": "Helpers for Node.js addons and dependency packages",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
|
@ -19,7 +19,7 @@
|
||||||
"gyp"
|
"gyp"
|
||||||
],
|
],
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=8.11.2",
|
"node": ">=8.11.4",
|
||||||
"npm": ">=5.6.0"
|
"npm": ">=5.6.0"
|
||||||
},
|
},
|
||||||
"maintainers": [
|
"maintainers": [
|
||||||
|
@ -34,6 +34,6 @@
|
||||||
"url": "https://github.com/node-3d/addon-tools-raub.git"
|
"url": "https://github.com/node-3d/addon-tools-raub.git"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"nan": "~2.10.0"
|
"nan": "2.11.0"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue