Compiling 4.0.18 under Fedora 11 - getline() conflict
Matt Garretson <[email protected]> Sun, 13 Sep 2009 17:37:42 -0400
| Newsgroups | gmane.mail.qpopper |
|---|---|
| Organization | New York State Assembly |
| Message-ID | <[email protected]> |
When trying to build Qpopper 4.0.18 on a fresh Fedora 11 installation, I got this error: popper.c: In function ‘qpopper’: popper.c:153: error: conflicting types for ‘getline’ /usr/include/stdio.h:653: note: previous declaration of ‘getline’ was here getline() is indeed defined in stdio.h . But, interestingly, the build succeeds under Fedora 10, which also has getline() in stdio.h. The difference between the two Fedoras seems to be that in Fedora 10, getline() is contained within an #ifdef __USE_GNU , while in Fedora 11, it's contained within an #ifdef __USE_XOPEN2K8 I'm not sure the implications of all this, but as a quick fix I renamed all references to Qpopper's getline() to qgetline() and now it builds successfully. -Matt