簡體   English   中英

未找到dyld符號,但nm報告否則(OS X更新問題)

[英]dyld symbol not found, but nm reports otherwise (OS X Update issue)

我正在開發一個OpenGL項目,它編譯得很好,運行它會產生以下錯誤:

swr-130-64-133-128:assignment Marcella$ ./run
dyld: lazy symbol binding failed: Symbol not found: _gliCreateContextWithShared
  Referenced from: /System/Library/Frameworks/OpenGL.framework/Resources/GLEngine.bundle/GLEngine
  Expected in: flat namespace

dyld: Symbol not found: _gliCreateContextWithShared
  Referenced from: /System/Library/Frameworks/OpenGL.framework/Resources/GLEngine.bundle/GLEngine
  Expected in: flat namespace

我認為這意味着OpenGL框架中缺少一個符號。 但是, nm另有說法:

0000000000001239 T _gliCreateContextWithShared

Asher有一個類似的問題,但我無法弄清楚如何將他的解決方案應用於我的情況。

值得注意的是:我最近升級到了OS X 10.9.2,而且依賴於這個庫的所有項目現在都失敗並出現同樣的錯誤。

通過添加修復它

export DYLD_INSERT_LIBRARIES='/System/Library/Frameworks/OpenGL.framework/Resources/GLEngine.bundle/GLEngine' 

到我的.bash_profile。 可能不是最優雅的解決方案,但這就是生活。

暫無
暫無

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

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