Re: [vchkpw] qmail-tap documentation error?

2005-10-07 Thread John Simpson

On 2005-10-04, at 1317, Paul Theodoropoulos wrote:

From the qmailtap INSTALL file:

4) Done

To compile it you will at least need to change the error.h file
to include errno.h just after the ifdefs at the top of the file.

#include error.h

doesn't make sense. shouldn't the include line be

#include errno.h

?


you need angle brackets (i.e. less than and greater than signs)  
around the filename errno.h.


an easier way to describe it is... find this line:

extern int errno;

and replace it with these lines:

/* extern int errno; */
#include errno.h

and actually the first line, the one starting with /* and ending with  
*/, is not really necessary. in C, /* starts a comment, and */ ends a  
comment... so if you were to remove the entire line instead of  
commenting it out, it ends up having the same effect.



this sed one-liner will do the job for any of djb's packages:

sed -i -e '/extern int errno/{s/^/\/* /;s/$/ *\//;G;s/$/#include  
errno.h/;}' error.h



and the fix is only necessary for systems using glibc-2.3 or newer...  
if you're using an older glibc, or not using glibc at all, you don't  
need to do it.


--
| John M. Simpson - KG4ZOW - Programmer At Large |
| http://www.jms1.net/   [EMAIL PROTECTED] |
--
| Mac OS X proves that it's easier to make UNIX  |
| pretty than it is to make Windows secure.  |
--




PGP.sig
Description: This is a digitally signed message part


Re: [vchkpw] qmail-tap documentation error?

2005-10-07 Thread Paul Theodoropoulos

At 11:10 PM 10/6/2005, John Simpson wrote:

To compile it you will at least need to change the error.h file
to include errno.h just after the ifdefs at the top of the file.

#include error.h

doesn't make sense. shouldn't the include line be

#include errno.h

?


you need angle brackets (i.e. less than and greater than signs)
around the filename errno.h.


what i was getting at is that the docs say to change the error.h file 
to include errno.h - but the include it describes is to include 
error.h in error.h. i'm no C programmer, but that seemed wrong.


as noted it doesn't apply to me, i run solaris.


Paul Theodoropoulos
http://www.energynucleus.com
http://www.anastrophe.com
http://www.smileglobal.com




[vchkpw] qmail-tap documentation error?

2005-10-04 Thread Paul Theodoropoulos


From the qmailtap INSTALL file:


4) Done


To compile it you will at least need to change the error.h file

to include errno.h just after the ifdefs at the top of the file.


#include error.h 


doesn't make sense. shouldn't the include line be
#include errno.h
?
Paul Theodoropoulos

http://www.energynucleus.com

http://www.anastrophe.com

http://www.smileglobal.com