Xcode 4, Three20 and Prodect -> Archive

354 views
Skip to first unread message

Taknology

unread,
Feb 5, 2011, 1:52:06 PM2/5/11
to Three20
I know you working to build support for Xcode 4 so I wanted to note an
issue I came across. When you attempt to Archive a Product, the
scripts that three20 runs when building error because the scripts
folder is not copied to the intermediate folder structure used by
Xcode for the archiving process. It would be great to make sure this
works going forward.

Thanks,
Tony

John Wang

unread,
Feb 6, 2011, 1:04:49 AM2/6/11
to Three20
Thanks. Noted.

Dave Peat

unread,
Feb 8, 2011, 6:00:04 AM2/8/11
to Three20
Same issue here.

Tom Angistalis

unread,
Feb 8, 2011, 11:48:45 AM2/8/11
to Three20
Does anyone have instructions on how to archive a project?

Tony Lewis

unread,
Feb 8, 2011, 12:20:33 PM2/8/11
to thr...@googlegroups.com
In Xcode 4, Select the Archive menu item below the Product menu.

Tony

> --
> You received this message because you are subscribed to the Google
> Groups "Three20" group.
> To post to this group, send email to thr...@googlegroups.com
> To unsubscribe from this group, send email to
> three20+u...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/three20?hl=en
>
> To learn more about Three20, check out
> http://Three20.info/

John Wang

unread,
Feb 9, 2011, 3:17:40 AM2/9/11
to Three20
Hi All,

The bandaid fix for this is the following:

In the Paths.xcconfig file - Change:
HEADER_SEARCH_PATHS = $(STDLIB_HEADERS) "$
(CONFIGURATION_BUILD_DIR)/../three20"
to
HEADER_SEARCH_PATHS = $(STDLIB_HEADERS) "$
(CONFIGURATION_BUILD_DIR)/../../three20"

Then, in the Protect.command file - Change:
cd ${CONFIGURATION_BUILD_DIR}${PUBLIC_HEADERS_FOLDER_PATH}
to
cd ${CONFIGURATION_BUILD_DIR}/..${PUBLIC_HEADERS_FOLDER_PATH}

Please note, that this is NOT a long term fix or support for XCode4.
This is merely a temporary solution for those using XCode4 GM with
Three20 while we continue working on the proper support for it.

If you're wondering what the full files look like, they are here in
this GitHub Gist - https://gist.github.com/818138

Thanks,
John

John Wang

unread,
Feb 9, 2011, 3:25:22 AM2/9/11
to Three20
Also, if you're using this fix, please be careful of jumping back and
forth between 3.2.5 and 4 as the changes will be picked up by 3.2.5
and likely not function properly. If you need to jump back and forth,
just remember to make the necessary adjustments while we work on a
more stable and reasonable support model for XCode4.

On Feb 8, 10:17 pm, John Wang <jwang...@gmail.com> wrote:
> Hi All,
>
> The bandaid fix for this is the following:
>
> In the Paths.xcconfig file - Change:
> HEADER_SEARCH_PATHS     = $(STDLIB_HEADERS) "$
> (CONFIGURATION_BUILD_DIR)/../three20"
> to
> HEADER_SEARCH_PATHS     = $(STDLIB_HEADERS) "$
> (CONFIGURATION_BUILD_DIR)/../../three20"
>
> Then, in the Protect.command file - Change:
> cd ${CONFIGURATION_BUILD_DIR}${PUBLIC_HEADERS_FOLDER_PATH}
> to
> cd ${CONFIGURATION_BUILD_DIR}/..${PUBLIC_HEADERS_FOLDER_PATH}
>
> Please note, that this is NOT a long term fix or support for XCode4.
> This is merely a temporary solution for those using XCode4 GM with
> Three20 while we continue working on the proper support for it.
>
> If you're wondering what the full files look like, they are here in
> this GitHub Gist -https://gist.github.com/818138

Marcus Brito

unread,
Feb 9, 2011, 9:39:17 AM2/9/11
to Three20
Also, read this:

https://devforums.apple.com/thread/86137

You need to set SKIP_INSTALL to YES or generated archives will contain
the static libraries, preventing Xcode from generating an IPA file
from these archives.

-- Marcus Brito

Tony Lewis

unread,
Feb 10, 2011, 9:02:32 PM2/10/11
to thr...@googlegroups.com
This is working well for me. Product - > Archive no longer throws any errors. I do have to modify these files back to original in order to run all other build schemes though. Not a big deal in the interim. Are there plans to make this read BUILD VAR in the future?

On another note, what does it take to get a pull request included in the core code? I submitted a few changes that looked like others might find useful but they seem to have disappeared and not have been included in the core.


Thanks,
Tony

Marcus Brito

unread,
Feb 10, 2011, 9:23:39 PM2/10/11
to thr...@googlegroups.com
Here's what I did to get my project working for both normal compile and archiving:


In short, Protect.command conditionally switches to the right directory in all cases, and Paths.xcconfig include *both* paths, since we can't include conditional magic here.

