include.am 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219
  1. bin_PROGRAMS+= src/or/tor
  2. noinst_LIBRARIES += \
  3. src/or/libtor.a
  4. if UNITTESTS_ENABLED
  5. noinst_LIBRARIES += \
  6. src/or/libtor-testing.a
  7. endif
  8. if COVERAGE_ENABLED
  9. noinst_PROGRAMS+= src/or/tor-cov
  10. endif
  11. if BUILD_NT_SERVICES
  12. tor_platform_source=src/or/ntmain.c
  13. else
  14. tor_platform_source=
  15. endif
  16. EXTRA_DIST+= src/or/ntmain.c src/or/Makefile.nmake
  17. LIBTOR_A_SOURCES = \
  18. src/or/addressmap.c \
  19. src/or/buffers.c \
  20. src/or/channel.c \
  21. src/or/channeltls.c \
  22. src/or/circpathbias.c \
  23. src/or/circuitbuild.c \
  24. src/or/circuitlist.c \
  25. src/or/circuitmux.c \
  26. src/or/circuitmux_ewma.c \
  27. src/or/circuitstats.c \
  28. src/or/circuituse.c \
  29. src/or/command.c \
  30. src/or/config.c \
  31. src/or/confparse.c \
  32. src/or/connection.c \
  33. src/or/connection_edge.c \
  34. src/or/connection_or.c \
  35. src/or/control.c \
  36. src/or/cpuworker.c \
  37. src/or/dircollate.c \
  38. src/or/directory.c \
  39. src/or/dirserv.c \
  40. src/or/dirvote.c \
  41. src/or/dns.c \
  42. src/or/dnsserv.c \
  43. src/or/fp_pair.c \
  44. src/or/geoip.c \
  45. src/or/entrynodes.c \
  46. src/or/ext_orport.c \
  47. src/or/hibernate.c \
  48. src/or/keypin.c \
  49. src/or/main.c \
  50. src/or/microdesc.c \
  51. src/or/networkstatus.c \
  52. src/or/nodelist.c \
  53. src/or/onion.c \
  54. src/or/onion_fast.c \
  55. src/or/onion_tap.c \
  56. src/or/shared_random.c \
  57. src/or/shared_random_state.c \
  58. src/or/transports.c \
  59. src/or/periodic.c \
  60. src/or/protover.c \
  61. src/or/policies.c \
  62. src/or/reasons.c \
  63. src/or/relay.c \
  64. src/or/rendcache.c \
  65. src/or/rendclient.c \
  66. src/or/rendcommon.c \
  67. src/or/rendmid.c \
  68. src/or/rendservice.c \
  69. src/or/rephist.c \
  70. src/or/replaycache.c \
  71. src/or/router.c \
  72. src/or/routerkeys.c \
  73. src/or/routerlist.c \
  74. src/or/routerparse.c \
  75. src/or/routerset.c \
  76. src/or/scheduler.c \
  77. src/or/statefile.c \
  78. src/or/status.c \
  79. src/or/torcert.c \
  80. src/or/onion_ntor.c \
  81. $(tor_platform_source)
  82. src_or_libtor_a_SOURCES = $(LIBTOR_A_SOURCES)
  83. src_or_libtor_testing_a_SOURCES = $(LIBTOR_A_SOURCES)
  84. src_or_tor_SOURCES = src/or/tor_main.c
  85. AM_CPPFLAGS += -I$(srcdir)/src/or -Isrc/or
  86. src/or/tor_main.$(OBJEXT) \
  87. src/or/src_or_tor_cov-tor_main.$(OBJEXT): micro-revision.i
  88. AM_CPPFLAGS += -DSHARE_DATADIR="\"$(datadir)\"" \
  89. -DLOCALSTATEDIR="\"$(localstatedir)\"" \
  90. -DBINDIR="\"$(bindir)\""
  91. src_or_libtor_testing_a_CPPFLAGS = $(AM_CPPFLAGS) $(TEST_CPPFLAGS)
  92. src_or_libtor_testing_a_CFLAGS = $(AM_CFLAGS) $(TEST_CFLAGS)
  93. # -L flags need to go in LDFLAGS. -l flags need to go in LDADD.
  94. # This seems to matter nowhere but on windows, but I assure you that it
  95. # matters a lot there, and is quite hard to debug if you forget to do it.
  96. src_or_tor_LDFLAGS = @TOR_LDFLAGS_zlib@ @TOR_LDFLAGS_openssl@ @TOR_LDFLAGS_libevent@
  97. src_or_tor_LDADD = src/or/libtor.a src/common/libor.a src/common/libor-ctime.a \
  98. src/common/libor-crypto.a $(LIBKECCAK_TINY) $(LIBDONNA) \
  99. src/common/libor-event.a src/trunnel/libor-trunnel.a \
  100. @TOR_ZLIB_LIBS@ @TOR_LIB_MATH@ @TOR_LIBEVENT_LIBS@ @TOR_OPENSSL_LIBS@ \
  101. @TOR_LIB_WS32@ @TOR_LIB_GDI@ @CURVE25519_LIBS@ @TOR_SYSTEMD_LIBS@
  102. if COVERAGE_ENABLED
  103. src_or_tor_cov_SOURCES = src/or/tor_main.c
  104. src_or_tor_cov_CPPFLAGS = $(AM_CPPFLAGS) $(TEST_CPPFLAGS)
  105. src_or_tor_cov_CFLAGS = $(AM_CFLAGS) $(TEST_CFLAGS)
  106. src_or_tor_cov_LDFLAGS = @TOR_LDFLAGS_zlib@ @TOR_LDFLAGS_openssl@ @TOR_LDFLAGS_libevent@
  107. src_or_tor_cov_LDADD = src/or/libtor-testing.a src/common/libor-testing.a \
  108. src/common/libor-ctime-testing.a \
  109. src/common/libor-crypto-testing.a $(LIBKECCAK_TINY) $(LIBDONNA) \
  110. src/common/libor-event-testing.a src/trunnel/libor-trunnel-testing.a \
  111. @TOR_ZLIB_LIBS@ @TOR_LIB_MATH@ @TOR_LIBEVENT_LIBS@ @TOR_OPENSSL_LIBS@ \
  112. @TOR_LIB_WS32@ @TOR_LIB_GDI@ @CURVE25519_LIBS@ @TOR_SYSTEMD_LIBS@
  113. endif
  114. ORHEADERS = \
  115. src/or/addressmap.h \
  116. src/or/buffers.h \
  117. src/or/channel.h \
  118. src/or/channeltls.h \
  119. src/or/circpathbias.h \
  120. src/or/circuitbuild.h \
  121. src/or/circuitlist.h \
  122. src/or/circuitmux.h \
  123. src/or/circuitmux_ewma.h \
  124. src/or/circuitstats.h \
  125. src/or/circuituse.h \
  126. src/or/command.h \
  127. src/or/config.h \
  128. src/or/confparse.h \
  129. src/or/connection.h \
  130. src/or/connection_edge.h \
  131. src/or/connection_or.h \
  132. src/or/control.h \
  133. src/or/cpuworker.h \
  134. src/or/dircollate.h \
  135. src/or/directory.h \
  136. src/or/dirserv.h \
  137. src/or/dirvote.h \
  138. src/or/dns.h \
  139. src/or/dns_structs.h \
  140. src/or/dnsserv.h \
  141. src/or/ext_orport.h \
  142. src/or/fallback_dirs.inc \
  143. src/or/fp_pair.h \
  144. src/or/geoip.h \
  145. src/or/entrynodes.h \
  146. src/or/hibernate.h \
  147. src/or/keypin.h \
  148. src/or/main.h \
  149. src/or/microdesc.h \
  150. src/or/networkstatus.h \
  151. src/or/nodelist.h \
  152. src/or/ntmain.h \
  153. src/or/onion.h \
  154. src/or/onion_fast.h \
  155. src/or/onion_ntor.h \
  156. src/or/onion_tap.h \
  157. src/or/or.h \
  158. src/or/shared_random.h \
  159. src/or/shared_random_state.h \
  160. src/or/transports.h \
  161. src/or/periodic.h \
  162. src/or/policies.h \
  163. src/or/protover.h \
  164. src/or/reasons.h \
  165. src/or/relay.h \
  166. src/or/rendcache.h \
  167. src/or/rendclient.h \
  168. src/or/rendcommon.h \
  169. src/or/rendmid.h \
  170. src/or/rendservice.h \
  171. src/or/rephist.h \
  172. src/or/replaycache.h \
  173. src/or/router.h \
  174. src/or/routerkeys.h \
  175. src/or/routerlist.h \
  176. src/or/routerkeys.h \
  177. src/or/routerset.h \
  178. src/or/routerparse.h \
  179. src/or/scheduler.h \
  180. src/or/statefile.h \
  181. src/or/status.h \
  182. src/or/torcert.h
  183. noinst_HEADERS+= $(ORHEADERS) micro-revision.i
  184. micro-revision.i: FORCE
  185. $(AM_V_at)rm -f micro-revision.tmp; \
  186. if test -d "$(top_srcdir)/.git" && \
  187. test -x "`which git 2>&1;true`"; then \
  188. HASH="`cd "$(top_srcdir)" && git rev-parse --short=16 HEAD`"; \
  189. echo \"$$HASH\" > micro-revision.tmp; \
  190. fi; \
  191. if test ! -f micro-revision.tmp; then \
  192. if test ! -f micro-revision.i; then \
  193. echo '""' > micro-revision.i; \
  194. fi; \
  195. elif test ! -f micro-revision.i || \
  196. test x"`cat micro-revision.tmp`" != x"`cat micro-revision.i`"; then \
  197. mv micro-revision.tmp micro-revision.i; \
  198. fi; \
  199. rm -f micro-revision.tmp; \
  200. true
  201. CLEANFILES+= micro-revision.i src/or/micro-revision.i micro-revision.tmp
  202. FORCE: