frash icon indicating copy to clipboard operation
frash copied to clipboard

iOS 4.2.1 - _abort() food.c:43 - reopened

Open calaba opened this issue 14 years ago • 42 comments

Hi, this is follow up on the issue #26: https://github.com/comex/frash/issues/closed/#issue/26 which was closed by mistake by kernell, ric.

calaba avatar Feb 25 '11 21:02 calaba

Again last reply before mistaken close:

*** Warning *** Even I have decades experience with development on various platforms/languages I am complete rookie in Mac OS/ iOS world ... so forbid any inaccuracies or other bulls_t I put below _

Ok guys, I got tired googling all over internet to get same output on this one -> means nothing, everyone just complains it doesn't work, none analyzes. Thus I had checked the source code of Fresh - food.c - line 43 - as some add function trying to lookp and initialize needed libraries - and here it is failing. So I scanned my /usr/lib and really some of referenced libraries were not found (also libraries referenced by other libraries), here is status update on my 4.2.1 iPad iOS:

  1. can anyone who is responsible for maintaing this git source add better error handling -> i.e. instead of dummy abort message display which library failed to load ...

  2. In the latest source code there is following sequence:

add("/usr/lib/libcrypto.dylib");   ----> don't have it
add("/usr/lib/libssl.dylib");      ----> don't have it
add("/usr/lib/libm.dylib");        ----> don't have it
add("/usr/lib/libSystem.B.dylib"); ----> don't have it

add("./libcutils.dylib");
add("./libutils.dylib");
add("./libgccstuff.dylib");
add("./libicudata.42.1.dylib");
add("./libicui18n.42.1.dylib");
add("./libicuio.42.1.dylib");
add("./libicule.42.1.dylib");
add("./libiculx.42.1.dylib");
add("./libicutu.42.1.dylib");
add("./libicuuc.42.1.dylib");

int fd = open("libflashplayer.so", O_RDONLY);

So as you see already 1st 4 libs were missing + anaylyzing the other libraries I also found other once also missing -> mainly libcrypt ang libgcc.

Then I remind myself when trying to add GNU cc comipler from cydia I was facing issue that libgcc was missing -> whatever are the reasons.

So reason for this problem is clear, question is if we can solve it or not, I started playing around and did:

A) I got libgcc and installed it from following repo (hope I am not mistaken as I tried too many repos recently :) - http://theworm.altervista.org/cydia/ - btw reffered from this thread http://modmyi.com/forums/iphone-ipod-touch-sdk-development-discussion/655111-compiling-iphone-3-0-a.html - other approaches are mentioned -> but read whole thread 1st !!!)

B) after that I was able to install bigboss GNU cc (and othe GNU libs) from Cydia ... I run gcc -> runs ok ... didn't tried yet to compile and run anything ... I looked into /usr/lib and saw lot of missing libs is now there -> sounds promissing ...

C) got also header files refered from: http://antirez.com/page/iphone-gcc-guide.html - so I can start playing around whether the gcc will even work installed this way

Next plan:

  • test whether GCC can compile hello world app and run it
  • test whether the header files allow me to compile Frash-0.02 on the ipad directly ...if not -> then I'll try Xcode on Max OS ..
  • based on source code analysis of food.c check every referred library (and the libraries referred by the lib itself). If I could compile Frahs -> i'll try to add better error message stating which lib failed to load ...

I am busy man so if you can try to play around and post results here I'll appreciate it .. and dozens of other "iPad flash hunters" I guess ...

Cheers

calaba avatar Feb 25 '11 21:02 calaba

Addin last kernell's reply:

kernell about 2 hours ago | link

But, what if you take those missing .dylib from an old firmware? Frash works fine in version 3.2.2, so it must have those files to work properly.

calaba avatar Feb 25 '11 21:02 calaba

i wonder if comex would know... .-. he has a twitter account http://twitter.com/comex

xxzedenxx avatar Feb 25 '11 23:02 xxzedenxx

Pretty sure the missing libraries are actually in the dyld shared cache.

GreySyntax avatar Mar 04 '11 12:03 GreySyntax

Nevertheless if they are there or not ... Frash doesn't see them, that's why it's failing with abort message

calaba avatar Mar 04 '11 20:03 calaba

Can anybody give me A normal instruction to fix error c43?