-- Marcus Brito

Tony Lewis

unread,
Feb 11, 2011, 6:25:59 PM2/11/11
to thr...@googlegroups.com
Thanks Marcus. This worked great.  Although I am having a problem with the Archiving process not production an IPA that can be used for validation and submission to the App Store. This issue is outside the scope of Three20 and appears to be a bug in Xcode 4 from what my research is showing.  Have you come across this?

Also, do you know how I get a Pull request incorporated into the master branch?  I have two small changes I submitted back at the beginning of December and they are still sitting there not touched.

Thanks,
Tony

Marcus Brito

unread,
Feb 11, 2011, 7:27:53 PM2/11/11
to thr...@googlegroups.com
On Fri, Feb 11, 2011 at 9:25 PM, Tony Lewis <tony....@taknology.net> wrote:

Thanks Marcus. This worked great.  Although I am having a problem with the Archiving process not production an IPA that can be used for validation and submission to the App Store. This issue is outside the scope of Three20 and appears to be a bug in Xcode 4 from what my research is showing.  Have you come across this?

No, I didn't. Since I've started using Xcode 4 I didn't submit to the app store yet. I did notices a few posts on Apple devforums about failed validations, so hopefully you're right about this being an Xcode 4 bug.

 
Also, do you know how I get a Pull request incorporated into the master branch?  I have two small changes I submitted back at the beginning of December and they are still sitting there not touched.

I don't know for sure — I have a couple of pull requests as well, and jwang commented on one of them stating it would be included in a future release, so I believe he or someone else will take a look at every request sooner or later.

-- Marcus Brito

gilletty

unread,
Feb 16, 2011, 8:33:47 AM2/16/11
to Three20
Tony,

After using the fix from Marcus (thanks Marcus), I went to Product >
Build For > Build For Archiving. Then, go to the Products directory
and find YourAppName.app, right-click on it, and choose "Show in
Finder". You must then zip that file and use Application Loader to
submit the binary to Apple. I could be wrong, but I don't think Xcode
4's Archive feature can be used with iOS apps yet (although I know it
works for Mac apps).

Ryan

Marcus Brito

unread,
Feb 16, 2011, 12:31:14 PM2/16/11
to thr...@googlegroups.com
I've just submitted a iOS application built using Xcode 4's Archive feature. I'm still waiting for review, but the pre-upload validation didn't show any issues.

What problems are you running into?

-- 
Marcus Brito
Sent with Sparrow

Tony Lewis

unread,
Feb 16, 2011, 1:16:42 PM2/16/11
to thr...@googlegroups.com
The result of this actions does not produce an IPA. It creates some other file and when I try to run validate it complains there is no IPA available to validate.

Marcus Brito

unread,
Feb 16, 2011, 1:51:17 PM2/16/11
to thr...@googlegroups.com, Tony Lewis
There's a known Xcode 4 issue where archives are including static libraries (and then can't be exported as IPA). Apple claims this is actually a bug fix, whatever. 

You need to make sure that Three20 libraries are *not* installed as part of your product. My modification to Three20 is supposed to do this, but what else might be effecting your project configuruation. Double check that "Skip Installation" is set to YES for every Three20 target in your project, and try to generate a new archive.

-- Marcus

Tony Lewis

unread,
Feb 16, 2011, 2:11:30 PM2/16/11
to thr...@googlegroups.com
Hi Marcus,

i thought I had tried that but will try again.  And the project main target. Does that get left as Skip Installation = No?

Tony

Marcus Brito

unread,
Feb 16, 2011, 2:14:36 PM2/16/11
to thr...@googlegroups.com
Yes, the main target stays as Skip Installation = NO. This build setting determines what gets packaged in the final archive, so only targets that are to be included should have this set to NO. Other targets, like your test target and static libraries should have this set to YES.

-- Marcus

Tony Lewis

unread,
Feb 16, 2011, 2:45:12 PM2/16/11
to thr...@googlegroups.com
Hi Marcus,

This seems to have resolved the issue.  Thanks again. I could have sworn I had done that once before.  I remember a forum posting regarding this issue.  It mentioned removing the Installation Directory value from the Deployment build settings as well. Do you know if this is necessary or not?

Thanks,
Tony

Marcus Brito

unread,
Feb 16, 2011, 2:47:10 PM2/16/11
to thr...@googlegroups.com, Tony Lewis
Installation Directory is only used if Skip Install is set to NO, so I don't think you have  to change it.

-- Marcus

Andy Dunn

unread,
Mar 11, 2011, 3:39:30 PM3/11/11
to Three20
Im still getting this problem and I have the main project set to
SKIP_INSTALL = NO, and all 7 of the Three20 projects set to
SKIP_INSTALL = YES.

Is there anyway to find out what libraries are trying to be included
in the IPA file so I can track this down further ?

Ive also set all Installation Directories to be "" as suggested in the
Apple forums.

Thanks for any help.

Andy

