Help please, i am stuck.

Discuss the development of software, tools, libraries and anything else that helps make ps2dev happen.

Moderators: cheriff, Herben

Post Reply
jloyd_
Posts: 6
Joined: Thu Jun 15, 2006 4:34 am

Help please, i am stuck.

Post by jloyd_ »

I have my slim ps2 connected via ethernet and using swapmagic to boot the ps2 side of the link, i can run demos fine using inlink.
Where i get stuck is compiling my own, i have installed PS2Dev Environment for Win32 but i have no idea how to use it to compile.

I have Suse linux installed but dont have Inlink for it and i dont use Linux that much only when im developing with php, my experiences lie with microsoft visual studio and directx and various languges.
It is really starting to wind me up how i can't figure this out, iv looked in tutorials and i cant fined any that explain how to compile in windows.
Does any one have any help please.

I also have an interest in having a go at development with the gametrak controller if any one has any information on this too, thans
SSpeare
Posts: 63
Joined: Tue May 23, 2006 11:45 pm
Contact:

Post by SSpeare »

Open a command prompt (Type "cmd" into Start->Run).
cd to the directory you installed into.
Run the cygwin paths batch file.
cd into the samples directory (ps2sdk/samples I think)
type "make"
cd into a sample.
you can then run the .elf using inlink or ps2client. Try:
"make run"
if you have ps2client.
jloyd_
Posts: 6
Joined: Thu Jun 15, 2006 4:34 am

Post by jloyd_ »

i get make as an unreconized internal or external command, would this be easier to do in linux, even though my linux experience is very limitied, or is there a was to use ms visual studio :s thanks for the reply
User avatar
Orfax
Posts: 21
Joined: Thu Apr 08, 2004 3:41 pm
Location: Adelaide, Australia
Contact:

Post by Orfax »

jloyd_ wrote:i get make as an unreconized internal or external command
This is a Windows cmd error. It cannot find make. What this means is you are not running a bash shell when make is run. There should be a script called "cygwin.bat" in the root cygwin folder which starts a bash shell for you.

The alternatives are setting up Windows batch scripts to wrap around the commands you use (like make) that starts bash and then runs the command. I would imagine this would be slow.

I start the following command "<path to cygwin install dir>\bin\rxvt.exe -e bash --login -i" in my cygwin bin directory (its actually a shortcut on my desktop), but it means you need the no-x rxvt installed as well (it is faster than cmd, though).
jloyd_ wrote:would this be easier to do in linux, even though my linux experience is very limitied
Probably, but it does work quite fine with cygwin. Using cygwin does mean you need to be aware of Unix like environments though (just like linux).
jloyd_ wrote:is there a was to use ms visual studio
Not that I'm aware of.
Look deep into their eyes for what they have to say, Emotions take control of life everyday
Death (Nothing Is Everything)
jloyd_
Posts: 6
Joined: Thu Jun 15, 2006 4:34 am

Post by jloyd_ »

thank you very much, using cygwin i have got it working, i put what i wanted to compile in my users folder in usr. Now i can begin hehe : )
User avatar
Drakonite
Site Admin
Posts: 990
Joined: Sat Jan 17, 2004 1:30 am
Contact:

Post by Drakonite »

usr is not "user" folders... it's for sharable (multi-user) read-only. Basically all the programs, libs, and other shared resources that are used on a regular basis live in /usr

The idea that it's short for 'user' is also false... It's an acronym, and IIRC it stands for User Sharable Resources ... but don't quote me on that.

The directory you put your files, documents, and projects in is inside of the home dir. specifically it should be /home/username/ but I don't know exactly how cygwin has things screwed up

EDIT: Okay, I looked it up and it's Unix System Resources... I had my acronym wrong.
Shoot Pixels Not People!
Makeshift Development
User avatar
Orfax
Posts: 21
Joined: Thu Apr 08, 2004 3:41 pm
Location: Adelaide, Australia
Contact:

Post by Orfax »

Drakonite wrote: specifically it should be /home/username/ but I don't know exactly how cygwin has things screwed up
Just as screwed up as any other Unix OS then, huh (yes its /home/username/).
Look deep into their eyes for what they have to say, Emotions take control of life everyday
Death (Nothing Is Everything)
User avatar
Drakonite
Site Admin
Posts: 990
Joined: Sat Jan 17, 2004 1:30 am
Contact:

Post by Drakonite »

Orfax wrote:
Drakonite wrote: specifically it should be /home/username/ but I don't know exactly how cygwin has things screwed up
Just as screwed up as any other Unix OS then, huh (yes its /home/username/).
Heh, fair enough.. unix directory structure isn't exactly intuitive for the newbie... But I was more talking about how cygwin has a record of doing some things in a bastardized way ;)
Shoot Pixels Not People!
Makeshift Development
jloyd_
Posts: 6
Joined: Thu Jun 15, 2006 4:34 am

Post by jloyd_ »

thanks with all the help so far, iv hacked away at some code and drawn my initials on screen using lines lol, messing with colours and such.

I have discovered the sameples with ps2sdk, the hello applications complie to a .erl what is it? i cannot send this file to the ps2. Thanks
User avatar
Drakonite
Site Admin
Posts: 990
Joined: Sat Jan 17, 2004 1:30 am
Contact:

Post by Drakonite »

ERLs are relocatable executables... TBH I haven't played with them, so while they may be neat I have no idea what the situation is with them ;)

There is a line in the makefile that starts with "ERL_BIN =" ... if you change it to "EE_BIN =" it will cause it to build elfs instead of erls.
Shoot Pixels Not People!
Makeshift Development
Kojima
Posts: 275
Joined: Mon Jun 26, 2006 3:49 am

Post by Kojima »

I have the same problem, ERL's instead of elfs.
I just opened up the makefile and can't find anything that matches what you suggest exactly, but I did find this

"EE_ERL = hello.erl"

Do I change it to "EE_BIN = hello.elf"?
misfire
Posts: 110
Joined: Mon Sep 06, 2004 7:53 am
Location: Germany

Post by misfire »

Yes.
nak
Posts: 4
Joined: Thu Jun 29, 2006 7:09 am

Post by nak »

I get this error when running the makefile from inside the /graph/ sample

$ make graph
ee-gcc -D_EE -O2 -G0 -Wall -IC:/ps2dev/ps2sdk/ee/include -IC:/ps2dev/ps2sdk/com
mon/include -I. -c graph.c -o graph.o
gcc graph.o -o graph
ld: graph.o: Relocations in generic ELF (EM: 8)
graph.o: could not read symbols: File in wrong format
make: *** [graph] Error 1

but it makes fine when I run the make file in the parent directory (/sample/) can anyone elighten me please :) ?
Post Reply