2013-11-21 19:39:03 -06:00
#
# @configure_input@
#
2014-02-20 08:12:19 -06:00
#
2014-04-24 09:13:19 -05:00
# Copyright (c) 2013, Verisign, Inc., NLnet Labs
2014-02-20 08:12:19 -06:00
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
2014-02-25 07:23:19 -06:00
# * Neither the names of the copyright holders nor the
2014-02-20 08:12:19 -06:00
# names of its contributors may be used to endorse or promote products
# derived from this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL Verisign, Inc. BE LIABLE FOR ANY
# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2013-11-21 19:39:03 -06:00
package = @PACKAGE_NAME@
version = @PACKAGE_VERSION@
tarname = @PACKAGE_TARNAME@
distdir = $( tarname) -$( version)
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
2013-11-29 08:41:06 -06:00
# datarootdir is here to please some checkers
datarootdir = @datarootdir@
mandir = @mandir@
INSTALL = @INSTALL@
2013-11-21 19:39:03 -06:00
srcdir = @srcdir@
VPATH = @srcdir@
2013-12-10 04:44:36 -06:00
EDITS = -e 's/@' 'version@/$(version)/g'
2014-03-06 11:14:19 -06:00
DOXYGEN = @DOXYGEN@
2013-12-10 04:44:36 -06:00
2013-11-21 19:39:03 -06:00
DOCDIRS = html latex man
2014-04-25 06:49:25 -05:00
MANPAGES3 = libgetdns.3 getdns_address.3 getdns_cancel_callback.3 getdns_context.3 getdns_context_create.3 getdns_context_set.3 getdns_context_set_context_update_callback.3 getdns_convert.3 getdns_dict.3 getdns_dict_get.3 getdns_dict_set.3 getdns_display_ip_address.3 getdns_free_sync_request_memory.3 getdns_general.3 getdns_hostname.3 getdns_list.3 getdns_list_get.3 getdns_list_set.3 getdns_pretty_print_dict.3 getdns_root_trust_anchor.3 getdns_service.3 getdns_validate_dnssec.3
2013-11-21 19:39:03 -06:00
default : all
all : doc
2013-12-10 03:32:57 -06:00
doc : $( MANPAGES 3)
2014-03-06 11:14:19 -06:00
if test x_$( DOXYGEN) != x_ ; then cd ../src; doxygen; fi
2013-11-21 19:39:03 -06:00
2013-12-10 03:32:57 -06:00
.SUFFIXES : .3.in .3
.3.in.3 :
2013-12-10 04:44:36 -06:00
sed $( EDITS) -e "s/@date@/`date +'%B %Y'`/g" $< > $@
2013-11-29 08:41:06 -06:00
2014-02-19 16:30:01 -06:00
# we assume that we want a separate file for each "name" specified for each man page
# and consider these "alternate names" simple copies of the main man page
2013-12-10 03:32:57 -06:00
install : $( MANPAGES 3)
2013-11-29 08:41:06 -06:00
$( INSTALL) -m 755 -d $( DESTDIR) $( mandir)
$( INSTALL) -m 755 -d $( DESTDIR) $( mandir) /man3
2014-05-19 08:23:40 -05:00
for x in $( MANPAGES3) ; do echo $( INSTALL) -m 644 $$ x $( DESTDIR) $( mandir) /man3; $( INSTALL) -m 644 $$ x $( DESTDIR) $( mandir) /man3; for altpg in $$ ( $( srcdir) /manpgaltnames $$ x) ; do cp $$ x $$ altpg; echo $( INSTALL) -m 644 $$ altpg $( DESTDIR) $( mandir) /man3; $( INSTALL) -m 644 $$ altpg $( DESTDIR) $( mandir) /man3; done ; done
2013-11-29 08:41:06 -06:00
uninstall :
2014-05-19 08:23:40 -05:00
for x in $( MANPAGES3) ; do echo rm -f $( DESTDIR) $( mandir) /man3/$$ x; rm -f $( DESTDIR) $( mandir) /man3/$$ x; for altpg in $$ ( $( srcdir) /manpgaltnames $$ x) ; do echo rm -f $( DESTDIR) $( mandir) /man3/$$ altpg; rm -f $( DESTDIR) $( mandir) /man3/$$ altpg; done ; done
2013-11-29 08:41:06 -06:00
2013-11-21 19:39:03 -06:00
clean :
2014-05-19 08:23:40 -05:00
for x in $( MANPAGES3) ; do rm -f $$ ( $( srcdir) /manpgaltnames $$ x) ; done
2013-12-10 03:32:57 -06:00
rm -rf $( DOCDIRS) $( MANPAGES3)
2013-11-21 19:39:03 -06:00
distclean : clean
rm -f Makefile config.status config.log
rm -Rf autom4te.cache
Makefile : Makefile .in ../config .status
cd .. && ./config.status $@
configure.status : configure
cd .. && ./config.status --recheck
.PHONY : clean $( DOC )