#898 TTL support broke build on RHEL5
Closed: Fixed Opened by sgallagh.

RHEL5 has c-ares 1.6.x. We need to include compatability features for the TTL feature added in ticket #811

depbase=`echo src/resolv/async_resolv.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; \
    if gcc -DHAVE_CONFIG_H -I. -I. -I.  -Wall -Iinclude -I.. -I./include -I./src/sss_client -I./src -Iinclude -I.      -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include        -I/usr/include/openldap24 -DLIBDIR=\"/usr/lib\" -DVARDIR=\"/var\" -DSHLIBEXT=\"\" -DSSSD_LIBEXEC_PATH=\"/usr/libexec/sssd\" -DSSSD_INTROSPECT_PATH=\"\" -DSSSD_CONF_DIR=\"/etc/sssd\" -DSSS_NSS_SOCKET_NAME=\"/var/lib/sss/pipes/nss\" -DSSS_PAM_SOCKET_NAME=\"/var/lib/sss/pipes/pam\" -DSSS_PAM_PRIV_SOCKET_NAME=\"/var/lib/sss/pipes/private/pam\" -DLOCALEDIR=\"@localedir@\"   -Wall -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Werror-implicit-function-declaration -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -MT src/resolv/async_resolv.o -MD -MP -MF "$depbase.Tpo" -c -o src/resolv/async_resolv.o src/resolv/async_resolv.c; \
    then mv -f "$depbase.Tpo" "$depbase.Po"; else rm -f "$depbase.Tpo"; exit 1; fi
depbase=`echo src/resolv/ares/ares_parse_srv_reply.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; \
    if gcc -DHAVE_CONFIG_H -I. -I. -I.  -Wall -Iinclude -I.. -I./include -I./src/sss_client -I./src -Iinclude -I.      -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include        -I/usr/include/openldap24 -DLIBDIR=\"/usr/lib\" -DVARDIR=\"/var\" -DSHLIBEXT=\"\" -DSSSD_LIBEXEC_PATH=\"/usr/libexec/sssd\" -DSSSD_INTROSPECT_PATH=\"\" -DSSSD_CONF_DIR=\"/etc/sssd\" -DSSS_NSS_SOCKET_NAME=\"/var/lib/sss/pipes/nss\" -DSSS_PAM_SOCKET_NAME=\"/var/lib/sss/pipes/pam\" -DSSS_PAM_PRIV_SOCKET_NAME=\"/var/lib/sss/pipes/private/pam\" -DLOCALEDIR=\"@localedir@\"   -Wall -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Werror-implicit-function-declaration -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -MT src/resolv/ares/ares_parse_srv_reply.o -MD -MP -MF "$depbase.Tpo" -c -o src/resolv/ares/ares_parse_srv_reply.o src/resolv/ares/ares_parse_srv_reply.c; \
    then mv -f "$depbase.Tpo" "$depbase.Po"; else rm -f "$depbase.Tpo"; exit 1; fi
src/resolv/async_resolv.c:409: warning: 'struct ares_addrttl' declared inside parameter list
src/resolv/async_resolv.c:409: warning: its scope is only this definition or declaration, which is probably not what you want
src/resolv/async_resolv.c: In function 'resolv_copy_in_addr':
src/resolv/async_resolv.c:414: error: dereferencing pointer to incomplete type
src/resolv/async_resolv.c:414: error: dereferencing pointer to incomplete type
src/resolv/async_resolv.c:415: error: dereferencing pointer to incomplete type
src/resolv/async_resolv.c: At top level:
src/resolv/async_resolv.c:422: warning: 'struct ares_addr6ttl' declared inside parameter list
src/resolv/async_resolv.c: In function 'resolv_copy_in6_addr':
src/resolv/async_resolv.c:427: error: dereferencing pointer to incomplete type
src/resolv/async_resolv.c:427: error: dereferencing pointer to incomplete type
src/resolv/async_resolv.c:428: error: dereferencing pointer to incomplete type
src/resolv/async_resolv.c: In function 'resolv_copy_hostent_ares':
src/resolv/async_resolv.c:551: error: invalid use of undefined type 'struct ares_addrttl'
src/resolv/async_resolv.c:551: error: dereferencing pointer to incomplete type
src/resolv/async_resolv.c:555: error: invalid use of undefined type 'struct ares_addr6ttl'
src/resolv/async_resolv.c:555: error: dereferencing pointer to incomplete type
src/resolv/async_resolv.c: In function 'resolv_gethostbyname_dns_parse':
src/resolv/async_resolv.c:848: error: invalid application of 'sizeof' to incomplete type 'struct ares_addrttl' 
src/resolv/async_resolv.c:856: warning: passing argument 4 of 'ares_parse_a_reply' from incompatible pointer type
src/resolv/async_resolv.c:861: error: invalid application of 'sizeof' to incomplete type 'struct ares_addr6ttl' 
src/resolv/async_resolv.c:869: warning: passing argument 4 of 'ares_parse_aaaa_reply' from incompatible pointer type
make[2]: *** [src/resolv/async_resolv.o] Error 1

Fields changed

patch: 0 => 1
status: new => assigned

master: fde4194a9bc18932c6cfdc44e69a4376feb26208

resolution: => fixed
status: assigned => closed

Fields changed

rhbz: => 0

Metadata Update from @sgallagh:
- Issue assigned to jhrozek
- Issue set to the milestone: SSSD 1.6.0

SSSD is moving from Pagure to Github. This means that new issues and pull requests
will be accepted only in SSSD's github repository.

This issue has been cloned to Github and is available here:
- https://github.com/SSSD/sssd/issues/1940

If you want to receive further updates on the issue, please navigate to the github issue
and click on subscribe button.

Thank you for understanding. We apologize for all inconvenience.

Metadata