Added ldns support

This commit is contained in:
Melinda Shore 2013-06-24 12:17:15 -08:00
parent 210a640ec6
commit 16a2175d4c
2 changed files with 4 additions and 3 deletions

View File

@ -17,7 +17,7 @@ VPATH = @srcdir@
CC=gcc CC=gcc
CFLAGS=-g -I. -std=c99 CFLAGS=-g -I. -std=c99
LDFLAGS=-L. LDFLAGS=-L.
LDLIBS=-levent_core -lgetdns LDLIBS=-levent_core -lldns -lgetdns
PROGRAMS=example-simple-answers example-tree example-all-functions example-synchronous PROGRAMS=example-simple-answers example-tree example-all-functions example-synchronous
# example-simple-answers.c example-tree.c # example-simple-answers.c example-tree.c
@ -28,8 +28,8 @@ all: libgetdns example-simple-answers example-tree example-all-functions example
getdns_core_only.o: getdns_core_only.c getdns_core_only.o: getdns_core_only.c
$(CC) -c -Wall -fPIC $(CFLAGS) $^ $(CC) -c -Wall -fPIC $(CFLAGS) $^
libgetdns: getdns_core_only.o libgetdns: getdns_core_only.c
$(CC) -shared -o libgetdns.so $^ $(CC) $(CFLAGS) -shared -o libgetdns.so $^
clean: clean:
rm -f *.o $(PROGRAMS) libgetdns.so rm -f *.o $(PROGRAMS) libgetdns.so

View File

@ -15,6 +15,7 @@ AC_PROG_CC
# Checks for libraries. # Checks for libraries.
AC_CHECK_LIB([event_core], [event_base_new]) AC_CHECK_LIB([event_core], [event_base_new])
AC_CHECK_LIB([getdns], [getdns_context_create]) AC_CHECK_LIB([getdns], [getdns_context_create])
AC_CHECK_LIB([ldns], [ldns_dname_new_frm_str])
# Checks for header files. # Checks for header files.
AC_CHECK_HEADERS([inttypes.h netinet/in.h stdint.h stdlib.h string.h]) AC_CHECK_HEADERS([inttypes.h netinet/in.h stdint.h stdlib.h string.h])