Stubby is getdns_query with a different name

This commit is contained in:
Willem Toorop 2016-10-14 12:02:23 +02:00
parent 47e718eeb8
commit 3f965e68c0
4 changed files with 49 additions and 11 deletions

View File

@ -44,7 +44,7 @@ libdir = @libdir@
srcdir = @srcdir@
INSTALL = @INSTALL@
all : default @GETDNS_QUERY@
all : default @GETDNS_QUERY@ @STUBBY@
everything: default
cd src/test && $(MAKE)
@ -52,7 +52,7 @@ everything: default
default:
cd src && $(MAKE) $@
install: all getdns.pc getdns_ext_event.pc @INSTALL_GETDNS_QUERY@
install: all getdns.pc getdns_ext_event.pc @INSTALL_GETDNS_QUERY@ @INSTALL_STUBBY@
$(INSTALL) -m 755 -d $(DESTDIR)$(docdir)
$(INSTALL) -m 644 $(srcdir)/AUTHORS $(DESTDIR)$(docdir)
$(INSTALL) -m 644 $(srcdir)/ChangeLog $(DESTDIR)$(docdir)
@ -87,7 +87,7 @@ install: all getdns.pc getdns_ext_event.pc @INSTALL_GETDNS_QUERY@
@echo "*** at package installation time from the post-install script."
@echo "***"
uninstall: @UNINSTALL_GETDNS_QUERY@
uninstall: @UNINSTALL_GETDNS_QUERY@ @UNINSTALL_STUBBY@
rm -rf $(DESTDIR)$(docdir)
cd doc && $(MAKE) $@
cd src && $(MAKE) $@
@ -104,6 +104,9 @@ test:
getdns_query:
cd src && $(MAKE) $@
stubby:
cd src && $(MAKE) $@
scratchpad:
cd src && $(MAKE) $@
@ -111,10 +114,16 @@ pad: scratchpad
src/test/scratchpad || ./libtool exec gdb src/test/scratchpad
install-getdns_query:
cd src/tools && $(MAKE) install
cd src/tools && $(MAKE) $@
uninstall-getdns_query:
cd src/tools && $(MAKE) uninstall
cd src/tools && $(MAKE) $@
install-stubby:
cd src/tools && $(MAKE) $@
uninstall-stubby:
cd src/tools && $(MAKE) $@
clean:
cd src && $(MAKE) $@

View File

@ -913,6 +913,26 @@ else
INSTALL_GETDNS_QUERY="install-getdns_query"
UNINSTALL_GETDNS_QUERY="uninstall-getdns_query"
fi
AC_SUBST(GETDNS_QUERY)
AC_SUBST(INSTALL_GETDNS_QUERY)
AC_SUBST(UNINSTALL_GETDNS_QUERY)
AC_ARG_WITH(stubby, AS_HELP_STRING([--without-stubby],
[Do not compile and install stubby, the (stub) resolver daemon]),
[], [withval="yes"])
if test x_$withval = x_no; then
STUBBY=""
INSTALL_STUBBY=""
UNINSTALL_STUBBY=""
else
STUBBY="stubby"
INSTALL_STUBBY="install-stubby"
UNINSTALL_STUBBY="uninstall-stubby"
fi
AC_SUBST(STUBBY)
AC_SUBST(INSTALL_STUBBY)
AC_SUBST(UNINSTALL_STUBBY)
AC_ARG_WITH(fd-setsize, AS_HELP_STRING([--with-fd-setsize=size],
[Set maximum file descriptor number that can be used by select]),
[], [withval="no"])
@ -925,10 +945,6 @@ case "$withval" in
;;
esac
AC_SUBST(GETDNS_QUERY)
AC_SUBST(INSTALL_GETDNS_QUERY)
AC_SUBST(UNINSTALL_GETDNS_QUERY)
AC_CONFIG_FILES([Makefile src/Makefile src/version.c src/getdns/getdns.h src/getdns/getdns_extra.h spec/example/Makefile src/test/Makefile src/tools/Makefile doc/Makefile getdns.pc getdns_ext_event.pc])
if [ test -n "$DOXYGEN" ]
then AC_CONFIG_FILES([src/Doxyfile])

View File

@ -159,6 +159,9 @@ test: all
getdns_query: all
cd tools && $(MAKE) $@
stubby: all
cd tools && $(MAKE) $@
scratchpad: all
cd test && $(MAKE) $@

View File

@ -67,13 +67,23 @@ $(ALL_OBJS):
getdns_query: getdns_query.lo
$(LIBTOOL) --tag=CC --mode=link $(CC) $(CFLAGS) -o $@ getdns_query.lo $(LDFLAGS) $(LDLIBS)
install: getdns_query
stubby: getdns_query
ln -s getdns_query stubby
install-getdns_query: getdns_query
$(INSTALL) -m 755 -d $(DESTDIR)$(bindir)
$(LIBTOOL) --mode=install cp getdns_query $(DESTDIR)$(bindir)
uninstall:
uninstall-getdns_query:
$(LIBTOOL) --mode=uninstall rm -f $(DESTDIR)$(bindir)/getdns_query
install-stubby: getdns_query
$(INSTALL) -m 755 -d $(DESTDIR)$(bindir)
$(LIBTOOL) --mode=install cp getdns_query $(DESTDIR)$(bindir)/stubby
uninstall-stubby:
$(LIBTOOL) --mode=uninstall rm -f $(DESTDIR)$(bindir)/stubby
clean:
rm -f *.o *.lo $(PROGRAMS)
rm -rf .libs