如何解决再一次...... libxmljs 不会安装在带有 Node 15.5 的 Win 10 上
Windows 似乎不太支持使用 Node.js 进行 Xml 验证。在我的所有 Windows 10 机器上,安装 libxmljs 与所有 15.x Node.js 版本一致失败。由于我的 C++ 知识真的过时了,我想获得一些帮助以使其在我的机器上运行。有人有想法吗? Linux 或 MacOS 是否存在类似问题?
这是迄今为止生成的最新日志:
0 verbose cli [
0 verbose cli 'C:\\Program Files\\nodejs\\node.exe',0 verbose cli 'C:\\Users\\XXX\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js',0 verbose cli 'i',0 verbose cli 'libxmljs'
0 verbose cli ]
1 info using npm@7.0.10
2 info using node@v15.5.0
3 timing config:load:defaults Completed in 2ms
4 timing config:load:file:C:\Users\XXX\AppData\Roaming\npm\node_modules\npm\npmrc Completed in 51ms
5 timing config:load:builtin Completed in 51ms
6 timing config:load:cli Completed in 2ms
7 timing config:load:env Completed in 1ms
8 timing config:load:file:C:\usr\dvl\JavaScript\YYYY\.npmrc Completed in 1ms
9 timing config:load:project Completed in 6ms
10 timing config:load:file:C:\Users\XXX\.npmrc Completed in 3ms
11 timing config:load:user Completed in 3ms
12 timing config:load:file:C:\Program Files\nodejs\etc\npmrc Completed in 0ms
13 timing config:load:global Completed in 0ms
14 timing config:load:cafile Completed in 0ms
15 timing config:load:validate Completed in 1ms
16 timing config:load:setUserAgent Completed in 1ms
17 timing config:load:setEnvs Completed in 1ms
18 timing config:load Completed in 68ms
19 verbose npm-session c0efbe9ef180745c
20 timing npm:load Completed in 84ms
21 timing arborist:ctor Completed in 1ms
22 timing idealTree:init Completed in 939ms
23 timing idealTree:userRequests Completed in 3ms
24 silly idealTree buildDeps
25 silly fetch manifest libxmljs@*
26 timing arborist:ctor Completed in 0ms
27 http fetch GET 304 https://registry.npmjs.org/libxmljs 842ms (from cache)
28 silly placeDep ROOT libxmljs@0.19.7 OK for: dxl-connection-manager@1.0.0 want: *
29 silly fetch manifest bindings@~1.3.0
30 silly fetch manifest node-pre-gyp@~0.11.0
31 http fetch GET 304 https://registry.npmjs.org/bindings 47ms (from cache)
32 http fetch GET 304 https://registry.npmjs.org/node-pre-gyp 99ms (from cache)
33 timing idealTree:#root Completed in 966ms
34 silly placeDep node_modules/libxmljs bindings@1.3.1 OK for: libxmljs@0.19.7 want: ~1.3.0
35 silly placeDep ROOT node-pre-gyp@0.11.0 OK for: libxmljs@0.19.7 want: ~0.11.0
36 silly fetch manifest detect-libc@^1.0.2
37 silly fetch manifest needle@^2.2.1
38 silly fetch manifest nopt@^4.0.1
39 silly fetch manifest npm-packlist@^1.1.6
40 silly fetch manifest npmlog@^4.0.2
41 silly fetch manifest rc@^1.2.7
42 silly fetch manifest rimraf@^2.6.1
43 silly fetch manifest tar@^4
44 http fetch GET 304 https://registry.npmjs.org/needle 64ms (from cache)
45 http fetch GET 304 https://registry.npmjs.org/nopt 74ms (from cache)
46 http fetch GET 304 https://registry.npmjs.org/detect-libc 142ms (from cache)
47 http fetch GET 304 https://registry.npmjs.org/tar 144ms (from cache)
48 http fetch GET 304 https://registry.npmjs.org/rc 160ms (from cache)
49 http fetch GET 304 https://registry.npmjs.org/npmlog 164ms (from cache)
50 http fetch GET 304 https://registry.npmjs.org/rimraf 161ms (from cache)
51 http fetch GET 304 https://registry.npmjs.org/npm-packlist 173ms (from cache)
52 timing idealTree:node_modules/libxmljs Completed in 185ms
53 silly placeDep ROOT detect-libc@1.0.3 OK for: node-pre-gyp@0.11.0 want: ^1.0.2
54 silly placeDep ROOT needle@2.5.2 OK for: node-pre-gyp@0.11.0 want: ^2.2.1
55 silly placeDep ROOT nopt@4.0.3 OK for: node-pre-gyp@0.11.0 want: ^4.0.1
56 silly placeDep ROOT npm-packlist@1.4.8 OK for: node-pre-gyp@0.11.0 want: ^1.1.6
57 silly placeDep ROOT npmlog@4.1.2 OK for: node-pre-gyp@0.11.0 want: ^4.0.2
58 silly placeDep ROOT rc@1.2.8 OK for: node-pre-gyp@0.11.0 want: ^1.2.7
59 silly placeDep node_modules/node-pre-gyp rimraf@2.7.1 OK for: node-pre-gyp@0.11.0 want: ^2.6.1
60 silly placeDep ROOT tar@4.4.13 OK for: node-pre-gyp@0.11.0 want: ^4
61 silly fetch manifest debug@^3.2.6
62 silly fetch manifest sax@^1.2.4
63 silly fetch manifest abbrev@1
64 silly fetch manifest osenv@^0.1.4
65 silly fetch manifest ignore-walk@^3.0.1
66 silly fetch manifest npm-bundled@^1.0.1
67 silly fetch manifest npm-normalize-package-bin@^1.0.1
68 silly fetch manifest are-we-there-yet@~1.1.2
69 silly fetch manifest console-control-strings@~1.1.0
70 silly fetch manifest gauge@~2.7.3
71 silly fetch manifest deep-extend@^0.6.0
72 silly fetch manifest ini@~1.3.0
73 silly fetch manifest strip-json-comments@~2.0.1
74 silly fetch manifest chownr@^1.1.1
75 silly fetch manifest fs-minipass@^1.2.5
76 silly fetch manifest minipass@^2.8.6
77 silly fetch manifest minizlib@^1.2.1
78 silly fetch manifest yallist@^3.0.3
79 http fetch GET 304 https://registry.npmjs.org/sax 224ms (from cachex
[ *** leaving out some success messages in order to save characters *** ]
180 http fetch GET 200 https://registry.npmjs.org/strip-ansi 12ms (from cache)
181 http fetch GET 304 https://registry.npmjs.org/is-fullwidth-code-point 49ms (from cache)
182 timing idealTree:node_modules/wide-align Completed in 53ms
183 silly placeDep node_modules/gauge is-fullwidth-code-point@1.0.0 OK for: string-width@1.0.2 want: ^1.0.0
184 timing idealTree:node_modules/gauge/node_modules/string-width Completed in 2ms
185 timing idealTree:node_modules/gauge/node_modules/is-fullwidth-code-point Completed in 0ms
186 silly placeDep node_modules/gauge ansi-regex@2.1.1 OK for: strip-ansi@3.0.1 want: ^2.0.0
187 timing idealTree:node_modules/gauge/node_modules/strip-ansi Completed in 1ms
188 timing idealTree:node_modules/gauge/node_modules/ansi-regex Completed in 0ms
189 timing idealTree:node_modules/libxmljs/node_modules/bindings Completed in 0ms
190 timing idealTree:node_modules/minipass/node_modules/yallist Completed in 0ms
191 timing idealTree:node_modules/needle/node_modules/debug Completed in 0ms
192 timing idealTree:node_modules/node-pre-gyp/node_modules/rimraf Completed in 0ms
193 timing idealTree:node_modules/tar/node_modules/yallist Completed in 0ms
194 silly placeDep node_modules/wide-align is-fullwidth-code-point@2.0.0 OK for: string-width@2.1.1 want: ^2.0.0
195 silly placeDep node_modules/wide-align strip-ansi@4.0.0 OK for: string-width@2.1.1 want: ^4.0.0
196 silly fetch manifest ansi-regex@^3.0.0
197 http fetch GET 304 https://registry.npmjs.org/ansi-regex 45ms (from cache)
198 timing idealTree:node_modules/wide-align/node_modules/string-width Completed in 50ms
199 timing idealTree:node_modules/wide-align/node_modules/is-fullwidth-code-point Completed in 1ms
200 silly placeDep node_modules/wide-align ansi-regex@3.0.0 OK for: strip-ansi@4.0.0 want: ^3.0.0
201 timing idealTree:node_modules/wide-align/node_modules/strip-ansi Completed in 1ms
202 timing idealTree:node_modules/wide-align/node_modules/ansi-regex Completed in 0ms
203 timing idealTree:buildDeps Completed in 2000ms
204 timing idealTree:fixDepFlags Completed in 10ms
205 timing idealTree Completed in 2971ms
206 timing reify:loadTrees Completed in 2972ms
207 timing reify:diffTrees Completed in 38ms
208 silly reify moves {}
209 timing reify:retireShallow Completed in 1ms
210 timing reify:createSparse Completed in 92ms
211 timing reify:loadBundles Completed in 0ms
212 timing reifyNode:node_modules/osenv Completed in 634ms
213 timing reifyNode:node_modules/libxmljs/node_modules/bindings Completed in 634ms
214 timing reifyNode:node_modules/chownr Completed in 637ms
215 timing reifyNode:node_modules/fs-minipass Completed in 643ms
216 timing reifyNode:node_modules/os-tmpdir Completed in 644ms
217 timing reifyNode:node_modules/ini Completed in 645ms
218 timing reifyNode:node_modules/strip-json-comments Completed in 646ms
219 timing reifyNode:node_modules/os-homedir Completed in 646ms
220 timing reifyNode:node_modules/wide-align Completed in 646ms
221 timing reifyNode:node_modules/wide-align/node_modules/ansi-regex Completed in 647ms
222 timing reifyNode:node_modules/wide-align/node_modules/strip-ansi Completed in 648ms
223 timing reifyNode:node_modules/wide-align/node_modules/string-width Completed in 649ms
224 timing reifyNode:node_modules/aproba Completed in 648ms
225 timing reifyNode:node_modules/has-unicode Completed in 649ms
226 timing reifyNode:node_modules/wide-align/node_modules/is-fullwidth-code-point Completed in 650ms
227 timing reifyNode:node_modules/gauge/node_modules/ansi-regex Completed in 650ms
228 timing reifyNode:node_modules/gauge/node_modules/strip-ansi Completed in 650ms
229 timing reifyNode:node_modules/gauge/node_modules/is-fullwidth-code-point Completed in 650ms
230 timing reifyNode:node_modules/gauge/node_modules/string-width Completed in 650ms
231 timing reifyNode:node_modules/ignore-walk Completed in 651ms
232 timing reifyNode:node_modules/npm-bundled Completed in 652ms
233 timing reifyNode:node_modules/npm-packlist Completed in 657ms
234 timing reifyNode:node_modules/abbrev Completed in 666ms
235 timing reifyNode:node_modules/minipass Completed in 672ms
236 timing reifyNode:node_modules/minizlib Completed in 677ms
237 timing reifyNode:node_modules/console-control-strings Completed in 676ms
238 timing reifyNode:node_modules/minipass/node_modules/yallist Completed in 692ms
239 timing reifyNode:node_modules/tar/node_modules/yallist Completed in 699ms
240 timing reifyNode:node_modules/node-pre-gyp/node_modules/rimraf Completed in 702ms
241 timing reifyNode:node_modules/deep-extend Completed in 706ms
242 timing reifyNode:node_modules/npmlog Completed in 710ms
243 timing reifyNode:node_modules/sax Completed in 715ms
244 timing reifyNode:node_modules/delegates Completed in 722ms
245 timing reifyNode:node_modules/detect-libc Completed in 740ms
246 timing reifyNode:node_modules/nopt Completed in 742ms
247 timing reifyNode:node_modules/are-we-there-yet Completed in 749ms
248 timing reifyNode:node_modules/needle/node_modules/debug Completed in 760ms
249 timing reifyNode:node_modules/rc Completed in 784ms
250 timing reifyNode:node_modules/npm-normalize-package-bin Completed in 811ms
251 timing reifyNode:node_modules/gauge Completed in 854ms
252 http fetch POST 200 https://registry.npmjs.org/-/npm/v1/security/advisories/bulk 945ms
253 timing auditReport:getReport Completed in 950ms
254 timing Metavuln:cache:get:security-advisory:mem:SBdyJAz7PzbHtnwWkMO+rogal51jICnD4nyzqW8VWXZWJt5UygkE+hg7jafoTcZ3u+l+9QEIT5wpevdBVQxijw== Completed in 54ms
255 timing reifyNode:node_modules/tar Completed in 1004ms
256 timing reifyNode:node_modules/node-pre-gyp Completed in 1063ms
257 http fetch GET 304 https://registry.npmjs.org/mem 254ms (from cache)
258 timing Metavuln:packument:mem Completed in 257ms
259 timing Metavuln:load:security-advisory:mem:1084 Completed in 1ms
260 timing Metavuln:calculate:security-advisory:mem:1084 Completed in 259ms
261 timing Metavuln:cache:get:security-advisory:in-gfw:SoNlHLO6tYd1NL6s9kkKfueEz/rSuSeC0EQmpuTvqJCWERJOyfeEflb0GyQ/uHgWlRnwSbazwErmCZt7VnP+9A== Completed in 74ms
262 timing reifyNode:node_modules/needle Completed in 1336ms
263 http fetch GET 304 https://registry.npmjs.org/in-gfw 434ms (from cache)
264 timing Metavuln:packument:in-gfw Completed in 445ms
265 timing Metavuln:load:security-advisory:in-gfw:SBdyJAz7PzbHtnwWkMO+rogal51jICnD4nyzqW8VWXZWJt5UygkE+hg7jafoTcZ3u+l+9QEIT5wpevdBVQxijw== Completed in 0ms
266 timing Metavuln:calculate:security-advisory:in-gfw:SBdyJAz7PzbHtnwWkMO+rogal51jICnD4nyzqW8VWXZWJt5UygkE+hg7jafoTcZ3u+l+9QEIT5wpevdBVQxijw== Completed in 451ms
267 timing Metavuln:cache:get:security-advisory:windows-build-tools:XFMS6BOvmzoGrdWvbiS89NGPqjCBKjs8hboRN+ZLu/m6coJ2tawHHOQyPxgKelmeVLIyyfR/9y6VC2/Z1DIzpg== Completed in 45ms
268 http fetch GET 304 https://registry.npmjs.org/windows-build-tools 95ms (from cache)
269 timing Metavuln:packument:windows-build-tools Completed in 111ms
270 timing Metavuln:load:security-advisory:windows-build-tools:SoNlHLO6tYd1NL6s9kkKfueEz/rSuSeC0EQmpuTvqJCWERJOyfeEflb0GyQ/uHgWlRnwSbazwErmCZt7VnP+9A== Completed in 2ms
271 timing Metavuln:calculate:security-advisory:windows-build-tools:SoNlHLO6tYd1NL6s9kkKfueEz/rSuSeC0EQmpuTvqJCWERJOyfeEflb0GyQ/uHgWlRnwSbazwErmCZt7VnP+9A== Completed in 114ms
272 timing auditReport:init Completed in 925ms
273 timing reify:audit Completed in 1877ms
274 timing reifyNode:node_modules/libxmljs Completed in 5256ms
275 timing reify:unpack Completed in 5260ms
276 timing reify:unretire Completed in 1ms
277 timing build:queue Completed in 76ms
278 timing build:link:node_modules/needle Completed in 63ms
279 timing build:link:node_modules/detect-libc Completed in 65ms
280 timing build:link:node_modules/node-pre-gyp Completed in 64ms
281 timing build:link:node_modules/nopt Completed in 63ms
282 timing build:link:node_modules/rc Completed in 66ms
283 timing build:link:node_modules/node-pre-gyp/node_modules/rimraf Completed in 68ms
284 timing build:link Completed in 70ms
285 info run libxmljs@0.19.7 install node_modules/libxmljs node-pre-gyp install --fallback-to-build --loglevel http
286 info run libxmljs@0.19.7 install { code: 1,signal: null }
287 timing reify:rollback:createSparse Completed in 0ms
288 timing reify:rollback:retireShallow Completed in 0ms
289 timing command:install Completed in 95471ms
290 verbose stack Error: command Failed
290 verbose stack at ChildProcess.<anonymous> \
(C:\Users\XXX\AppData\Roaming\npm\node_modules\npm\node_modules\@npmcli\promise-spawn\index.js:64:27)
290 verbose stack at ChildProcess.emit (node:events:376:20)
290 verbose stack at maybeClose (node:internal/child_process:1063:16)
290 verbose stack at Process.ChildProcess._handle.onexit \
(node:internal/child_process:295:5)
291 verbose pkgid libxmljs@0.19.7
292 verbose cwd C:\usr\dvl\JavaScript\YYYY
293 verbose Windows_NT 10.0.19042
294 verbose argv "C:\\Program Files\\nodejs\\node.exe" \
"C:\\Users\\XXX\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" \
"i" "libxmljs"
295 verbose node v15.5.0
296 verbose npm v7.0.10
297 error code 1
298 error path C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs
299 error command Failed
300 error command C:\WINDOWS\system32\cmd.exe /d /s /c "node-pre-gyp install \
--fallback-to-build --loglevel http"
301 error Die Projekte in dieser Projektmappe werden nacheinander erstellt. Um eine \
parallele Erstellung zu ermöglichen,müssen Sie den Schalter "-m" hinzufügen.
301 error libxmljs.cc
301 error xml_attribute.cc
301 error xml_document.cc
301 error xml_element.cc
301 error xml_comment.cc
301 error xml_namespace.cc
301 error xml_node.cc
301 error xml_sax_parser.cc
301 error C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\src\xml_sax_parser.cc(130,10): \
warning C4996: 'Nan::MakeCallback': wurde als veraltet deklariert \
[C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\xmljs.vcxproj]
301 error xml_Syntax_error.cc
301 error xml_text.cc
301 error xml_pi.cc
301 error xml_xpath_context.cc
301 error buf.c
301 error catalog.c
301 error \
C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\vendor\libxml\catalog.c(984,19): warning \
C4013: "open" undefiniert; Annahme: extern mit Rückgabetyp int \
[C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\xmljs.vcxproj]
301 error \
C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\vendor\libxml\catalog.c(1003,7): \
warning C4013: "close" undefiniert; Annahme: extern mit Rückgabetyp int \
[C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\xmljs.vcxproj]
301 error \
C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\vendor\libxml\catalog.c(1010,15): \
warning C4013: "read" undefiniert; Annahme: extern mit Rückgabetyp int \
[C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\xmljs.vcxproj]
301 error chvalid.c
301 error dict.c
301 error encoding.c
301 error entities.c
301 error error.c
301 error globals.c
301 error hash.c
301 error HTMLparser.c
301 error HTMLtree.c
301 error legacy.c
301 error list.c
301 error parser.c
301 error parserInternals.c
301 error pattern.c
301 error relaxng.c
301 error SAX2.c
301 error SAX.c
301 error tree.c
301 error threads.c
301 error uri.c
301 error valid.c
301 error xinclude.c
301 error xlink.c
301 error xmlIO.c
301 error \
C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\vendor\libxml\xmlIO.c(733,15): \
warning C4013: "read" undefiniert; Annahme: extern mit Rückgabetyp int \
[C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\xmljs.vcxproj]
301 error \
C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\vendor\libxml\xmlIO.c(754,13): \
warning C4013: "write" undefiniert; Annahme: extern mit Rückgabetyp int \
[C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\xmljs.vcxproj]
301 error \
C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\vendor\libxml\xmlIO.c(772,16): \
warning C4013: "close" undefiniert; Annahme: extern mit Rückgabetyp int \
[C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\xmljs.vcxproj]
301 error \
C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\vendor\libxml\xmlIO.c(3743,19): \
warning C4013: "getcwd" undefiniert; Annahme: extern mit Rückgabetyp int \
[C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\xmljs.vcxproj]
301 error \
C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\vendor\libxml\xmlIO.c(3743,38): \
warning C4047: "!=": Anzahl der Dereferenzierungen bei "int" und "void *" \
unterschiedlich ?
[C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\xmljs.vcxproj]
301 error xmlmemory.c
301 error xmlmodule.c
301 error xmlreader.c
301 error xmlregexp.c
301 error xmlsave.c
301 error xmlschemas.c
301 error xmlschemastypes.c
301 error xmlstring.c
301 error xmlunicode.c
301 error xmlwriter.c
301 error xpath.c
301 error xpointer.c
301 error win_delay_load_hook.cc
301 error LINK : Fatal error LNK1194: Verzögertes Laden von "node.exe" aufgrund des \
Imports des Datensymbols ""__declspec(dllimport) const \
v8::ArrayBuffer::Allocator::`vftable'" (__imp_??_7Allocator@ArrayBuffer@v8@@6B@)" \
nicht möglich. Link ohne /DELAYLOAD:node.exe \
[C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\xmljs.vcxproj]
301 error Failed to execute 'C:\Program Files\nodejs\node.exe \
C:\Users\XXX\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js build \
--fallback-to-build --loglevel=http \
--module=C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\Release\xmljs.node \
--module_name=xmljs \
--module_path=C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\Release \
--napi_version=7 --node_abi_napi=napi --napi_build_version=0 \
--node_napi_label=node-v88' (1)
302 error node-pre-gyp WARN Using request for node-pre-gyp https download
302 error node-pre-gyp http GET \
https://github.com/libxmljs/libxmljs/releases/download/v0.19.7/node-v88-win32-x64.tar.gz
302 error node-pre-gyp http 404 \
https://github.com/libxmljs/libxmljs/releases/download/v0.19.7/node-v88-win32-x64.tar.gz
302 error node-pre-gyp WARN Tried to download(404): \
https://github.com/libxmljs/libxmljs/releases/download/v0.19.7/node-v88-win32-x64.tar.gz
302 error node-pre-gyp WARN Pre-built binaries not found for libxmljs@0.19.7 and \
node@15.5.0 (node-v88 ABI,unkNown) (falling back to source compile with node-gyp)
302 error node-pre-gyp http 404 status code downloading tarball \
https://github.com/libxmljs/libxmljs/releases/download/v0.19.7/node-v88-win32-x64.tar.gz
302 error gyp info it worked if it ends with ok
302 error gyp info using node-gyp@7.1.2
302 error gyp info using node@15.5.0 | win32 | x64
302 error gyp info ok
302 error gyp http GET https://nodejs.org/download/release/v15.5.0/node-v15.5.0-headers.tar.gz
302 error gyp http 200 https://nodejs.org/download/release/v15.5.0/node-v15.5.0-headers.tar.gz
302 error gyp http GET https://nodejs.org/download/release/v15.5.0/SHASUMS256.txt
302 error gyp http GET https://nodejs.org/download/release/v15.5.0/win-x86/node.lib
302 error gyp http GET https://nodejs.org/download/release/v15.5.0/win-arm64/node.lib
302 error gyp http GET https://nodejs.org/download/release/v15.5.0/win-x64/node.lib
302 error gyp http 200 https://nodejs.org/download/release/v15.5.0/SHASUMS256.txt
302 error gyp http 200 https://nodejs.org/download/release/v15.5.0/win-x86/node.lib
302 error gyp http 404 https://nodejs.org/download/release/v15.5.0/win-arm64/node.lib
302 error gyp http 200 https://nodejs.org/download/release/v15.5.0/win-x64/node.lib
302 error gyp ERR! build error
302 error gyp ERR! stack Error: `C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\MSBuild\Current\Bin\MSBuild.exe` \
Failed with exit code: 1
302 error gyp ERR! stack at ChildProcess.onExit \
(C:\Users\XXX\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\build.js:194:23)
302 error gyp ERR! stack at ChildProcess.emit (node:events:376:20)
302 error gyp ERR! stack at Process.ChildProcess._handle.onexit \
(node:internal/child_process:284:12)
302 error gyp ERR! System Windows_NT 10.0.19042
302 error gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" \
"C:\\Users\\XXX\\AppData\\Roaming\\npm\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" \
"build" "--fallback-to-build" "--loglevel=http" \
"--module=C:\\usr\\dvl\\JavaScript\\YYYY\\node_modules\\libxmljs\\build\\Release\\xmljs.node" \
"--module_name=xmljs" \
"--module_path=C:\\usr\\dvl\\JavaScript\\YYYY\\node_modules\\libxmljs\\build\\Release" \
"--napi_version=7" "--node_abi_napi=napi" "--napi_build_version=0" \
"--node_napi_label=node-v88"
302 error gyp ERR! cwd C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs
302 error gyp ERR! node -v v15.5.0
302 error gyp ERR! node-gyp -v v7.1.2
302 error gyp ERR! not ok
302 error node-pre-gyp ERR! build error
302 error node-pre-gyp ERR! stack Error: Failed to execute \
'C:\Program Files\nodejs\node.exe \
C:\Users\XXX\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js \
build --fallback-to-build --loglevel=http \
--module=C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\Release\xmljs.node \
--module_name=xmljs \
--module_path=C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs\build\Release \
--napi_version=7 --node_abi_napi=napi --napi_build_version=0 \
--node_napi_label=node-v88' (1)
302 error node-pre-gyp ERR! stack at ChildProcess.<anonymous> \
(C:\usr\dvl\JavaScript\YYYY\node_modules\node-pre-gyp\lib\util\compile.js:83:29)
302 error node-pre-gyp ERR! stack at ChildProcess.emit (node:events:3A76:20)
302 error node-pre-gyp ERR! stack at maybeClose \
(node:internal/child_process:1063:16)
302 error node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit \
(node:internal/child_process:295:5)
302 error node-pre-gyp ERR! System Windows_NT 10.0.19042
302 error node-pre-gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" \
"C:\\usr\\dvl\\JavaScript\\YYYY\\node_modules\\node-pre-gyp\\bin\\node-pre-gyp" \
"install" "--fallback-to-build" "--loglevel" "http"
302 error node-pre-gyp ERR! cwd C:\usr\dvl\JavaScript\YYYY\node_modules\libxmljs
302 error node-pre-gyp ERR! node -v v15.5.0
302 error node-pre-gyp ERR! node-pre-gyp -v v0.11.0
302 error node-pre-gyp ERR! not ok
303 verbose exit 1
解决方法
我的印象是不再维护用于 Windows 的 libxmljs gyp 构建脚本。然而,正如我(准确地说是 Google 博士)发现的那样,libxmljs2 和 libxmljs2-xsd 的组合似乎形成了一个很好的替代品。由于我无法与 libxml.js 进行比较,因此我无法判断 libxmljs 和 libxmljs2 是否等效。但是,libxmljs2 完成了我目前所需要的一切,例如架构验证。
观察:无论编码集如何,Document.toString() 始终输出“UTF-8”。我不知道行为是否与 libxmljs 相同 - 我希望输出实际的编码。这是有道理的,因为我可以使用任何编码将 Xml 字符串转换为字节数组,因此,例如,如果我使用 latin-1,在序言中指定“UTF-8”会产生误导。
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。