Three20-GSoC doesn't work on iPod Touch (iOS 4.0)

10 views
Skip to first unread message

Błażej Biesiada

unread,
Jul 22, 2010, 6:57:17 AM7/22/10
to Three20
Yesterday I've came across a very strange bug in the latest Three20
GSoC fork. It doesn't work on iPod Touch with iOS 4.0, it fails at
TTStyleSheet initialization (crash report below). On other devices
(3...@4.0.1 and 2...@3.1.3) it works fine, but I haven't tried iPod Touch
with an older iOS. This is the crash report (only 1st thread):

Incident Identifier: 5D570FFA-A145-4361-B5D0-CBFCCD28131A
CrashReporter Key: c2e9377b5245cf5ae26eaadc263a8576a43a2a88
Hardware Model: iPod2,1
Process: numote [533]
Path: /var/mobile/Applications/40CB7AE5-8B55-4C7E-9E45-
BE8492C272C3/numote 17.app/numote
Identifier: numote
Version: ??? (???)
Code Type: ARM (Native)
Parent Process: launchd [1]

Date/Time: 2010-07-21 21:42:15.749 -0400
OS Version: iPhone OS 4.0 (8A293)
Report Version: 104

Exception Type: EXC_BAD_INSTRUCTION (SIGILL)
Exception Codes: 0x00000001, 0x00000000
Crashed Thread: 0

Thread 0 Crashed:
0 numote 0x000f11ee -[TTStyleSheet init]
(TTStyleSheet.m:36)
1 numote 0x00029186 -[NumoteAppDelegate
applicationDidFinishLaunching:] (NumoteAppDelegate.m:60)
2 UIKit 0x0001314c -[UIApplication
_callInitializationDelegatesForURL:payload:suspended:] + 1192
3 UIKit 0x001c16cc -[UIApplication
_runWithURL:payload:launchOrientation:statusBarStyle:statusBarHidden:]
+ 292
4 UIKit 0x0007c7b8 -[UIApplication
handleEvent:withNewEvent:] + 1784
5 UIKit 0x0007beb4 -[UIApplication
sendEvent:] + 60
6 UIKit 0x0007b7e8
_UIApplicationHandleEvent + 6704
7 GraphicsServices 0x00004edc PurpleEventCallback +
1024
8 CoreFoundation 0x000742ac
__CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 22
9 CoreFoundation 0x000761d6 __CFRunLoopDoSource1 +
158
10 CoreFoundation 0x0007718e __CFRunLoopRun + 574
11 CoreFoundation 0x0001e0bc CFRunLoopRunSpecific +
220
12 CoreFoundation 0x0001dfca CFRunLoopRunInMode + 54
13 UIKit 0x00007b18 -[UIApplication _run] +
524
14 UIKit 0x00005fb8 UIApplicationMain + 964
15 numote 0x000023de main (main.m:14)
16 numote 0x00002354 start + 44

Pablo

unread,
Jul 26, 2010, 9:13:36 AM7/26/10
to Three20, Błażej Biesiada
I can reproduce this for the iPhone 3G under 4.0.0 and 4.0.1 using the
latest three20,
but only when building for release or ad-hoc configuration!

Program received signal: “EXC_BAD_INSTRUCTION”.

Debug works fine... On the 3GS it runs without a hatch!

Incident Identifier: 0EC8E284-7561-485B-9288-1AA4318783A9
CrashReporter Key: d8b3e77c115b2e541f80031989d727e4cf502e1b
Hardware Model: iPhone1,2
Process: myApp [977]
Path: /var/mobile/Applications/D814DCD2-9574-4384-BDF2-
B5DFE3D67143/myApp.app/VOL
Identifier: myApp
Version: ??? (???)
Code Type: ARM (Native)
Parent Process: launchd [1]

Date/Time: 2010-06-26 15:08:59.255 +0200
OS Version: iPhone OS 4.0.1 (8A306)
Report Version: 104

