@neon-rs/cli 0.1.70 → 0.1.72
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +11 -1
- package/package.json +8 -8
package/index.js
CHANGED
|
@@ -40277,6 +40277,14 @@ var lib_platform = __nccwpck_require__(8140);
|
|
|
40277
40277
|
|
|
40278
40278
|
|
|
40279
40279
|
|
|
40280
|
+
// Starting around Rust 1.78 or 1.79, cargo will begin normalizing
|
|
40281
|
+
// crate names in the JSON output, so to support both old and new
|
|
40282
|
+
// versions of cargo, we need to compare against both variants.
|
|
40283
|
+
//
|
|
40284
|
+
// See: https://github.com/rust-lang/cargo/issues/13867
|
|
40285
|
+
function normalize(crateName) {
|
|
40286
|
+
return crateName.replaceAll(/-/g, "_");
|
|
40287
|
+
}
|
|
40280
40288
|
// FIXME: add options to infer crate name from manifests
|
|
40281
40289
|
// --package <path/to/package.json>
|
|
40282
40290
|
// --crate <path/to/Cargo.toml>
|
|
@@ -40366,6 +40374,7 @@ class Dist {
|
|
|
40366
40374
|
_mount;
|
|
40367
40375
|
_manifestPath;
|
|
40368
40376
|
_crateName;
|
|
40377
|
+
_normalizedCrateName;
|
|
40369
40378
|
_out;
|
|
40370
40379
|
_verbose;
|
|
40371
40380
|
constructor(argv) {
|
|
@@ -40385,6 +40394,7 @@ class Dist {
|
|
|
40385
40394
|
this._manifestPath = options['manifest-path'];
|
|
40386
40395
|
this._crateName = options.name ||
|
|
40387
40396
|
basename(ensureDefined(process.env['npm_package_name'], '$npm_package_name'));
|
|
40397
|
+
this._normalizedCrateName = normalize(this._crateName);
|
|
40388
40398
|
this._out = parseOutputFile(options.debug, options.out, options.platform);
|
|
40389
40399
|
this._verbose = !!options.verbose;
|
|
40390
40400
|
this.log(`crate name = "${this._crateName}"`);
|
|
@@ -40397,7 +40407,7 @@ class Dist {
|
|
|
40397
40407
|
});
|
|
40398
40408
|
let file = null;
|
|
40399
40409
|
for await (const msg of reader) {
|
|
40400
|
-
if (!file && msg.isCompilerArtifact() && msg.crateName() === this.
|
|
40410
|
+
if (!file && msg.isCompilerArtifact() && normalize(msg.crateName()) === this._normalizedCrateName) {
|
|
40401
40411
|
file = msg.findFileByCrateType('cdylib');
|
|
40402
40412
|
}
|
|
40403
40413
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@neon-rs/cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.72",
|
|
4
4
|
"description": "Command-line build tool for Neon modules.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": "./index.js",
|
|
@@ -27,12 +27,12 @@
|
|
|
27
27
|
},
|
|
28
28
|
"homepage": "https://github.com/dherman/neon-rs#readme",
|
|
29
29
|
"optionalDependencies": {
|
|
30
|
-
"@cargo-messages/android-arm-eabi": "0.1.
|
|
31
|
-
"@cargo-messages/darwin-arm64": "0.1.
|
|
32
|
-
"@cargo-messages/darwin-x64": "0.1.
|
|
33
|
-
"@cargo-messages/linux-arm-gnueabihf": "0.1.
|
|
34
|
-
"@cargo-messages/linux-x64-gnu": "0.1.
|
|
35
|
-
"@cargo-messages/win32-arm64-msvc": "0.1.
|
|
36
|
-
"@cargo-messages/win32-x64-msvc": "0.1.
|
|
30
|
+
"@cargo-messages/android-arm-eabi": "0.1.71",
|
|
31
|
+
"@cargo-messages/darwin-arm64": "0.1.71",
|
|
32
|
+
"@cargo-messages/darwin-x64": "0.1.71",
|
|
33
|
+
"@cargo-messages/linux-arm-gnueabihf": "0.1.71",
|
|
34
|
+
"@cargo-messages/linux-x64-gnu": "0.1.71",
|
|
35
|
+
"@cargo-messages/win32-arm64-msvc": "0.1.71",
|
|
36
|
+
"@cargo-messages/win32-x64-msvc": "0.1.71"
|
|
37
37
|
}
|
|
38
38
|
}
|