This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: libverbose_terminate, pass 1 of N
On Sat, Dec 21, 2002 at 03:26:14AM +0100, Gabriel Dos Reis wrote:
> As far as the LD_PRELOAD thiny isn't the mandated way to get this sort
> of feature, I don't mind. I much favor the -l approach as it is
> transparent about .a or .so distinction.
Except that the .a isn't currently working. I haven't considered it much,
but I fear that to make the .a work, the user must still change the source
code to generate a reference to the dummy object, or tweak the command
line even more, else the archive library is ignored.
They can still use .so.
Personally, I prefer LD_PRELOAD, because that way the user doesn't have
to relink. But I agree that -l must be supported.
> | I'm guessing that dg-output is only scanning stdout, not stderr.
>
> Yeah. The tool (libstdc++-v3) is expected to output diagnostics on
> stderr and testcase are expected to do output on stdout. I guess
> there might be a way to hack around that.
Any suggestions? I can't think of a way.
> | + static struct __Verb_Term_Preload
> | + {
[...]
> | + } __verb_term_dummy;
>
> + struct __verb_term_preload
> + {
[...]
> + };
> +
> + static __verb_term_preload __verb_term_dummy;
Other than the fix to the naming, is there a particular reason to separate
the two declarations? This style seems to be in use elsewhere in GCC when
a one-shot variable is need.
Phil
--
I would therefore like to posit that computing's central challenge, viz. "How
not to make a mess of it," has /not/ been met.
- Edsger Dijkstra, 1930-2002