Nmzik avatar Mar 26 '11 12:03 Nmzik

Some findings: I've an IPhone 4 with 4.2.1. Frash installed, of course I'm getting error @ food.c line 43. I checked if the missing libraries were not there, and the 4 mentioned weren´t

add("/usr/lib/libcrypto.dylib"); add("/usr/lib/libssl.dylib");
add("/usr/lib/libm.dylib");
add("/usr/lib/libSystem.B.dylib");

=>Added the first two libraries and libgcc from the repos below, Tried Frash and still got the same error. => Since I've a working Frash in one Iphone 3GS running with IOS 4.1, I went there to fetch the two missing libraries. However, to my surprise not all the libraries were there!!!

So I guess we need to try compiliing and adding a more descriptive error message?

jpla avatar Apr 01 '11 02:04 jpla

Yup, you have to add all libraries the Frash is trying to load including the ones which are referenced by those listed ... so yes we need to improve the error message sent back .. i had problem to make any C code compiled on the phone directly so now trying to learn xcode if it brings something ... if anyone has a step-by-step scenario how to make gcc working on 4.2.1 iOS (including setup of the header files) please help ...

calaba avatar Apr 01 '11 04:04 calaba

Still, what I do not understand is why Frash is working properly in IOS 4.1 without the last two libraries:

add("/usr/lib/libm.dylib"); add("/usr/lib/libSystem.B.dylib");

But ok, I guess the path is improve the error messages to debug it...

jpla avatar Apr 01 '11 14:04 jpla

How about going down the list of required dylib(s) and getting the ones missing, then paste them into /usr/lib ? Probabally a stupid idea, but just curious.

ismoothproject avatar Apr 03 '11 00:04 ismoothproject

Oh and by the way, http://modmyi.com/forums/file-mods/745028-frash-error-abort-food-c-43-a-2.html

ismoothproject avatar Apr 03 '11 01:04 ismoothproject

Hello everyone!

I am going to post everything that has happened recently on the fourm above with the porting proccess.

"

Hello!

I just happend to bump into your thread. I am working on making Frash for iOS 4.3.1 . I will be porting it and building probably tomorrow. (Not that it will be finished tomorrow, but some progress will be made! lol)

Wish Us Luck! The iSmooth Project.


ModMyi Rocks!

#17
04-02-2011, 07:57 PM

z3r01
apatia

Join Date: Jul 2007 Device + Firmware: iphone 3Gs/iPad Operating System: widescreen iMac Os X 10.5.6/macbook Pro unibody snow leopard Location: Brooklyn Posts: 4,930 Thanks: 74 Thanked 807 Times in 510 Posts

Good luck.


#18
04-02-2011, 08:01 PM

ismoothproject
Green Apple

Join Date: Jan 2011 Device + Firmware: iPod Touch 4.3 GM Beta Tethered Jailbreak Operating System: Mac OS X 10.6.6 Posts: 34 Thanks: 12 Thanked 2 Times in 2 Posts LOL Thanks!

Thanks, The iSmooth Project.

Ok. So, this is a Quote from Comex's GitHub Page.

To actually run it, you'll need libflashplayer.so from Android.

