Hi,
I would like to submit a patch to fix building of ares on a ppc64
system with certain compilers. The code in ares_build.h.dist tries to
figure out correct value for CARES_SIZEOF_LONG for gcc. It does so by
check __ppc__ first and then __ppc64__. There are two issues.
1. gcc actually does not use __ppc__ and __ppc64__ but __PPC__ and
__PPC64__.
The tests of __ILP32__ and __LP64__ are sufficient for gcc.
2. clang defines __GNU__ and defines both __ppc64__ and __ppc__ when
targeting ppc64. This makes CARES_SIZEOF_LONG to be 4 on a ppc64 system
when building with clang.
My patch is two change the order of the checks so that we check the 64-bit
case first.
Could someone consider that patch and incorporate that into ares?
-Doug