|
From: H. P. A. <hp...@zy...> - 2005-03-16 07:28:07
|
H. Peter Anvin wrote: > anonymous coward wrote: > >>> 1: *Strage Linking Problem* >> >> I'm not a Linux/GCC expert. But in the first case >> your code becomes start(), whereas in the second > > > _start() actually; ELF doesn't use an extra underscore. > N.B. For those that may not be familiar: some ABIs use a convention to preface C-language identifiers with underscores (_), in order to make identifiers generated by the compiler invisible to C. That would, however, make the dlsym() function awkward to use; instead ELF leaves C identifiers as-is, and identifiers that are supposed to be invisible to C instead contain a dot (.) somewhere. It is, however, common on ELF systems for FORTRAN symbols to be lower case and contain a *trailing* underscore, for example the FORTRAN subroutine "BLUTTAN" would become "bluttan_" on a typical ELF system, and would frequently be callable from C as bluttan_(). -hpa |