[Pdns-users] PDNS Recursor compile errors on g++ 4.4.0

Leen Besselink leen at consolejunkie.net
Sun Jul 5 08:50:38 UTC 2009


Roger Libiez wrote:
> pdns_recursor.cc: In function "void startDoResolve(void*)":
> pdns_recursor.cc:669: error: reference to "exception" is ambiguous
> /usr/include/boost/exception/exception.hpp:177: error: candidates are:
> class boost::exception
> /usr/lib/gcc/x86_64-redhat-linux/4.4.0/../../../../include/c++/4.4.0/exception:60:
> error:                 class std::exception
> pdns_recursor.cc:669: error: expected type-specifier before "exception"
> pdns_recursor.cc:669: error: expected ) before & token
> pdns_recursor.cc:669: error: expected { before & token
> pdns_recursor.cc:669: error: e was not declared in this scope
> pdns_recursor.cc:669: error: expected ; before ) token
> pdns_recursor.cc:672: error: expected primary-expression before catch
> pdns_recursor.cc:672: error: expected ; before catch
> 
> The above is displayed when attempting to compile on a server where g++
> 4.4.0 is the only available compiler. Downgrading the compiler is not an
> option. What's the correct fix for these? There are quite a few of them
> in various different spots in that module.
> 

Hi Roger,

What version of PowerDNS-recursor and what version of Boost are you using ?:

I'm no expert, but I wouldn't be surprised if a newer Boost library solved the problem.

Atleast that's what my gut instinct told me, a quick Google search was much more useful.

I think you might need to add:

#include <cstdio>

to misc.hh

http://cvs.fedora.redhat.com/viewvc/devel/pdns-recursor/pdns-recursor-gcc44.patch?revision=1.1&view=markup

Hope that helps.

Have a nice day,
	Leen Besselink.



More information about the Pdns-users mailing list