On Feb 16, 7:47 pm, Marcus Brito <mbr...@gmail.com> wrote:
> Installation Directory is only used if Skip Install is set to NO, so I don't
> think you have  to change it.
>
> -- Marcus
>
> On Wed, Feb 16, 2011 at 5:45 PM, Tony Lewis <tony.le...@taknology.net>wrote:
>
>
>
> > Hi Marcus,
>
> > This seems to have resolved the issue.  Thanks again. I could have sworn I
> > had done that once before.  I remember a forum posting regarding this issue.
> >  It mentioned removing the Installation Directory value from the Deployment
> > build settings as well. Do you know if this is necessary or not?
>
> > Thanks,
> > Tony
>
> > On Feb 16, 2011, at 2:14 PM, Marcus Brito wrote:
>
> > Yes, the main target stays as Skip Installation = NO. This build setting
> > determines what gets packaged in the final archive, so only targets that are
> > to be included should have this set to NO. Other targets, like your test
> > target and static libraries should have this set to YES.
>
> > -- Marcus
>
> > On Wed, Feb 16, 2011 at 5:11 PM, Tony Lewis <tony.le...@taknology.net>wrote:
>
> >> Hi Marcus,
>
> >> i thought I had tried that but will try again.  And the project main
> >> target. Does that get left as Skip Installation = No?
>
> >> Tony
>
> >> On Feb 16, 2011, at 1:51 PM, Marcus Brito wrote:
>
> >> There's a known Xcode 4 issue where archives are including static
> >> libraries (and then can't be exported as IPA). Apple claims this is actually
> >> a bug fix, whatever.
>
> >> You need to make sure that Three20 libraries are *not* installed as part
> >> of your product. My modification to Three20 is supposed to do this, but what
> >> else might be effecting your project configuruation. Double check that "Skip
> >> Installation" is set to YES for every Three20 target in your project, and
> >> try to generate a new archive.
>
> >> -- Marcus
>
> >> On Wed, Feb 16, 2011 at 4:16 PM, Tony Lewis <tony.le...@taknology.net>wrote:
>
> >>> The result of this actions does not produce an IPA. It creates some other
> >>> file and when I try to run validate it complains there is no IPA available
> >>> to validate.
>
> >>> On Feb 16, 2011, at 12:31 PM, Marcus Brito wrote:
>
> >>>  I've just submitted a iOS application built using Xcode 4's Archive
> >>> feature. I'm still waiting for review, but the pre-upload validation didn't
> >>> show any issues.
>
> >>> What problems are you running into?
>
> >>> --
> >>> Marcus Brito
> >>> Sent with Sparrow <http://www.sparrowmailapp.com/>

Marcus Brito

unread,
Mar 11, 2011, 3:46:33 PM3/11/11
to thr...@googlegroups.com, Andy Dunn
On Fri, Mar 11, 2011 at 5:39 PM, Andy Dunn <sui...@gmail.com> wrote:

Is there anyway to find out what libraries are trying to be included
in the IPA file so I can track this down further ?

First, check out the recently released Three20 1.0.5, it officialy supports Xcode 4. Answering your question, sure, just right-click the generated archive in the Organizer window, and select "Open in Finder". Then you can inspect the contents of the archive.

-- Marcus

Andy Dunn

unread,
Mar 14, 2011, 5:25:16 AM3/14/11
to Three20
Thanks Marcus.

After further testing and comparing my project to the working
TTCatalog it seems that I was including load_all and lib_xml in the
linker flags unnecssarily. Once I took those out it seemed to work
fine.

Andy

On Mar 11, 8:46 pm, Marcus Brito <mbr...@gmail.com> wrote:

remy.vanherweghem

unread,
Mar 14, 2011, 2:53:57 PM3/14/11
to Three20
Using Three20 10.0.5, I'm getting "error: Three20/Three20.h: No such
file or directory" when I try to archive; builds fine for testing
otherwise...

coneybeare

unread,
Mar 28, 2011, 3:43:46 PM3/28/11
to Three20
I am also having issues with the Archive function.

Three20 builds fine under any scheme I give it. when I select "Project
-> Archive" however, it says it can't find the headers for Three20. I
have ensured that Skip Install is "YES" for all Three20 and supporting
project targets, I have ensured that Skip Install is "NO" for my
project target, and I have double checked that the proper XCode 4
Header search paths were added.

Has anybody actually gotten a Three20 app to "Archive"

On Mar 14, 2:53 pm, "remy.vanherweghem" <remy.vanherweg...@gmail.com>
wrote:

elpuerco63

unread,
Mar 28, 2011, 7:18:46 PM3/28/11
to thr...@googlegroups.com, Three20
I have regularly got three20 to archive including once this evening to a release .ipa file.

ep

> --
> We are moving away from Google Groups as our primary community in favor of a new, custom-made Vanilla forums setup. Please start asking questions there going forward. We will continue supporting the Three20 Google Group at least until April 9th of 2011.
>
> http://forums.three20.info/

Reply all
Reply to author
Forward
Message has been deleted
0 new messages