so I used Venmo/Synx on my Xcode project with CocoaPods, and it completely screwed everything up.
I was able to fix the Manifest.lock and Podfile.lock errors, but now I am getting this error:
The file “Pods.debug.xcconfig” couldn’t be opened because there is no such file. (/Users/user/GitHub/xxxxxx/Pods/Pods/Target Support Files/Pods/Pods.debug.xcconfig)
As you can see, the path is incorrect, as there is no Pods/Pods
directory (there is one extra pod).
How can I fix this? I have only added PODS_ROOT
to the user-defined variable, as that fixed my Podfile and Manifest.lock files.
Any help would be much appreciated!
Edit:
After adding PODS_ROOT, I get this when running pod install
.
[!] The `Project [Debug]` target overrides the `PODS_ROOT` build setting defined in `Pods/Target Support Files/Pods/Pods.debug.xcconfig'. This can lead to problems with the CocoaPods installation
- Use the `$(inherited)` flag, or
- Remove the build settings from the target.
I had the same problem in Xcode 6.1.1. I did the following to solve it:
- Set the configuration file setting* "None" for the Pods related target.
- Close the .xcworkspace.
- run pod install again
- now open and build your .xcworkspace
*The configuration file setting is found by selecting the project (not the target) and then the Info tab.
If your path to pods in error is wrong try this:
- use
pod deintegrate
- delete all pod remains files -
Podfile.lock
,Pods
,<Project>.xcworkspace
- open
<Project>.xcodeproj
- remove
Pods
project on left side - try
pod install
I faced this issue when I upgraded/downgraded cocoapods between 1.6.x and 1.5.x. The following step fixed this error
1, go to project info tab
2, just under Deployment target, there is configurations field. change your configuration. In my case, there are 2 options
/Users/user/GitHub/xxxxxx/Pods/Pods/Target Support Files/Pods/Pods.debug.xcconfig
/Users/user/GitHub/xxxxxx/Pods/Target Support Files/Pods/Pods.debug.xcconfig
3, clean and build again.
I had the same problem with Xcode 11
but I just updated CocoaPods and it worked.
- Update CocoaPods to latest version with
sudo gem install cocoapods
- Run
pod install
again
I had the same error while trying to build my project for the first time. This is how I resolved it:
- pod deintegrate
- sudo gem install cocoapods-clean
- pod clean
Open the project and delete the “Pods” folder that should be red.
- pod setup
- pod install
Reopen and build the project, I think it's good to go!
There has been an update to cocoa pods that is causing this problem. Please refer to the cocoa pods release notes :
Change shell script relative paths to use ${PODS_ROOT} instead of ${SRCROOT}/Pods. Whirlwind #7878
This was done in version 1.6.0.beta.1 (2018-08-16) Release notes are here: cocoapods release notes
A few things worth trying:
- As Keith mentioned above, you definitely want to exclude
Pods
from synx. - You almost certainly do not want to override the
PODS_ROOT
build setting. - I've seen similar errors to yours in a project with multiple targets. Make sure that your
Podfile
includes alink_with
setting that specifies all your app targets. - If you have at least one test target, consider using your
Podfile
to explicitly import all your app pods to both your application and test targets. - I've not too much experience using a custom
xcconfig
with CocoaPods, but you might first try removing your xcconfig and allowing CocoaPods to generate its own first.
I got the same situation in Xcode 10.1
. This is what works for me.
- Open
<Project>.xcworkspace
- Go into your
<project_name>
folder(by default it's blue), delete thePods
folder (by default it's yellow) - In
Terminal.app
, runpod install
again - Then I'm able to
CMD + R
to run the simulator
Try deleting the debug.xcconfig file and run pod install again. It solved my issue
In my case, I deleted my Podfile, Podfile.lock.
Run pod init
, then copy all pods to new Podfile, then run pod install
again and it's worked.
I think it's happened for the differences from folder paths in the old project (for me, I cloned another project from Git repo).
For me, changing Build system
to Legacy
in File
-> workspace settings
did the trick
I had the same error and I fixed in following way
1 - Goto your projected setting by blue icon of your project from left pan 2 - Select your project under the project 3 - Select Info window 4 - Check IOS deployement target. This target should be same as you set in general settings of your project (Pic 2).
- Close project
- Do pod deintegrate
- Delete - Podfile.lock, Pods,.xcworkspace in project directory
- Do sudo gem install cocoapods
- Do pod install
来源:https://stackoverflow.com/questions/27109476/incorrect-path-for-pods-debug-xcconfig-in-xcode