forums.ps2dev.org Forum Index forums.ps2dev.org
Homebrew PS2, PSP & PS3 Development Discussions
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

IDE Selection and woes

 
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development
View previous topic :: View next topic  
Author Message
pspblizz



Joined: 13 Sep 2005
Posts: 15

PostPosted: Tue Sep 13, 2005 8:48 pm    Post subject: IDE Selection and woes Reply with quote

Hi

First off, I'm newbie to c++ development, but not to programming. I've read up on c++ and in "nice friendly ides" managed to make some pieces of code compile and run (whohoo!)

But now I want to participate on the homebrew front it all thikens:...

http://wiki.ps2dev.org/psp:programming_faq

This setup didn't work at all for me. It all runs and compiles for hours when trying to setup the toolchain. But crashes randomly during setup. It all comes down to that my Windows XP box gets corrupt during running the psptoolchain script "./toolchain.sh". Symptoms are that "fork resource is not available" is reported, or that cywin-1.dll isn't the right one. After these errors no dlls will load on my computer(codecs when viewing divxx for example). So it's obvious to me that this is most likely due to that cygwin or one of it's components is crap.

Deinstalling all of that, including cygwin, and then going with devkitpro.org release 1.0.7 isn't fun either....

When trying to compile one of the samples in that distribution I get a popup box saying "libiconv-2.dll isn't found try to reinstall to fix the problem".

The only one that works for me which is "voila!" out of the box is milhouse's PSPide1.0. But this is not up to date with the latest PSPDSK and there is no mention anywhere of how to keep up to date with this.

Also, on windows and linux I've used libsdl to play around, but I have no clue on how to get it for psp and into which directory in the file structure of the three different psp dev distros listed here.

Some pointers would be greatly appreciated! :)

1. Which should I use? I prefere devkitpro, but it doesn't work (seems like it has a good editor and is easy to keep up to date, but I prefere svn over cvs... :-/ )

2. When using extra libs like libsdl, a 1-2-3 tutorial would be nice.

My system is a Windows XP SP2 box. It's a laptop with 1GB Ram and a centrino CPU. It has cygwin installed, but I suspect that it's a crap version by the cygwin ppl (the dlls become unstable and crash).

edit: added links
Back to top
View user's profile Send private message
pspblizz



Joined: 13 Sep 2005
Posts: 15

PostPosted: Wed Sep 14, 2005 12:08 am    Post subject: First ./toolchain.sh run Reply with quote

Here is the first attempt at running the toolchain.

Code:

./config.status: line 765: /usr/bin/rm: Resource temporarily unavailable
./config.status: line 767: /usr/bin/mv: Resource temporarily unavailable
config.status: creating config.h
./config.status: fork: Resource temporarily unavailable
./config.status: fork: Resource temporarily unavailable
./config.status: fork: Resource temporarily unavailable
./config.status: fork: Resource temporarily unavailable
/tmp/pspdev/gcc-4.0.1/intl/configure: fork: Resource temporarily unavailable
/tmp/pspdev/gcc-4.0.1/intl/configure: line 8673: /usr/bin/cat: Resource temporar
ily unavailable
/tmp/pspdev/gcc-4.0.1/intl/configure: fork: Resource temporarily unavailable
/tmp/pspdev/gcc-4.0.1/intl/configure: fork: Resource temporarily unavailable
make: *** [configure-intl] Error 1
ERROR BUILDING GCC


Last edited by pspblizz on Wed Sep 14, 2005 8:26 pm; edited 1 time in total
Back to top
View user's profile Send private message
pspblizz



Joined: 13 Sep 2005
Posts: 15

PostPosted: Wed Sep 14, 2005 12:09 am    Post subject: second attempt at running ./toolchain.sh Reply with quote

Here is the second attempt.

Code:

checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
/tmp/pspdev/gcc-4.0.1/intl/configure: fork: Resource temporarily unavailable
/tmp/pspdev/gcc-4.0.1/intl/configure: fork: Resource temporarily unavailable
/tmp/pspdev/gcc-4.0.1/intl/configure: fork: Resource temporarily unavailable
/tmp/pspdev/gcc-4.0.1/intl/configure: fork: Resource temporarily unavailable
make: *** [configure-intl] Error 1
ERROR BUILDING GCC


Last edited by pspblizz on Wed Sep 14, 2005 8:26 pm; edited 1 time in total
Back to top
View user's profile Send private message
pspblizz



Joined: 13 Sep 2005
Posts: 15

PostPosted: Wed Sep 14, 2005 4:57 am    Post subject: Reply with quote

following a variation of this one:
http://forums.ps2dev.org/viewtopic.php?p=22080#22080

I got it working... goode... Now I only need to figure out how to include libsdl.

Any takers?
Back to top
View user's profile Send private message
pspblizz



Joined: 13 Sep 2005
Posts: 15

PostPosted: Wed Sep 14, 2005 8:27 pm    Post subject: Reply with quote

Well, that wasn't the newest toolchain, and I can't get the compile to work.

Seems like cygwin is known to crash on large configure scripts.

