Skip to content

build error when add registry-js #190

@zredb

Description

@zredb

Hi,
When I add registry-js via npm install registry-js, the program build will fail. the details log is as below:

=======================================================================
C:\code\Msp_electron>npm install registry-js --python="C:\Users\zredb\miniconda3\python.exe"

[email protected] install C:\code\Msp_electron\node_modules\registry-js
prebuild-install || node-gyp rebuild

prebuild-install WARN install unexpected end of file

C:\code\Msp_electron\node_modules\registry-js>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin\....\node_modules\node-gyp\bin\node-gyp.js" rebuild ) else (node "C:\Program Files\nodejs\node_
modules\npm\node_modules\node-gyp\bin\node-gyp.js" rebuild )
在此解决方案中一次生成一个项目。若要启用并行生成,请添加“-m”开关。
main.cc
win_delay_load_hook.cc
正在创建库 C:\code\Msp_electron\node_modules\registry-js\build\Release\registry.lib 和对象 C:\code\Msp_electron\node_modules\registry-js\build\Release\registry.exp
registry.vcxproj -> C:\code\Msp_electron\node_modules\registry-js\build\Release\registry.node
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\webpack-dev-server\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\watchpack-chokidar2\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

  • [email protected]
    added 34 packages from 25 contributors, removed 2 packages and audited 1666 packages in 25.114s
    found 1 low severity vulnerability
    run npm audit fix to fix them, or npm audit for details

C:\code\Msp_electron>yarn serve
yarn run v1.21.1
$ vue-cli-service electron:serve
INFO Starting development server...
98% after emitting CopyPlugin

DONE Compiled successfully in 28118ms 9:11:15

App running at:

Note that the development build is not optimized.
To create a production build, run yarn build.

\ Bundling main process...

ERROR Failed to compile with 1 errors 9:11:18

error in ./node_modules/registry-js/build/Release/registry.node

Module parse failed: Unexpected character '�' (1:2)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
(Source code omitted for this binary file)

@ ./node_modules/registry-js/dist/lib/registry.js 5:6-50
@ ./node_modules/registry-js/dist/lib/index.js
@ ./src/background.js
@ multi ./src/background.js

ERROR Build failed with errors.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

C:\code\Msp_electron>

Any one can give some suggestion?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions