目标......覆盖了`Pods/Pods.xcconfig中定义的`OTHER_LDFLAGS`构建设置 [英] The target ... overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Pods.xcconfig

查看:22
本文介绍了目标......覆盖了`Pods/Pods.xcconfig中定义的`OTHER_LDFLAGS`构建设置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已将 SpatialIite 合并到一个 Xcode 项目中,该项目使用来自 Proj.4 的头文件,只有一个头文件.两者都是 Xcode 项目并且具有静态目标.

I have incorporate SpatialIite into a Xcode project which uses a header file from Proj.4, just one header. Both are Xcode projects and have static targets.

我正在尝试从 git 子模块迁移到 Cocoapods.由于静态目标似乎很难与 Cocoapods 一起使用,我只想以通常的方式构建项目.我为 Proj.4 制作了 podspec.在为 SpatialLite 编写 podfile 后,我收到了警告:

I'm trying to migrate from git submodule to Cocoapods. Since static targets seems to be difficult to use with Cocoapods, I just want to have the project built in the usual way. I made podspec for Proj.4. After writing podfile for SpatialLite I got the warnings:

[!] The target `SpatialiteIOS [Debug]` overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Pods.xcconfig'.
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The target `SpatialiteIOS [Debug]` overrides the `HEADER_SEARCH_PATHS` build setting defined in `Pods/Pods.xcconfig'.
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The target `SpatialiteIOS [Debug - Release]` overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Pods.xcconfig'.
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The target `SpatialiteIOS [Debug - Release]` overrides the `HEADER_SEARCH_PATHS` build setting defined in `Pods/Pods.xcconfig'.
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

我阅读了这个问题,但我对警告的含义以及我能做些什么一无所知修复它.

I read this issue but I'm pretty clueless to what the warnings mean and what can I do to fix it.

另外一个问题,当我打开工作区以及单独打开 SpatiaLite 项目时,两者都针对 Mac OSX 64,假设它是一个 iOS 项目.我的 podfile 确实说平台:ios".

Additionally problem, when I open the workspace as well as opening SpatiaLite project alone, both are targeted to Mac OSX 64, when it is suppose to be an iOS project. My podfile does say "platform :ios".

推荐答案

这在大多数情况下绝对有效:

This definitely works most of the time:

转到您的目标构建设置 -> 其他链接器标志 -> 双击 .将 $(inherited) 添加到新行.

Go to your target Build Settings -> Other linker flags -> double click . Add $(inherited) to a new line.

如果您对...目标覆盖在...中定义的 GCC_PREPROCESSOR_DEFINITIONS 构建设置有问题",那么您必须将 $(inherited) 添加到您的目标构建设置 -> 预处理器宏

If you have problem with "...target overrides the GCC_PREPROCESSOR_DEFINITIONS build setting defined in..." then you must add $(inherited) to your target Build Settings -> Preprocessor Macros

这篇关于目标......覆盖了`Pods/Pods.xcconfig中定义的`OTHER_LDFLAGS`构建设置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