Here is one (of many reports):
http://studio.imagemagick.org/pipermail/magick-users/2003-March/008059.html

Update:
http://www.mail-archive.com/cygwin@cygwin.com/msg59047.html

Seems like the only fix is to run fewer processes, I'll try this and report back.

Update II:
Okay, that didn't work. The process ran further this time, but still it had a hard time starting new processes after a while and so it crashed with resource temp unavailable.

So now I'll try to run throught the different options one at a time, and reboot in between and see if that works.

Update III:
YES! binutils compiled, now after a reboot I'm compiling the gcc


Last edited by pspblizz on Wed Sep 14, 2005 10:42 pm; edited 1 time in total
Back to top
View user's profile Send private message
rinco



Joined: 21 Jan 2005
Posts: 255
Location: Canberra, Australia

PostPosted: Wed Sep 14, 2005 10:39 pm    Post subject: Reply with quote

toolchain.sh runs fine for me in cygwin. i doubt a bug report from 32 months ago still applies today.

chances are your memory is buggered. i find many computers ship from retail outlets without any testing whatsoever. try testing your memory by booting memtest86.

it is also likely your computer is infected with trojans and viruses. try building the toolchain on a fresh installation of windows.

or get yourself a copy of knoppix and build the toolchain in linux. cool kids use linux. (cooler kids use macosx)
Back to top
View user's profile Send private message
pspblizz



Joined: 13 Sep 2005
Posts: 15

PostPosted: Wed Sep 14, 2005 10:55 pm    Post subject: Reply with quote

rinco wrote:
toolchain.sh runs fine for me in cygwin. i doubt a bug report from 32 months ago still applies today.


Sad to say it does, because it's not a bug. "It's a feature". Or at least until cygwin people know how to fix it, they were still working on this as late as 19th of August 2005.

rinco wrote:

chances are your memory is buggered. i find many computers ship from retail outlets without any testing whatsoever. try testing your memory by booting memtest86.


I've got a Dell D800, and it's testing fine with dells and other memtest tools.

rinco wrote:

it is also likely your computer is infected with trojans and viruses. try building the toolchain on a fresh installation of windows.


It could be, but it's highly unlikely. I've got four security tools running at all times (TinyPersonal FW, SPWD, Search&Destr. and MS AntiSPW). And bidaily reports states that I'm clean. One of the actions I've done to make it compile is to deactivate all tools and stay offline. I've got LOADS running on this laptop since it's my java development environment. All is now off so that the machine is as "silent" as possible.

rinco wrote:

or get yourself a copy of knoppix and build the toolchain in linux. cool kids use linux. (cooler kids use macosx)


I might migrate this whole thing to my linux box at home (Suse 9.3), I only want to put it on my laptop since it's my work box :)

But I really appreciate your feedback rinco, the only thing I hadn't tried was testing my memory - but alas, it came out good :-/

But it seems like that I can compile it "in steps" so far, first "leg" went well, now I'm trying to compile the gcc. (option -g to the toolchain script).

compiling of the gcc failed:
Code:
e:\cygwin\bin\sh.exe (4072): *** thread handle not set - 0x0<0x0>, Win32 error 1
450
/tmp/pspdev/gcc-4.0.1/intl/configure: fork: Resource temporarily unavailable
checking for putenv... /tmp/pspdev/gcc-4.0.1/intl/configure: line 5758: ${+set}:
 bad substitution
/tmp/pspdev/gcc-4.0.1/intl/configure: line 5761: /usr/bin/cat: Resource temporar
ily unavailable
/tmp/pspdev/gcc-4.0.1/intl/configure: fork: Resource temporarily unavailable
/tmp/pspdev/gcc-4.0.1/intl/configure: fork: Resource temporarily unavailable
/tmp/pspdev/gcc-4.0.1/intl/configure: fork: Resource temporarily unavailable
/tmp/pspdev/gcc-4.0.1/intl/configure: fork: Resource temporarily unavailable
make: *** [configure-intl] Error 1
ERROR BUILDING GCC (C++)


But I might have been a bit brave, opening Outlook and browsing with firefox during the compiling. When I get home in an hour, I'll try again - perhaps in safemode then :)
Back to top
View user's profile Send private message
pspblizz



Joined: 13 Sep 2005
Posts: 15

PostPosted: Thu Sep 15, 2005 7:40 am    Post subject: Reply with quote

Nopes, I'm giving this up for now.

Running
Code:
./toolchain -g
ran for several hours and ended in
Code:
../../../libiberty/regex.c:8234: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8235: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8237: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8238: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8239: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8240: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8242: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8243: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8244: error: dereferencing pointer to incomplete type

