Giter Club home page Giter Club logo

Comments (6)

lqsong avatar lqsong commented on May 26, 2024

新项目很多依赖gyp的编译,npm install --global --production windows-build-tools命令有的时候不起作用,还是安装了visual studio2019,但模块太多了,不知道要选哪些

你说的“模块”具体指的哪些?本项目和编辑器没有关系,编辑器的使用看个人习惯。

from admin-antd-vue.

chengkai2022 avatar chengkai2022 commented on May 26, 2024

乱选一通,vs安了好大个软件(因为之前会报错做不到vs),终于支持gyp了,但是项目用npm就是安装不了依赖,用yarn可以,整了一晚上也没整好

from admin-antd-vue.

lqsong avatar lqsong commented on May 26, 2024

乱选一通,vs安了好大个软件(因为之前会报错做不到vs),终于支持gyp了,但是项目用npm就是安装不了依赖,用yarn可以,整了一晚上也没整好

不好意思,你说的和本项目有关系吗?

from admin-antd-vue.

chengkai2022 avatar chengkai2022 commented on May 26, 2024

可能我是没说清楚,如果用npm安装这个项目,会报错,yarn不会,什么原因呢
npm ERR! code 1
npm ERR! path C:\Users\jack 程\Desktop\new\admin-antd-vue\node_modules\canvas
npm ERR! command failed
npm ERR! command C:\Windows\system32\cmd.exe /d /s /c node-gyp rebuild
npm ERR! Warning: Missing input files:
npm ERR! C:\GTK\bin\zlib1.dll
npm ERR! C:\GTK\bin\libintl-8.dll
npm ERR! C:\GTK\bin\libpangowin32-1.0-0.dll
npm ERR! C:\GTK\bin\libfreetype-6.dll
npm ERR! C:\GTK\bin\libgmodule-2.0-0.dll
npm ERR! C:\GTK\bin\libpangocairo-1.0-0.dll
npm ERR! C:\GTK\bin\libgthread-2.0-0.dll
npm ERR! C:\GTK\bin\libgobject-2.0-0.dll
npm ERR! C:\GTK\bin\libpango-1.0-0.dll
npm ERR! C:\GTK\bin\libglib-2.0-0.dll
npm ERR! C:\GTK\bin\libpng14-14.dll
npm ERR! C:\GTK\bin\libfontconfig-1.dll
npm ERR! C:\GTK\bin\libcairo-2.dll
npm ERR! C:\GTK\bin\libpangoft2-1.0-0.dll
npm ERR! C:\GTK\bin\libexpat-1.dll
npm ERR! �ڴ˽��������һ������һ����Ŀ����Ҫ���ò������ɣ������ӡ�-m�����ء�
npm ERR! Backend.cc
npm ERR! C:\Users\jack ��\Desktop\new\admin-antd-vue\node_modules\canvas\src\backend\Backend.h(3,10): fatal error C1083: �޷��򿪰����ļ�: ��cairo.h��: No such file or directory [C:\Users\jack ��\Desktop\new\admi n-antd-vue\node_modules\canvas\build\canvas.vcxproj]
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using [email protected]
npm ERR! gyp info using [email protected] | win32 | x64
npm ERR! gyp info find Python using Python version 3.9.4 found at "D:\tools\python\python.exe"
npm ERR! gyp info find VS using VS2019 (16.9.31205.134) found at:
npm ERR! gyp info find VS "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise"
npm ERR! gyp info find VS run with --verbose for detailed information
npm ERR! gyp info spawn D:\tools\python\python.exe
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args 'D:\tools\node.js\node_global\node_modules\npm\node_modules\node-gyp\gyp\gyp_main.py',
npm ERR! gyp info spawn args 'binding.gyp',
npm ERR! gyp info spawn args '-f',
npm ERR! gyp info spawn args 'msvs',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args 'C:\Users\jack 程\Desktop\new\admin-antd-vue\node_modules\canvas\build\config.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args 'D:\tools\node.js\node_global\node_modules\npm\node_modules\node-gyp\addon.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args 'C:\Users\jack 程\AppData\Local\node-gyp\Cache\14.16.1\include\node\common.gypi',
npm ERR! gyp info spawn args '-Dlibrary=shared_library',
npm ERR! gyp info spawn args '-Dvisibility=default',
npm ERR! gyp info spawn args '-Dnode_root_dir=C:\Users\jack 程\AppData\Local\node-gyp\Cache\14.16.1',
npm ERR! gyp info spawn args '-Dnode_gyp_dir=D:\tools\node.js\node_global\node_modules\npm\node_modules\node-gyp',
npm ERR! gyp info spawn args '-Dnode_lib_file=C:\\Users\\jack 程\\AppData\\Local\\node-gyp\\Cache\\14.16.1\\<(target_arch)\\node.lib',
npm ERR! gyp info spawn args '-Dmodule_root_dir=C:\Users\jack 程\Desktop\new\admin-antd-vue\node_modules\canvas',
npm ERR! gyp info spawn args '-Dnode_engine=v8',
npm ERR! gyp info spawn args '--depth=.',
npm ERR! gyp info spawn args '--no-parallel',
npm ERR! gyp info spawn args '--generator-output',
npm ERR! gyp info spawn args 'C:\Users\jack 程\Desktop\new\admin-antd-vue\node_modules\canvas\build',
npm ERR! gyp info spawn args '-Goutput_dir=.'
npm ERR! gyp info spawn args ]
npm ERR! gyp info spawn C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current\Bin\MSBuild.exe
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args 'build/binding.sln',
npm ERR! gyp info spawn args '/clp:Verbosity=minimal',
npm ERR! gyp info spawn args '/nologo',
npm ERR! gyp info spawn args '/p:Configuration=Release;Platform=x64'
npm ERR! gyp info spawn args ]
npm ERR! gyp ERR! build error
npm ERR! gyp ERR! stack Error: C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current\Bin\MSBuild.exe failed with exit code: 1
npm ERR! gyp ERR! stack at ChildProcess.onExit (D:\tools\node.js\node_global\node_modules\npm\node_modules\node-gyp\lib\build.js:194:23)
npm ERR! gyp ERR! stack at ChildProcess.emit (events.js:315:20)
npm ERR! gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12)
npm ERR! gyp ERR! System Windows_NT 10.0.19041
npm ERR! gyp ERR! command "D:\tools\node.js\node.exe" "D:\tools\node.js\node_global\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd C:\Users\jack 程\Desktop\new\admin-antd-vue\node_modules\canvas
npm ERR! gyp ERR! node -v v14.16.1
npm ERR! gyp ERR! node-gyp -v v7.1.2
npm ERR! gyp ERR! not ok

from admin-antd-vue.

lqsong avatar lqsong commented on May 26, 2024

o(╥﹏╥)o,你好,用npm安装报错,是你这边自己本地环境的问题,这个需要你自己排查本地环境。
你可参考:
http://admin-antd-vue.liqingsong.cc/webpackts/guide/#前序准备
http://liqingsong.cc/article/detail/12
http://liqingsong.cc/article/detail/4

from admin-antd-vue.

chengkai2022 avatar chengkai2022 commented on May 26, 2024

谢谢大哥,新手初上路

from admin-antd-vue.

Related Issues (9)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.