Build instructions: (do networkpx Project Blog: Compiling iPhoneOS (3.1) apps with Xcode 3.2 without Provisioning Profile but use my version of ldid2) (do http://sumgroup.wikispaces.com/iPhone_Dynamic_Library) ln -s /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS3.1.3.sdk /var/sdk export PATH=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:$PATH cp -a /System/Library/Frameworks/IOSurface.framework/Versions/A/Headers Player2/IOSurface cp -a /System/Library/Frameworks/IOSurface.framework/Versions/A/Headers food/IOSurface cp -a /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/CoreText.framework/Versions/A/Headers food/CoreText cp -a /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator3.1.3.sdk/System/Library/Frameworks/IOKit.framework/Versions/A/Headers/ food/IOKit

make -C rpc # Yes, I know what MIG is and there is a reason for this.

probably a bad reason

make -C utils make -C libgcc make -C food xcodebuild -alltargets -project Player2/Player2.xcodeproj

Can someone explain what this does specifically? I think I know, but not sure. Don't want to ruin my new shiny Xcode 4. LOL

Thanks, The iSmooth Project.


ModMyi Rocks! Last edited by ismoothproject; 04-02-2011 at 08:01 PM.. Reason: Automerged Doublepost

#19
04-02-2011, 09:42 PM

invisiblelight
Green Apple

Join Date: Feb 2011 Device + Firmware: iPhone 4 (4.2.1) Operating System: i7 W7 64 Posts: 57 Thanks: 3 Thanked 1 Time in 1 Post this is great news - but it is so much easier using sky-fire for flash.... keep up the good work!


no sig spam

#20
04-02-2011, 09:44 PM

ismoothproject
Green Apple

Join Date: Jan 2011 Device + Firmware: iPod Touch 4.3 GM Beta Tethered Jailbreak Operating System: Mac OS X 10.6.6 Posts: 34 Thanks: 12 Thanked 2 Times in 2 Posts Thanks! I hope it works! I have been googling and think I have a good strategy!

This was really helpful!

https://github.com/comex/frash/issues/#issue/28

Thanks, The iSmooth Project.


ModMyi Rocks!

#21
04-04-2011, 10:52 AM

ismoothproject
Green Apple

Join Date: Jan 2011 Device + Firmware: iPod Touch 4.3 GM Beta Tethered Jailbreak Operating System: Mac OS X 10.6.6 Posts: 34 Thanks: 12 Thanked 2 Times in 2 Posts Ok. So I have pretty much everything setup for building, except for this one little bug.

I will be posting it shortly.


ModMyi Rocks!

The Following User Says Thank You to ismoothproject For This Useful Post: KaMneed (04-04-2011) #22
Yesterday, 12:27 PM KaMneed
What's Jailbreak?

Join Date: Apr 2011 Posts: 1 Thanks: 1 Thanked 0 Times in 0 Posts Quote: Originally Posted by ismoothproject
Ok. So I have pretty much everything setup for building, except for this one little bug.

I will be posting it shortly. Is there any news?

#23
Yesterday, 01:41 PM

Fhsjaagshs
iPhone? More like MyPhone

Join Date: Jul 2010 Device + Firmware: iPT3G + iPad 4.2.1 JB Operating System: Vista SP1 x32 Location: /var/mobile/fhsjaagshs Posts: 171 Thanks: 3 Thanked 6 Times in 6 Posts I think it converts video on their server.

#24
Today, 10:00 AM

ismoothproject
Green Apple

Join Date: Jan 2011 Device + Firmware: iPod Touch 4.3 GM Beta Tethered Jailbreak Operating System: Mac OS X 10.6.6 Posts: 34 Thanks: 12 Thanked 2 Times in 2 Posts Sorry I took so long! I will be podting the error in about 5 min... My mac has to boot up.

Ok. Here are the errors I am getting.

Can someone please explain this? One of them is a file is missing. I have looked over the ENTIRE source code I downloaded and I cannot find any file!

The others might be resolved once we have the other file.

Thanks, The iSmooth Project.

Ok, nevermind! I just fixed all of the bugs above. Now this is what I am having trouble with.

Thanks, The iSmoothProject.

Hello Everyone!

Please ignore all of the bugs above, I just found the files and downloaded them and put them where they belong.

So now, it is making it work for iOS 4.3.1!

I was reading somewhere that system files in 4.1 don't exist anymore, so we need to find them and make a debian that installs them safely.

Here is the link: https://github.com/comex/frash/issues#issue/28

This is a very helpful link.

Thanks for all of your continuing help! The iSmooth Project.


ModMyi Rocks! Last edited by ismoothproject; Today at 10:00 AM.. Reason: Automerged Doublepost

#25
Today, 12:24 PM ads2006
What's Jailbreak?

Join Date: Apr 2011 Posts: 3 Thanks: 0 Thanked 0 Times in 0 Posts Hello iSmooth Project,

Good job.

Have you already have the new frash file that support iOS 4.3.1 in iPad ?

Best Regards,

ads2006

#26
Today, 12:41 PM

ismoothproject
Green Apple

Join Date: Jan 2011 Device + Firmware: iPod Touch 4.3 GM Beta Tethered Jailbreak Operating System: Mac OS X 10.6.6 Posts: 34 Thanks: 12 Thanked 2 Times in 2 Posts Sorry, but what do you mean by that?

Do I have the latest source code? Is it working yet for 4.3.1?

Thanks, The iSmooth Project


ModMyi Rocks!

#27
Today, 01:45 PM ads2006
What's Jailbreak?

Join Date: Apr 2011 Posts: 3 Thanks: 0 Thanked 0 Times in 0 Posts Sorry if I misunderstood but I am imagining you will be providing a new frash.deb file to be uploaded to the iPad to work with OS iOS 4.3.1. Is that right ?

I have a iPad iOS 4.3.1 and I tested frash.deb versions 0.01 and 0.02 and it not worked.

My understaning of this topic is to give ways to make Flash work with iOS 4.3.1 right in iPad, iPhone, etc..., right ? If positive should we expect a guide to do that ?

ads2006

#28
Today, 01:48 PM

ismoothproject
Green Apple

Join Date: Jan 2011 Device + Firmware: iPod Touch 4.3 GM Beta Tethered Jailbreak Operating System: Mac OS X 10.6.6 Posts: 34 Thanks: 12 Thanked 2 Times in 2 Posts Perfectly explained!

Yes, I will be making a debian file and will be on modmyi repo. It will be as simple as: install in cydia, and it works!

That is my goal! It will be called "Frash4iOS"

Thanks! The iSmooth Project.


ModMyi Rocks!

#29
Today, 01:56 PM ads2006
What's Jailbreak?

Join Date: Apr 2011 Posts: 3 Thanks: 0 Thanked 0 Times in 0 Posts Please allow me my latest stupid question. I just signed into this forum so I'm not familiar with it. What you mean with "my modmyi repo" ? Is it some kind of download page inside the Web Site ? When do you expect to have the "Frash4iOS" available to users ?

ads2006

#30
Today, 02:26 PM

ismoothproject
Green Apple

Join Date: Jan 2011 Device + Firmware: iPod Touch 4.3 GM Beta Tethered Jailbreak Operating System: Mac OS X 10.6.6 Posts: 34 Thanks: 12 Thanked 2 Times in 2 Posts That's ok! I ask a lot of stupid questions myself! Lol

This website, modmyi has a cydia repo (you know what repo is, right?) and I will publish "Frash4iOS" on it.

For the second question. 2 weeks? That is what I am hoping for. It could be longer and when it is public, it will be a little buggy of course, but it should be soon!

Ok, I cannot get on my mac because someone else is using it, but I am on my linux server so I will be able to do some things! (The Linux server is running my custom linux operating system. SO SWEET AND FAST! lol)

Anyway, so this is what I am looking for.

/usr/lib/libcrypto.dylib /usr/lib/libssl.dylib /usr/lib/libm.dylib /usr/lib/libSystem.B.dylib

I am going to be jailbreaking an old iOS 4.0 firmware and unzip it to get these system files that frash needs. These are not in the latest firmware so I will get them, put them on my device, and see what happens! lol

When we publish Frash4iOS, we will include these in the debian obviously.

Thanks! The iSmooth Project.


ModMyi Rocks!

"

ismoothproject avatar Apr 06 '11 18:04 ismoothproject

Any news?

Nmzik avatar Apr 10 '11 21:04 Nmzik

You have a github account? Lol no news yet! I might be able to do it tuesday.

ismoothproject avatar Apr 10 '11 21:04 ismoothproject

OK thank you all for everything i respect all the developers and programmers and who works so hard to make everything nice and easy for us

they said knowing or understanding the question is half the answer

the question is what is the difference between iOS 3.xx and the new iOS 4.3.x ?

I'm not a phone developer or anything i'm just a pc programmer with some knowledge.

anyway from all up i understood that the new iOS 4.3.x does not support or use the lib that are missing in the Frash

if that's right then i think if we put the missing lib in the new iOS 4.3. it maybe not going to work.

so we need a new Frash that does not based on the old lib and it can works with current lib in iOS 4.3

to do that we need to understand how Frash actually works.

Can you make the new iOS 4.3 to work with old lib?

or You need to build a new Frash?

comex said he will works on that issue but not right now

Good Luck guys Thank you all

noir1412 avatar Oct 10 '11 09:10 noir1412

Hi all,

Managed to compile a new food.c to try debugging at which point the problem was happening - e.g to know the lib that was causing the trouble. Just installed frash from scratch and replaced the food executable with the new one I compiled.

I found that frash was crashing at the lib ("./libutils.dylib") The lib was present so I checked the dependencies:

libutils.dylib: libutils.dylib (compatibility version 0.0.0, current version 0.0.0) libcutils.dylib (compatibility version 0.0.0, current version 0.0.0) /usr/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.3) /usr/lib/libstdc++.6.dylib (compatibility version 7.0.0, current version 7.9.0) /usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0) /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 125.1.0)

