Add aarch64

This commit is contained in:
Luis Blanco 2022-12-24 17:10:35 +04:00
parent d4ed519e71
commit a274cd227e
8 changed files with 95 additions and 88 deletions

View File

@ -36,7 +36,7 @@ jobs:
name: Unit Tests name: Unit Tests
strategy: strategy:
matrix: matrix:
os: [ubuntu-20.04, windows-2022, macos-11] os: [ubuntu-20.04, windows-2022, macos-11, [self-hosted, linux, ARM64]]
runs-on: ${{ matrix.os }} runs-on: ${{ matrix.os }}

View File

@ -11,6 +11,7 @@ with
``` ```
#include <addon-tools.hpp> #include <addon-tools.hpp>
``` ```
In **GYP**, the include directory should be set for your addon. In **GYP**, the include directory should be set for your addon.
An actual path to the directory is exported from the module An actual path to the directory is exported from the module
and is accessible like this: and is accessible like this:

View File

@ -19,7 +19,7 @@ A snippet for **src/package.json**:
"rebuild-dev": "node-gyp rebuild && node -e \"require('addon-tools-raub/cpbin')('ADDON')\"" "rebuild-dev": "node-gyp rebuild && node -e \"require('addon-tools-raub/cpbin')('ADDON')\""
}, },
"dependencies": { "dependencies": {
"addon-tools-raub": "6.1.0", "addon-tools-raub": "6.2.0",
"DEPS": "1.0.0" "DEPS": "1.0.0"
} }
} }
@ -43,8 +43,8 @@ In **package.json**:
"postinstall": "node install", "postinstall": "node install",
}, },
"dependencies": { "dependencies": {
"addon-tools-raub": "^6.0.2", "addon-tools-raub": "^6.2.0",
"adm-zip": "^0.5.9" "adm-zip": "^0.5.10"
}, },
"devDependencies": { "devDependencies": {
"node-addon-api": "^5.0.0" "node-addon-api": "^5.0.0"
@ -146,9 +146,9 @@ dependency include path(s).
'<(DEPS_include)', '<(DEPS_include)',
], ],
'defines': ['UNICODE', '_UNICODE'], 'defines': ['UNICODE', '_UNICODE'],
'cflags_cc': ['-std=c++17', '-fno-exceptions'],
'library_dirs': ['<(DEPS_bin)'], 'library_dirs': ['<(DEPS_bin)'],
'libraries': ['-lDEPS' ], 'libraries': ['-lDEPS' ],
'cflags_cc': ['-std=c++17'],
'conditions': [ 'conditions': [
['OS=="linux"', { ['OS=="linux"', {
'libraries': [ 'libraries': [
@ -167,22 +167,19 @@ dependency include path(s).
'MACOSX_DEPLOYMENT_TARGET': '10.9', 'MACOSX_DEPLOYMENT_TARGET': '10.9',
'defines': ['__APPLE__'], 'defines': ['__APPLE__'],
'CLANG_CXX_LIBRARY': 'libc++', 'CLANG_CXX_LIBRARY': 'libc++',
'OTHER_CFLAGS': ['-std=c++17'], 'OTHER_CFLAGS': ['-std=c++17', '-fno-exceptions'],
}], }],
['OS=="win"', { ['OS=="win"', {
'defines' : [ 'defines' : ['WIN32_LEAN_AND_MEAN', 'VC_EXTRALEAN', '_WIN32', '_HAS_EXCEPTIONS=0'],
'WIN32_LEAN_AND_MEAN',
'VC_EXTRALEAN',
'_WIN32',
],
'msvs_settings' : { 'msvs_settings' : {
'VCCLCompilerTool' : { 'VCCLCompilerTool' : {
'AdditionalOptions' : [ 'AdditionalOptions' : [
'/GL', '/GF', '/EHsc', '/GS', '/Gy', '/GR-', '/O2','/Oy','/GL','/GF','/Gm-', '/std:c++17',
'/EHa-s-c-r-','/MT','/GS','/Gy','/GR-','/Gd',
] ]
}, },
'VCLinkerTool' : { 'VCLinkerTool' : {
'AdditionalOptions' : ['/RELEASE','/OPT:REF','/OPT:ICF','/LTCG'], 'AdditionalOptions' : ['/OPT:REF','/OPT:ICF','/LTCG']
}, },
}, },
}], }],

21
index.d.ts vendored
View File

@ -6,29 +6,30 @@ declare module "addon-tools-raub" {
export const paths: (dir: string) => Readonly<{ export const paths: (dir: string) => Readonly<{
/** /**
* Path to binaries * Path to binaries
* Platform binary directory absolute path * Platform binary directory absolute path for this `dir`
*/ */
bin: string; bin: string;
/** /**
* Path to include * Path to include
* Include directory for this dir * Include directory for this `dir`
*/ */
include: string; include: string;
}>; }>;
type TPlatformName = 'windows' | 'linux' | 'osx' | 'aarch64' | 'unknown';
type TPlatformDir = `bin-${TPlatformName}`;
/** /**
* Binary folder name
* Platform-dependent binary directory name * Platform-dependent binary directory name
*/ */
export const bin: string; export const bin: TPlatformDir;
/**
* Platform name export const platform: TPlatformName;
* One of: 'windows', 'linux', 'osx'
*/
export const platform: string;
/** /**
* Main include directories * Main include directories
* Both 'addon-tools-raub' and 'node-addon-api' include paths. * Both 'addon-tools-raub' and 'node-addon-api' include paths.
* Use with node -p through list context command expansion <!@(...). * For binding.gyp: `'<!@(node -p "require(\'addon-tools-raub\').include")'`
*/ */
export const include: string; export const include: string;
} }

View File

@ -7,20 +7,28 @@ try {
// do nothing // do nothing
} }
const nameWindows = 'windows';
const nameUnknown = 'unknown';
const platformNames = { const platformNames = {
win32: 'windows', win32: nameWindows,
linux: 'linux', linux: 'linux',
darwin: 'osx', darwin: 'osx',
'linux-arm64': 'aarch64',
}; };
const platformName = platformNames[process.platform]; const platformName = (
const isWindows = process.platform === 'win32'; platformNames[process.platform] ||
platformNames[`${process.platform}-${process.arch}`] ||
'unknown'
);
if (!platformName) { if (platformName === nameUnknown) {
console.log(`Error: UNKNOWN PLATFORM "${process.platform}"`); console.log(`Error: UNKNOWN PLATFORM "${process.platform}"`);
} }
const isWindows = platformName === nameWindows;
const rootPath = __dirname.replace(/\\/g, '/'); const rootPath = __dirname.replace(/\\/g, '/');

102
package-lock.json generated
View File

@ -1,28 +1,28 @@
{ {
"name": "addon-tools-raub", "name": "addon-tools-raub",
"version": "6.1.1", "version": "6.2.0",
"lockfileVersion": 2, "lockfileVersion": 2,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "addon-tools-raub", "name": "addon-tools-raub",
"version": "6.1.1", "version": "6.2.0",
"license": "MIT", "license": "MIT",
"devDependencies": { "devDependencies": {
"adm-zip": "^0.5.9", "adm-zip": "^0.5.10",
"eslint": "^8.29.0", "eslint": "^8.30.0",
"eslint-plugin-jest": "^27.1.6", "eslint-plugin-jest": "^27.1.7",
"eslint-plugin-node": "^11.1.0", "eslint-plugin-node": "^11.1.0",
"jest": "^29.3.1", "jest": "^29.3.1",
"node-addon-api": "^5.0.0", "node-addon-api": "^5.0.0",
"typescript": "^4.9.3" "typescript": "^4.9.4"
}, },
"engines": { "engines": {
"node": ">=18.12.1", "node": ">=18.12.1",
"npm": ">=8.19.2" "npm": ">=8.19.2"
}, },
"peerDependencies": { "peerDependencies": {
"adm-zip": "^0.5.9", "adm-zip": "^0.5.10",
"node-addon-api": "^5.0.0" "node-addon-api": "^5.0.0"
}, },
"peerDependenciesMeta": { "peerDependenciesMeta": {
@ -646,15 +646,15 @@
"dev": true "dev": true
}, },
"node_modules/@eslint/eslintrc": { "node_modules/@eslint/eslintrc": {
"version": "1.3.3", "version": "1.4.0",
"resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.3.3.tgz", "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.4.0.tgz",
"integrity": "sha512-uj3pT6Mg+3t39fvLrj8iuCIJ38zKO9FpGtJ4BBJebJhEwjoT+KLVNCcHT5QC9NGRIEi7fZ0ZR8YRb884auB4Lg==", "integrity": "sha512-7yfvXy6MWLgWSFsLhz5yH3iQ52St8cdUY6FoGieKkRDVxuxmrNuUetIuu6cmjNWwniUHiWXjxCr5tTXDrbYS5A==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"ajv": "^6.12.4", "ajv": "^6.12.4",
"debug": "^4.3.2", "debug": "^4.3.2",
"espree": "^9.4.0", "espree": "^9.4.0",
"globals": "^13.15.0", "globals": "^13.19.0",
"ignore": "^5.2.0", "ignore": "^5.2.0",
"import-fresh": "^3.2.1", "import-fresh": "^3.2.1",
"js-yaml": "^4.1.0", "js-yaml": "^4.1.0",
@ -669,9 +669,9 @@
} }
}, },
"node_modules/@humanwhocodes/config-array": { "node_modules/@humanwhocodes/config-array": {
"version": "0.11.7", "version": "0.11.8",
"resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.7.tgz", "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.8.tgz",
"integrity": "sha512-kBbPWzN8oVMLb0hOUYXhmxggL/1cJE6ydvjDIGi9EnAGUyA7cLVKQg+d/Dsm+KZwx2czGHrCmMVLiyg8s5JPKw==", "integrity": "sha512-UybHIJzJnR5Qc/MsD9Kr+RpO2h+/P1GhOwdiLPXK5TWk5sgTdu88bTD9UP+CKbPPh5Rni1u0GjAdYQLemG8g+g==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@humanwhocodes/object-schema": "^1.2.1", "@humanwhocodes/object-schema": "^1.2.1",
@ -1456,9 +1456,9 @@
} }
}, },
"node_modules/adm-zip": { "node_modules/adm-zip": {
"version": "0.5.9", "version": "0.5.10",
"resolved": "https://registry.npmjs.org/adm-zip/-/adm-zip-0.5.9.tgz", "resolved": "https://registry.npmjs.org/adm-zip/-/adm-zip-0.5.10.tgz",
"integrity": "sha512-s+3fXLkeeLjZ2kLjCBwQufpI5fuN+kIGBxu6530nVQZGVol0d7Y/M88/xw9HGGUcJjKf8LutN3VPRUBq6N7Ajg==", "integrity": "sha512-x0HvcHqVJNTPk/Bw8JbLWlWoo6Wwnsug0fnYYro1HBrjxZ3G7/AZk7Ahv8JwDe1uIcz8eBqvu86FuF1POiG7vQ==",
"dev": true, "dev": true,
"engines": { "engines": {
"node": ">=6.0" "node": ">=6.0"
@ -2004,13 +2004,13 @@
} }
}, },
"node_modules/eslint": { "node_modules/eslint": {
"version": "8.29.0", "version": "8.30.0",
"resolved": "https://registry.npmjs.org/eslint/-/eslint-8.29.0.tgz", "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.30.0.tgz",
"integrity": "sha512-isQ4EEiyUjZFbEKvEGJKKGBwXtvXX+zJbkVKCgTuB9t/+jUBcy8avhkEwWJecI15BkRkOYmvIM5ynbhRjEkoeg==", "integrity": "sha512-MGADB39QqYuzEGov+F/qb18r4i7DohCDOfatHaxI2iGlPuC65bwG2gxgO+7DkyL38dRFaRH7RaRAgU6JKL9rMQ==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@eslint/eslintrc": "^1.3.3", "@eslint/eslintrc": "^1.4.0",
"@humanwhocodes/config-array": "^0.11.6", "@humanwhocodes/config-array": "^0.11.8",
"@humanwhocodes/module-importer": "^1.0.1", "@humanwhocodes/module-importer": "^1.0.1",
"@nodelib/fs.walk": "^1.2.8", "@nodelib/fs.walk": "^1.2.8",
"ajv": "^6.10.0", "ajv": "^6.10.0",
@ -2029,7 +2029,7 @@
"file-entry-cache": "^6.0.1", "file-entry-cache": "^6.0.1",
"find-up": "^5.0.0", "find-up": "^5.0.0",
"glob-parent": "^6.0.2", "glob-parent": "^6.0.2",
"globals": "^13.15.0", "globals": "^13.19.0",
"grapheme-splitter": "^1.0.4", "grapheme-splitter": "^1.0.4",
"ignore": "^5.2.0", "ignore": "^5.2.0",
"import-fresh": "^3.0.0", "import-fresh": "^3.0.0",
@ -2103,9 +2103,9 @@
} }
}, },
"node_modules/eslint-plugin-jest": { "node_modules/eslint-plugin-jest": {
"version": "27.1.6", "version": "27.1.7",
"resolved": "https://registry.npmjs.org/eslint-plugin-jest/-/eslint-plugin-jest-27.1.6.tgz", "resolved": "https://registry.npmjs.org/eslint-plugin-jest/-/eslint-plugin-jest-27.1.7.tgz",
"integrity": "sha512-XA7RFLSrlQF9IGtAmhddkUkBuICCTuryfOTfCSWcZHiHb69OilIH05oozH2XA6CEOtztnOd0vgXyvxZodkxGjg==", "integrity": "sha512-0QVzf+og4YI1Qr3UoprkqqhezAZjFffdi62b0IurkCXMqPtRW84/UT4CKsYT80h/D82LA9avjO/80Ou1LdgbaQ==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"@typescript-eslint/utils": "^5.10.0" "@typescript-eslint/utils": "^5.10.0"
@ -2569,9 +2569,9 @@
} }
}, },
"node_modules/globals": { "node_modules/globals": {
"version": "13.18.0", "version": "13.19.0",
"resolved": "https://registry.npmjs.org/globals/-/globals-13.18.0.tgz", "resolved": "https://registry.npmjs.org/globals/-/globals-13.19.0.tgz",
"integrity": "sha512-/mR4KI8Ps2spmoc0Ulu9L7agOF0du1CZNQ3dke8yItYlyKNmGrkONemBbd6V8UTc1Wgcqn21t3WYB7dbRmh6/A==", "integrity": "sha512-dkQ957uSRWHw7CFXLUtUHQI3g3aWApYhfNR2O6jn/907riyTYKVBmxYVROkBcY614FSSeSJh7Xm7SrUWCxvJMQ==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"type-fest": "^0.20.2" "type-fest": "^0.20.2"
@ -5125,15 +5125,15 @@
"dev": true "dev": true
}, },
"@eslint/eslintrc": { "@eslint/eslintrc": {
"version": "1.3.3", "version": "1.4.0",
"resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.3.3.tgz", "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.4.0.tgz",
"integrity": "sha512-uj3pT6Mg+3t39fvLrj8iuCIJ38zKO9FpGtJ4BBJebJhEwjoT+KLVNCcHT5QC9NGRIEi7fZ0ZR8YRb884auB4Lg==", "integrity": "sha512-7yfvXy6MWLgWSFsLhz5yH3iQ52St8cdUY6FoGieKkRDVxuxmrNuUetIuu6cmjNWwniUHiWXjxCr5tTXDrbYS5A==",
"dev": true, "dev": true,
"requires": { "requires": {
"ajv": "^6.12.4", "ajv": "^6.12.4",
"debug": "^4.3.2", "debug": "^4.3.2",
"espree": "^9.4.0", "espree": "^9.4.0",
"globals": "^13.15.0", "globals": "^13.19.0",
"ignore": "^5.2.0", "ignore": "^5.2.0",
"import-fresh": "^3.2.1", "import-fresh": "^3.2.1",
"js-yaml": "^4.1.0", "js-yaml": "^4.1.0",
@ -5142,9 +5142,9 @@
} }
}, },
"@humanwhocodes/config-array": { "@humanwhocodes/config-array": {
"version": "0.11.7", "version": "0.11.8",
"resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.7.tgz", "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.8.tgz",
"integrity": "sha512-kBbPWzN8oVMLb0hOUYXhmxggL/1cJE6ydvjDIGi9EnAGUyA7cLVKQg+d/Dsm+KZwx2czGHrCmMVLiyg8s5JPKw==", "integrity": "sha512-UybHIJzJnR5Qc/MsD9Kr+RpO2h+/P1GhOwdiLPXK5TWk5sgTdu88bTD9UP+CKbPPh5Rni1u0GjAdYQLemG8g+g==",
"dev": true, "dev": true,
"requires": { "requires": {
"@humanwhocodes/object-schema": "^1.2.1", "@humanwhocodes/object-schema": "^1.2.1",
@ -5763,9 +5763,9 @@
"requires": {} "requires": {}
}, },
"adm-zip": { "adm-zip": {
"version": "0.5.9", "version": "0.5.10",
"resolved": "https://registry.npmjs.org/adm-zip/-/adm-zip-0.5.9.tgz", "resolved": "https://registry.npmjs.org/adm-zip/-/adm-zip-0.5.10.tgz",
"integrity": "sha512-s+3fXLkeeLjZ2kLjCBwQufpI5fuN+kIGBxu6530nVQZGVol0d7Y/M88/xw9HGGUcJjKf8LutN3VPRUBq6N7Ajg==", "integrity": "sha512-x0HvcHqVJNTPk/Bw8JbLWlWoo6Wwnsug0fnYYro1HBrjxZ3G7/AZk7Ahv8JwDe1uIcz8eBqvu86FuF1POiG7vQ==",
"dev": true "dev": true
}, },
"ajv": { "ajv": {
@ -6160,13 +6160,13 @@
"dev": true "dev": true
}, },
"eslint": { "eslint": {
"version": "8.29.0", "version": "8.30.0",
"resolved": "https://registry.npmjs.org/eslint/-/eslint-8.29.0.tgz", "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.30.0.tgz",
"integrity": "sha512-isQ4EEiyUjZFbEKvEGJKKGBwXtvXX+zJbkVKCgTuB9t/+jUBcy8avhkEwWJecI15BkRkOYmvIM5ynbhRjEkoeg==", "integrity": "sha512-MGADB39QqYuzEGov+F/qb18r4i7DohCDOfatHaxI2iGlPuC65bwG2gxgO+7DkyL38dRFaRH7RaRAgU6JKL9rMQ==",
"dev": true, "dev": true,
"requires": { "requires": {
"@eslint/eslintrc": "^1.3.3", "@eslint/eslintrc": "^1.4.0",
"@humanwhocodes/config-array": "^0.11.6", "@humanwhocodes/config-array": "^0.11.8",
"@humanwhocodes/module-importer": "^1.0.1", "@humanwhocodes/module-importer": "^1.0.1",
"@nodelib/fs.walk": "^1.2.8", "@nodelib/fs.walk": "^1.2.8",
"ajv": "^6.10.0", "ajv": "^6.10.0",
@ -6185,7 +6185,7 @@
"file-entry-cache": "^6.0.1", "file-entry-cache": "^6.0.1",
"find-up": "^5.0.0", "find-up": "^5.0.0",
"glob-parent": "^6.0.2", "glob-parent": "^6.0.2",
"globals": "^13.15.0", "globals": "^13.19.0",
"grapheme-splitter": "^1.0.4", "grapheme-splitter": "^1.0.4",
"ignore": "^5.2.0", "ignore": "^5.2.0",
"import-fresh": "^3.0.0", "import-fresh": "^3.0.0",
@ -6234,9 +6234,9 @@
} }
}, },
"eslint-plugin-jest": { "eslint-plugin-jest": {
"version": "27.1.6", "version": "27.1.7",
"resolved": "https://registry.npmjs.org/eslint-plugin-jest/-/eslint-plugin-jest-27.1.6.tgz", "resolved": "https://registry.npmjs.org/eslint-plugin-jest/-/eslint-plugin-jest-27.1.7.tgz",
"integrity": "sha512-XA7RFLSrlQF9IGtAmhddkUkBuICCTuryfOTfCSWcZHiHb69OilIH05oozH2XA6CEOtztnOd0vgXyvxZodkxGjg==", "integrity": "sha512-0QVzf+og4YI1Qr3UoprkqqhezAZjFffdi62b0IurkCXMqPtRW84/UT4CKsYT80h/D82LA9avjO/80Ou1LdgbaQ==",
"dev": true, "dev": true,
"requires": { "requires": {
"@typescript-eslint/utils": "^5.10.0" "@typescript-eslint/utils": "^5.10.0"
@ -6566,9 +6566,9 @@
} }
}, },
"globals": { "globals": {
"version": "13.18.0", "version": "13.19.0",
"resolved": "https://registry.npmjs.org/globals/-/globals-13.18.0.tgz", "resolved": "https://registry.npmjs.org/globals/-/globals-13.19.0.tgz",
"integrity": "sha512-/mR4KI8Ps2spmoc0Ulu9L7agOF0du1CZNQ3dke8yItYlyKNmGrkONemBbd6V8UTc1Wgcqn21t3WYB7dbRmh6/A==", "integrity": "sha512-dkQ957uSRWHw7CFXLUtUHQI3g3aWApYhfNR2O6jn/907riyTYKVBmxYVROkBcY614FSSeSJh7Xm7SrUWCxvJMQ==",
"dev": true, "dev": true,
"requires": { "requires": {
"type-fest": "^0.20.2" "type-fest": "^0.20.2"

View File

@ -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": "6.1.1", "version": "6.2.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",
@ -67,7 +67,7 @@
"url": "https://github.com/node-3d/addon-tools-raub.git" "url": "https://github.com/node-3d/addon-tools-raub.git"
}, },
"peerDependencies": { "peerDependencies": {
"adm-zip": "^0.5.9", "adm-zip": "^0.5.10",
"node-addon-api": "^5.0.0" "node-addon-api": "^5.0.0"
}, },
"peerDependenciesMeta": { "peerDependenciesMeta": {
@ -75,12 +75,12 @@
"node-addon-api": { "optional": true } "node-addon-api": { "optional": true }
}, },
"devDependencies": { "devDependencies": {
"adm-zip": "^0.5.9", "adm-zip": "^0.5.10",
"eslint-plugin-jest": "^27.1.6", "eslint-plugin-jest": "^27.1.7",
"eslint-plugin-node": "^11.1.0", "eslint-plugin-node": "^11.1.0",
"eslint": "^8.29.0", "eslint": "^8.30.0",
"jest": "^29.3.1", "jest": "^29.3.1",
"node-addon-api": "^5.0.0", "node-addon-api": "^5.0.0",
"typescript": "^4.9.3" "typescript": "^4.9.4"
} }
} }

8
test/binding.gyp vendored
View File

@ -5,7 +5,7 @@
'test.cpp', 'test.cpp',
], ],
'defines': ['UNICODE', '_UNICODE'], 'defines': ['UNICODE', '_UNICODE'],
'cflags_cc': ['-std=c++17'], 'cflags_cc': ['-std=c++17', '-fno-exceptions'],
'include_dirs': [ 'include_dirs': [
'<!@(node -p "require(\'..\').include")', '<!@(node -p "require(\'..\').include")',
], ],
@ -17,15 +17,15 @@
'MACOSX_DEPLOYMENT_TARGET': '10.9', 'MACOSX_DEPLOYMENT_TARGET': '10.9',
'defines': ['__APPLE__'], 'defines': ['__APPLE__'],
'CLANG_CXX_LIBRARY': 'libc++', 'CLANG_CXX_LIBRARY': 'libc++',
'OTHER_CFLAGS': ['-std=c++17'], 'OTHER_CFLAGS': ['-std=c++17', '-fno-exceptions'],
}], }],
['OS=="win"', { ['OS=="win"', {
'defines' : ['WIN32_LEAN_AND_MEAN', 'VC_EXTRALEAN', '_WIN32'], 'defines' : ['WIN32_LEAN_AND_MEAN', 'VC_EXTRALEAN', '_WIN32', '_HAS_EXCEPTIONS=0'],
'msvs_settings' : { 'msvs_settings' : {
'VCCLCompilerTool' : { 'VCCLCompilerTool' : {
'AdditionalOptions' : [ 'AdditionalOptions' : [
'/O2','/Oy','/GL','/GF','/Gm-', '/std:c++17', '/O2','/Oy','/GL','/GF','/Gm-', '/std:c++17',
'/EHsc','/MT','/GS','/Gy','/GR-','/Gd', '/EHa-s-c-r-','/MT','/GS','/Gy','/GR-','/Gd',
] ]
}, },
'VCLinkerTool' : { 'VCLinkerTool' : {