RE: Re[2]: [cc65] Graphics library

Date view Thread view Subject view

From: Keates, Mark (
Date: 2001-08-15 18:11:14

Hi Mike,
> IMO, "library" implies just that, that many things are collected into
> one place, nothing about how it is implemented.
> Do you think that "fgets()" has the same implementation on Sun/Solaris
> (which I use at work) and on the 6502?

I guess I was thinking of this too closely to CC65.
For us, fgets() is part of a common library which could
(in theory) be built into its own library and linked
with the target machines library. However, as it
currently stands each target has its own lib.

For a 'portable' library to work it would need to contain
each target's implementation. A clever linker might be 
able to remove the redundant (non-target) routines
as somewhere in the code a decision must be made as to
which function to call. E.g: 

	switch (getsystype())
		case SYS_ATARI: atari_DrawLine(x1,y1,x2,y2); break;
		case SYS_CBM64: cbm64_DrawLine(x1,y1,x2,y2); break;

I guess this could work if each function was in its own .o file.
Does LD65 handle this?


To unsubscribe from the list send mail to with
the string "unsubscribe cc65" in the body(!) of the mail.

Date view Thread view Subject view

This archive was generated by hypermail 2.1.3 : 2001-12-14 22:05:41 CET