xcode7: Undefined symbols for architecture i386: "_iconv_open", referenced from:
在整合cocos和quick时,出现这个错误,我按照以前的方法
link binary with libraries 中add libiconv.2.dylib ,发现已经没有了这个库。
网上找了一下,找到一个:
问题:
I use libxml to save game data. in order to support chinese character, i use iconv to convert format.
but a linke error was appeard:
Undefined symbols for architecture i386:
"_iconv_open", referenced from:
FConverter::code_convert(char*, char*, char*, unsigned long, char*, unsigned long)in GameData.o
"_iconv", referenced from:
FConverter::code_convert(char*, char*, char*, unsigned long, char*, unsigned long)in GameData.o
"_iconv_close", referenced from:
FConverter::code_convert(char*, char*, char*, unsigned long, char*, unsigned long)in GameData.o
ld: symbol(s) not found for architecture i386
I was not familiar with mac os and xcode, so i try to resolve it refer to visual c++.
I found a configuration in target/Build Phase and search iconv, there are three dylib under the list.
libiconv.2.4.0.dylib
libiconv.2.dylib
libiconv.dylib.
i select libiconv.dylib. compile error was resolved.
but i am not sure is this the best solution, and will it cause another problem later.
does dylib mean dynamic library like dll? if i have to public or share my application with this dylib file as windows application combine dll file.
thanks a lot.
:D
解答:
After Xcode 7, Apple did a lot to strip the size of apps, including changing .dylib to .tbd.
Here you don't need to add library & framework but you can add the library by changing the following option:
Other Linker Flags > Add "-l{yourlibraryname} (no space after -l)
In your case, you can add -liconv in Other Linker Flags.
原文地址:http://discuss.cocos2d-x.org/t/link-error-in-xcode-4-2-iconv-error/1173
xcode7: Undefined symbols for architecture i386: "_iconv_open", referenced from:的更多相关文章
- Undefined symbols for architecture i386: "_crc32", referenced from:——crc链接错误
有时候用别人的框架,你会碰到下面的错误,很是吓人,什么玩意,我怎么看不懂!!! Undefined symbols for architecture i386: "_RELEASE&quo ...
- Undefined symbols for architecture i386: "_deflate", referenced from:
Undefined symbols for architecture i386: "_deflate", referenced from: PlatCompress(enumCom ...
- 当编译AFNetworking 2.0时出现了Undefined symbols for architecture i386
当将AFNetworking添加到工程后编译时出现 Undefined symbols for architecture i386: "_SecCertificateCopyData&quo ...
- oc调用c++接口时 报错 Undefined symbols for architecture i386:
当在oc中调用c++中的方法时,发现说c++中的方法没定义或是找不到 Undefined symbols for architecture i386: "_desTYData", ...
- Undefined symbols for architecture i386:和"_OBJC_CLASS_$_xx", referenced from:问题解决方法
多个人共同操作同一个项目或拷贝项目时,经常会出现类似这样的问题: Undefined symbols for architecture i386: "_OBJC_CLASS_$_xx文件名& ...
- Undefined symbols for architecture i386:"_OBJC_CLASS_$_xx", referenced from: 解决方法
多个人共同操作同一个项目或拷贝项目时,经常会出现类似这样的问题: Undefined symbols for architecture i386: "_OBJC_CLASS_$_xx文件名& ...
- 【转】Undefined symbols for architecture i386:和"_OBJC_CLASS_$_xx", referenced from:问题解决方法
多个人共同操作同一个项目或拷贝项目时,经常会出现类似这样的问题: Undefined symbols for architecture i386: "_OBJC_CLASS_$_xx文件名& ...
- iOS:编译错误Undefined symbols for architecture i386: _OBJC_CLASS_$_XXX", referenced from: error
Undefined symbols for architecture i386: _OBJC_CLASS_$_XXX", referenced from: error 这个意思为无法找到名为 ...
- 微信SDK导入报错 Undefined symbols for architecture i386:"operator delete[](void*)", referenced from:
异常信息: Undefined symbols for architecture i386: "operator delete[](void*)", referenced fro ...
随机推荐
- 剑指Offer 总结
给一个链表,若其中包含环,请找出该链表的环的入口结点,否则,输出null. public class Solution { public ListNode EntryNodeOfLoop(ListNo ...
- 前端1-----CSS颜色属性,字体文本和背景属性,边框属性,margin和padding,盒模型,行内块转换,浮动,三大定位
前端1-----CSS颜色属性,字体文本和背景属性,边框属性,margin和padding,盒模型,行内块转换,浮动,三大定位 一丶css选择器的优先级 行内 > id选择器 > 类选择器 ...
- 为什么K8s会成为主流?
容器技术和K8s是云原生概念的核心和基础.云计算诞生已有超过10年,但云计算时代的应用到底该是什么样子,一直没人能说清楚,也没人能确定云计算的基础架构将会如何发展.在K8s出现之前,没人设想过会有一个 ...
- js实现数组去重(方式大汇总)
方法一:循环判断当前元素与其后面所有元素对比是否相等,如果相等删除:(执行速度慢) var arr = [1,23,1,1,1,3,23,5,6,7,9,9,8,5]; function remove ...
- JS 中类型和类型转换
类型 首先明确一点,Js中的类型是针对值来说,而不是针对变量,值就是所谓的42, 'abc', false 等能用js 操作的数据.在js 中说某某某是什么数据类型,其实是说的这些值是什么类型.值呢? ...
- CSS3 完善盒模型
CSS3 改善了传统盒模型结构,增强了盒子构成要素的功能,扩展了盒模型显示的方式. 改善结构:为盒子新增轮廓区: 增强功能:内容区增强 CSS 自动添加内容功能,增强内容移除.换行处理:允许多重定义背 ...
- sendMessage 与 obtainMessage (sendToTarget)比较
我们平时在做到多线程问题的时候可能利用Handler去传递Message,其中,经常使用的就是 1.new Handler().obtainMessage().sendToTarget(); 2.ne ...
- Java面试通关要点 汇总集【最终版】
本文转载自公众号:服务端思维,阅读大约需要7分钟.梁兄的知识储备很丰富,组织的知识星球里也是干货十足,平常还会有技术研习等活动,欢迎关注. 首先,声明下,以下知识点并非阿里的面试题.这里,笔者结合自己 ...
- PHP的垃圾回收机制之引用计数
1,介绍 php的垃圾回收机制(GC)是在PHP5之后出现的,而在PHP5.3版本之前使用的都是“引用计数”的方式.实现引用计数的实质就是在每个内存对象中都有一个计数器,当内存对象被变量引用时,计数器 ...
- linux系统IO操作
本文重点说明下面内容: 什么是标准IO,什么是文件IO? 什么是Direct IO? O_SYNC标识有什么意义? 各个层面的缓存如何同步? 还在page cache中的脏页可以读写吗? IO路径上的 ...