PDA

View Full Version : Dc dev pack



rawoul
September 18th, 2004, 00:16
I made a dev pack for cygwin with gcc 3.3.3, binutils 2.15, newlib 1.12.0, kos 1.3 and iris 0.9.1. It took me a very long time to find a combination of those tools that work together, so i release it here to save you a lot of time =)

get it here ! (57mo) (http://rawoul.free.fr/dcdev.tar.bz2)

Vorrtexx
September 19th, 2004, 16:06
nice job rawoul.
What snapshot of kos 1.3 did you use. pre-newlib or post newlib?

Tiri
September 19th, 2004, 16:35
can someone give me some info on how to use this pack?

Vorrtexx
September 19th, 2004, 16:58
I haven't downloaded it (dial-up) but I would think it needs to be extracted into your cywgin directory. So you would need cygwin setup on your machine first.
That is I am assuming cygwin is not included in the archive, which I doubt it is at its file size.

rawoul
September 19th, 2004, 17:35
This is post newlib kos (kos now uses newlib instead of it own libc), i used the august 28 snapshot.
To use it just untar it in your home directory. You can put it elsewhere but you will have to modify the environ.sh script. Do not use winrar to uncompress it, i don't know why but it only works with tar.

edit: i also have a linux version of the pack, but for amd64. Tell me if you want it. A 32bit version shouldn't be hard to make with the included script.

edit2: i also have a 3dsmax6 version of the model exporter of iris. I'll post links later

bender
September 19th, 2004, 19:46
Do not use winrar to uncompress it, i don't know why but it only works with tar.

i think winrar does not keep the symlinks, that's why you can't extract it with most of the windoze programs ;)



i also have a linux version of the pack, but for amd64. Tell me if you want it. A 32bit version shouldn't be hard to make with the included script.

i don't think there's need for a pack for linux. wget+ a good script with all the things you want to download and build, it's probably all what you need ;)

Mekanaizer
September 19th, 2004, 21:49
Hi

if you get errors like this one:

http://mekanaizer.planetaclix.pt/sdl_error.JPG

just add:

-fno-delayed-branch

to environ_base.sh under KOS dir

export KOS_CFLAGS="${KOS_CFLAGS} ${KOS_INC_PATHS} -D_arch_${KOS_ARCH} -D_arch_sub_${KOS_SUBARCH} -Wall -g -fno-builtin -fno-strict-aliasing -fno-delayed-branch"

-Mekanaizer-

