5f9f39116fafd235c4fd8d5d555db0146d916b99
[oweals/gnunet.git] / src / dns / Makefile.am
1 INCLUDES = -I$(top_srcdir)/src/include
2
3 if MINGW
4   WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
5 endif
6
7 if USE_COVERAGE
8   AM_CFLAGS = --coverage -O0
9 endif
10
11 pkgcfgdir= $(pkgdatadir)/config.d/
12
13 plugindir = $(libdir)/gnunet
14
15 pkgcfg_DATA = \
16   dns.conf
17
18 if LINUX
19 HIJACKBIN = gnunet-helper-dns
20 install-exec-hook:
21         $(SUDO_BINARY) chown root $(bindir)/gnunet-helper-dns || true
22         $(SUDO_BINARY) chgrp $(GNUNETDNS_GROUP) $(bindir)/gnunet-helper-dns || true
23         $(SUDO_BINARY) chmod 4750 $(bindir)/gnunet-helper-dns || true
24         $(SUDO_BINARY) chgrp $(GNUNETDNS_GROUP) $(bindir)/gnunet-service-dns || true
25         $(SUDO_BINARY) chmod 2755 $(bindir)/gnunet-service-dns || true
26 else
27 install-exec-hook:
28 endif
29
30 lib_LTLIBRARIES = \
31   libgnunetdnsparser.la \
32   libgnunetdns.la
33
34 bin_PROGRAMS = \
35   gnunet-service-dns $(HIJACKBIN)
36
37 noinst_PROGRAMS = \
38   gnunet-dns-monitor gnunet-dns-redirector
39
40 plugin_LTLIBRARIES = \
41   libgnunet_plugin_block_dns.la 
42
43
44 gnunet_helper_dns_SOURCES = \
45  gnunet-helper-dns.c
46
47
48 gnunet_dns_monitor_SOURCES = \
49  gnunet-dns-monitor.c
50 gnunet_dns_monitor_LDADD = \
51   $(top_builddir)/src/dns/libgnunetdnsparser.la \
52   $(top_builddir)/src/dns/libgnunetdns.la \
53   $(top_builddir)/src/util/libgnunetutil.la \
54   $(GN_LIBINTL)
55 gnunet_dns_monitor_DEPENDENCIES = \
56   libgnunetdnsparser.la \
57   libgnunetdns.la
58
59 gnunet_dns_redirector_SOURCES = \
60  gnunet-dns-redirector.c
61 gnunet_dns_redirector_LDADD = \
62   $(top_builddir)/src/dns/libgnunetdnsparser.la \
63   $(top_builddir)/src/dns/libgnunetdns.la \
64   $(top_builddir)/src/util/libgnunetutil.la \
65   $(GN_LIBINTL)
66 gnunet_dns_redirector_DEPENDENCIES = \
67   libgnunetdnsparser.la \
68   libgnunetdns.la
69
70 gnunet_service_dns_SOURCES = \
71  gnunet-service-dns.c 
72 gnunet_service_dns_LDADD = \
73   $(top_builddir)/src/tun/libgnunettun.la \
74   $(top_builddir)/src/statistics/libgnunetstatistics.la \
75   $(top_builddir)/src/util/libgnunetutil.la \
76   $(GN_LIBINTL)
77
78 libgnunetdnsparser_la_SOURCES = \
79  dnsparser.c 
80 libgnunetdnsparser_la_LIBADD = \
81  $(top_builddir)/src/util/libgnunetutil.la $(XLIB)
82 libgnunetdnsparser_la_LDFLAGS = \
83   $(GN_LIB_LDFLAGS)
84
85 libgnunetdns_la_SOURCES = \
86  dns_api.c dns.h
87 libgnunetdns_la_LIBADD = \
88  $(top_builddir)/src/util/libgnunetutil.la $(XLIB)
89 libgnunetdns_la_LDFLAGS = \
90   $(GN_LIB_LDFLAGS)
91
92 libgnunet_plugin_block_dns_la_SOURCES = \
93   plugin_block_dns.c
94 libgnunet_plugin_block_dns_la_LIBADD = \
95   $(top_builddir)/src/util/libgnunetutil.la
96 libgnunet_plugin_block_dns_la_LDFLAGS = \
97   $(top_builddir)/src/block/$(GN_PLUGIN_LDFLAGS)
98
99
100