make[1]: *** [regex.o] Error 1
make[1]: Leaving directory `/tmp/pspdev/gcc-4.0.1/build-psp-c++/psp/libiberty'
make: *** [all-target-libiberty] Error 2
ERROR BUILDING GCC (C++)


I can't believe it's supposed to be this hard :(

My experience so far:
* PSPide = old PSPSDK, doesn't compile new samples
* devkitPRO w/hack to make it compile code = old psp-config, doesn't compile libsdl
* devkitPRO out of the box = complains on missing libiconv-2.dll
* psptoolchain w/cygwin = doesn't compile and crashes windows (no new processes able to start)
* psptoolchain booted in safe mode w/cygwin = crashes with error stated above
* psptoolchain on Dell Dimention 8300 = same as on Dell D800

So this have parked me for now. It feels like a defeat :-/[/list]
Back to top
View user's profile Send private message
CyberBill



Joined: 26 Jul 2005
Posts: 86
Location: Redmond, WA

PostPosted: Thu Sep 15, 2005 9:44 am    Post subject: Reply with quote

Are you logged in as administrator?

You might want to try completely uninstalling cygwin, deleting the cygwin directory, and reinstalling it. Do a FULL install of EVERYTHING. After the install completes, try to run toolchain.sh.

The thing is, there are a lot of people on here who have installed the toolchain. I have, and it worked fine on two computers (work and home). Honestly memory errors are very difficult to track down, and even Memtest86 misses things. I've run it on computers for hours and it showed nothing on computers that I knew had memory problems.

If you've got more than one stick, try removing them one at a time... Run the install with your case off maybe.
Back to top
View user's profile Send private message AIM Address MSN Messenger
rinco



Joined: 21 Jan 2005
Posts: 255
Location: Canberra, Australia

PostPosted: Thu Sep 15, 2005 10:26 am    Post subject: Reply with quote

Cyberbill might have a valid suggestion. But a better idea is to remove pspdev (as suggested various times in the forums and irc), ie:
rm -rf /usr/local/pspdev

It sounds like all your anti-virus software is taking away so many resources that you'd probably be better off without them.

My experience so far:
- toolchain.sh works on Macosx
- toolchain.sh works on Debian
- toolchain.sh works on Cygwin (fresh windows installation with nothing else)

Also, someone (jason867?) indicated he fixed his problems by jiggering with the Hard drive settings. You may wish to find his forum post or private message him.
Back to top
View user's profile Send private message
opicron



Joined: 15 Sep 2005
Posts: 2

PostPosted: Sat Sep 17, 2005 12:22 am    Post subject: yes :s Reply with quote

I'm having the same problems. On both my gaming rig as my server I'm getting this error at the end of GCC compilation:

Quote:

./../../libiberty/regex.c:8234: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8235: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8237: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8238: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8239: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8240: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8242: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8243: error: dereferencing pointer to incomplete type

../../../libiberty/regex.c:8244: error: dereferencing pointer to incomplete type

make[1]: *** [regex.o] Error 1
make[1]: Leaving directory `/tmp/pspdev/gcc-4.0.1/build-psp-c++/psp/libiberty'
make: *** [all-target-libiberty] Error 2
ERROR BUILDING GCC (C++)


And I'm building with the ./toolchain.sh -g command. Maybe some of you who can run the whole script can run the toolchain with this command? It could be a problem with the make?

EDIT: I've tried both a full install of cygwin, and a minimal install of cygwin. Both resulting in the same error. Right now I am rebuilding with all processes turned off, lets see if that helps.

Thx in advance,

Opi
Back to top
View user's profile Send private message
pspblizz



Joined: 13 Sep 2005
Posts: 15

PostPosted: Sat Sep 17, 2005 12:38 am    Post subject: Re: yes :s Reply with quote

opicron wrote:

EDIT: I've tried both a full install of cygwin, and a minimal install of cygwin. Both resulting in the same error. Right now I am rebuilding with all processes turned off, lets see if that helps.

Thx in advance,

Opi


Hello Opi, I haven't found a way around these problems yet.

But what I've managed to get the devkitPro kit working:
http://prdownloads.sourceforge.net/devkitpro/devkitProUpdater-1.0.8.exe?download

And here is a fix for it:
http://prdownloads.sourceforge.net/devkitpro/libiconv-2.dll?download

This is a response to my bug report:
http://sourceforge.net/tracker/index.php?func=detail&aid=1291923&group_id=114505&atid=668551

I'm currently investigating if there's a way to use cygwin install to build libs for the devkitPRO install, because with a "clean" install, one can't runt autogen.sh etc since autoconf and such tools are not installed with the devkitPRO distro.

I'll keep ya'all posted
Back to top
View user's profile Send private message
pspblizz



Joined: 13 Sep 2005
Posts: 15

PostPosted: Thu Sep 22, 2005 7:29 pm    Post subject: Reply with quote

Okay, here's a quick update:

devkitPRO:
Very nice, works now fine. But is missing autotools and other needed parts, so it's not possible to get and build needed libraries such as SDL and zlib etc... I tried myself to install autotools under mingw, but ended up chasing problems to why autoheader wouldn't work with any perl installation I did, so I couldn't build m4 as needed. So I gave up that chase, and have asked nicely for autotools to be included in the devkitPRO distribution.

psptoolchain:
I've posted a support request on the cygwin mailing list:
http://cygwin.com/ml/cygwin/2005-09/msg00751.html

Now lets see if the cygwin wizzards can sort me out :)
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development All times are GMT + 10 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group