Subject: Re: adding __libc_read et al?
To: None <email@example.com>
From: der Mouse <mouse@Rodents.Montreal.QC.CA>
Date: 12/31/1999 02:32:47
> Does anyone else think having __libc_read, __libc_write etc would be
Maybe, though I have trouble imagining what could reasonably use them.
> It would be nice to be able to use something like
> -D_LIB_ENTRY_LABEL=__libc_ or whatever, but I've not worked out how
> to get that to work - I get either "__libc_ read" or
I snipped out of your patch enough to play with, and find this works
for me with -DPREFIX=whatever. I hope you can adapt it. (I had to
diddle with it a little to make it suitable for direct cc -E runs, such
as the first #define.)
# define __CONCAT(x,y) x ## y
# define __STRING(x) #x
# define __CONCAT(x,y) x/**/y
# define __STRING(x) "x"
#define __CONCATDEFER(x,y) __CONCAT(x,y)
#define ENTRY(name) _ENTRY(_C_LABEL(__CONCATDEFER(PREFIX,name)));_ENTRY(_C_LABEL(name)); _PROF_PROLOGUE
#define ENTRY(name) _ENTRY(_C_LABEL(name)); _PROF_PROLOGUE
7D C8 61 52 5D E7 2D 39 4E F1 31 3E E8 B3 27 4B