Brendan Doyle <Brendan.Doyle at Sun.COM> wrote:

> So then there's no avoiding a #ifdef SOLARIS, at least in the short term.

Cleanly written portable code uses fine grained tests and #fdefs....

> > The Linux man pages do have this to say about program_invocation_name
> > and program_invocation_short_name:
> >
> >     These variables are GNU extensions, and should not be used in
> >     programs intended to be portable.
> >   
> Yeah I'm aware of that, but I didn't write the lib. I'm just trying to 
> port it and then
> contribute it back to an Open Source community that currently doesn't 
> support Solaris,
> and is resistant to any OS specific #defines.

Did you tell them that using program_invocation_name is bad coding style
because it is non-portable?

Knowing about portability issues and writing clean code that used fine grained
#ifdefs is good style. Unconditionally using non-portable features of Linux 
needs to be avoided....

J?rg

-- 
 EMail:joerg at schily.isdn.cs.tu-berlin.de (home) J?rg Schilling D-13353 Berlin
       js at cs.tu-berlin.de                (uni)  
       joerg.schilling at fokus.fraunhofer.de (work) Blog: 
http://schily.blogspot.com/
 URL:  http://cdrecord.berlios.de/private/ ftp://ftp.berlios.de/pub/schily

Reply via email to