Exception Type: 00000020
Exception Codes: 0x8badf00d
Highlighted Thread: 0

Application Specific Information:
com.medienhaus.volnews failed to launch in time
elapsed total CPU time (seconds): 23.130 (user 20.600, system 2.530),
99% CPU
elapsed application CPU time (seconds): 0.020, 0% CPU

Backtrace not available

Unknown thread crashed with unknown flavor: 5, state_count: 1

Binary Images:
0x2fe00000 - 0x2fe28fff dyld armv6
<a2a8d67606c76b315fd9e97b0b023784> /usr/lib/dyld

RolandG

unread,
Jul 26, 2010, 11:36:42 AM7/26/10
to Three20
I have exactly the same problem, but on iPod Touch 1st gen with iOS
3.1.3
works in debug, but not in release, very strange

any ideas?

humsuplo

unread,
Jul 26, 2010, 2:47:47 PM7/26/10
to Three20
same error here but i am getting it on :

[[TTURLRequestQueue mainQueue] setMaxContentLength:0];

It gets a EXC_BAD_INSTRUCTIONS in release mode;

Dane Hesseldahl

unread,
Jul 26, 2010, 3:00:45 PM7/26/10
to thr...@googlegroups.com

Have you verified that your release configuration contains the "all_load" flag?

On Jul 26, 2010 11:47 AM, "humsuplo" <fra...@gmail.com> wrote:

same error here but i am getting it on :

[[TTURLRequestQueue mainQueue] setMaxContentLength:0];

It gets a EXC_BAD_INSTRUCTIONS in release mode;


On Jul 26, 11:36 am, RolandG <rgropm...@googlemail.com> wrote:

> I have exactly the same problem, b...

Pablo

unread,
Jul 26, 2010, 3:46:32 PM7/26/10
to Three20
Yes, all_load and ObjC are there...

humsuplo: What ever Three20 function gets called first causes the
crash...

So if your first function call in applicationDidFinishLaunching calls
TTURLRequestQueue it will crash on it's init / super init call...

I've also created a ticket for it at github: http://github.com/facebook/three20/issues#issue/254

Add your comments there too and vote for it so it gets fixed.

Pablo



On 26 Jul., 21:00, Dane Hesseldahl <dane.hesseld...@gmail.com> wrote:
> Have you verified that your release configuration contains the "all_load"
> flag?
>

Pablo

unread,
Jul 27, 2010, 8:06:23 AM7/27/10
to Three20
For now I'm using Commit: d7eb8b8681077be1d8602d5af129b35cd7c3fc36

This one seems to be the last working one.


Regards,

Pablo

Pablo

unread,
Jul 28, 2010, 7:23:37 AM7/28/10
to Three20
Ok... Here's the fix:
Pull the latest three20 commit
(679e6802c5af45d4dad86a9c9d34eb1205ff6fe3).

Now remove three20 and it's dependencies from your project.

Delete the build folder.

Delete your three20 folder and replace it with the latest commit.

Go to the src directory and open up all xcodeproj.

In each project edit the project settings:

Base SDK to "iPhone Device 4.0" (from "iPhone Simulator 3.2")
Architecture to "Standard" (from "Optimized").

Kudos to Johan Kool for figuring this out!


Cheers,

Pablo

Перепелицын Александр

unread,
Aug 5, 2010, 9:33:33 AM8/5/10
to Three20
I'm can't compiled todays release with many linker errors. I'm had
try to compile TTCatalog- base Three20 sample. I'm trying with SDK iOS
4.0, using yours previous post about changing target and sdk's.

Mike

unread,
Aug 31, 2010, 9:36:55 AM8/31/10
to Three20
I can confirm here that this does appear to fix the problem on the one
device I tried.

I have an app that is in the App Store right now with this problem.
Maybe the green header that says "Safe" at the top of three20.info
isn't exactly accurate.

