[A89] Re: tigcc.a


[Prev][Next][Index][Thread]

[A89] Re: tigcc.a




try this:

the xdef _nostub means a nostub program
i'm not sure what the others are because i've never programmed in doorsos
mode. Apparently it must assume a library if you don't xdef anything
Technoplaza has some excellent asm lessons at
http://www.technoplaza.net/assembly/ they are written to be used for kernel
based programs, but they are easily adaptable to nostub programming.

     include     "os.h"

 xdef _nostub
 xdef _ti89
 xdef _ti92plus
 xdef _main

_main:
     move.w      #1,-(sp)
     pea.l       string(pc)
     bsr         printf
     addq.l      #6,sp
     rts

string:
     dc.b        "Hello, World!, %i",0

-Greg
GForce Programming: http://gforce.calc.org/

----- Original Message ----- 
From: "R.A." <funkaster@mac.com>
To: <assembly-89@lists.ticalc.org>
Sent: Tuesday, July 09, 2002 11:07 AM
Subject: [A89] tigcc.a


> 
> I'm trying to test a function of tigcc.a (now that I have TIGCC 
> running). This is my code (slightly modified version of what Joel 
> Thompson sent to the list a few days back)
> 
>      include     "os.h"
> 
>      xdef        _ti89
> 
>      move.w      #1,-(sp)
>      pea.l       string(pc)
>      bsr         printf
>      addq.l      #6,sp
>      rts
> 
> string:
>      dc.b        "Hello, World!, %i",0
> 
> this compiles fine, but when I run it on my calc it says: "Libraries 
> are not executable." I think this has to do with the way TIGCC is 
> linking. Do I have to include something special in the command line? 
> (I'm just using tigcc source.asm, I also tried tigcc tigcc.a 
> source.asm)
> regards,
> ra.-
>