Mantis - MyDNS-NG
Viewing Issue Advanced Details
56 Global minor always 2010-05-12 17:41 2014-08-09 15:20
rhardy  
jameno123  
normal  
feedback 1.2.8.27  
open  
none    
none  
0000056: Current code assumes AI_ADDRCONFIG is always present in netdb.h
Current mydns-ng code blindly assumes if netdb.h is present that AI_ADDRCONFIG is defined. This isn't the always the case especially on legacy platforms.

Using the attached patch and adding -llwres to the configure line will build properly. For example: ./configure --without-mysql LIBS=-llwres

There must be cleaner ways to do this but I'm including this as is in order to help other legacy compilers.
AI_ADDRCONFIG is only used once in notify.c and without lwres on legacy platforms the build may fail as follows:

gcc -DLOCALEDIR=\"/usr/local/share/locale\" -I. -I../.. -I../../lib -I../../src/lib -I../../intl -I/usr/local/pgsql/include -g -O2 -finline-functions -funsigned-char -MT notify.o -MD -MP -MF .deps/notify.Tpo -c -o notify.o notify.c
notify.c: In function `name_servers2ip':
notify.c:790: `AI_ADDRCONFIG' undeclared (first use in this function)
notify.c:790: (Each undeclared identifier is reported only once
notify.c:790: for each function it appears in.)
make[3]: *** [notify.o] Error 1
make[3]: Leaving directory `/home/src/foo/mydns-1.2.8/src/mydns'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/src/foo/mydns-1.2.8/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/src/foo/mydns-1.2.8'
related to 0000057resolved jameno123 Fails to build on OpenSolaris 
related to 0000018resolved jameno123 Syntax error in notify.c 
? file icon mydns-1.2.8.27.1-lwres.diff [^] (302 bytes) 2010-05-12 17:41
log file icon mydns-1.2.8.27.1-build_fail.log [^] (18,563 bytes) 2010-05-12 18:46
Issue History
2010-05-12 17:41 rhardy New Issue
2010-05-12 17:41 rhardy File Added: mydns-1.2.8.27.1-lwres.diff
2010-05-12 17:49 itamarjp Note Added: 0000150
2010-05-12 18:02 rhardy Note Added: 0000152
2010-05-12 18:46 rhardy Note Added: 0000153
2010-05-12 18:46 rhardy Note Deleted: 0000153
2010-05-12 18:46 rhardy File Added: mydns-1.2.8.27.1-build_fail.log
2010-05-13 15:30 itamarjp Note Added: 0000154
2010-05-13 17:18 rhardy Note Added: 0000156
2010-05-14 14:09 itamarjp Note Added: 0000157
2010-06-04 23:03 toddr Note Added: 0000158
2010-06-04 23:05 toddr Issue Monitored: toddr
2010-06-29 19:49 jwarnier Issue Monitored: jwarnier
2010-11-22 18:40 itamarjp Note Added: 0000187
2014-08-05 23:49 jameno123 Relationship added related to 0000057
2014-08-05 23:49 jameno123 Relationship added related to 0000018
2014-08-05 23:51 jameno123 Note Added: 0000206
2014-08-05 23:51 jameno123 Assigned To => jameno123
2014-08-05 23:51 jameno123 Status new => feedback
2014-08-09 15:20 rhardy Note Added: 0000216

Notes
(0000150)
itamarjp   
2010-05-12 17:49   
what if you try this before ./configure

export CPPFLAGS="-I/usr/include/lwres"
(0000152)
rhardy   
2010-05-12 18:02   
Doing export CPPFLAGS="-I/usr/include/lwres" results in quite a blowup/build failure.
See attached mydns-1.2.8.27.1-build_fail.log
This makes me wonder if notify is really broken in the legacy compile and the compiler isn't showing it....
Notify wasn't working properly on ubuntu LTS 10.04 either so I'm not sure.
(0000154)
itamarjp   
2010-05-13 15:30   
do you have libc6-dev installed in your ubuntu box ?
(0000156)
rhardy   
2010-05-13 17:18   
I have the equivalent on the system. This legacy compile was an old Redhat box. I suspect my notify problem is a different issue. I'll get into notify another day and likely in a different bug report.
(0000157)
itamarjp   
2010-05-14 14:09   
do you have glibc-headers in your old redhat box ?
what are your distro version of your old redhat box ?
(0000158)
toddr   
2010-06-04 23:03   
I'm seeing the issue just now on Redhat 9. glibc headers are installed:

[root@redhat-9-32bit mydns-1.2.8]# rpm -qa|grep glibc
glibc-common-2.3.2-11.9
glibc-2.3.2-11.9
glibc-devel-2.3.2-11.9
glibc-kernheaders-2.4-8.10
(0000187)
itamarjp   
2010-11-22 18:40   
what are your ubuntu version ?

buntu LTS 10.04 ?

I will download it and try to compile.
(0000206)
jameno123   
2014-08-05 23:51   
Ive restructured some of the ifdef's and precompiler if's in the notify.c file that, probably wont, but might fix the problem. Is this still an issue? (no comments in 4 years - trying to clean up the bug report db).
(0000216)
rhardy   
2014-08-09 15:20   
Please close this ticket as I'm no longer using this software.