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 

compiling asm...

 
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PS2 Development
View previous topic :: View next topic  
Author Message
evilo



Joined: 22 Apr 2004
Posts: 230

PostPosted: Tue Jul 13, 2004 3:58 am    Post subject: compiling asm... Reply with quote

Hi all,

I just switch to ps2sdk, and I have now problems when compiling asm codes (working before with ps2lib), so I guess that sthg in the environment must be wrong... ?

when I compile the gs lib, and I have the following errors,
first with dma.asm.s :

$ make all
ee-gcc -D_EE -O2 -G0 -Wall -I/usr/local/ps2dev/sdk/ee/include I/usr/local/ps2d ev/sdk/common/include -I. -c gs/gs.c -o gs/gs.o ee-gcc -D_EE -O2 -G0 -Wall -I/usr/local/ps2dev/sdk/ee/include -I/usr/local/ps2d
ev/sdk/common/include -I. -c gs/g2.c -o gs/g2.o
ee-as -G0 gs/ps2_asm.s -o gs/ps2_asm.o
ee-as -G0 gs/dma_asm.s -o gs/dma_asm.o
gs/dma_asm.s: Assembler messages:
gs/dma_asm.s:49: Error: illegal operands `daddu v0,zero,zero'
gs/dma_asm.s:50: Error: illegal operands `jr ra'
make: *** [gs/dma_asm.o] Error 1

then with gs_asm.s
ee-as -G0 gs/gs_asm.s -o gs/gs_asm.o
gs/gs_asm.s: Assembler messages:
gs/gs_asm.s:22: Error: illegal operands `li a0,0x0000FF00'
gs/gs_asm.s:23: Error: illegal operands `ld v0,csr'
gs/gs_asm.s:24: Error: illegal operands `dsrl v0,16'
gs/gs_asm.s:25: Error: illegal operands `andi v0,0xFF'
gs/gs_asm.s:26: Error: illegal operands `li v1,0x71'
gs/gs_asm.s:31: Error: illegal operands `daddu v0,zero,zero'
gs/gs_asm.s:32: Error: illegal operands `jr ra'
gs/gs_asm.s:42: Error: illegal operands `li v1,0x02'
gs/gs_asm.s:46: Error: illegal operands `daddu v0,zero,zero'
gs/gs_asm.s:47: Error: illegal operands `jr ra'
make: *** [gs/gs_asm.o] Error 1

for the moment, I just copy paste the .o from another project, but of course I'd like to fix this !!

if anyone can help ?
Back to top
View user's profile Send private message Visit poster's website
TyRaNiD



Joined: 18 Jan 2004
Posts: 918

PostPosted: Tue Jul 13, 2004 4:35 am    Post subject: Reply with quote

Try renaming the assembly files so that the .s is captialised as .S. That way it will be run through the preprocessor. Failing that try adding the -xassembler-with-cpp switch to the EE_ASFLAGS in your makefile.
Back to top
View user's profile Send private message
Saotome



Joined: 03 Apr 2004
Posts: 182

PostPosted: Tue Jul 13, 2004 4:47 am    Post subject: Reply with quote

maybe its because of that:

Code:

#include "regs.h"

maybe you dont have this file in the right directory, or dont have that #include-line
just a quess ;)
Back to top
View user's profile Send private message
evilo



Joined: 22 Apr 2004
Posts: 230

PostPosted: Tue Jul 13, 2004 5:58 am    Post subject: Reply with quote

TyRaNiD wrote:
Try renaming the assembly files so that the .s is captialised as .S. That way it will be run through the preprocessor. Failing that try adding the -xassembler-with-cpp switch to the EE_ASFLAGS in your makefile.


you're the king, it was that, I changed the extension to .S and it works !

thanx !
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PS2 Development All times are GMT + 10 Hours
Page 1 of 1

 
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