I have added the chat kit framework to my iOS app (i know it won't be accepted) and it says the file doesn't exist. Any idea why?
Navigate to your project, then select your target. Click the Build Settings tab and use the search bar to look for the header search paths setting. Add the desired path and you should be set.
Related
Has anyone figured out how to add/edit values in the Info.plist of Xcode 13 yet? I see they moved the Info.plist from the navigator pane... but although I can find it, I'm not sure how to edit it.
It's a "feature."
You don't need it anymore. From the Release Notes:
Projects created from several templates no longer require configuration files such as entitlements and Info.plist files. Configure common fields in the target’s Info tab, and build settings in the project editor. These files are added to the project when additional fields are used. (68254857)
So, instead of inside Info.plist, edit properties like NSCameraUsageDescription here:
Project -> Targets -> Info -> Custom iOS Target Properties
The first time you add/edit, Xcode will automatically generate a new Info.plist file that’s kind of synced1 with Custom iOS Target Properties. Xcode will later merge them for you.
[1]: They’re not fully synced. Some properties like NSCameraUsageDescription will only appear in Custom iOS Target Properties, while Application requires iPhone environment will appear in both. I have no idea how Xcode determines this.
Want Info.plist back, completely?
You might want all of your app's properties in one place. Or maybe you don't trust Xcode with the merging. I spoke with an Apple engineer at WWDC21 about this... here's how to get the classic Info.plist back.
Create a new "Property List" file (File -> New -> File)
Name it Info.plist
Copy and paste the existing values from Project -> Targets -> Info -> Custom iOS Target Properties to Info.plist.
Copy
Paste
Note: Currently you can only select and copy 1 row at a time. If you want to save some time, here are the default contents in XML format. To use this, right-click Info.plist -> Open As -> Source Code, then paste.
Copy the path to Info.plist in the attributes inspector.
Paste the path here:
Project -> Targets -> Build Settings -> Info.plist File
Set Generate Info.plist File to No
Last step. Remove Info.plist from Copy Bundle Resources (select, then press the - button).
Project -> Targets -> Build Phases -> Copy Bundle Resources
Yep, that was a lot. But whether you want classic Info.plist or not is up to you — both are fine and won't change your app.
Xcode 13.3.1, macOS Monterey(12.0.1)
Here is the most simple solution which work for both swiftUI and Storyboard projects, if you are not able to find info.plist and want to add target properties like Privacy - Camera Usage Description and things like we can add in older Xcode version. Here is the solution...
***> Select target of you project on top of the files click on Info on
> top of the right side, now you can see "Custom iOS properties" like
> info.plist, do whatever you want.***
Target > Info
see the image below for reference
Here is a link to a raywenderlich tutorial: https://www.raywenderlich.com/19611194-multiplatform-app-tutorial-swiftui-and-xcode-12
The sample projects uses Xcode 12.0-compatible (objectVersion = 54) project format, created with the Multi Platform app template. I borrowed the plists from this project. Until the sample project is revised, it's nice to have a reference project (structure) for comparison.
This also applies to Xcode 14. To be brief, a few pieces of information about this change:
There is a good write up of the issue here:
https://useyourloaf.com/blog/xcode-13-missing-info.plist/
There is a good YouTube video (found in this page above):
https://youtu.be/mml9ZI81VKA
This issue applies to SwiftUI projects not Storyboard. Once you make
a change to the "standard" info settings, Xcode actually
automatically creates an info.plist file in your project navigator. You can then add more custom settings in the info.plist file.
I got this email from Apple:
We have discovered one or more issues with your recent delivery for "App Name Here". To process your delivery, the following issues must be corrected:
Missing Storyboard File - The referenced storyboard file 'Pass_iPhone.storyboard.storyboardc' was not found in the application bundle.
I don't understand the issue, my storyboard is visible in my project and is editable ect? What can I do to fix this?
I'm not sure if this is your problem, but one thing to check: With the storyboard file selected in the Xcode Project Navigator on the left side, click on the File Inspector tab in the Utilities panel on the right side and make sure your storyboard file has the check box selected for your project under Target Membership. If it is not selected, the file will not be included in the app bundle, although it will still be editable.
I'm trying to localize my app.
I noticed that if I add a language every localized file become doubled.
In this way it's impossible to maintain code or storyboard so I learnt that I need Base internationalization.
The problem is that when I select that checkbox in xcode project setting it shows a window without nothing to select, does anyone know how to fix this?
Here's a screenshot
First, you need to go to your storyboard file, open the bar on the right side, and go to Show the File Inspector, the furthest tab to the left. Then, scroll down and click localize. After this, when you check Use Base Localization, you should see the storyboard appear.
This could happen if Base Internationalization was active before then disabled and files deleted manually.
Create Base.lproj folder in your project folder using the finder.
Move your main story board to it also using the finder.
fix the reference to it from Xcode.
remove app. from device, clean & build your project.
All will be back to normal.
I'm trying to add this: https://github.com/bengottlieb/Twitter-OAuth-iPhone
The readme doesn't give a step by step so I just tried dragging the whole folder into my project and then when I try to compile I get a file not found error on #include
What do I do?
I found the solution, it's on the bottom of this page: http://www.cocos2d-iphone.org/forum/topic/6136
In order to get your project to compile you’ll need to first include the libxml2 Framework (right click on your project and choose Add Exisiting Frameworks).
Now right click on your project and choose ‘Get Info’. In the build tab, scroll down till you see the ‘Search Paths’ section. In the ‘Header Search Paths’ field, add ‘$(SDKROOT)/usr/include/libxml2′
Finally, expand the Twitter+OAuth group in your project and then expand theMGTwitterEngine group. Open MGTwitterEngine.m and alter #define USE_LBXML 0 to #define USE_LIBXML 1.
you will have to add the following frameworks
libxml
And edit the header search path in the project settings to include
"$(SDK_DIR)"/usr/include/libxml2
For further info please read the following
LibXML2.dylib and Xcode4
I'm making iphone app using XCODE 4.2.
I would like to make a localized apps.
I moved the project folder. And then files(related localization)' link is broken.
I use to move folder often.
How can I do? please tell me.... thank!~
Select the xib marked in red
open the File Inspector (View - Utilities - File Inspector)
change "Full Path" to new location