home *** CD-ROM | disk | FTP | other *** search
/ Magazyn Exec 5 / CD_Magazyn_EXEC_nr_5.iso / Programy / Programowanie / AmigaE / yaec.lha / externs / externs.txt < prev    next >
Encoding:
Text File  |  2001-02-23  |  1.3 KB  |  66 lines

  1.  
  2.    yaec1.4a - externs/externs.txt
  3.  
  4.    --------------------------------
  5.  
  6.    Globals that can be accessed by external code :
  7.  
  8.    ( access with name(a4) )
  9.  
  10.    GLOBAL_execbase        OR _SysBase
  11.    GLABAL_dosbase         OR _DOSBase
  12.    GLOBAL_graphicsbase    OR _GfxBase
  13.    GLOBAL_intuitionbase   OR _IntuiBase
  14.    GLOBAL_stdin           OR _stdin
  15.    GLOBAL_stdout          OR _stdout
  16.    GLOBAL_arg
  17.    GLOBAL_mempool
  18.    GLOBAL_stacksize
  19.    GLOBAL_initialstack
  20.    GLOBAL_exception
  21.    GLOBAL_exceptioninfo
  22.    GLOBAL_stdrast
  23.  
  24.    AND any globals that you define in your program :
  25.  
  26.    GLOBAL_<name>
  27.  
  28.  
  29.    An external function looks like :
  30.  
  31.    EXT <fname> <#ofargs> ; comments
  32.       <asm>
  33.       ....
  34.    ENDEXT
  35.  
  36.    <fname> must start with Uppercase A-Z.
  37.  
  38.    <asm> will be inserted directly (inline) into the program.
  39.  
  40.    Parameters are pushed (reverse order) on stack by YAEC.
  41.    Get them with :
  42.  
  43.    move.l (a7)+, <something>
  44.  
  45.    OR  (most usual)
  46.  
  47.    movem.l (a7)+, reglist
  48.  
  49.  
  50.    If you are using any other regs then a0/a1/d0/d1/a6
  51.    you must first save them.
  52.  
  53.  
  54.    To link in external linklibs with your code :
  55.  
  56.    LINK <path/nameoflinklib>
  57.  
  58.    Put above at the top of the .ext file.
  59.  
  60.  
  61.    Finally, this format of the .ext files may change
  62.    anytime. especially on other platforms, but even
  63.    between compiler versions is possible.
  64.  
  65.  
  66.