iOS Xcode不能识别Masonry.h文件

遇到Xcode不能识别Masonry.h文件,进而build失败,报错信息如下:

-[UIButton mas_makeConstraints:]: unrecognized selector sent to instance 0x100584110
Showing All Messages
clang: error: no such file or directory: 'Mansory.h'
iOS Xcode不能识别Masonry.h文件_第1张图片

iOS Xcode不能识别Masonry.h文件_第2张图片

此时工程中没有引用到pod中的Masonry.h文件。重新Pod install后会给出具体的解决方案。


iOS Xcode不能识别Masonry.h文件_第3张图片
[!] Your Podfile has had smart quotes sanitised. To avoid issues in the future, you should not use TextEdit for editing it. If you are not using TextEdit, you should turn off smart quotes in your editor of choice.

[!] The `人脸SDK接入 [Debug]` target overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Target Support Files/Pods-人脸SDK接入/Pods-人脸SDK接入.debug.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `人脸SDK接入 [Release]` target overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Target Support Files/Pods-人脸SDK接入/Pods-人脸SDK接入.release.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

解决方案是将Other linker flag由-ObjC(先前是为了兼容第三方的C++库而改为-ObjC,现在将用到第三方C++库文件的后缀改为.mm)改为$(inherited)即可。

iOS Xcode不能识别Masonry.h文件_第4张图片

你可能感兴趣的:(iOS Xcode不能识别Masonry.h文件)