几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量  


返回   几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量 » 仿射空间:CAX软件开发(三)二次开发与程序设计 » CAD二次开发 » AutoCAD二次开发 » DirectDWG
用户名
密码
注册 帮助 会员 日历 银行 搜索 今日新帖 标记论坛为已读


回复
 
主题工具 搜索本主题 显示模式
旧 2009-05-06, 04:46 PM   #1
yang686526
高级会员
 
注册日期: 06-11
帖子: 14579
精华: 1
现金: 224494 标准币
资产: 234494 标准币
yang686526 向着好的方向发展
默认 【转帖】library linking errors in xcode 1.5

library linking errors in xcode 1.5
library linking errors in xcode 1.5
i am trying to use/link to the latest dwg direct libraries in my software product. i am getting either 'undefined' or 'multiply defined' symbol errors in the library linking step of the compile process.
to diagnose the problem i returned to the "dd_nonlibsmac/examples/odreadex" example which i ported/built in xcode. it compiles and runs when using the 'zerolink' xcode option for development software.
i am seeing the same 'undefined' library linking errors in odreadex when not using the 'zerolink" compiler flag. i get error reports of undefined symbols, such as in the odreadex example.
ld: warning prebinding disabled because of undefined symbols
ld: undefined symbols:
odbrentity::~odbrentity()
odbrtraverser::~odbrtraverser()
odacisrendererimpl:dacisrendererimpl()
odbrbrepfacetraverser::setbrep(odbrbrep const&)
odbrbrepfacetraverser:dbrbrepfacetraverser()
....
the "odacisrendererimpl" only seems to be contained in the 'libdd_macosx_acisrenderer.a' and 'libdd_macosx_modelergeometry.a' files, and both of them are linked into the project build!!!
in the 'zerolink' mode of compiling, the project builds and runs properly.
tha main issue is, i cannot build my main/work project in 'zerolink'.
any ideas? i'm also consulting apple about this issue.
thanks in advance
michael
linking directdwg in xcode (mac os x)
hi,
i had similar (undefined symbols) problem when linking direct dwg libraries (dd libs) in xcode ide ("deployment" variant).
problem:
dd libraries can be linked with zerolink in "development" variant but failed to be linked with "ld" in "deployment" variant (a lot of "unresolved symbol" errors reported by "ld").
here is solution that worked for me:
1) rename all dd libraries to "lib<name.ext>". in other words, rename all dd_... libraries with prefix "lib", i.e. "dd_macosx_acisbuilder.a" to "libdd_macosx_acisbuilder.a". this is required by "ld" linking tool used by xcode for "deployment" builds.
2) build your project without dd libraries, naturally you'll get a lot of "undefined_symbol" errors at linking stage.
3) add "libdd..." library to resolve undefined symbols which are reported first. a little luck and guess work will be required to add proper libraries because sometimes it's not obvious which library exports required symbols.
4) build your project again. if you have added some library but same unresolved symbols are at the beginning of errors log, you should remove library from your project (xcode will do symbols lookup in libraries in the order of their addition to the project, rearranging libraries inside xcode project window will not change the order of "ld" command line and thus lookup order). repeat steps 3 and 4 until no "undefined symbol" errors left.
in my case i added following libraries one by one(in exact order):
libdd_macosx_db.a
libdd_macosx_alloc.a
libdd_macosx_root.a
libdd_macosx_ge.a
libdd_macosx_gi.a
libdd_macosx_ft.a
best regards and good luck with your projects,
yuriy litoshenko,
ecsat, kiev.
on behalf of fons de wolf.
adw software.
yang686526离线中   回复时引用此帖
GDT自动化论坛(仅游客可见)
回复


主题工具 搜索本主题
搜索本主题:

高级搜索
显示模式

发帖规则
不可以发表新主题
不可以回复主题
不可以上传附件
不可以编辑您的帖子

vB 代码开启
[IMG]代码开启
HTML代码关闭

相似的主题
主题 主题发起者 论坛 回复 最后发表
【转帖】help please - link errors yang686526 DirectDWG 0 2009-05-05 12:06 PM
【转帖】corrupt dwg file generated from xcode yang686526 DirectDWG 0 2009-05-04 06:21 PM
【转帖】[翻译] metaprogramming with autocad (二) - 精华帖集合 yang686526 ObjectARX(VB.NET/C#) 0 2009-04-29 05:02 PM


所有的时间均为北京时间。 现在的时间是 10:50 PM.


于2004年创办,几何尺寸与公差论坛"致力于产品几何量公差标准GD&T | GPS研究/CAD设计/CAM加工/CMM测量"。免责声明:论坛严禁发布色情反动言论及有关违反国家法律法规内容!情节严重者提供其IP,并配合相关部门进行严厉查处,若內容有涉及侵权,请立即联系我们QQ:44671734。注:此论坛须管理员验证方可发帖。
沪ICP备06057009号-2
更多