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 

WANTED:GCC 4.0 Toolchain for windows (supporting C++, float)
Goto page Previous  1, 2
 
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development
View previous topic :: View next topic  
Author Message
Sharkus



Joined: 19 Jun 2005
Posts: 27

PostPosted: Wed Jun 22, 2005 9:13 am    Post subject: Reply with quote

I tried building under MinGW/Msys. The first thing that dies is due to an include path problem. The problem seems to be common problem with building GCC 4.0 under MinGW and is mentioned here:

https://sourceforge.net/forum/message.php?msg_id=3114120

As mentioned in the above post, I copied the config directory (and headers) and the compile got only slightly farther before an assembler error along the lines of "unexpected symbol found..." occurred.

The same thing built fine with both Cygwin and Linux, so I gave up on MinGW...

-Sharkus
Back to top
View user's profile Send private message
MrHTFord



Joined: 10 Feb 2004
Posts: 35
Location: England

PostPosted: Wed Jun 22, 2005 10:34 am    Post subject: Reply with quote

I've not actually built gcc 4.0 under minGW, but this may provide some clues for those who are trying.

https://sourceforge.net/forum/forum.php?thread_id=1276241&forum_id=286529

If enough people want it, I'll try to make it build and provide some binaries.
Back to top
View user's profile Send private message Send e-mail
mrbrown



Joined: 17 Jan 2004
Posts: 1536

PostPosted: Wed Jun 22, 2005 12:48 pm    Post subject: Reply with quote

MrHTFord wrote:
If enough people want it, I'll try to make it build and provide some binaries.


It's already been planned :).
Back to top
View user's profile Send private message
crazyc



Joined: 17 Jun 2005
Posts: 410

PostPosted: Fri Jun 24, 2005 7:28 am    Post subject: Reply with quote

I've built a working toolchain from Mingw/msys. To bypass the libintl build problem, you add -disable-nls to configure's command line for gcc and binutils. Also you have to copy the config directory from the gcc dir to the build dir. The major problem that I ran into was with msvcrt and printf format strings. Since it doesn't support %lld and uses %I64d instead i had to patch hwint.h line 83 from

# define HOST_WIDE_INT_PRINT "ll"

to

# ifdef __MSVCRT__
# define HOST_WIDE_INT_PRINT "I64"
# else
# define HOST_WIDE_INT_PRINT "ll"
# endif
Back to top
View user's profile Send private message
agent_stewie



Joined: 25 Jun 2005
Posts: 7

PostPosted: Sun Jun 26, 2005 7:39 am    Post subject: Reply with quote

Thanhda wrote:
i'm currently using the ps2sdk, not the psp. but! you will most likely have to modify the mk.bat file. i had to do that. just rename the bat file to a txt file.

c:\ps2dev\gcc\ee\bin\ee-gcc -march=r4000 -g -mgp32 -mlong32 -c hellopsp.c
c:\ps2dev\gcc\ee\bin\ee-gcc -march=r4000 -g -mgp32 -mlong32 -c pg.c
c:\ps2dev\gcc\ee\bin\ee-gcc -march=r4000 -g -mgp32 -c -xassembler -O -o startup.o startup.s
c:\ps2dev\gcc\ee\bin\ee-ld -O0 startup.o hellopsp.o pg.o -M -Ttext 8900000 -q -o out > hellopsp.map
outpatch
@echo you got outp as psp elf
Elf2pbp.exe outp Eboot

ps2dev - http://www.internalreality.com/PS2Dev_Setup.zip
toolchain was the

and used the ps2 toolchain. but its probably recomended that you use the new psp toolchain.


does this mean if im working on compiling a web browser i have to compile all C files?? can someone give me steps on how to do thiss???
_________________
___________________________________________
Don't Get Hooked on Drugs Get Hooked on Phonics
Back to top
View user's profile Send private message AIM Address
Thanhda



Joined: 09 Apr 2005
Posts: 331
Location: Canada

PostPosted: Sun Jun 26, 2005 7:45 am    Post subject: Reply with quote

yes, i have already posted it in your other post. if you need more details just ask.

if you have more then 1 file its simple

ee-gcc -march=r4000 -g -mgp32 -mlong32 -c web.c
ee-gcc -march=r4000 -g -mgp32 -mlong32 -c wifi.c
ee-gcc -march=r4000 -g -mgp32 -mlong32 -c pg.c
ee-gcc -march=r4000 -g -mgp32 -c -xassembler -O -o startup.o startup.s
ee-ld -O0 startup.o web.o wifi.o pg.o -M -Ttext 8900000 -q -o out > web.map

same thing, just modify file to what you need.

you do realize that a bat file is just a txt file. if you cant follow simple instructions i suggest, you go back and learn how to program before you decide to work on some psp projects.

http://forums.ps2dev.org/viewtopic.php?t=2294
_________________
There are 10 types of people in the world: Those who understand binary, and those who don't...
Back to top
View user's profile Send private message Visit poster's website
agent_stewie



Joined: 25 Jun 2005
Posts: 7

PostPosted: Sat Jul 09, 2005 5:22 am    Post subject: Reply with quote

I have 4,313 c++ files. how the hell would i compile all of these with a shell prompt?
\
_________________
___________________________________________
Don't Get Hooked on Drugs Get Hooked on Phonics
Back to top
View user's profile Send private message AIM Address
Agoln



Joined: 08 Jun 2005
Posts: 326
Location: Fort Wayne, IN

PostPosted: Sat Jul 09, 2005 5:24 am    Post subject: Reply with quote

agent_stewie wrote:
I have 4,313 c++ files. how the hell would i compile all of these with a shell prompt?
\


psp-g++ -c *.cpp
_________________
Lego of my Ago!
Back to top
View user's profile Send private message AIM Address
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development All times are GMT + 10 Hours
Goto page Previous  1, 2
Page 2 of 2

 
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