kstenerud / iOS-Universal-Framework

An XCode project template to build universal frameworks (arm7, arm7s, and simulator) for iOS / iPhone.
2.95k stars 473 forks source link

how to contain *.strings file in .embeddedframework/Resoures? #85

Open Kofktu opened 11 years ago

Kofktu commented 11 years ago

hmm,

i make App.strings file

strings file has localize (korean, english, chinese)

project setting -> build phases -> Copy Bundle Resources -> Add strings files(en.lproj, ko.lproj, zd...lproj)

build and when use,,

not found strings file...

how would it be to contain strings resource ?

kstenerud commented 11 years ago

It looks like the script is not making symlinks to the strings files.

   └── Products    └── Debug-iphoneos    ├── Localized.embeddedframework    │   ├── Localized.framework    │   │   ├── Headers -> Versions/Current/Headers    │   │   ├── Localized -> Versions/Current/Localized    │   │   ├── Resources -> Versions/Current/Resources    │   │   └── Versions    │   │   ├── A    │   │   │   ├── Headers    │   │   │   │   ├── Localized.h    │   │   │   │   └── LocalizedVCViewController.h    │   │   │   ├── Localized    │   │   │   └── Resources    │   │   │   ├── Info.plist    │   │   │   ├── LocalizedVCViewController.nib    │   │   │   ├── en.lproj    │   │   │   │   ├── InfoPlist.strings    │   │   │   │   └── MyFramework.strings    │   │   │   ├── es.lproj    │   │   │   │   └── MyFramework.strings    │   │   │   └── ja.lproj    │   │   │   └── MyFramework.strings    │   │   └── Current -> A    │   └── Resources    │   └── LocalizedVCViewController.nib -> ../Localized.framework/Resources/LocalizedVCViewController.nib    └── Localized.framework -> Localized.embeddedframework/Localized.framework

I'll need to think up a fix for this, but for now, you can go into the built products dir in a shell and manually add the symlinks.

Kofktu commented 11 years ago

how add the symlinks? tell me the solution shell script..

jenner2222 commented 11 years ago

bump

arianox commented 10 years ago

Hi there,

is the issue planned to be fixed in the future? It would be awsome if the framework could handle localized files likes Localizable.strings

Has anyone a good workaround yet?

Thank you!

kstenerud commented 10 years ago

Unfortunately, I've gotten so bogged down with work that I haven't had any time to look at the universal framework project in some time, and I don't know when I will have the time :(

The beta branch is the way of the future as it switches to a python solution that actually reads the project file, but I need a champion who can step up and continue it, as I'm not giving it anywhere near the attention it requires...

arianox commented 10 years ago

Too bad :( Thank you anyway!

WarSunsOfPeace commented 10 years ago

I was just building a project and ran into this same issue.

I found the following on line 716 of the build script for file in filter(lambda x: x != "Info.plist" and not x.endswith(".lproj"), os.listdir(os.path.join(fw_path, "Resources"))):

I removed the following line and now my project is working. I don't know if this will cause other problems. and not x.endswith(".lproj")

New line

for file in filter(lambda x: x != "Info.plist", os.listdir(os.path.join(fw_path, "Resources"))):

arianox commented 10 years ago

Nice! Can you tell me which build/script file it is?

arianox commented 10 years ago

Works! Thank you!

WarSunsOfPeace commented 10 years ago

Sorry, it was in the mk8 python script in the Run Script of the build phases. When get a chance I will update the github project with a pull request.