References to Removed Framework in project.pbxproj File

为君一笑 提交于 2019-12-04 04:38:26

问题


I recently removed a framework from my iOS project and am installing it instead through a dependency manager (CocoaPods). I noticed, however, when checking my changes in to source control that some references to the framework were removed, but one was added with an absolute path. From the diff (the first line was removed and the second line added to my project file):

-       767C7EC51DB295CE00A8850F /* TealiumIOSLifecycle.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = TealiumIOSLifecycle.framework; sourceTree = "<group>"; };
+       767C7EC51DB295CE00A8850F /* TealiumIOSLifecycle.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = TealiumIOSLifecycle.framework; path = /Users/jal/workspace/com.myapp/MyApp/Shared/ThirdParty/TealiumIOSLifecycle.framework; sourceTree = "<absolute>"; };

There is no file at that path on my local machine, and I was able to make a fresh clone in a separate directory and on other machines with a different directory structure and was able to build the project without any warnings or errors. The physical file of the framework no longer exists in the project directory (when I removed the file from the project in Xcode, I chose "move to trash).

Is this normal? If not, how can I remove these references?

To be clear, there are no references to this framework anywhere in the project. This includes Linked Frameworks and Libraries, Link Binary with Libraries, Target Dependencies, Embed Frameworks, etc.


回答1:


Tap on your project file in xcode and in the General tab scroll down and check that it is not included in the following sections

The missing frameworks would be probably highlighted in red (or faded in gray i don't remember exactly)

Also in the build phases check it's not being tried to be copied



来源:https://stackoverflow.com/questions/40287250/references-to-removed-framework-in-project-pbxproj-file

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!