rawoul
September 20th, 2004, 14:27
Here is the iris imd2 exporter plugin for 3dsmax6: imdexp.dle (http://rawoul.free.fr/imdexp.dle).
This format support bones, textures and animations so it's useful to make a game =)
Don't forget to download the plugin dlls and the viewer at http://iris3d.sf.net

Ian_micheal
October 5th, 2004, 02:44
Great work Rawoul just want i needed.. Was not looking forward to all the time it would of taken. Thanks for sharing this top props to you.

a128
October 5th, 2004, 07:10
Here is the iris imd2 exporter plugin for 3dsmax6: imdexp.dle (http://rawoul.free.fr/imdexp.dle).
This format support bones, textures and animations so it's useful to make a game =)
Don't forget to download the plugin dlls and the viewer at http://iris3d.sf.net

the iris 3d files are here

http://sourceforge.net/projects/iris3d/

Vorrtexx
October 5th, 2004, 16:31
I changed the Makefile in Iris3d to use the stl library that comes with GCC for anyone who ever has had trouble trying to build Iris3D with the STLPort. So this library source doesn't require STLPort to build.

I've tested the build with rawoul's cygwin build and it worked fine for me. Also, for anyone on a higher version of GCC 3.3.3, you need to edit the makefiles in iris3d and opcode to set the version of GCC. Environmental variable is called GCC_VERSION and it's at the top of the file.
You can get the library package Here (http://www.consolevision.com/members/vorrtexx/iris3d/libiris3d.tar.gz)

Ian_micheal
October 7th, 2004, 09:18
Had no luck geting it to work since cygwin is complaining of some entry point in sh-elf .. Cygwin install is over 1 year old looks like i will have to redownload it. Ive removed the old install and every thing that might cause the problem. Read on the net people having this problem with the cgywin1.dll i need the newer version.

Any ways This is how i untared it was this correct.

bzip2 -d dcdev.tar.bz2
tar xvf dcdev.tar



I think this is correct winrar does not work as stated.

Vorrtexx
October 7th, 2004, 12:17
Ian, I had problems with my cygwin as well, as it's also over 1 year old.
I downloaded two recent packages called : cygwin-1.5.11-1.tar.bz2 and libintl3-0.14.1-1.tar.bz2

I extracted them to my cygwin directory, but I had to copy /usr/bin directory from the package cygwin-1.5.11-1.tar.bz2 to /bin for it to work. After that I was able to compile.

Ian_micheal
October 7th, 2004, 20:33
Thanks Vorrtexx

Ian_micheal
October 8th, 2004, 08:19
With the environ files ive noticed it's changed a lot im geting a bit stuck with errors. *'Say my system is like this path wize.
C:\cygwin\usr\local\dcdev *how should i edit the environ files ---
DC_ROOT="/usr/local${USER}/dcdev" *i *thought this would be correct.
Never seen this style of environ files before.

Errors i get are as follows i know it looks like a wrong path must be looking at the errors.


make -C display
make[1]: Entering directory `/usr/local/dcdev/sticks/src/display'
kos-c++ -c SMenu.cpp -o SMenu.o
make[1]: kos-c++: Command not found
make[1]: *** [SMenu.o] Error 127
make[1]: Leaving directory `/usr/local/dcdev/sticks/src/display'
make: *** [_dir_display] Error 2

Im runing the environ file like this *. ./environ.sh in the kos directory?

Vorrtexx what did you have to run first and path to change to get it to compile most times i dont ask but ive deleted my other dev system and have to get this to work some how. :-[

Any help on these environ files as im use to kos 1.1.9 style.

Vorrtexx
October 8th, 2004, 14:28
Ok.
Well rawoul packaged the entire thing up from his home directory, which for him was:


/home/{USER}/dcdev/

so if you want to get it going straight from extraction, move/copy the dcdev.tar.bz2 file to your home directory in cywgin. This may be something like C:\cygwin\home\ian , or from within the unix environment itself, /home/ian

now execute the command:

tar -xvjf dcdev.tar.bz2

Once extraction is complete you should now have something like /home/ian/dcdev

After that you are pretty much ready to go. you just have to load the environment variable from the environ.sh file in the dcdev directory.

so cd to /home/ian/dcdev and execute the command:

source environ.sh

Now the KOS environment variables should all be set and you're ready to compile.


The KOS directory structure has changed quite a bit from 1.1.9 too.


However, if you prefer to have your KOS stuff in another directory, make sure to edit the DC_ROOT variable in the environ.sh file from the dcdev directory, to the path of where dcdev is extracted. Then load your environment variables from this file...ignore the one in the kos folder. This is just the way rawoul has his environment setup, so if you know what you're doing you can edit the environ.sh file in the kos directory and use that one instead.
Let me know how it goes.

Vorrtexx
October 8th, 2004, 15:14
just reading your post there again and I noticed you're loading your environ.sh file from the kos directory. try the one from the dcdev directory and it will probably work then

Alexvrb
October 8th, 2004, 16:34
Doesn't GCC 3.3.3 sometimes produce broken code for SH4?

Ian_micheal
October 8th, 2004, 18:58
After that im still geting *
make[1]: kos-c++: Command not found I have *followed what you said exactly. *Even Tryed the old directory it still gives the same error.The CPP base must not be finding the right path? Cygwin is setup correctly my old system i rebuilt and it works fine with this new install of cygwin as well. but kos 1.1.9 is very much out-of date now and gcc 2.95 is out of date to I was looking forward to this new system :'(.

I have it here now *
C:\cygwin\home\Ian micheal\dcdev


Source environ.sh * is there a new make **command as well? :: I use to put . ./environ.sh for kos before..

Thanks for helping me out with this :). *I will get it sooner or later it should be working looking at what you told me but im geting the one error. Which has some thing to do with a wrong path.

Vorrtexx
October 9th, 2004, 04:53
I notice there's a space in your username "Ian micheal".
I would say cygwin has a problem setting the environment variables because of this.
So I went ahead and tested setting up the environment on my machine with the username you are using and it had problems using the environment variables with "ian micheal" in it.

So I would say either change the username to "ian_micheal" or extract the dcdev package to "/usr/local/dc" maybe.
then open "/usr/local/dc/dcdev/environ.sh" and edit the DC_ROOT variable to "/usr/local/dc/dcdev"


DC_ROOT="/usr/local/dc/dcdev"

now load the environ.sh file with either:


source environ.sh
or

. ./environ.sh

Test if the example will compile for you now.

Ian_micheal
October 9th, 2004, 06:34
Ok i tryed that still giving me the same error. I noticed the space in user name to i thought that was it but seems it's not. *I know 127 error im geting is to do with some thing that cant be found looks like it does not work for me im at a loss now.

Thanks for helping me on trying to get it to work as well *Vorrtexx. *some things i wanted to do *needed this version to become real.

In the environ there is this * *
PATH="${PATH}:${KOS_CC_BASE}/bin:/home/rawoul/dcdev/dc/bin


make[2]: kos-c++: Command not found did you ever or any one get this error?

Back to looking at it i guess. How on a working system would you get this error if you tryed

make[2]: kos-c++: Command not found

Vorrtexx
October 9th, 2004, 09:54
It seems to me that the path to where the kos-c++ file and the other gnu wrapper files is not actually getting amended to the $PATH variable.

Some checks you could try are:
1. Check your kos/utils/gnu_wrappers directory to see if the "kos-c++" file is there. It should be.

2. run the command "set" from the cygwin command line. look at your PATH variable and you should see something at the end of it like /usr/local/dcdev/dc/kos/utils/gnu_wrappers .If this is missing I would think the environ_base.sh file did not get load from your kos directory.

3. Try loading the environ_base.sh file manually from the kos directory after loading the environ.sh file from the dcdev directory.

Vorrtexx
October 9th, 2004, 10:33
If you do get it working you may notice that genromfs is not compiled in the kos/utils/genromfs directory so to get it to compile you will need to fix the following code in the genromfs.c file:

Replace the following header inclusion:


#ifdef _WIN32
# include <getopt.h>
#else
# include <fnmatch.h>
#endif /* _WIN32 */


with this:


# include <fnmatch.h>

it should build cleanly now.

Ian_micheal
October 9th, 2004, 11:37
Here's the info from the set command thanks for telling me about that.



IRIS_BASE=/usr/local/dc/dcdev/dc/kos/../iris3d
KOS_AFLAGS=' -little -little'
KOS_AR=/usr/local/dc/dcdev/dc/sh-elf/bin/sh-elf-ar
KOS_ARCH=dreamcast
KOS_ARCH_DIR=/usr/local/dc/dcdev/dc/kos/kernel/arch/dreamcast
KOS_AS=/usr/local/dc/dcdev/dc/sh-elf/bin/sh-elf-as
KOS_BASE=/usr/local/dc/dcdev/dc/kos
KOS_CC=/usr/local/dc/dcdev/dc/sh-elf/bin/sh-elf-gcc
KOS_CCPLUS=/usr/local/dc/dcdev/dc/sh-elf/bin/sh-elf-g++
KOS_CC_BASE=/usr/local/dc/dcdev/dc/sh-elf
KOS_CC_PREFIX=sh-elf
KOS_CFLAGS='-O2 -fomit-frame-pointer -ml -m4-single-only -fno-crossjumping -I/us
r/local/dc/dcdev/dc/kos/../kos-ports/include -I/usr/local/dc/dcdev/dc/kos/includ
e -I/usr/local/dc/dcdev/dc/kos/kernel/arch/dreamcast/include -I/usr/local/dc/dcd
ev/dc/kos/addons/include -I/usr/local/dc/dcdev/dc/kos/../iris3d/include/iris3d -
I/usr/local/dc/dcdev/dc/kos/../iris3d/include/opcode -D_arch_dreamcast -D_arch_s
ub_pristine -Wall -g -fno-builtin -fno-strict-aliasing -ml -m4-single-only -fno-
crossjumping -I/usr/local/dc/dcdev/dc/kos/../kos-ports/include -I/usr/local/dc/d
cdev/dc/kos/include -I/usr/local/dc/dcdev/dc/kos/kernel/arch/dreamcast/include -
I/usr/local/dc/dcdev/dc/kos/addons/include -I/usr/local/dc/dcdev/dc/kos/../iris3
d/include/iris3d -I/usr/local/dc/dcdev/dc/kos/../iris3d/include/opcode -I/usr/lo
cal/dc/dcdev/dc/kos/include -I/usr/local/dc/dcdev/dc/kos/kernel/arch/dreamcast/i
nclude -I/usr/local/dc/dcdev/dc/kos/addons/include -I/usr/local/dc/dcdev/dc/kos/
../iris3d/include/iris3d -I/usr/local/dc/dcdev/dc/kos/../iris3d/include/opcode -
D_arch_dreamcast -D_arch_sub_pristine -Wall -g -fno-builtin -fno-strict-aliasing
'
KOS_CPPFLAGS=' -fno-operator-names -fno-rtti -fno-exceptions -fno-operator-nam
es -fno-rtti -fno-exceptions'
KOS_GENROMFS=/usr/local/dc/dcdev/dc/kos/utils/genromfs/genromfs
KOS_INC_PATHS='-I/usr/local/dc/dcdev/dc/kos/../kos-ports/include -I/usr/local/dc
/dcdev/dc/kos/include -I/usr/local/dc/dcdev/dc/kos/kernel/arch/dreamcast/include
-I/usr/local/dc/dcdev/dc/kos/addons/include -I/usr/local/dc/dcdev/dc/kos/../iri
s3d/include/iris3d -I/usr/local/dc/dcdev/dc/kos/../iris3d/include/opcode -I/usr/
local/dc/dcdev/dc/kos/include -I/usr/local/dc/dcdev/dc/kos/kernel/arch/dreamcast
/include -I/usr/local/dc/dcdev/dc/kos/addons/include -I/usr/local/dc/dcdev/dc/ko
s/../iris3d/include/iris3d -I/usr/local/dc/dcdev/dc/kos/../iris3d/include/opcode
'
KOS_LD=/usr/local/dc/dcdev/dc/sh-elf/bin/sh-elf-ld
KOS_LDFLAGS=' -ml -m4-single-only -Wl,-Ttext=0x8c010000 -nostartfiles -nostdlib
-L/usr/local/dc/dcdev/dc/kos/lib/dreamcast -L/usr/local/dc/dcdev/dc/kos/addons/l
ib/dreamcast -L/usr/local/dc/dcdev/dc/kos/../iris3d/lib -ml -m4-single-only -Wl,
-Ttext=0x8c010000 -nostartfiles -nostdlib -L/usr/local/dc/dcdev/dc/kos/lib/dream
cast -L/usr/local/dc/dcdev/dc/kos/addons/lib/dreamcast -L/usr/local/dc/dcdev/dc/
kos/../iris3d/lib'
KOS_LIBS='-Wl,--start-group -lkallisti -lc -lgcc -Wl,--end-group'
KOS_LIB_PATHS='-L/usr/local/dc/dcdev/dc/kos/lib/dreamcast -L/usr/local/dc/dcdev/
dc/kos/addons/lib/dreamcast -L/usr/local/dc/dcdev/dc/kos/../iris3d/lib'
KOS_LOADER='dc-tool -x'
KOS_MAKE=make
KOS_OBJCOPY=/usr/local/dc/dcdev/dc/sh-elf/bin/sh-elf-objcopy
KOS_RANLIB=/usr/local/dc/dcdev/dc/sh-elf/bin/sh-elf-ranlib
KOS_START=/usr/local/dc/dcdev/dc/kos/kernel/arch/dreamcast/kernel/startup.o
KOS_STRIP=/usr/local/dc/dcdev/dc/sh-elf/bin/sh-elf-strip
KOS_SUBARCH=pristine
LINES=25
MACHTYPE=i686-pc-cygwin
MAILCHECK=60
MAKE_MODE=UNIX
NUMBER_OF_PROCESSORS=1
OLDPWD=/usr/local/dc/dcdev
OPTERR=1
OPTIND=1
OS=Windows_NT
OSTYPE=cygwin
PATH='/USR/LOCAL/BIN:/usr/lib/gcc-lib/i686-pc-cygwin/3.2:/usr/bin:/cygdrive/c/WI
NDOWS/system32:/cygdrive/c/WINDOWS:/cygdrive/c/WINDOWS/System32/Wbem:/cygdrive/c
/Program Files/Common Files/Ulead Systems/MPEG:/cygdrive/c/EUPHORIA/BIN: :/usr/
local/dc/dcdev/dc/sh-elf/bin:/home/rawoul/dcdev/dc/bin:/usr/local/dc/dcdev/dc/ko
s/utils/gnu_wrappers:/usr/local/dc/dcdev/dc/kos/utils/gnu_wrappers'
PATHEXT='.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.W SF;.WSH'
PIPESTATUS=([0]="2")

I loaded the other file after still get the same error every thing seems like it's set the gnu_ wrappers file is in the directorys.

Dont know if you can see any thing im missing from the set command or how it compares to yours which works.

Thanks again dont want to be a bother.

Vorrtexx
October 9th, 2004, 14:24
Im all out of ideas.
Your enviroment variables are all the same as mine, no differences.

when you execute "source /usr/local/dc/dcdev/environ.sh" and then from the command line execute the command "kos-c++" does it say command not found?

what if you then change directory to cd /usr/local/dc/dcdev/dc/kos/utils/gnu_wrappers and run the same command again "./kos-c++".
does it ever output the following?


$ kos-c++
sh-elf-g++: no input files


The thing is that kos-c++ and kos-cc use the kos variables KOS_CC and KOS_CCPLUS and they are both set as far as I can see.

Ian_micheal
October 9th, 2004, 22:31
when you execute "source /usr/local/dc/dcdev/environ.sh" and then from the command line execute the command "kos-c++" does it say command not found?
.

No it reports
BASH-2.05b$ kos-c++ sh-elf-g++: No input files

WHen i then Type make and i get ..


BASH-2.05b$ make
make -C *src
make[1]: Entering directory `/usr/local/dc/dcdev/sticks/src'
make -C *display
make[2]: Entering directory `/usr/local/dc/dcdev/sticks/src/display'
kos-c++ -c SMenu.cpp -o SMenu.o
make[2]: kos-c++: Command not found
make[2]: *** [SMenu.o] Error 127
make[2]: Leaving directory `/usr/local/dc/dcdev/sticks/src/display'
make[1]: *** [_dir_display] Error 2



what if you then change directory to cd /usr/local/dc/dcdev/dc/kos/utils/gnu_wrappers and run the same command again "./kos-c++".
does it ever output the following?
.

Yes it does it outputs


$ kos-c++
sh-elf-g++: no input files

Seems it's all correct only thing i can think is some rogue cgywin bug or some other package needs updating.

Dont know why but i seem to allways get the un explain-able problems.. ;D

Vorrtexx
October 10th, 2004, 05:07
yeah, I really don't know what the problem is. everything looks ok.
Have you tried compiling and of the KOS examples in:

/usr/local/dc/dcdev/dc/kos/examples/dreamcast

Do they also say kos-cc not found or kos-c++ not found?

Ian_micheal
October 10th, 2004, 05:35
Thanks ive since quit dc any thing so thanks vorrtex for trying to help was my last bother with this stuff.

:)

rawoul
October 12th, 2004, 14:55
Doesn't GCC 3.3.3 sometimes produce broken code for SH4?
I had no problem at all with C++, kos and iris on the game i was working so i guess it works fine =).

rawoul
October 12th, 2004, 14:57
I changed the Makefile in Iris3d to use the stl library that comes with GCC for anyone who ever has had trouble trying to build Iris3D with the STLPort. So this library source doesn't require STLPort to build.
Iris is not compiled with stlport either in my pack :x

Vorrtexx
October 12th, 2004, 16:12
Iris is not compiled with stlport either in my pack :x


I just noticed this in the Makefile for Iris3D in your pack:


KOS_CFLAGS += * * *-I/usr/local/include/stlport -I$(INCLUDE_IRIS)/ -I$(INCLUDE_OPCODE)/ -O2 \

and figured that it was using the stlport library...as it's using it in its includes. Maybe I was mistaken. Didn't know it was using the local gcc stuff. Thanks for letting me know :)

rawoul
October 17th, 2004, 08:22
No you're right gcc includes are overrided by this line, i didn't remember it was still here ! It's just that i don't have stlport on my hd, so i don't think my iris build was compiled with it =)

elefas
October 20th, 2004, 05:05
hi all, I have installed the dev pack, it works ok but the produced .elf doens't run on my dc when I send it via coders cable. Any suggestions?