I am trying to create a LITE version of my iPhone app by using different targets. So I have duplicated the release target 'Checklists' and it will name it 'Checklists copy'. I have managed to change the name of the actual .app that is created but not the target name. Any ideas?
So the .app is named via the product name. The target name is an identifier for the build settings, which are actually built using a scheme. The name you see when selecting what to build is a scheme, and you can rename those by clicking on the bar and going to "manage schemes".
To rename the target you just click on the name and it will turn into an edit box.
Related
I duplicate a target, create and link a new Info.plist file, a prefix.pch file, also change bundle ID and bundle name. Build is ok, but got message:
Xcode cannot run using the selected device.
Choose a destination with a supported architecture in order to run on this device.
what ever in simulator or in iPod, it can not run.
What can I do? Is it because the reason of bundle?
After changed Product name in Build setting, it can be run.
i try to generate a nameproject.app after the build/Release.the build has succeed but i didn't find the file nameproject.app under product !! (it seems to be availble but the option "show in Finder" is disabled ) . My question is how to generate nameproject.app?
You will need to Build and Archive your project. You may need to check what code signing settings you have in the project and executable.
Use the Organiser to select your archive version and then you can Share that version of your project. You will need to select the correct code signing again. It will allow you to save the .ipa file where you want.
Drag and drop the .ipa file into iTunes and then sync with your iPhone.
Here are some more detailed instructions including screenshots;
Here are some more detailed instructions
Click on: Product - Archive (You must select IOS devices into active scheme and you not select IOS Simulator scheme).
When the run is terminated it's open the organizer view.
Right click on your app - Show in finder.
Right click on your archive into finder - Show package content - Products - Applications and here you find your file.app
File .../FaceDeFace.app depends on itself.
This target might include its own product.
File .../FaceDeFace.app depends on itself.
This target might include its own product.
I have done my project in os Snow leopard but now my os version also changed and it is now 10.7.3. This is installed in my Imac machine. This app start first in MacBook but now I want to develop it in IMac. But the above error is shown so what i have to do. Though I have change all of my certificate, and all provisioning profiles newly.
Please help.
Thanks i advance.
Select the target in your Xcode project and click the Build Phases tab. Look at the Target Dependencies list; the target's product should not be listed there, but it sounds like it may have been added to that list by mistake. Also check the other areas in that same tab -- you don't want your product listed in Copy Bundle Resources or Link Binary With Libraries, either -- you obviously can't use the thing that you're building as a resource or library to build the product in the first place. That's what Xcode seems to be complaining about.
Ran across this issue using Xcode 7 (beta 1) when trying to build a Static Library target. Here was the error message from the build output:
Unable to run command 'CopySwiftLibs libMyStaticLibraryName.a' - this target might include its own product.
(I substituted libMyStaticLibraryName.a above in place of the actual name of my static library.)
The problem turned out to be that this static library target had the Embedded Content Contains Swift Code build setting (EMBEDDED_CONTENT_CONTAINS_SWIFT) set to YES, when in reality there was no Swift code associated with this target. Setting this to NO in Xcode fixed the issue.
Static libraries cannot include Swift code, so if this build setting is set it causes the error, even if there is no actual Swift code in the target.
In my case, very simple, please delete Universal target, then add new target.
That's all
In my case my project had submodule inside, so commands
git submodule add submoduleURL
git submodule init
git submodule update
solved this issue.
I had the same problem, when podspec file was incorrect. My mistake was that I didn't specify .h and .m extensions for source_files. Because of that .xib files were added twice. This is a correct example:
s.source_files = 'YourTarget/Classes/**/*.{h,m}'
s.resources = ['YourTarget/Classes/UIComponents/**/*.xib']
See https://guides.cocoapods.org/syntax/podspec.html#source_files
I am using XCODE 4.2 & when I build my project I do not see libMyProject.a file under "Products" folder turning black even though my build is successful.
Where do these .a files gets stored. With 3.2.6, build folder used to be inside my project workspace.
When you build, check out the Log navigator (cmd-7). Read the log for your build: it will contain the full path to the build product.
Still, it should show up as a Product in Xcode...
You have to build it for device and not simulator for it to become black. But if you have only build it for the simulator, it will remain red.
As for the location of the binary, it is located in the Derived Data folder in the subfolder specified in Pre-Configuration Build Products Path which by default has the values build/Debug-iphoneos and build/Release-iphoneos
EDIT
You can change the product name in the Build settings of your target by modifying the value of Product Name in the Packaging group.
They normally get put into /Library/Developer/Xcode/DerivedData/{PROJECT_NAME_AND_RANDOM_CRAP}/Build/Products/{BUILD_TYPE}/{PROJECT_NAME}.app
You have to build it for device and not simulator. If you build it for device then its color would be red and you does not get project.app file. To get project.app file you have to build in device(iPhone/iPad/iPod Touch). After build in device the color of project.app file will change to black.
Another procedure you can follow if you want to get only .app file not under Products folder.For that goto Products->Archive->Share then save. It will generate .ipa file. By changing app to zip and unzip the file you get the .app file.
Try to commit my first iPhone application to Subversion found that there's "code signing identity" section in my xcode project.pbxproj file.
CODE_SIGN_IDENTITY = "iPhone Developer: my username here...;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer: above...";
The issue is, in our team we use different provisioning which bound to our device. So when other want to run the code on device, they have to change this line. We can share one provisioning to across this, but that way have several downside. Is there any other way to solve it? i.e. include code signing section to another file which not commit to SVN?
As long as you have just one signing identity, you can just use "iPhone Developer" as your codesigning identity. Codesign will search for an identity containing "iPhone Developer" and use that.
You can base a project or target configuration on the contents of an xcconfig file that is not checked in to Subversion or is otherwise customized per developer. Add an appropriate xcconfig file to your project and then choose the file from the "Based On" pop-up at the bottom of the Build tab in the Project Info or Target Info window.
For example, you could have a DeveloperSettings.xcconfig file in the project whose contents on your system are:
CODE_SIGN_IDENTITY = "iPhone Developer: favoyang"
while its contents on my system are:
CODE_SIGN_IDENTITY = "iPhone Developer: cmh"
These settings will be inherited by either the project or target configuration that is set to be based on this file.
You can use $(USER) in your build setting definition to include your short user name.
For example:
CODE_SIGN_IDENTITY = "iPhone Developer: $(USER)";
That will use the contents of the USER environment variable in the definition of the CODE_SIGN_IDENTITY build setting.
The obvious choice would be to create other build configurations.
Why are you "changing this line" directly? You should almost never directly edit anything in the .xcodeproj file bundle.
Instead, you should be changing this within your build settings. To be more specific in your case, you need to add several more build configurations, one for each member of the team. That member can then build using their own provisioning file withouth messing with any other build settings.