当前位置: 首页 > 工具软件 > RegexKitLite > 使用案例 >

iOS编译RegexKitLite的时候报错解决方法

宋航
2023-12-01

工程在不小心删除了一个链接库的情况下,突然出现了下面错误:

[html]view plaincopy

Undefined symbols for architecture i386:

"_u_errorName", referenced from:

_rkl_NSExceptionForRegex in libPods.a(RegexKitLite.o)

_rkl_makeNSError in libPods.a(RegexKitLite.o)

_rkl_userInfoDictionary in libPods.a(RegexKitLite.o)

"_u_strlen", referenced from:

_rkl_userInfoDictionary in libPods.a(RegexKitLite.o)

"_uregex_appendReplacement", referenced from:

_rkl_replaceAll in libPods.a(RegexKitLite.o)

"_uregex_appendTail", referenced from:

_rkl_replaceAll in libPods.a(RegexKitLite.o)

"_uregex_clone", referenced from:

-[RKLBlockEnumerationHelper initWithRegex:options:string:range:error:] in libPods.a(RegexKitLite.o)

"_uregex_close", referenced from:

_rkl_clearCachedRegex in libPods.a(RegexKitLite.o)

"_uregex_end", referenced from:

_rkl_performRegexOp in libPods.a(RegexKitLite.o)

_rkl_findRanges in libPods.a(RegexKitLite.o)

_rkl_search in libPods.a(RegexKitLite.o)

"_uregex_find", referenced from:

_rkl_search in libPods.a(RegexKitLite.o)

"_uregex_findNext", referenced from:

_rkl_search in libPods.a(RegexKitLite.o)

_rkl_replaceAll in libPods.a(RegexKitLite.o)

"_uregex_groupCount", referenced from:

_rkl_getCachedRegex in libPods.a(RegexKitLite.o)

"_uregex_open", referenced from:

_rkl_getCachedRegex in libPods.a(RegexKitLite.o)

"_uregex_reset", referenced from:

_rkl_replaceAll in libPods.a(RegexKitLite.o)

"_uregex_setText", referenced from:

-[RKLBlockEnumerationHelper initWithRegex:options:string:range:error:] in libPods.a(RegexKitLite.o)

_rkl_clearCachedRegexSetTo in libPods.a(RegexKitLite.o)

_rkl_setCachedRegexToString in libPods.a(RegexKitLite.o)

"_uregex_start", referenced from:

_rkl_performRegexOp in libPods.a(RegexKitLite.o)

_rkl_findRanges in libPods.a(RegexKitLite.o)

_rkl_search in libPods.a(RegexKitLite.o)

ld: symbol(s) not found for architecture i386

clang: error: linker command failed with exit code 1 (use -v to see invocation)

才发现是Other Linker Flags,缺少了licucore。

然后在Other Linker Flags后面,添加“-licucore”就可以了。

 类似资料: