>On 2001-02-11 19:51:43, Ben Hsu wrote:
>Hello,
> I've wrote a library in assembly using GAS,
>then I tried to compile it with "-ffreestanding"
>with a C file. Both using source file to compile.
>However, only the first few functions in in
>assembly code were read and the rest were told to
>be undefined refrences.
I don't use gas myself but it sounds like your asm
function names don't match to the functions your trying
to call from your C code.
> The situation is very tricky that even Borland's
>Turbo C++ fall to this trap. Is this the stuff
>on the buttom of the "Mixing C and Assembly" page?
>For that sentence describing 3 methods are hard
>to understand => conplex sentence very hard to read.
That paragraph is about string constant placement within
C code.
Try looking at some examples of using gas with djgpp:
http://www.castle.net/~avly/djasm.html
http://www.delorie.com/djgpp/doc/ug/asm/calling.html