After you have a source code how do you compile it.
-
- Mental DCEmu
- Posts: 380
- https://www.artistsworkshop.eu/meble-kuchenne-na-wymiar-warszawa-gdzie-zamowic/
- Joined: Sun Nov 18, 2001 6:19 pm
- Location: Tx
- Has thanked: 0
- Been thanked: 0
After you have a source code how do you compile it.
How do you make a sourc code into a program the dc can read.
I have the dcphoenix code and I'm working with it, but don't expect anything. I haven't worked with c or c++ in four years.
How do you compile the code.
Thanks
Cmtz
I have the dcphoenix code and I'm working with it, but don't expect anything. I haven't worked with c or c++ in four years.
How do you compile the code.
Thanks
Cmtz
If you have MS Visual c++, just open filename.c and find the menu bar option for link/compile. The executable ends up in a subfolder of the folder of the source.
In nix, at prompt type: gcc -c filename.c
then: gcc filename.o -o filename
then to run: ./filename
or
gcc filename.c
then to run: ./a.out
Dunno about c++ sources or other compiler apps.
In nix, at prompt type: gcc -c filename.c
then: gcc filename.o -o filename
then to run: ./filename
or
gcc filename.c
then to run: ./a.out
Dunno about c++ sources or other compiler apps.
[quote="The Biz"]
If you have MS Visual c++, just open filename.c and find the menu bar option for link/compile. The executable ends up in a subfolder of the folder of the source.
In nix, at prompt type: gcc -c filename.c
then: gcc filename.o -o filename
then to run: ./filename
or
gcc filename.c
then to run: ./a.out
Dunno about c++ sources or other compiler apps.
[/quote]
This procedure won't work (at least not as written) when compiling for the DC. You must specify exactly what libraries to link against, the location in memory to sit, and other DC specific options.
If you have MS Visual c++, just open filename.c and find the menu bar option for link/compile. The executable ends up in a subfolder of the folder of the source.
In nix, at prompt type: gcc -c filename.c
then: gcc filename.o -o filename
then to run: ./filename
or
gcc filename.c
then to run: ./a.out
Dunno about c++ sources or other compiler apps.
[/quote]
This procedure won't work (at least not as written) when compiling for the DC. You must specify exactly what libraries to link against, the location in memory to sit, and other DC specific options.
- showka
- DCEmu Freak
- Posts: 95
- Joined: Fri Nov 23, 2001 12:01 pm
- Location: Border Town
- Has thanked: 0
- Been thanked: 0
- Contact:
Geeze,
Someone needs to write up a very thorough guide for idiots that will allow them to compile source code into a CD that'll work on the Dreamcast. If this ever happened, the "scene" would get a hell of a lot more active.
-
- DCFactory Creator
- Posts: 597
- Joined: Mon Nov 12, 2001 7:58 pm
- Location: Ontario, Canada
- Has thanked: 0
- Been thanked: 0
- Contact:
Geeze,
Oh, for sure!showka wrote: Someone needs to write up a very thorough guide for idiots that will allow them to compile source code into a CD that'll work on the Dreamcast. If this ever happened, the "scene" would get a hell of a lot more active.
Then, Idiots everywhere would use the DreamCast as their platform of choice...
Geeze,
Yesh, but active idiots, not idle ones that bitch & whine about the shitty EMU's for the DC. Think about it! They can say "Hey, the DreaMSNES sux, SPIT!!!$#@%%!!!", but you can say "Here's the instructions, compile your own, ya ungrateful fuc|<."kRYPT_ wrote:Oh, for sure!showka wrote: Someone needs to write up a very thorough guide for idiots that will allow them to compile source code into a CD that'll work on the Dreamcast. If this ever happened, the "scene" would get a hell of a lot more active.
Then, Idiots everywhere would use the DreamCast as their platform of choice...
Signatures images may be no greater than cock pixels high by dick pixels wide in dimension and balls kilobytes in filesize. Multiple images may be wang, but in total they may not exceed the johnson specifications.
heh... alright, mod fight!!!
Nah, typically you have to setup the SH4 (and possibly ARM7) gcc toolchain on either a Unix system or Cygwin. This is a rather long, involved process that is more properly documented elsewhere. The site I used long ago to do it was Hitmen's description, I believe there have been a few more since.
As for actually compiling it, it's really no different than a standard program compilation. The main differences are you specify the proper library and compilation tools (in this case sh-elf-xxxx). You also obviously must copy to the dc to run it.
All of the compilation is typically handled via make, which reads the Makefile and follows the appropriate instructions. For source code someone else wrote, you usually just change the Makefile to point to the location of the sh-elf toolchain on your system. If writing your own software, it's usually easier to copy a Makefile and go from there (I did this for some KOS code...)
That brings up the other point of having some library to compile against for setting up the DC. This is usually libdream or KOS.
Nah, typically you have to setup the SH4 (and possibly ARM7) gcc toolchain on either a Unix system or Cygwin. This is a rather long, involved process that is more properly documented elsewhere. The site I used long ago to do it was Hitmen's description, I believe there have been a few more since.
As for actually compiling it, it's really no different than a standard program compilation. The main differences are you specify the proper library and compilation tools (in this case sh-elf-xxxx). You also obviously must copy to the dc to run it.
All of the compilation is typically handled via make, which reads the Makefile and follows the appropriate instructions. For source code someone else wrote, you usually just change the Makefile to point to the location of the sh-elf toolchain on your system. If writing your own software, it's usually easier to copy a Makefile and go from there (I did this for some KOS code...)
That brings up the other point of having some library to compile against for setting up the DC. This is usually libdream or KOS.