engr_ AsadUllah

unread,
Aug 31, 2010, 2:13:20 PM8/31/10
to Three20
very thanks
my problem solved.
now i can run the app on device as well.

regards
asad

Alessio Di Cienzo

unread,
Sep 10, 2010, 12:37:15 PM9/10/10
to Three20
I'm using the latest three20 release downloaded in August, that has
the commit you've linked. I've also already done the settings of base
sdk and architecture you've said, but I'm continuing had this problem.
The problem is that my app is already on App Store and I'm worried
about that.

A friend of mine downloaded the app but can't use it because the app
crashes at startup: after click on it, it starts launching and after a
couple of seconds of black screen it returns to the Home. The iPod is
a 8Gb Second Generation one, with iOS 4.0.2
I have no problems with the app on my iPod Touch 32Gb Third
Generation, neither in the simulator. And, for now, it seems that no
one that downloaded the app from App Store has this kind of issue
because I haven't no bad rating.

I've picked up the iPod of my friend and I found that if I install the
application from XCode, the app works well. Also after relaunching it
from iPod (after the installation from XCode), the app gives no
problems.
But if I download the app again from App Store or from iTunes, it
gives the problem again. If I download instead the app from the App
Store on my iPod 32Gb, I haven't the problem.
The logs of the device from the iPod that had the problem says:

[...]
Hardware Model: iPod2,1
Process: LucidDreams [55]
Path: /var/mobile/Applications/8A3XXXX5-BE55-4XXX-XXD2-77D2493E8XX1/
LucidDreams.app/LucidDreams
Identifier: LucidDreams
Version: ??? (???)
Code Type: ARM (Native)
Parent Process: launchd [1]

Date/Time: 2010-09-06 16:59:22.741 +0200
OS Version: iPhone OS 4.0.2 (8A400)
Report Version: 104

Exception Type: EXC_BAD_INSTRUCTION (SIGILL)
Exception Codes: 0x00000001, 0x00000000
Crashed Thread: 0

Thread 0 Crashed:
0 LucidDreams 0x00012daa 0x1000 + 73130
1 LucidDreams 0x00002d84 0x1000 + 7556
2 UIKit 0x000130f8 -[UIApplication
_callInitializationDelegatesForURLayload:suspend ed:] + 1108
3 UIKit 0x001c16cc -[UIApplication
_runWithURLayload:launchOrientation:statusBarSty le:statusBarHidden:]
+ 292
4 UIKit 0x0007c7b8 -[UIApplication handleEvent:withNewEvent:] + 1784
5 UIKit 0x0007beb4 -[UIApplication sendEvent:] + 60
6 UIKit 0x0007b7e8 _UIApplicationHandleEvent + 6704
7 GraphicsServices 0x00004edc PurpleEventCallback + 1024
8 CoreFoundation 0x000742ac
__CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FU NCTION__ + 22
9 CoreFoundation 0x000761d6 __CFRunLoopDoSource1 + 158
10 CoreFoundation 0x0007718e __CFRunLoopRun + 574
11 CoreFoundation 0x0001e0bc CFRunLoopRunSpecific + 220
12 CoreFoundation 0x0001dfca CFRunLoopRunInMode + 54
13 UIKit 0x00007b18 -[UIApplication _run] + 524
14 UIKit 0x00005fb8 UIApplicationMain + 964
15 LucidDreams 0x00002d18 0x1000 + 7448
16 LucidDreams 0x00002ce8 0x1000 + 7400

Thread 1:
0 libSystem.B.dylib 0x00034e84 kevent + 24
1 libSystem.B.dylib 0x00102a48 _dispatch_mgr_invoke + 88
2 libSystem.B.dylib 0x00102494 _dispatch_queue_invoke + 96
3 libSystem.B.dylib 0x00102634 _dispatch_worker_thread2 + 120
4 libSystem.B.dylib 0x0008b53c _pthread_wqthread + 392
5 libSystem.B.dylib 0x00082b6c start_wqthread + 0
[...]


