New Dreamcast toolchain build script
- BlueCrab
- The Crabby Overlord
- Posts: 5665
- https://www.artistsworkshop.eu/meble-kuchenne-na-wymiar-warszawa-gdzie-zamowic/
- Joined: Mon May 27, 2002 11:31 am
- Location: Sailing the Skies of Arcadia
- Has thanked: 9 times
- Been thanked: 69 times
- Contact:
New Dreamcast toolchain build script
I have created a script for use with the shell of MSYS to create a MinGW hosted cross-compiler toolchain for the Dreamcast. The script itself should work with just about any other development environment (Cygwin, Linux) but I haven't tested it on such systems. This script even builds the g++ program that never seems to compile (this step takes an enormous amount of time however, prepare to leave your computer running for a few hours). I welcome your comments on how to improve the script in the future.
Get the script from this address - http://vmudomain.tripod.com/.
Hope this helps anyone who has trouble doing this!
Note: This script requires the MSYS-DTK package along with the wget program to be installed on MSYS
Get the script from this address - http://vmudomain.tripod.com/.
Hope this helps anyone who has trouble doing this!
Note: This script requires the MSYS-DTK package along with the wget program to be installed on MSYS
-
- DCEmu Freak
- Posts: 66
- Joined: Sat Jul 06, 2002 7:40 am
- Location: France
- Has thanked: 0
- Been thanked: 0
- Contact:
Hmm, does it really build g++ ? Wouldn't like to waste a couple of hours trying that new script (would be the 4th I try) if it end up failing on my pooter..BlueCrab wrote:This script even builds the g++ program that never seems to compile (this step takes an enormous amount of time however, prepare to leave your computer running for a few hours).
"And then... I'm glad I found true friends..."
"Avant de mourir, je suis heureux d'avoir eu des amis..."
"Avant de mourir, je suis heureux d'avoir eu des amis..."
- BlueCrab
- The Crabby Overlord
- Posts: 5665
- Joined: Mon May 27, 2002 11:31 am
- Location: Sailing the Skies of Arcadia
- Has thanked: 9 times
- Been thanked: 69 times
- Contact:
I got it to build g++ just fine with my BAD (really) computer:
Pentium II 400 mhz
128 MB RAM
Windows 98
MinGW runtime 2.0
MSYS 1.0.8
w32api 1.5 (patched by the script)
MSYS-DTK package
Output from system:
L.J.@PROTEVA /mingw/cross/dc/sh-elf/bin
$ ./sh-elf-g++ -v
Reading specs from c:\mingw\cross\dc\sh-elf\bin\..\lib\gcc-lib\sh-elf\3.1\specs
Configured with: ../gcc-3.1/configure --prefix=/mingw/cross/dc/sh-elf --target=sh-elf --without-headers --with-newlib --enable-languages=c : (reconfigured) ../gcc-3.1/configure --prefix=/mingw/cross/dc/sh-elf --target=sh-elf --without-headers --with-newlib --enable-languages=c,c++
Thread model: single
gcc version 3.1
And it seems to compile the KOS cpp examples just fine! But remember the script is designed to run on MSYS so if you are using something else, your mileage may vary. Be forewarned however, the build of g++ does fail part of the way through, but the script expects this and attempts to continue after making two files to fix dependancy problems with gcc.
I wish you luck in getting my script to work, and please tell me any problems you have in getting it to work other than what was mentioned above!
Pentium II 400 mhz
128 MB RAM
Windows 98
MinGW runtime 2.0
MSYS 1.0.8
w32api 1.5 (patched by the script)
MSYS-DTK package
Output from system:
L.J.@PROTEVA /mingw/cross/dc/sh-elf/bin
$ ./sh-elf-g++ -v
Reading specs from c:\mingw\cross\dc\sh-elf\bin\..\lib\gcc-lib\sh-elf\3.1\specs
Configured with: ../gcc-3.1/configure --prefix=/mingw/cross/dc/sh-elf --target=sh-elf --without-headers --with-newlib --enable-languages=c : (reconfigured) ../gcc-3.1/configure --prefix=/mingw/cross/dc/sh-elf --target=sh-elf --without-headers --with-newlib --enable-languages=c,c++
Thread model: single
gcc version 3.1
And it seems to compile the KOS cpp examples just fine! But remember the script is designed to run on MSYS so if you are using something else, your mileage may vary. Be forewarned however, the build of g++ does fail part of the way through, but the script expects this and attempts to continue after making two files to fix dependancy problems with gcc.
I wish you luck in getting my script to work, and please tell me any problems you have in getting it to work other than what was mentioned above!
-
- DCEmu Freak
- Posts: 66
- Joined: Sat Jul 06, 2002 7:40 am
- Location: France
- Has thanked: 0
- Been thanked: 0
- Contact:
Hi,
Thanks for the explanations. I've taken a look at your script and the comments in it before running it anyway
I ran it last night, and you can't imagine how disappointed I was when I got up this morning and found out that it hadn't worked The script couldn't find G++ in the end and aborted - I forgot to copy the error messages I got just before the end though
My config:
PIII 1GHz
256 MB SDRAM
Freshly formatted hard disk with no crap on it (except AOL 5.0.. lol)
Cygwin, very recent and very complete version, my modem's still very hot
gcc-3.0.3
newlib-1.9.0
binutils-2.11.2
A question :
Anyway, thanks for the time you spent replying to me and good luck for your RPG ! I'll have to use C as I really seem to be cursed, C++-wise!
See you later
++
Soilwork
Thanks for the explanations. I've taken a look at your script and the comments in it before running it anyway
I ran it last night, and you can't imagine how disappointed I was when I got up this morning and found out that it hadn't worked The script couldn't find G++ in the end and aborted - I forgot to copy the error messages I got just before the end though
My config:
PIII 1GHz
256 MB SDRAM
Freshly formatted hard disk with no crap on it (except AOL 5.0.. lol)
Cygwin, very recent and very complete version, my modem's still very hot
gcc-3.0.3
newlib-1.9.0
binutils-2.11.2
A question :
Do I have to apply the patch as well? I think I saw somewhere it was only for mingw but I m not too sure about that!w32api 1.5 (patched by the script)
Anyway, thanks for the time you spent replying to me and good luck for your RPG ! I'll have to use C as I really seem to be cursed, C++-wise!
See you later
++
Soilwork
"And then... I'm glad I found true friends..."
"Avant de mourir, je suis heureux d'avoir eu des amis..."
"Avant de mourir, je suis heureux d'avoir eu des amis..."
- BlueCrab
- The Crabby Overlord
- Posts: 5665
- Joined: Mon May 27, 2002 11:31 am
- Location: Sailing the Skies of Arcadia
- Has thanked: 9 times
- Been thanked: 69 times
- Contact:
I had a lot of trouble with cygwin before, that's why I used MSYS. You don't need the patch because yes, its MinGW specific. I'll have to try to debug the script in cygwin some... Sorry it didn't work out for you , maybe I'll figure out why. Now off to do some debugging.... I'll update you if I figure out what's wrong...
Edit:
Oh and BTW, if you are REALLY determined to get g++, you could download a prebuilt toolchain like the one on the develop now! section of dcemu. I used that before on cygwin, and it worked fine. Be warned, it is a VERY large download. Back to more 12:40 AM debugging....
Edit:
Oh and BTW, if you are REALLY determined to get g++, you could download a prebuilt toolchain like the one on the develop now! section of dcemu. I used that before on cygwin, and it worked fine. Be warned, it is a VERY large download. Back to more 12:40 AM debugging....
-
- DCEmu Freak
- Posts: 66
- Joined: Sat Jul 06, 2002 7:40 am
- Location: France
- Has thanked: 0
- Been thanked: 0
- Contact:
Hey,
Thanks for the hint on the pre-built toolchain, I'm gonna download and try it soonish!
Right now I'm about to re-run your script and this time I'll copy the error messages (If I get any ), maybe they'll help you figure out what's wrong (and help me hehe)
See you later and thanks again
++
Soilwork
Thanks for the hint on the pre-built toolchain, I'm gonna download and try it soonish!
Right now I'm about to re-run your script and this time I'll copy the error messages (If I get any ), maybe they'll help you figure out what's wrong (and help me hehe)
See you later and thanks again
++
Soilwork
"And then... I'm glad I found true friends..."
"Avant de mourir, je suis heureux d'avoir eu des amis..."
"Avant de mourir, je suis heureux d'avoir eu des amis..."
-
- Official DCEMU Stalker
- Posts: 1604
- Joined: Tue Apr 23, 2002 6:26 pm
- Location: South Dakota
- Has thanked: 0
- Been thanked: 0
- Contact:
i think some of the problems may be memory. right click on cygwin.bat, and select properties. click the memory tab. change the initial environment to 4096. that fixed a lot of problems i had a long time ago, the first time i made the toolchain
Thanks to Digital Chaos, GoldbergWWE, and ace for the avatar, sig, and badge!
http://devcast.dcemulation.com
-
- DCEmu Freak
- Posts: 66
- Joined: Sat Jul 06, 2002 7:40 am
- Location: France
- Has thanked: 0
- Been thanked: 0
- Contact:
Hiya,
Here are the error messages I get at the end.
++
Soilwork
Here are the error messages I get at the end.
and thanks for the tip corta!make[5]: Entering directory `/install/build-sh4-gcc/sh-elf/ml/libstdc++-v3'
make[5]: *** No rule to make target `all'. Stop.
make[5]: Leaving directory `/install/build-sh4-gcc/sh-elf/ml/libstdc++-v3'
make[4]: *** [multi-do] Error 1
make[4]: Leaving directory `/install/build-sh4-gcc/sh-elf/libstdc++-v3'
make[3]: *** [all-multi] Error 2
make[3]: Leaving directory `/install/build-sh4-gcc/sh-elf/libstdc++-v3'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/install/build-sh4-gcc/sh-elf/libstdc++-v3'
make[1]: *** [all-recursive-am] Error 2
make[1]: Leaving directory `/install/build-sh4-gcc/sh-elf/libstdc++-v3'
make: *** [all-target-libstdc++-v3] Error 2
Build of gcc with c++ support failed!
Aborting script
++
Soilwork
"And then... I'm glad I found true friends..."
"Avant de mourir, je suis heureux d'avoir eu des amis..."
"Avant de mourir, je suis heureux d'avoir eu des amis..."
- BlueCrab
- The Crabby Overlord
- Posts: 5665
- Joined: Mon May 27, 2002 11:31 am
- Location: Sailing the Skies of Arcadia
- Has thanked: 9 times
- Been thanked: 69 times
- Contact:
That's odd... mine seems to have messed up at a different directory than yours Here's what I ended up with:
Now I'm really confused
make[5]: Entering directory `/home/L.J./build-sh4-gcc/sh-elf/m4-single-only/libs
tdc++-v3'
make[5]: *** No rule to make target `all'. Stop.
make[5]: Leaving directory `/home/L.J./build-sh4-gcc/sh-elf/m4-single-only/libst
dc++-v3'
make[4]: *** [multi-do] Error 1
make[4]: Leaving directory `/home/L.J./build-sh4-gcc/sh-elf/libstdc++-v3'
make[3]: *** [all-multi] Error 2
make[3]: Leaving directory `/home/L.J./build-sh4-gcc/sh-elf/libstdc++-v3'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/L.J./build-sh4-gcc/sh-elf/libstdc++-v3'
make[1]: *** [all-recursive-am] Error 2
make[1]: Leaving directory `/home/L.J./build-sh4-gcc/sh-elf/libstdc++-v3'
make: *** [all-target-libstdc++-v3] Error 2
Now I'm really confused
-
- DCEmu Freak
- Posts: 66
- Joined: Sat Jul 06, 2002 7:40 am
- Location: France
- Has thanked: 0
- Been thanked: 0
- Contact:
Wish I could help but I know nothing about make and makefiles I'm actually wondering if I'll ever be able to write my own makefiles or if I'll always take the sample ones and modify them to match my files.
It could be worse, though, if I had to modify my filenames to match the makefiles , calling all my source files 'firstexample.c' But I'm not that bad lol
It could be worse, though, if I had to modify my filenames to match the makefiles , calling all my source files 'firstexample.c' But I'm not that bad lol
"And then... I'm glad I found true friends..."
"Avant de mourir, je suis heureux d'avoir eu des amis..."
"Avant de mourir, je suis heureux d'avoir eu des amis..."
- BlueCrab
- The Crabby Overlord
- Posts: 5665
- Joined: Mon May 27, 2002 11:31 am
- Location: Sailing the Skies of Arcadia
- Has thanked: 9 times
- Been thanked: 69 times
- Contact:
Hey don't feel bad about taking the example makefiles and changing them, all of the Dreamcast related makefiles in my RPG project are modified forms of one of the KOS example makefiles (I don't remember which one!).
Anyway, back on topic, it seems after the doing the tip that corta gave, doing a make clean, and then starting the script again, that it will actually build on my computer's copy of Cygwin (at least it hasn't messed up yet!)! Now hopefully it will actually finish without error....
Anyway, back on topic, it seems after the doing the tip that corta gave, doing a make clean, and then starting the script again, that it will actually build on my computer's copy of Cygwin (at least it hasn't messed up yet!)! Now hopefully it will actually finish without error....
-
- DCEmu Freak
- Posts: 66
- Joined: Sat Jul 06, 2002 7:40 am
- Location: France
- Has thanked: 0
- Been thanked: 0
- Contact:
So, did it work ? I tried it again with Corta's tip but it failed at the exact same place.
So I downloaded the pre-built toolchain. But I had a problem with it too.. When I extracted the archive, I had 2 corrupted files
And I even have a working G++
++
Soilwork
PS: How is your RPG progressing?
So I downloaded the pre-built toolchain. But I had a problem with it too.. When I extracted the archive, I had 2 corrupted files
However it seemed to work just fine when I tried to make kos (I haven't tried to run the examples but I didn't get any error message - except for the conio/adventure bit).! C:\Tmp\SH4-Arm-Tools\sh4_arm_tools_win32.rar: Le CRC a ?chou? dans dc\sh-elf\sh-elf\lib\ml\libiberty.a. Le fichier est corrompu
! C:\Tmp\SH4-Arm-Tools\sh4_arm_tools_win32.rar: Le CRC a ?chou? dans dc\sh-elf\sh-elf\lib\ml\m2\libc.a. Le fichier est corrompu
And I even have a working G++
++
Soilwork
PS: How is your RPG progressing?
"And then... I'm glad I found true friends..."
"Avant de mourir, je suis heureux d'avoir eu des amis..."
"Avant de mourir, je suis heureux d'avoir eu des amis..."