i2pd_qt.pro 7.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245
  1. QT += core gui
  2. greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
  3. TARGET = i2pd_qt
  4. TEMPLATE = app
  5. QMAKE_CXXFLAGS *= -std=c++11 -Wno-unused-parameter -Wno-maybe-uninitialized
  6. DEFINES += USE_UPNP
  7. SOURCES += DaemonQT.cpp mainwindow.cpp \
  8. ../../libi2pd/api.cpp \
  9. ../../libi2pd/Base.cpp \
  10. ../../libi2pd/Blinding.cpp \
  11. ../../libi2pd/BloomFilter.cpp \
  12. ../../libi2pd/ChaCha20.cpp \
  13. ../../libi2pd/Config.cpp \
  14. ../../libi2pd/CPU.cpp \
  15. ../../libi2pd/Crypto.cpp \
  16. ../../libi2pd/CryptoKey.cpp \
  17. ../../libi2pd/Datagram.cpp \
  18. ../../libi2pd/Destination.cpp \
  19. ../../libi2pd/Ed25519.cpp \
  20. ../../libi2pd/Event.cpp \
  21. ../../libi2pd/Family.cpp \
  22. ../../libi2pd/FS.cpp \
  23. ../../libi2pd/Garlic.cpp \
  24. ../../libi2pd/Gost.cpp \
  25. ../../libi2pd/Gzip.cpp \
  26. ../../libi2pd/HTTP.cpp \
  27. ../../libi2pd/I2NPProtocol.cpp \
  28. ../../libi2pd/I2PEndian.cpp \
  29. ../../libi2pd/Identity.cpp \
  30. ../../libi2pd/LeaseSet.cpp \
  31. ../../libi2pd/Log.cpp \
  32. ../../libi2pd/NetDb.cpp \
  33. ../../libi2pd/NetDbRequests.cpp \
  34. ../../libi2pd/NTCP2.cpp \
  35. ../../libi2pd/NTCPSession.cpp \
  36. ../../libi2pd/Poly1305.cpp \
  37. ../../libi2pd/Profiling.cpp \
  38. ../../libi2pd/Reseed.cpp \
  39. ../../libi2pd/RouterContext.cpp \
  40. ../../libi2pd/RouterInfo.cpp \
  41. ../../libi2pd/Signature.cpp \
  42. ../../libi2pd/SSU.cpp \
  43. ../../libi2pd/SSUData.cpp \
  44. ../../libi2pd/SSUSession.cpp \
  45. ../../libi2pd/Streaming.cpp \
  46. ../../libi2pd/Timestamp.cpp \
  47. ../../libi2pd/TransitTunnel.cpp \
  48. ../../libi2pd/Transports.cpp \
  49. ../../libi2pd/Tunnel.cpp \
  50. ../../libi2pd/TunnelEndpoint.cpp \
  51. ../../libi2pd/TunnelGateway.cpp \
  52. ../../libi2pd/TunnelPool.cpp \
  53. ../../libi2pd/util.cpp \
  54. ../../libi2pd_client/AddressBook.cpp \
  55. ../../libi2pd_client/BOB.cpp \
  56. ../../libi2pd_client/ClientContext.cpp \
  57. ../../libi2pd_client/HTTPProxy.cpp \
  58. ../../libi2pd_client/I2CP.cpp \
  59. ../../libi2pd_client/I2PService.cpp \
  60. ../../libi2pd_client/I2PTunnel.cpp \
  61. ../../libi2pd_client/MatchedDestination.cpp \
  62. ../../libi2pd_client/SAM.cpp \
  63. ../../libi2pd_client/SOCKS.cpp \
  64. ../../libi2pd_client/Websocket.cpp \
  65. ../../libi2pd_client/WebSocks.cpp \
  66. ../../daemon/Daemon.cpp \
  67. ../../daemon/HTTPServer.cpp \
  68. ../../daemon/I2PControl.cpp \
  69. ../../daemon/i2pd.cpp \
  70. ../../daemon/UPnP.cpp \
  71. ClientTunnelPane.cpp \
  72. MainWindowItems.cpp \
  73. ServerTunnelPane.cpp \
  74. SignatureTypeComboboxFactory.cpp \
  75. TunnelConfig.cpp \
  76. TunnelPane.cpp \
  77. textbrowsertweaked1.cpp \
  78. pagewithbackbutton.cpp \
  79. widgetlock.cpp \
  80. widgetlockregistry.cpp \
  81. logviewermanager.cpp
  82. HEADERS += DaemonQT.h mainwindow.h \
  83. ../../libi2pd/api.h \
  84. ../../libi2pd/Base.h \
  85. ../../libi2pd/Blinding.h \
  86. ../../libi2pd/BloomFilter.h \
  87. ../../libi2pd/ChaCha20.h \
  88. ../../libi2pd/Config.h \
  89. ../../libi2pd/CPU.h \
  90. ../../libi2pd/Crypto.h \
  91. ../../libi2pd/CryptoKey.h \
  92. ../../libi2pd/CryptoWorker.h \
  93. ../../libi2pd/Datagram.h \
  94. ../../libi2pd/Destination.h \
  95. ../../libi2pd/Ed25519.h \
  96. ../../libi2pd/Event.h \
  97. ../../libi2pd/Family.h \
  98. ../../libi2pd/FS.h \
  99. ../../libi2pd/Garlic.h \
  100. ../../libi2pd/Gost.h \
  101. ../../libi2pd/Gzip.h \
  102. ../../libi2pd/HTTP.h \
  103. ../../libi2pd/I2NPProtocol.h \
  104. ../../libi2pd/I2PEndian.h \
  105. ../../libi2pd/Identity.h \
  106. ../../libi2pd/LeaseSet.h \
  107. ../../libi2pd/LittleBigEndian.h \
  108. ../../libi2pd/Log.h \
  109. ../../libi2pd/NetDb.hpp \
  110. ../../libi2pd/NetDbRequests.h \
  111. ../../libi2pd/NTCP2.h \
  112. ../../libi2pd/NTCPSession.h \
  113. ../../libi2pd/Poly1305.h \
  114. ../../libi2pd/Profiling.h \
  115. ../../libi2pd/Queue.h \
  116. ../../libi2pd/Reseed.h \
  117. ../../libi2pd/RouterContext.h \
  118. ../../libi2pd/RouterInfo.h \
  119. ../../libi2pd/Signature.h \
  120. ../../libi2pd/Siphash.h \
  121. ../../libi2pd/SSU.h \
  122. ../../libi2pd/SSUData.h \
  123. ../../libi2pd/SSUSession.h \
  124. ../../libi2pd/Streaming.h \
  125. ../../libi2pd/Tag.h \
  126. ../../libi2pd/Timestamp.h \
  127. ../../libi2pd/TransitTunnel.h \
  128. ../../libi2pd/Transports.h \
  129. ../../libi2pd/TransportSession.h \
  130. ../../libi2pd/Tunnel.h \
  131. ../../libi2pd/TunnelBase.h \
  132. ../../libi2pd/TunnelConfig.h \
  133. ../../libi2pd/TunnelEndpoint.h \
  134. ../../libi2pd/TunnelGateway.h \
  135. ../../libi2pd/TunnelPool.h \
  136. ../../libi2pd/util.h \
  137. ../../libi2pd/version.h \
  138. ../../libi2pd_client/AddressBook.h \
  139. ../../libi2pd_client/BOB.h \
  140. ../../libi2pd_client/ClientContext.h \
  141. ../../libi2pd_client/HTTPProxy.h \
  142. ../../libi2pd_client/I2CP.h \
  143. ../../libi2pd_client/I2PService.h \
  144. ../../libi2pd_client/I2PTunnel.h \
  145. ../../libi2pd_client/MatchedDestination.h \
  146. ../../libi2pd_client/SAM.h \
  147. ../../libi2pd_client/SOCKS.h \
  148. ../../libi2pd_client/Websocket.h \
  149. ../../libi2pd_client/WebSocks.h \
  150. ../../daemon/Daemon.h \
  151. ../../daemon/HTTPServer.h \
  152. ../../daemon/I2PControl.h \
  153. ../../daemon/UPnP.h \
  154. ClientTunnelPane.h \
  155. MainWindowItems.h \
  156. ServerTunnelPane.h \
  157. SignatureTypeComboboxFactory.h \
  158. TunnelConfig.h \
  159. TunnelPane.h \
  160. TunnelsPageUpdateListener.h \
  161. textbrowsertweaked1.h \
  162. pagewithbackbutton.h \
  163. widgetlock.h \
  164. widgetlockregistry.h \
  165. i2pd.rc \
  166. logviewermanager.h
  167. INCLUDEPATH += ../../libi2pd
  168. INCLUDEPATH += ../../libi2pd_client
  169. INCLUDEPATH += ../../daemon
  170. INCLUDEPATH += .
  171. FORMS += mainwindow.ui \
  172. tunnelform.ui \
  173. statusbuttons.ui \
  174. routercommandswidget.ui \
  175. generalsettingswidget.ui
  176. LIBS += -lz
  177. macx {
  178. message("using mac os x target")
  179. BREWROOT=/usr/local
  180. BOOSTROOT=$$BREWROOT/opt/boost
  181. SSLROOT=$$BREWROOT/opt/libressl
  182. UPNPROOT=$$BREWROOT/opt/miniupnpc
  183. INCLUDEPATH += $$BOOSTROOT/include
  184. INCLUDEPATH += $$SSLROOT/include
  185. INCLUDEPATH += $$UPNPROOT/include
  186. LIBS += $$SSLROOT/lib/libcrypto.a
  187. LIBS += $$SSLROOT/lib/libssl.a
  188. LIBS += $$BOOSTROOT/lib/libboost_system.a
  189. LIBS += $$BOOSTROOT/lib/libboost_date_time.a
  190. LIBS += $$BOOSTROOT/lib/libboost_filesystem.a
  191. LIBS += $$BOOSTROOT/lib/libboost_program_options.a
  192. LIBS += $$UPNPROOT/lib/libminiupnpc.a
  193. }
  194. linux:!android {
  195. message("Using Linux settings")
  196. LIBS += -lcrypto -lssl -lboost_system -lboost_date_time -lboost_filesystem -lboost_program_options -lpthread -lminiupnpc
  197. }
  198. windows {
  199. message("Using Windows settings")
  200. RC_FILE = i2pd.rc
  201. DEFINES += BOOST_USE_WINDOWS_H WINDOWS _WINDOWS WIN32_LEAN_AND_MEAN MINIUPNP_STATICLIB
  202. DEFINES -= UNICODE _UNICODE
  203. BOOST_SUFFIX = -mt
  204. QMAKE_CXXFLAGS_RELEASE = -Os
  205. QMAKE_LFLAGS = -Wl,-Bstatic -static-libgcc -static-libstdc++ -mwindows
  206. #linker's -s means "strip"
  207. QMAKE_LFLAGS_RELEASE += -s
  208. LIBS = -lminiupnpc \
  209. -lboost_system$$BOOST_SUFFIX \
  210. -lboost_date_time$$BOOST_SUFFIX \
  211. -lboost_filesystem$$BOOST_SUFFIX \
  212. -lboost_program_options$$BOOST_SUFFIX \
  213. -lssl \
  214. -lcrypto \
  215. -lz \
  216. -lwsock32 \
  217. -lws2_32 \
  218. -lgdi32 \
  219. -liphlpapi \
  220. -lstdc++ \
  221. -lpthread
  222. }
  223. !android:!symbian:!maemo5:!simulator {
  224. message("Build with a system tray icon")
  225. # see also http://doc.qt.io/qt-4.8/qt-desktop-systray-systray-pro.html for example on wince*
  226. #sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS i2pd_qt.pro resources images
  227. RESOURCES = i2pd.qrc
  228. QT += xml
  229. #INSTALLS += sources
  230. }