I had all of them on my IPhone 4 running IOS 4.2.1, except libz.1.dylib. and libstdc++.6.dylib. I installed libstdc++.6.dylib from Cydia (there's a package with just the symlink) I tried copyng libz.1.2.3.dylib from the IPhone platform SDK (and made a symlink to libz.1.dylib)

Tried running frash and still was throwing error at that d... library (libutils). I could not understand why.

Gave one last try and compiled a new food executable removing the call to add the library and.... VOILÀ!!!! Frash STARTED WORKING as before but now in iOS 4.2.1 on my iPhone 4!!!!!

I got very exited and tried it as well on my iPad 2 running iOS 5.0.1. Got an "Unexpected Error" in the frash window.... to be further analyzed....

jpla avatar Feb 02 '12 03:02 jpla

This is wonderful!!! Hopefully the unexpected error is just a little bug that can be squashed! :)

Good luck and keep up the great work!

The iSmooth Project

ismoothproject avatar Feb 02 '12 05:02 ismoothproject

Update: works on iPad1 IOS 4.2.1 as well.
Just installed stock Frash from Repo and changed the food file with the one I compiled without the add libutils line. Worked fine without needing to install the libstdc++ and the libz dylibs.

It would be interesting to test it in IOS 4.3.x...

jpla avatar Feb 06 '12 01:02 jpla