Hope that someone can give me an hint...

Benjamin Reed

unread,
Sep 10, 2010, 1:55:53 PM9/10/10
to thr...@googlegroups.com
I can't comment on what did or did not work in your case, but I can
tell you that I accidentally released my 1.0.0 of OpenNMS with the
wrong SDK settings (I was in a branch that didn't have the changes),
and it crashed just as you describe on iOS < 3.2. After making the
changes that have been recommended here a number of times, everything
worked:

1. edit active target, "General" tab, "Linked Libraries" should have
UIKit.framework as Type: Weak
2. edit active project, make sure "All Configurations" is selected,
change "Other Linker Flags" to "-ObjC -all_load"
3. edit active project, make sure "All Configurations" is selected
3a. change "Base SDK" to "iPhone Device 4.0"
3b. change "Architectures" to "Standard (armv6, armv7)"
3c. change "iPhone OS Deployment Target" to "iPhone OS 3.0".
4. open each three20 project, and do all of step 3 for each one

...once I did that, everything was fine.

My update with these fixes just went live a few days ago, so Three20
top-of-tree with these changes is definitely getting accepted by
Apple.

> --
> 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.
>
>

--
Benjamin Reed a.k.a. Ranger Rick
Fink, KDE, and Mac OS X development

Blog: http://www.raccoonfink.com/
Music: http://music.raccoonfink.com/

robertvmathews

unread,
Sep 10, 2010, 2:30:06 PM9/10/10
to Three20
Our app was working on 3GS, working in 'Debug' on a 3G and older
Touch. 'Release' on a 3G crashed.

This worked for us.

Thanks!


On Jul 28, 7:23 am, Pablo <pablo.guil...@medienhaus.com> wrote:
> Ok... Here's the fix:
> Pull the latestthree20commit
> (679e6802c5af45d4dad86a9c9d34eb1205ff6fe3).
>
> Now removethree20and it's dependencies from yourproject.
>
> Delete the build folder.
>
> Delete yourthree20folder and replace it with the latest commit.
>
> Go to the src directory and open up all xcodeproj.
>
> In eachprojectedit theprojectsettings:
>
> Base SDK to "iPhone Device 4.0" (from "iPhone Simulator 3.2")
> Architecture to "Standard" (from "Optimized").
>
> Kudos to Johan Kool for figuring this out!
>
> Cheers,
>
> Pablo
>
> On 27 Jul., 14:06, Pablo <pablo.guil...@medienhaus.com> wrote:
>
> > For now I'm using Commit: d7eb8b8681077be1d8602d5af129b35cd7c3fc36
>
> > This one seems to be the last working one.
>
> > Regards,
>
> > Pablo
>
> > On 26 Jul., 21:46, Pablo <pablo.guil...@medienhaus.com> wrote:
>
> > > Yes, all_load and ObjC are there...
>
> > > humsuplo: What everThree20function gets called first causes the

Alessio Di Cienzo

unread,
Sep 12, 2010, 9:18:38 AM9/12/10
to Three20
Hi!

Thanks for answering :)

Today I've done again from the beginning all the entire procedure
described in this topic and now it works :D
I think that maybe I've forgot to change the "architectures" in one of
the .xcodeproj of the src directory.

Thanks again for the help!
Alessio
> > For more options, visit this group athttp://groups.google.com/group/three20?hl=en.

Pablo Guillen Schlippe

unread,
Sep 13, 2010, 2:06:35 AM9/13/10
to <three20@googlegroups.com>
Shouldn't it be URLPayload instead of ayload?

Looks like a simple typo to me.

Cheers,

Pablo

--
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.


Pablo Guillen | Softwareentwicklung



medienhaus.com GmbH
Gutenbergstr.1, 6858 Schwarzach, Austria




Reply all
Reply to author
Forward
0 new messages