Re: How to exclude existing resource languages from a target
Re: How to exclude existing resource languages from a target
- Subject: Re: How to exclude existing resource languages from a target
- From: Chris Espinosa <email@hidden>
- Date: Mon, 17 Dec 2007 08:48:57 -0800
On Dec 17, 2007, at 7:07 AM, Ulf Dunkel wrote:
Sometimes I wonder if my questions are misplaced here but this time
I was quite sure that this is an issue which I share with others.
Really noone out there who could give me a hint?
- - - - -
Ulf Dunkel wrote:
I work on a project with several frameworks, plugins etc.
Everything's fine for the main target A which creates the executable.
Now I want to get another target B with a similar version of the
same executable, but without some distinct files and plugins, and -
not copying all available languages (en, de, fr, cs, da, nl, it),
but only copying three of them (en, de, fr).
I have duplicated target A and adjusted everything in B to not copy
the unwanted files and plugins. But now I am stuck because I don't
find a way to exclude the unwanted languages from my target B.
Whenever I want to remove localized files from e.g. MainMenu.nib,
the removed languages are also removed in target A - and even in
the project.
How can I define that target A copies all available localized files
of the project while target B should only copy the localized files
for en, de and fr?
Any hint is appreciated.
Xcode doesn't provide for this kind of setup easily. The UI creates
<lang>.lproj folders in your project when you declare a file to be
localized, and the Copy Bundle Resources build phase always copies all
localized resource folders. There's no fine-grain way to exclude a
localized folder from the Copy Bundle Resources phase.
Here are some approaches:
- Build only in one language, and create a postprocessing step
(perhaps another project, perhaps a shell script) to merge in other
resources after the fact
- Remove the localized resources from the Copy Bundle Resources build
phase, and instead create a Run Script build phase that copies them
manually, perhaps conditionally based on the value of ${CONFIGURATION}.
Both of these will have the advantage that you don't have to keep two
targets in synch.
Chris
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden