簡體   English   中英

macOS和dyld:未找到符號:_usdt_create_provider

[英]macOS & dyld: Symbol not found: _usdt_create_provider

簡而言之,我無法在開發計算機上安裝@ pact-foundation / pact-node,從我的收集來看,它似乎與在macOS 10.14上存在松散的關系。 松散地說,這不會影響運行同一堆棧的其他非開發計算機。

在nvm中,除了系統Node也是11.6.0之外,我還嘗試使用Node 8.14.0、8.15.0、94.0、10.14.2、10.15.0和11.6.0。 不管我是在團隊的項目目錄中還是在其他空的沙箱目錄中,每個版本都會產生相同的錯誤消息。

直到幾分鍾前,我一直在運行macOS 10.14.1,並且在10.14.2上看到了相同的問題。 沒有尚未安裝的更新。

軟件包安裝輸出如下。

$ npm install @pact-foundation/pact-node

> dtrace-provider@0.8.7 install /Users/andrewgould/www/sandbox/node_modules/dtrace-provider
> node-gyp rebuild || node suppress-error.js

  ACTION binding_gyp_ndtp_target_build_ndtp .
  TOUCH Release/obj.target/ndtp.stamp

> spawn-sync@1.0.15 postinstall /Users/andrewgould/www/sandbox/node_modules/spawn-sync
> node postinstall


> caporal@0.10.0 postinstall /Users/andrewgould/www/sandbox/node_modules/caporal
> (test -f ./node_modules/husky/bin/install.js && node ./node_modules/husky/bin/install.js) || exit 0


> @pact-foundation/pact-node@6.20.0 postinstall /Users/andrewgould/www/sandbox/node_modules/@pact-foundation/pact-node
> node postinstall.js

dyld: lazy symbol binding failed: Symbol not found: _usdt_create_provider
  Referenced from: /Users/andrewgould/www/sandbox/node_modules/dtrace-provider/src/build/Release/DTraceProviderBindings.node
  Expected in: flat namespace

dyld: Symbol not found: _usdt_create_provider
  Referenced from: /Users/andrewgould/www/sandbox/node_modules/dtrace-provider/src/build/Release/DTraceProviderBindings.node
  Expected in: flat namespace

Abort trap: 6

以前有沒有人見過這樣的錯誤? 有已知的解決方案嗎?

原來,這個問題是由我通過Homebrew安裝的binutils引起的。 卸載可以解決問題。

GNU binutils網站上,其中包含的主要軟件包是ld ,GNU鏈接器和as ,即GNU匯編器。 這兩個工具都包含在macOS中,但是這些工具的Homebrew版本導致了上述問題中顯示的沖突。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM