diff options
author | Christian Grothoff <christian@grothoff.org> | 2012-01-01 23:00:59 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2012-01-01 23:00:59 +0000 |
commit | 66ffc809472f27d69b9ad7361f8ba29c2674f716 (patch) | |
tree | 609623cb79291939f9cb81a8858853a202dae2ca | |
parent | 131c43b2b18b12e52ff045e51025706802cbd2e2 (diff) | |
download | gnunet-66ffc809472f27d69b9ad7361f8ba29c2674f716.tar.gz gnunet-66ffc809472f27d69b9ad7361f8ba29c2674f716.zip |
-moving DNS code into its own directory
-rw-r--r-- | src/Makefile.am | 1 | ||||
-rw-r--r-- | src/dns/Makefile.am | 48 | ||||
-rw-r--r-- | src/dns/gnunet-dns-parser.c (renamed from src/vpn/gnunet-dns-parser.c) | 3 | ||||
-rw-r--r-- | src/dns/gnunet-helper-hijack-dns.c (renamed from src/vpn/gnunet-helper-hijack-dns.c) | 0 | ||||
-rw-r--r-- | src/dns/gnunet-service-dns.c (renamed from src/vpn/gnunet-service-dns.c) | 5 | ||||
-rw-r--r-- | src/include/Makefile.am | 1 | ||||
-rw-r--r-- | src/include/gnunet_dns_service.h (renamed from src/vpn/gnunet-service-dns-p.h) | 0 | ||||
-rw-r--r-- | src/include/gnunet_dnsparser_lib.h (renamed from src/vpn/gnunet-dns-parser.h) | 0 | ||||
-rw-r--r-- | src/vpn/Makefile.am | 21 | ||||
-rw-r--r-- | src/vpn/gnunet-daemon-vpn-dns.c | 1 | ||||
-rw-r--r-- | src/vpn/gnunet-daemon-vpn-helper.c | 1 | ||||
-rw-r--r-- | src/vpn/gnunet-daemon-vpn.h | 2 | ||||
-rw-r--r-- | src/vpn/gnunet-vpn-packet.h | 2 |
13 files changed, 57 insertions, 28 deletions
diff --git a/src/Makefile.am b/src/Makefile.am index eb4049285..6022f0733 100644 --- a/src/Makefile.am +++ b/src/Makefile.am | |||
@@ -30,6 +30,7 @@ SUBDIRS = \ | |||
30 | topology \ | 30 | topology \ |
31 | fs \ | 31 | fs \ |
32 | mesh \ | 32 | mesh \ |
33 | dns \ | ||
33 | vpn \ | 34 | vpn \ |
34 | integration-tests \ | 35 | integration-tests \ |
35 | $(EXP_DIR) | 36 | $(EXP_DIR) |
diff --git a/src/dns/Makefile.am b/src/dns/Makefile.am new file mode 100644 index 000000000..aad1b0f7a --- /dev/null +++ b/src/dns/Makefile.am | |||
@@ -0,0 +1,48 @@ | |||
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 | if LINUX | ||
16 | HIJACKBIN = gnunet-helper-hijack-dns | ||
17 | install-exec-hook: | ||
18 | $(SUDO_BINARY) chown root:root $(bindir)/gnunet-helper-hijack-dns || true | ||
19 | $(SUDO_BINARY) chmod u+s $(bindir)/gnunet-helper-hijack-dns || true | ||
20 | else | ||
21 | install-exec-hook: | ||
22 | endif | ||
23 | |||
24 | lib_LTLIBRARIES = libgnunetdnsparser.la | ||
25 | |||
26 | bin_PROGRAMS = \ | ||
27 | gnunet-service-dns $(HIJACKBIN) | ||
28 | |||
29 | gnunet_helper_hijack_dns_SOURCES = \ | ||
30 | gnunet-helper-hijack-dns.c | ||
31 | |||
32 | gnunet_service_dns_SOURCES = \ | ||
33 | gnunet-service-dns.c gnunet-service-dns-p.h | ||
34 | gnunet_service_dns_LDADD = \ | ||
35 | $(top_builddir)/src/core/libgnunetcore.la \ | ||
36 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | ||
37 | $(top_builddir)/src/util/libgnunetutil.la \ | ||
38 | $(top_builddir)/src/dht/libgnunetdht.la \ | ||
39 | $(top_builddir)/src/mesh/libgnunetmesh.la \ | ||
40 | $(GN_LIBINTL) -lgnunetdnsparser | ||
41 | |||
42 | |||
43 | libgnunetdnsparser_la_SOURCES = \ | ||
44 | gnunet-dns-parser.c | ||
45 | libgnunetdnsparser_la_LIBADD = \ | ||
46 | $(top_builddir)/src/util/libgnunetutil.la $(XLIB) | ||
47 | libgnunetdnsparser_la_LDFLAGS = \ | ||
48 | $(GN_LIB_LDFLAGS) \ No newline at end of file | ||
diff --git a/src/vpn/gnunet-dns-parser.c b/src/dns/gnunet-dns-parser.c index e87109e0c..6921f0d34 100644 --- a/src/vpn/gnunet-dns-parser.c +++ b/src/dns/gnunet-dns-parser.c | |||
@@ -1,6 +1,5 @@ | |||
1 | #include "platform.h" | 1 | #include "platform.h" |
2 | #include "gnunet-dns-parser.h" | 2 | #include "gnunet_dnsparser_lib.h" |
3 | #include "gnunet-vpn-packet.h" | ||
4 | 3 | ||
5 | /** | 4 | /** |
6 | * Parse a name from DNS to a normal .-delimited, 0-terminated string. | 5 | * Parse a name from DNS to a normal .-delimited, 0-terminated string. |
diff --git a/src/vpn/gnunet-helper-hijack-dns.c b/src/dns/gnunet-helper-hijack-dns.c index 70da96477..70da96477 100644 --- a/src/vpn/gnunet-helper-hijack-dns.c +++ b/src/dns/gnunet-helper-hijack-dns.c | |||
diff --git a/src/vpn/gnunet-service-dns.c b/src/dns/gnunet-service-dns.c index 12d0a93cf..ee42a7001 100644 --- a/src/vpn/gnunet-service-dns.c +++ b/src/dns/gnunet-service-dns.c | |||
@@ -28,13 +28,12 @@ | |||
28 | #include <gnunet_constants.h> | 28 | #include <gnunet_constants.h> |
29 | #include "gnunet_network_lib.h" | 29 | #include "gnunet_network_lib.h" |
30 | #include "gnunet_os_lib.h" | 30 | #include "gnunet_os_lib.h" |
31 | #include "gnunet-service-dns-p.h" | 31 | #include "gnunet_dns_service.h" |
32 | #include "gnunet_connection_lib.h" | 32 | #include "gnunet_connection_lib.h" |
33 | #include "gnunet_protocols.h" | 33 | #include "gnunet_protocols.h" |
34 | #include "gnunet_applications.h" | 34 | #include "gnunet_applications.h" |
35 | #include "gnunet-vpn-packet.h" | ||
36 | #include "gnunet_container_lib.h" | 35 | #include "gnunet_container_lib.h" |
37 | #include "gnunet-dns-parser.h" | 36 | #include "gnunet_dnsparser_lib.h" |
38 | #include "gnunet_dht_service.h" | 37 | #include "gnunet_dht_service.h" |
39 | #include "gnunet_block_lib.h" | 38 | #include "gnunet_block_lib.h" |
40 | #include "block_dns.h" | 39 | #include "block_dns.h" |
diff --git a/src/include/Makefile.am b/src/include/Makefile.am index 003a90e24..417e200c2 100644 --- a/src/include/Makefile.am +++ b/src/include/Makefile.am | |||
@@ -40,6 +40,7 @@ gnunetinclude_HEADERS = \ | |||
40 | gnunet_datastore_plugin.h \ | 40 | gnunet_datastore_plugin.h \ |
41 | gnunet_dht_service.h \ | 41 | gnunet_dht_service.h \ |
42 | gnunet_disk_lib.h \ | 42 | gnunet_disk_lib.h \ |
43 | gnunet_dnsparser_lib.h \ | ||
43 | gnunet_dv_service.h \ | 44 | gnunet_dv_service.h \ |
44 | gnunet_fragmentation_lib.h \ | 45 | gnunet_fragmentation_lib.h \ |
45 | gnunet_fs_service.h \ | 46 | gnunet_fs_service.h \ |
diff --git a/src/vpn/gnunet-service-dns-p.h b/src/include/gnunet_dns_service.h index 632145ae2..632145ae2 100644 --- a/src/vpn/gnunet-service-dns-p.h +++ b/src/include/gnunet_dns_service.h | |||
diff --git a/src/vpn/gnunet-dns-parser.h b/src/include/gnunet_dnsparser_lib.h index a9ed5b3b2..a9ed5b3b2 100644 --- a/src/vpn/gnunet-dns-parser.h +++ b/src/include/gnunet_dnsparser_lib.h | |||
diff --git a/src/vpn/Makefile.am b/src/vpn/Makefile.am index e69c5643e..dfba44f0a 100644 --- a/src/vpn/Makefile.am +++ b/src/vpn/Makefile.am | |||
@@ -17,30 +17,23 @@ dist_pkgcfg_DATA = \ | |||
17 | 17 | ||
18 | if LINUX | 18 | if LINUX |
19 | VPNBIN = gnunet-helper-vpn | 19 | VPNBIN = gnunet-helper-vpn |
20 | HIJACKBIN = gnunet-helper-hijack-dns | ||
21 | install-exec-hook: | 20 | install-exec-hook: |
22 | $(SUDO_BINARY) chown root:root $(bindir)/gnunet-helper-vpn || true | 21 | $(SUDO_BINARY) chown root:root $(bindir)/gnunet-helper-vpn || true |
23 | $(SUDO_BINARY) chmod u+s $(bindir)/gnunet-helper-vpn || true | 22 | $(SUDO_BINARY) chmod u+s $(bindir)/gnunet-helper-vpn || true |
24 | $(SUDO_BINARY) chown root:root $(bindir)/gnunet-helper-hijack-dns || true | ||
25 | $(SUDO_BINARY) chmod u+s $(bindir)/gnunet-helper-hijack-dns || true | ||
26 | else | 23 | else |
27 | install-exec-hook: | 24 | install-exec-hook: |
28 | endif | 25 | endif |
29 | 26 | ||
30 | 27 | ||
31 | bin_PROGRAMS = \ | 28 | bin_PROGRAMS = \ |
32 | gnunet-daemon-exit gnunet-daemon-vpn gnunet-service-dns $(VPNBIN) $(HIJACKBIN) | 29 | gnunet-daemon-exit gnunet-daemon-vpn $(VPNBIN) $(HIJACKBIN) |
33 | 30 | ||
34 | 31 | ||
35 | gnunet_helper_vpn_SOURCES = \ | 32 | gnunet_helper_vpn_SOURCES = \ |
36 | gnunet-helper-vpn.c | 33 | gnunet-helper-vpn.c |
37 | 34 | ||
38 | gnunet_helper_hijack_dns_SOURCES = \ | ||
39 | gnunet-helper-hijack-dns.c | ||
40 | |||
41 | gnunet_daemon_vpn_SOURCES = \ | 35 | gnunet_daemon_vpn_SOURCES = \ |
42 | gnunet-daemon-vpn.c gnunet-daemon-vpn.h \ | 36 | gnunet-daemon-vpn.c gnunet-daemon-vpn.h \ |
43 | gnunet-dns-parser.c gnunet-dns-parser.h \ | ||
44 | gnunet-daemon-vpn-helper.c gnunet-daemon-vpn-helper.h \ | 37 | gnunet-daemon-vpn-helper.c gnunet-daemon-vpn-helper.h \ |
45 | gnunet-daemon-vpn-dns.c gnunet-daemon-vpn-dns.h \ | 38 | gnunet-daemon-vpn-dns.c gnunet-daemon-vpn-dns.h \ |
46 | gnunet-helper-vpn-api.c gnunet-helper-vpn-api.h \ | 39 | gnunet-helper-vpn-api.c gnunet-helper-vpn-api.h \ |
@@ -50,17 +43,7 @@ gnunet_daemon_vpn_LDADD = \ | |||
50 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 43 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
51 | $(top_builddir)/src/util/libgnunetutil.la \ | 44 | $(top_builddir)/src/util/libgnunetutil.la \ |
52 | $(top_builddir)/src/mesh/libgnunetmesh.la \ | 45 | $(top_builddir)/src/mesh/libgnunetmesh.la \ |
53 | $(GN_LIBINTL) | 46 | $(top_builddir)/src/dns/libgnunetdnsparser.la \ |
54 | |||
55 | gnunet_service_dns_SOURCES = \ | ||
56 | gnunet-service-dns.c gnunet-service-dns-p.h \ | ||
57 | gnunet-dns-parser.c gnunet-dns-parser.h | ||
58 | gnunet_service_dns_LDADD = \ | ||
59 | $(top_builddir)/src/core/libgnunetcore.la \ | ||
60 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | ||
61 | $(top_builddir)/src/util/libgnunetutil.la \ | ||
62 | $(top_builddir)/src/dht/libgnunetdht.la \ | ||
63 | $(top_builddir)/src/mesh/libgnunetmesh.la \ | ||
64 | $(GN_LIBINTL) | 47 | $(GN_LIBINTL) |
65 | 48 | ||
66 | gnunet_daemon_exit_SOURCES = \ | 49 | gnunet_daemon_exit_SOURCES = \ |
diff --git a/src/vpn/gnunet-daemon-vpn-dns.c b/src/vpn/gnunet-daemon-vpn-dns.c index bd65e373f..b24d802f7 100644 --- a/src/vpn/gnunet-daemon-vpn-dns.c +++ b/src/vpn/gnunet-daemon-vpn-dns.c | |||
@@ -36,7 +36,6 @@ | |||
36 | #include "gnunet-daemon-vpn-dns.h" | 36 | #include "gnunet-daemon-vpn-dns.h" |
37 | #include "gnunet-daemon-vpn.h" | 37 | #include "gnunet-daemon-vpn.h" |
38 | #include "gnunet-daemon-vpn-helper.h" | 38 | #include "gnunet-daemon-vpn-helper.h" |
39 | #include "gnunet-service-dns-p.h" | ||
40 | #include "gnunet-vpn-packet.h" | 39 | #include "gnunet-vpn-packet.h" |
41 | 40 | ||
42 | struct query_packet_list *head; | 41 | struct query_packet_list *head; |
diff --git a/src/vpn/gnunet-daemon-vpn-helper.c b/src/vpn/gnunet-daemon-vpn-helper.c index d0e36099e..8f295506a 100644 --- a/src/vpn/gnunet-daemon-vpn-helper.c +++ b/src/vpn/gnunet-daemon-vpn-helper.c | |||
@@ -38,7 +38,6 @@ | |||
38 | #include "gnunet-daemon-vpn-dns.h" | 38 | #include "gnunet-daemon-vpn-dns.h" |
39 | #include "gnunet-daemon-vpn.h" | 39 | #include "gnunet-daemon-vpn.h" |
40 | #include "gnunet-daemon-vpn-helper.h" | 40 | #include "gnunet-daemon-vpn-helper.h" |
41 | #include "gnunet-service-dns-p.h" | ||
42 | #include "gnunet-vpn-packet.h" | 41 | #include "gnunet-vpn-packet.h" |
43 | #include "gnunet-vpn-checksum.h" | 42 | #include "gnunet-vpn-checksum.h" |
44 | #include "gnunet-helper-vpn-api.h" | 43 | #include "gnunet-helper-vpn-api.h" |
diff --git a/src/vpn/gnunet-daemon-vpn.h b/src/vpn/gnunet-daemon-vpn.h index 95218aa61..c8bf91ebb 100644 --- a/src/vpn/gnunet-daemon-vpn.h +++ b/src/vpn/gnunet-daemon-vpn.h | |||
@@ -26,7 +26,7 @@ | |||
26 | #ifndef GNUNET_DAEMON_VPN_H | 26 | #ifndef GNUNET_DAEMON_VPN_H |
27 | #define GNUNET_DAEMON_VPN_H | 27 | #define GNUNET_DAEMON_VPN_H |
28 | 28 | ||
29 | #include "gnunet-service-dns-p.h" | 29 | #include "gnunet_dns_service.h" |
30 | 30 | ||
31 | /** | 31 | /** |
32 | * This gets scheduled with cls pointing to an answer_packet and does everything | 32 | * This gets scheduled with cls pointing to an answer_packet and does everything |
diff --git a/src/vpn/gnunet-vpn-packet.h b/src/vpn/gnunet-vpn-packet.h index 19b2c8d7b..ddbfba730 100644 --- a/src/vpn/gnunet-vpn-packet.h +++ b/src/vpn/gnunet-vpn-packet.h | |||
@@ -3,7 +3,7 @@ | |||
3 | 3 | ||
4 | #include "platform.h" | 4 | #include "platform.h" |
5 | #include "gnunet_common.h" | 5 | #include "gnunet_common.h" |
6 | #include "gnunet-dns-parser.h" | 6 | #include "gnunet_dnsparser_lib.h" |
7 | 7 | ||
8 | GNUNET_NETWORK_STRUCT_BEGIN | 8 | GNUNET_NETWORK_STRUCT_BEGIN |
9 | 9 | ||