jpla may I have your compiled food file?

ShapeShifter499 avatar Feb 28 '12 12:02 ShapeShifter499

Sure, I'll send it in a separate email. Please let me know yr results

Sent from my iPhone

On 28/02/2012, at 09:38, [email protected] wrote:

jpla may I have your compiled food file?


Reply to this email directly or view it on GitHub: https://github.com/comex/frash/issues/28#issuecomment-4214851

jpla avatar Feb 29 '12 14:02 jpla

Please see if you receive it.
Otherwise send me an email directly to [email protected] with an address to send it to

Sent from my iPhone

jpla avatar Feb 29 '12 14:02 jpla

Jpla: can you email me the compiled food file? I can repackage it and test it on 4.3.1. (iPad 2)

mabrowning avatar Apr 08 '12 23:04 mabrowning

Sure. Just send me an email to send it to

On Sun, Apr 8, 2012 at 8:28 PM, mabrowning < [email protected]

wrote:

Jpla: can you email me the compiled food file? I can repackage it and test it on 4.3.1. (iPad 2)


Reply to this email directly or view it on GitHub: https://github.com/comex/frash/issues/28#issuecomment-5019256

jpla avatar Apr 11 '12 03:04 jpla

Does someone tested it on 4.3.3 ? Send me this file I'll post report is it work or not. [email protected]

UniDay avatar Apr 24 '12 19:04 UniDay

It's been a while... I wish we knew how it worked!

Sent from the new iPad 32GB! :P

On Apr 24, 2012, at 3:38 PM, [email protected] wrote:

Does some one tested it on 4.3.3 ? Send me this file I'll post report is it work or not. [email protected]


Reply to this email directly or view it on GitHub: https://github.com/comex/frash/issues/28#issuecomment-5315390

ismoothproject avatar Apr 24 '12 19:04 ismoothproject

It did not work for me on iOS 4.3.x, though it does no longer fail at _abort().

mabrowning avatar Apr 24 '12 19:04 mabrowning

Anybody working on this problem ? Or we can forget about flash on ipad ? Abandon all hope all who entered thee ))) ?

UniDay avatar Apr 24 '12 19:04 UniDay

ABANDDON SHIP! :)

ismoothproject avatar Apr 24 '12 19:04 ismoothproject

In reply to jpla: it did not work for me on 5.0.1 iPhone 4s, nothing happened at all

ShapeShifter499 avatar Apr 24 '12 20:04 ShapeShifter499