Use the ChaCha-Poly1305 cipher for the SPTPS protocol.
[tinc] / src / Makefile.am
1 ## Produce this file with automake to get Makefile.in
2
3 sbin_PROGRAMS = tincd tinc sptps_test sptps_keypair
4
5 if LINUX
6 sbin_PROGRAMS += sptps_speed
7 endif
8
9 DEFAULT_INCLUDES =
10
11 ed25519_SOURCES = \
12         ed25519/add_scalar.c \
13         ed25519/ed25519.h \
14         ed25519/fe.c ed25519/fe.h \
15         ed25519/fixedint.h \
16         ed25519/ge.c ed25519/ge.h \
17         ed25519/key_exchange.c \
18         ed25519/keypair.c \
19         ed25519/precomp_data.h \
20         ed25519/sc.c ed25519/sc.h \
21         ed25519/seed.c \
22         ed25519/sha512.c ed25519/sha512.h \
23         ed25519/sign.c \
24         ed25519/verify.c
25
26 chacha_poly1305_SOURCES = \
27         chacha-poly1305/chacha.c chacha-poly1305/chacha.h \
28         chacha-poly1305/chacha-poly1305.c chacha-poly1305/chacha-poly1305.h \
29         chacha-poly1305/poly1305.c chacha-poly1305/poly1305.h
30
31 tincd_SOURCES = \
32         buffer.c buffer.h \
33         cipher.h \
34         conf.c conf.h \
35         connection.c connection.h \
36         control.c control.h \
37         control_common.h \
38         crypto.h \
39         device.h \
40         digest.h \
41         dropin.c dropin.h \
42         dummy_device.c \
43         ecdh.h \
44         ecdsa.h \
45         ecdsagen.h \
46         edge.c edge.h \
47         ethernet.h \
48         event.c event.h \
49         fake-gai-errnos.h \
50         fake-getaddrinfo.c fake-getaddrinfo.h \
51         fake-getnameinfo.c fake-getnameinfo.h \
52         getopt.c getopt.h \
53         getopt1.c \
54         graph.c graph.h \
55         hash.c hash.h \
56         have.h \
57         ipv4.h \
58         ipv6.h \
59         list.c list.h \
60         logger.c logger.h \
61         meta.c meta.h \
62         multicast_device.c \
63         names.c names.h \
64         net.c net.h \
65         net_packet.c \
66         net_setup.c \
67         net_socket.c \
68         netutl.c netutl.h \
69         node.c node.h \
70         prf.h \
71         process.c process.h \
72         protocol.c protocol.h \
73         protocol_auth.c \
74         protocol_edge.c \
75         protocol_key.c \
76         protocol_misc.c \
77         protocol_subnet.c \
78         raw_socket_device.c \
79         route.c route.h \
80         rsa.h \
81         rsagen.h \
82         script.c script.h \
83         splay_tree.c splay_tree.h \
84         sptps.c sptps.h \
85         subnet.c subnet.h \
86         subnet_parse.c \
87         system.h \
88         tincd.c \
89         utils.c utils.h \
90         xalloc.h \
91         $(ed25519_SOURCES) \
92         $(chacha_poly1305_SOURCES)
93
94 tinc_SOURCES = \
95         dropin.c dropin.h \
96         getopt.c getopt.h \
97         getopt1.c \
98         info.c info.h \
99         invitation.c invitation.h \
100         list.c list.h \
101         names.c names.h \
102         netutl.c netutl.h \
103         script.c script.h \
104         sptps.c sptps.h \
105         subnet_parse.c subnet.h \
106         tincctl.c tincctl.h \
107         top.c top.h \
108         utils.c utils.h \
109         $(ed25519_SOURCES) \
110         $(chacha_poly1305_SOURCES)
111
112 sptps_test_SOURCES = \
113         logger.c logger.h \
114         sptps.c sptps.h \
115         sptps_test.c \
116         utils.c utils.h \
117         $(ed25519_SOURCES) \
118         $(chacha_poly1305_SOURCES)
119
120 sptps_keypair_SOURCES = \
121         sptps_keypair.c \
122         utils.c utils.h \
123         $(ed25519_SOURCES)
124
125 sptps_speed_SOURCES = \
126         logger.c logger.h \
127         sptps.c sptps.h \
128         sptps_speed.c \
129         utils.c utils.h \
130         $(ed25519_SOURCES) \
131         $(chacha_poly1305_SOURCES)
132
133 ## Conditionally compile device drivers
134         
135 if LINUX
136 tincd_SOURCES += linux/device.c
137 endif
138
139 if BSD
140 tincd_SOURCES += bsd/device.c
141 if TUNEMU
142 tincd_SOURCES += bsd/tunemu.c bsd/tunemu.h
143 endif
144 endif
145
146 if SOLARIS
147 tincd_SOURCES += solaris/device.c
148 endif
149
150 if MINGW
151 tincd_SOURCES += mingw/device.c mingw/common.h
152 endif
153
154 if CYGWIN
155 tincd_SOURCES += cygwin/device.c
156 endif
157
158 if UML
159 tincd_SOURCES += uml_device.c
160 endif
161
162 if VDE
163 tincd_SOURCES += vde_device.c
164 endif
165
166 if OPENSSL
167 tincd_SOURCES += \
168         openssl/cipher.c \
169         openssl/crypto.c \
170         openssl/digest.c openssl/digest.h \
171         ed25519/ecdh.c \
172         ed25519/ecdsa.c \
173         openssl/prf.c \
174         openssl/rsa.c
175 tinc_SOURCES += \
176         openssl/cipher.c \
177         openssl/crypto.c \
178         openssl/digest.c openssl/digest.h \
179         ed25519/ecdh.c \
180         ed25519/ecdsa.c \
181         ed25519/ecdsagen.c \
182         openssl/prf.c \
183         openssl/rsa.c \
184         openssl/rsagen.c
185 sptps_test_SOURCES += \
186         openssl/crypto.c \
187         openssl/digest.c openssl/digest.h \
188         ed25519/ecdh.c \
189         ed25519/ecdsa.c \
190         openssl/prf.c
191 sptps_keypair_SOURCES += \
192         openssl/crypto.c \
193         ed25519/ecdsagen.c
194 sptps_speed_SOURCES += \
195         openssl/crypto.c \
196         openssl/digest.c openssl/digest.h \
197         ed25519/ecdh.c \
198         ed25519/ecdsa.c \
199         ed25519/ecdsagen.c \
200         openssl/prf.c
201 endif
202
203 if GCRYPT
204 tincd_SOURCES += \
205         gcrypt/cipher.c \
206         gcrypt/crypto.c \
207         gcrypt/digest.c gcrypt/digest.h \
208         gcrypt/ecdh.c \
209         gcrypt/ecdsa.c \
210         gcrypt/prf.c \
211         gcrypt/rsa.c
212 tinc_SOURCES += \
213         gcrypt/cipher.c \
214         gcrypt/crypto.c \
215         gcrypt/digest.c gcrypt/digest.h \
216         gcrypt/ecdh.c \
217         gcrypt/ecdsa.c \
218         gcrypt/ecdsagen.c \
219         gcrypt/prf.c \
220         gcrypt/rsa.c \
221         gcrypt/rsagen.c
222 sptps_test_SOURCES += \
223         gcrypt/cipher.c \
224         gcrypt/crypto.c \
225         gcrypt/digest.c gcrypt/digest.h \
226         gcrypt/ecdh.c \
227         gcrypt/ecdsa.c \
228         gcrypt/prf.c
229 endif
230
231 tinc_LDADD = $(READLINE_LIBS) $(CURSES_LIBS)
232 sptps_speed_LDADD = -lrt
233
234 LIBS = @LIBS@
235
236 if TUNEMU
237 LIBS += -lpcap
238 endif
239
240 AM_CFLAGS = -DCONFDIR=\"$(sysconfdir)\" -DLOCALSTATEDIR=\"$(localstatedir)\" -DSBINDIR=\"$(sbindir)\"