]>
Commit | Line | Data |
---|---|---|
4300876c | 1 | DIST_SUBDIRS = secp256k1 |
575e70c0 | 2 | AM_LDFLAGS = $(PTHREAD_CFLAGS) $(LIBTOOL_LDFLAGS) |
eb12a14d | 3 | |
35b8af92 | 4 | |
6b9f0d55 | 5 | if EMBEDDED_LEVELDB |
56c157d5 CF |
6 | LEVELDB_CPPFLAGS += -I$(srcdir)/leveldb/include |
7 | LEVELDB_CPPFLAGS += -I$(srcdir)/leveldb/helpers/memenv | |
8 | LIBLEVELDB += $(builddir)/leveldb/libleveldb.a | |
9 | LIBMEMENV += $(builddir)/leveldb/libmemenv.a | |
6b9f0d55 CF |
10 | |
11 | # NOTE: This dependency is not strictly necessary, but without it make may try to build both in parallel, which breaks the LevelDB build system in a race | |
12 | $(LIBLEVELDB): $(LIBMEMENV) | |
13 | ||
14 | $(LIBLEVELDB) $(LIBMEMENV): | |
15 | @echo "Building LevelDB ..." && $(MAKE) -C $(@D) $(@F) CXX="$(CXX)" \ | |
16 | CC="$(CC)" PLATFORM=$(TARGET_OS) AR="$(AR)" $(LEVELDB_TARGET_FLAGS) \ | |
ff7fe8b1 | 17 | OPT="$(CXXFLAGS) $(CPPFLAGS) -D__STDC_LIMIT_MACROS" |
6b9f0d55 CF |
18 | endif |
19 | ||
54372482 | 20 | BITCOIN_CONFIG_INCLUDES=-I$(builddir)/config |
6b099402 | 21 | BITCOIN_INCLUDES=-I$(builddir) -I$(builddir)/obj $(BOOST_CPPFLAGS) $(LEVELDB_CPPFLAGS) $(CRYPTO_CFLAGS) $(SSL_CFLAGS) |
f4d81129 | 22 | |
55668266 | 23 | BITCOIN_INCLUDES += -I$(srcdir)/secp256k1/include |
55668266 | 24 | |
84ce18ca WL |
25 | LIBBITCOIN_SERVER=libbitcoin_server.a |
26 | LIBBITCOIN_WALLET=libbitcoin_wallet.a | |
27 | LIBBITCOIN_COMMON=libbitcoin_common.a | |
28 | LIBBITCOIN_CLI=libbitcoin_cli.a | |
29 | LIBBITCOIN_UTIL=libbitcoin_util.a | |
30 | LIBBITCOIN_CRYPTO=crypto/libbitcoin_crypto.a | |
cbe39a38 | 31 | LIBBITCOIN_UNIVALUE=univalue/libbitcoin_univalue.a |
84ce18ca | 32 | LIBBITCOINQT=qt/libbitcoinqt.a |
07a99017 | 33 | LIBSECP256K1=secp256k1/libsecp256k1.la |
1785bdb9 | 34 | LIBZCASH=libzcash.a |
07a99017 PW |
35 | |
36 | $(LIBSECP256K1): $(wildcard secp256k1/src/*) $(wildcard secp256k1/include/*) | |
4300876c | 37 | $(AM_V_at)$(MAKE) $(AM_MAKEFLAGS) -C $(@D) $(@F) |
84ce18ca | 38 | |
071473c5 | 39 | # Make is not made aware of per-object dependencies to avoid limiting building parallelization |
40 | # But to build the less dependent modules first, we manually select their order here: | |
fe925e22 | 41 | EXTRA_LIBRARIES = \ |
071473c5 | 42 | crypto/libbitcoin_crypto.a \ |
84ce18ca | 43 | libbitcoin_util.a \ |
071473c5 | 44 | libbitcoin_common.a \ |
cbe39a38 | 45 | univalue/libbitcoin_univalue.a \ |
071473c5 | 46 | libbitcoin_server.a \ |
e463edc1 | 47 | libbitcoin_cli.a \ |
1785bdb9 | 48 | libzcash.a |
4f9e993b | 49 | if ENABLE_WALLET |
f4d81129 | 50 | BITCOIN_INCLUDES += $(BDB_CPPFLAGS) |
fe925e22 | 51 | EXTRA_LIBRARIES += libbitcoin_wallet.a |
4f9e993b | 52 | endif |
35b8af92 | 53 | |
cdd36c6c | 54 | if BUILD_BITCOIN_LIBS |
08d6b02d JG |
55 | lib_LTLIBRARIES = libzcashconsensus.la |
56 | LIBZCASH_CONSENSUS=libzcashconsensus.la | |
cdd36c6c | 57 | else |
08d6b02d | 58 | LIBZCASH_CONSENSUS= |
cdd36c6c | 59 | endif |
2cf5f16c | 60 | |
f930341d | 61 | bin_PROGRAMS = |
8e0fc390 | 62 | noinst_PROGRAMS = |
65e8ba4d | 63 | TESTS = |
f930341d LD |
64 | |
65 | if BUILD_BITCOIND | |
8a183335 | 66 | bin_PROGRAMS += zcashd |
f930341d LD |
67 | endif |
68 | ||
c101c769 | 69 | if BUILD_BITCOIN_UTILS |
66a89c08 | 70 | bin_PROGRAMS += zcash-cli zcash-tx |
f930341d | 71 | endif |
35b8af92 | 72 | |
1785bdb9 | 73 | LIBZCASH_H = \ |
c06664fb | 74 | zcash/IncrementalMerkleTree.hpp \ |
6c36a9fe | 75 | zcash/NoteEncryption.hpp \ |
369df065 SB |
76 | zcash/Address.hpp \ |
77 | zcash/JoinSplit.hpp \ | |
78 | zcash/Note.hpp \ | |
81469bbb | 79 | zcash/prf.h \ |
9ffe371d | 80 | zcash/Proof.hpp \ |
cc552e4d KG |
81 | zcash/util.h \ |
82 | zcash/Zcash.h | |
e463edc1 | 83 | |
a5e918a0 | 84 | .PHONY: FORCE check-symbols check-security |
35b8af92 | 85 | # bitcoin core # |
5a407bd0 WL |
86 | BITCOIN_CORE_H = \ |
87 | addrman.h \ | |
88 | alert.h \ | |
a372168e | 89 | amount.h \ |
bfc60703 | 90 | arith_uint256.h \ |
fc72c078 S |
91 | asyncrpcoperation.h \ |
92 | asyncrpcqueue.h \ | |
7cd0af7c | 93 | base58.h \ |
5a407bd0 | 94 | bloom.h \ |
e8b5f0d5 | 95 | chain.h \ |
bfc60703 | 96 | chainparams.h \ |
ff734e90 | 97 | chainparamsbase.h \ |
a60120e9 | 98 | chainparamsseeds.h \ |
5a407bd0 WL |
99 | checkpoints.h \ |
100 | checkqueue.h \ | |
101 | clientversion.h \ | |
102 | coincontrol.h \ | |
103 | coins.h \ | |
104 | compat.h \ | |
ff734e90 JT |
105 | compat/byteswap.h \ |
106 | compat/endian.h \ | |
107 | compat/sanity.h \ | |
561e9e9d | 108 | compressor.h \ |
691161d4 | 109 | consensus/consensus.h \ |
bd006110 | 110 | consensus/params.h \ |
da29ecbc | 111 | consensus/validation.h \ |
ae775b5b | 112 | core_io.h \ |
900078ae | 113 | eccryptoverify.h \ |
50f71cd5 | 114 | ecwrapper.h \ |
5a407bd0 WL |
115 | hash.h \ |
116 | init.h \ | |
117 | key.h \ | |
118 | keystore.h \ | |
119 | leveldbwrapper.h \ | |
120 | limitedmap.h \ | |
121 | main.h \ | |
540629c6 | 122 | memusage.h \ |
afd4b94b | 123 | merkleblock.h \ |
a6df7ab5 | 124 | metrics.h \ |
5a407bd0 WL |
125 | miner.h \ |
126 | mruset.h \ | |
5a407bd0 | 127 | net.h \ |
ff734e90 | 128 | netbase.h \ |
5a407bd0 | 129 | noui.h \ |
b649e039 | 130 | policy/fees.h \ |
df852d2b | 131 | pow.h \ |
bfc60703 WL |
132 | primitives/block.h \ |
133 | primitives/transaction.h \ | |
5a407bd0 | 134 | protocol.h \ |
d2e74c55 | 135 | pubkey.h \ |
6354935c | 136 | random.h \ |
6b51b9b1 | 137 | reverselock.h \ |
fb78cc23 WL |
138 | rpcclient.h \ |
139 | rpcprotocol.h \ | |
140 | rpcserver.h \ | |
928b950e | 141 | scheduler.h \ |
611116d4 | 142 | script/interpreter.h \ |
cbd22a50 | 143 | script/script.h \ |
ff734e90 | 144 | script/script_error.h \ |
5c1e798a | 145 | script/sigcache.h \ |
e088d65a | 146 | script/sign.h \ |
c4408a6c | 147 | script/standard.h \ |
5a407bd0 | 148 | serialize.h \ |
fa736190 | 149 | streams.h \ |
d7d187e8 CF |
150 | support/allocators/secure.h \ |
151 | support/allocators/zeroafterfree.h \ | |
1630219d | 152 | support/cleanse.h \ |
d7d187e8 | 153 | support/pagelocker.h \ |
5a407bd0 WL |
154 | sync.h \ |
155 | threadsafety.h \ | |
14f888ca | 156 | timedata.h \ |
b77dfdc9 | 157 | tinyformat.h \ |
5a407bd0 WL |
158 | txdb.h \ |
159 | txmempool.h \ | |
160 | ui_interface.h \ | |
161 | uint256.h \ | |
defe37a6 | 162 | uint252.h \ |
999a2ab4 | 163 | undo.h \ |
5a407bd0 | 164 | util.h \ |
ad49c256 | 165 | utilmoneystr.h \ |
bfc60703 | 166 | utilstrencodings.h \ |
ad49c256 | 167 | utiltime.h \ |
26c16d9d | 168 | validationinterface.h \ |
5a407bd0 | 169 | version.h \ |
fc72c078 | 170 | wallet/asyncrpcoperation_sendmany.h \ |
a354a59f | 171 | wallet/crypter.h \ |
ff734e90 | 172 | wallet/db.h \ |
50c72f23 JS |
173 | wallet/wallet.h \ |
174 | wallet/wallet_ismine.h \ | |
ff734e90 | 175 | wallet/walletdb.h |
5a407bd0 WL |
176 | |
177 | JSON_H = \ | |
178 | json/json_spirit.h \ | |
179 | json/json_spirit_error_position.h \ | |
180 | json/json_spirit_reader.h \ | |
181 | json/json_spirit_reader_template.h \ | |
182 | json/json_spirit_stream_reader.h \ | |
183 | json/json_spirit_utils.h \ | |
184 | json/json_spirit_value.h \ | |
185 | json/json_spirit_writer.h \ | |
35b8af92 CF |
186 | json/json_spirit_writer_template.h |
187 | ||
188 | obj/build.h: FORCE | |
56c157d5 | 189 | @$(MKDIR_P) $(builddir)/obj |
35b8af92 CF |
190 | @$(top_srcdir)/share/genbuild.sh $(abs_top_builddir)/src/obj/build.h \ |
191 | $(abs_top_srcdir) | |
71697f97 | 192 | libbitcoin_util_a-clientversion.$(OBJEXT): obj/build.h |
35b8af92 | 193 | |
84ce18ca | 194 | # server: shared between bitcoind and bitcoin-qt |
9f7f504e | 195 | libbitcoin_server_a_CPPFLAGS = $(BITCOIN_INCLUDES) $(MINIUPNPC_CPPFLAGS) |
4f9e993b | 196 | libbitcoin_server_a_SOURCES = \ |
b39e1bdb | 197 | sendalert.cpp \ |
4f9e993b WL |
198 | addrman.cpp \ |
199 | alert.cpp \ | |
7553b173 | 200 | alertkeys.h \ |
fc72c078 S |
201 | asyncrpcoperation.cpp \ |
202 | asyncrpcqueue.cpp \ | |
fb78cc23 | 203 | bloom.cpp \ |
e8b5f0d5 | 204 | chain.cpp \ |
4f9e993b | 205 | checkpoints.cpp \ |
4f9e993b | 206 | init.cpp \ |
4f9e993b WL |
207 | leveldbwrapper.cpp \ |
208 | main.cpp \ | |
afd4b94b | 209 | merkleblock.cpp \ |
a6df7ab5 | 210 | metrics.cpp \ |
4a85e067 | 211 | miner.cpp \ |
4f9e993b WL |
212 | net.cpp \ |
213 | noui.cpp \ | |
b649e039 | 214 | policy/fees.cpp \ |
df852d2b | 215 | pow.cpp \ |
e2655e0a | 216 | rest.cpp \ |
4f9e993b | 217 | rpcblockchain.cpp \ |
4a85e067 | 218 | rpcmining.cpp \ |
652e1569 | 219 | rpcmisc.cpp \ |
4f9e993b WL |
220 | rpcnet.cpp \ |
221 | rpcrawtransaction.cpp \ | |
dfd39962 | 222 | rpcserver.cpp \ |
bfe029fe | 223 | script/sigcache.cpp \ |
14f888ca | 224 | timedata.cpp \ |
4f9e993b WL |
225 | txdb.cpp \ |
226 | txmempool.cpp \ | |
26c16d9d | 227 | validationinterface.cpp \ |
4f9e993b | 228 | $(JSON_H) \ |
e463edc1 | 229 | $(BITCOIN_CORE_H) \ |
1785bdb9 | 230 | $(LIBZCASH_H) |
4f9e993b | 231 | |
84ce18ca WL |
232 | # wallet: shared between bitcoind and bitcoin-qt, but only linked |
233 | # when wallet enabled | |
f4d81129 | 234 | libbitcoin_wallet_a_CPPFLAGS = $(BITCOIN_INCLUDES) |
4f9e993b | 235 | libbitcoin_wallet_a_SOURCES = \ |
0bb3d40f JG |
236 | utiltest.cpp \ |
237 | utiltest.h \ | |
6962bb3d | 238 | zcbenchmarks.cpp \ |
2f3ecb44 | 239 | zcbenchmarks.h \ |
fc72c078 | 240 | wallet/asyncrpcoperation_sendmany.cpp \ |
a354a59f | 241 | wallet/crypter.cpp \ |
50c72f23 | 242 | wallet/db.cpp \ |
50c72f23 JS |
243 | wallet/rpcdump.cpp \ |
244 | wallet/rpcwallet.cpp \ | |
245 | wallet/wallet.cpp \ | |
246 | wallet/wallet_ismine.cpp \ | |
247 | wallet/walletdb.cpp \ | |
e463edc1 | 248 | $(BITCOIN_CORE_H) \ |
1785bdb9 | 249 | $(LIBZCASH_H) |
0b47fe6b | 250 | |
c7aaab7a DH |
251 | EQUIHASH_TROMP_SOURCES = \ |
252 | pow/tromp/equi_miner.h \ | |
253 | pow/tromp/equi.h \ | |
254 | pow/tromp/osx_barrier.h | |
255 | ||
84ce18ca | 256 | # crypto primitives library |
c7aaab7a | 257 | crypto_libbitcoin_crypto_a_CPPFLAGS = $(BITCOIN_CONFIG_INCLUDES) -DEQUIHASH_TROMP_ATOMIC |
4791b99e | 258 | crypto_libbitcoin_crypto_a_SOURCES = \ |
4791b99e | 259 | crypto/common.h \ |
6d25662f JG |
260 | crypto/equihash.cpp \ |
261 | crypto/equihash.h \ | |
60157808 | 262 | crypto/equihash.tcc \ |
ff734e90 | 263 | crypto/hmac_sha256.cpp \ |
a8f5087e | 264 | crypto/hmac_sha256.h \ |
ff734e90 | 265 | crypto/hmac_sha512.cpp \ |
36fa4a78 | 266 | crypto/hmac_sha512.h \ |
ff734e90 JT |
267 | crypto/ripemd160.cpp \ |
268 | crypto/ripemd160.h \ | |
269 | crypto/sha1.cpp \ | |
4791b99e | 270 | crypto/sha1.h \ |
ff734e90 JT |
271 | crypto/sha256.cpp \ |
272 | crypto/sha256.h \ | |
273 | crypto/sha512.cpp \ | |
c7aaab7a DH |
274 | crypto/sha512.h \ |
275 | ${EQUIHASH_TROMP_SOURCES} | |
4791b99e | 276 | |
cbe39a38 JG |
277 | # univalue JSON library |
278 | univalue_libbitcoin_univalue_a_SOURCES = \ | |
279 | univalue/univalue.cpp \ | |
ff734e90 | 280 | univalue/univalue.h \ |
3cceba7a | 281 | univalue/univalue_escapes.h \ |
ff734e90 JT |
282 | univalue/univalue_read.cpp \ |
283 | univalue/univalue_write.cpp | |
cbe39a38 | 284 | |
84ce18ca | 285 | # common: shared between bitcoind, and bitcoin-qt and non-server tools |
f4d81129 | 286 | libbitcoin_common_a_CPPFLAGS = $(BITCOIN_INCLUDES) |
0b47fe6b | 287 | libbitcoin_common_a_SOURCES = \ |
eda37330 | 288 | amount.cpp \ |
ff734e90 | 289 | arith_uint256.cpp \ |
75c82d49 | 290 | base58.cpp \ |
0b47fe6b | 291 | chainparams.cpp \ |
75c82d49 | 292 | coins.cpp \ |
561e9e9d | 293 | compressor.cpp \ |
ae775b5b JG |
294 | core_read.cpp \ |
295 | core_write.cpp \ | |
900078ae | 296 | eccryptoverify.cpp \ |
50f71cd5 | 297 | ecwrapper.cpp \ |
0b47fe6b WL |
298 | hash.cpp \ |
299 | key.cpp \ | |
75c82d49 | 300 | keystore.cpp \ |
0b47fe6b | 301 | netbase.cpp \ |
ff734e90 JT |
302 | primitives/block.cpp \ |
303 | primitives/transaction.cpp \ | |
0b47fe6b | 304 | protocol.cpp \ |
d2e74c55 | 305 | pubkey.cpp \ |
928b950e | 306 | scheduler.cpp \ |
611116d4 | 307 | script/interpreter.cpp \ |
cbd22a50 | 308 | script/script.cpp \ |
ff734e90 | 309 | script/script_error.cpp \ |
e088d65a | 310 | script/sign.cpp \ |
c4408a6c | 311 | script/standard.cpp \ |
e463edc1 | 312 | $(BITCOIN_CORE_H) \ |
1785bdb9 | 313 | $(LIBZCASH_H) |
84ce18ca WL |
314 | |
315 | # util: shared between all executables. | |
316 | # This library *must* be included to make sure that the glibc | |
317 | # backward-compatibility objects and their sanity checks are linked. | |
318 | libbitcoin_util_a_CPPFLAGS = $(BITCOIN_INCLUDES) | |
319 | libbitcoin_util_a_SOURCES = \ | |
d7d187e8 | 320 | support/pagelocker.cpp \ |
84ce18ca | 321 | chainparamsbase.cpp \ |
71697f97 | 322 | clientversion.cpp \ |
bfc60703 WL |
323 | compat/glibc_sanity.cpp \ |
324 | compat/glibcxx_sanity.cpp \ | |
325 | compat/strnlen.cpp \ | |
6354935c | 326 | random.cpp \ |
84ce18ca | 327 | rpcprotocol.cpp \ |
1630219d | 328 | support/cleanse.cpp \ |
0b47fe6b | 329 | sync.cpp \ |
de79aaa7 | 330 | uint256.cpp \ |
0b47fe6b | 331 | util.cpp \ |
ad49c256 | 332 | utilmoneystr.cpp \ |
bfc60703 | 333 | utilstrencodings.cpp \ |
ad49c256 | 334 | utiltime.cpp \ |
e463edc1 | 335 | $(BITCOIN_CORE_H) \ |
1785bdb9 | 336 | $(LIBZCASH_H) |
35b8af92 | 337 | |
d5aab704 | 338 | if GLIBC_BACK_COMPAT |
84ce18ca | 339 | libbitcoin_util_a_SOURCES += compat/glibc_compat.cpp |
d5aab704 CF |
340 | endif |
341 | ||
84ce18ca | 342 | # cli: shared between bitcoin-cli and bitcoin-qt |
a65668dd | 343 | libbitcoin_cli_a_CPPFLAGS = $(BITCOIN_INCLUDES) |
0b47fe6b WL |
344 | libbitcoin_cli_a_SOURCES = \ |
345 | rpcclient.cpp \ | |
e463edc1 | 346 | $(BITCOIN_CORE_H) \ |
1785bdb9 | 347 | $(LIBZCASH_H) |
0b47fe6b | 348 | |
84ce18ca | 349 | nodist_libbitcoin_util_a_SOURCES = $(srcdir)/obj/build.h |
35b8af92 CF |
350 | # |
351 | ||
352 | # bitcoind binary # | |
8a183335 TH |
353 | zcashd_SOURCES = bitcoind.cpp |
354 | zcashd_CPPFLAGS = $(BITCOIN_INCLUDES) | |
355 | zcashd_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) | |
72ac792b | 356 | |
357 | if TARGET_WINDOWS | |
8a183335 | 358 | zcashd_SOURCES += bitcoind-res.rc |
72ac792b | 359 | endif |
360 | ||
8a183335 | 361 | zcashd_LDADD = \ |
84ce18ca WL |
362 | $(LIBBITCOIN_SERVER) \ |
363 | $(LIBBITCOIN_COMMON) \ | |
cbe39a38 | 364 | $(LIBBITCOIN_UNIVALUE) \ |
84ce18ca WL |
365 | $(LIBBITCOIN_UTIL) \ |
366 | $(LIBBITCOIN_CRYPTO) \ | |
1785bdb9 | 367 | $(LIBZCASH) \ |
4a290b52 | 368 | $(LIBLEVELDB) \ |
07a99017 PW |
369 | $(LIBMEMENV) \ |
370 | $(LIBSECP256K1) | |
55668266 | 371 | |
4f9e993b | 372 | if ENABLE_WALLET |
8a183335 | 373 | zcashd_LDADD += libbitcoin_wallet.a |
4f9e993b | 374 | endif |
72ac792b | 375 | |
c4da0970 NW |
376 | zcashd_LDADD += \ |
377 | $(BOOST_LIBS) \ | |
378 | $(BDB_LIBS) \ | |
379 | $(SSL_LIBS) \ | |
380 | $(CRYPTO_LIBS) \ | |
381 | $(MINIUPNPC_LIBS) \ | |
1785bdb9 | 382 | $(LIBZCASH) \ |
d3612b1c | 383 | $(LIBBITCOIN_CRYPTO) \ |
1785bdb9 | 384 | $(LIBZCASH_LIBS) |
35b8af92 CF |
385 | # |
386 | ||
72ac792b | 387 | # bitcoin-cli binary # |
8a183335 TH |
388 | zcash_cli_SOURCES = bitcoin-cli.cpp |
389 | zcash_cli_CPPFLAGS = $(BITCOIN_INCLUDES) | |
390 | zcash_cli_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) | |
72ac792b | 391 | |
dee632cc | 392 | if TARGET_WINDOWS |
8a183335 | 393 | zcash_cli_SOURCES += bitcoin-cli-res.rc |
dee632cc CF |
394 | endif |
395 | ||
8a183335 | 396 | zcash_cli_LDADD = \ |
84ce18ca | 397 | $(LIBBITCOIN_CLI) \ |
c4da0970 NW |
398 | $(LIBBITCOIN_UTIL) \ |
399 | $(BOOST_LIBS) \ | |
400 | $(SSL_LIBS) \ | |
401 | $(CRYPTO_LIBS) \ | |
1785bdb9 | 402 | $(LIBZCASH) \ |
d3612b1c | 403 | $(LIBBITCOIN_CRYPTO) \ |
1785bdb9 | 404 | $(LIBZCASH_LIBS) |
2a03a390 WL |
405 | # |
406 | ||
66a89c08 JG |
407 | # zcash-tx binary # |
408 | zcash_tx_SOURCES = bitcoin-tx.cpp | |
409 | zcash_tx_CPPFLAGS = $(BITCOIN_INCLUDES) | |
410 | zcash_tx_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS) | |
72ac792b | 411 | |
cc24610f | 412 | if TARGET_WINDOWS |
66a89c08 | 413 | zcash_tx_SOURCES += bitcoin-tx-res.rc |
cc24610f LD |
414 | endif |
415 | ||
66a89c08 JG |
416 | # FIXME: Is libzcash needed for zcash_tx? |
417 | zcash_tx_LDADD = \ | |
cbe39a38 JG |
418 | $(LIBBITCOIN_UNIVALUE) \ |
419 | $(LIBBITCOIN_COMMON) \ | |
420 | $(LIBBITCOIN_UTIL) \ | |
c4da0970 | 421 | $(LIBSECP256K1) \ |
1785bdb9 | 422 | $(LIBZCASH) \ |
d3612b1c | 423 | $(LIBBITCOIN_CRYPTO) \ |
1785bdb9 | 424 | $(LIBZCASH_LIBS) |
28d412ff | 425 | |
66a89c08 | 426 | zcash_tx_LDADD += $(BOOST_LIBS) $(CRYPTO_LIBS) |
cbe39a38 | 427 | # |
2a03a390 | 428 | |
c9c4611d | 429 | # zcash protocol primitives # |
1785bdb9 | 430 | libzcash_a_SOURCES = \ |
e1ff849d | 431 | zcash/IncrementalMerkleTree.cpp \ |
6c36a9fe | 432 | zcash/NoteEncryption.cpp \ |
369df065 SB |
433 | zcash/Address.cpp \ |
434 | zcash/JoinSplit.cpp \ | |
f0dab51c | 435 | zcash/Proof.cpp \ |
369df065 | 436 | zcash/Note.cpp \ |
81469bbb | 437 | zcash/prf.cpp \ |
58d09f27 KG |
438 | zcash/util.cpp \ |
439 | zcash/circuit/commitment.tcc \ | |
440 | zcash/circuit/gadget.tcc \ | |
441 | zcash/circuit/merkle.tcc \ | |
442 | zcash/circuit/note.tcc \ | |
443 | zcash/circuit/prfs.tcc \ | |
444 | zcash/circuit/utils.tcc | |
e463edc1 | 445 | |
f5d3d420 TH |
446 | libzcash_a_CPPFLAGS = -DMULTICORE -fopenmp -fPIC -DBINARY_OUTPUT -DCURVE_ALT_BN128 -DBOOST_SPIRIT_THREADSAFE -DHAVE_BUILD_INFO -D__STDC_FORMAT_MACROS $(HARDENED_CPPFLAGS) -pipe -O1 -g -Wstack-protector -fstack-protector-all -fPIE -fvisibility=hidden -DSTATIC $(BITCOIN_INCLUDES) |
447 | ||
448 | libzcash_a_CXXFLAGS = $(HARDENED_CXXFLAGS) -fwrapv -fno-strict-aliasing | |
449 | ||
450 | libzcash_a_LDFLAGS = $(HARDENED_LDFLAGS) | |
e463edc1 | 451 | |
decde386 SB |
452 | libzcash_a_CPPFLAGS += -DMONTGOMERY_OUTPUT |
453 | ||
08d6b02d | 454 | # zcashconsensus library # |
2cf5f16c | 455 | if BUILD_BITCOIN_LIBS |
08d6b02d JG |
456 | include_HEADERS = script/zcashconsensus.h |
457 | libzcashconsensus_la_SOURCES = \ | |
6d25662f | 458 | crypto/equihash.cpp \ |
36fa4a78 | 459 | crypto/hmac_sha512.cpp \ |
bfc60703 | 460 | crypto/ripemd160.cpp \ |
2cf5f16c | 461 | crypto/sha1.cpp \ |
36fa4a78 PW |
462 | crypto/sha256.cpp \ |
463 | crypto/sha512.cpp \ | |
2cf5f16c CF |
464 | eccryptoverify.cpp \ |
465 | ecwrapper.cpp \ | |
466 | hash.cpp \ | |
bfc60703 | 467 | primitives/transaction.cpp \ |
2cf5f16c | 468 | pubkey.cpp \ |
08d6b02d | 469 | script/zcashconsensus.cpp \ |
bfc60703 WL |
470 | script/interpreter.cpp \ |
471 | script/script.cpp \ | |
2cf5f16c CF |
472 | uint256.cpp \ |
473 | utilstrencodings.cpp | |
474 | ||
475 | if GLIBC_BACK_COMPAT | |
08d6b02d | 476 | libzcashconsensus_la_SOURCES += compat/glibc_compat.cpp |
2cf5f16c CF |
477 | endif |
478 | ||
08d6b02d JG |
479 | libzcashconsensus_la_LDFLAGS = -no-undefined $(RELDFLAGS) |
480 | libzcashconsensus_la_LIBADD = $(CRYPTO_LIBS) | |
481 | libzcashconsensus_la_CPPFLAGS = $(CRYPTO_CFLAGS) -I$(builddir)/obj -DBUILD_BITCOIN_INTERNAL | |
72ac792b | 482 | |
cdd36c6c | 483 | endif |
72ac792b | 484 | # |
2cf5f16c | 485 | |
9773b95f | 486 | CLEANFILES = leveldb/libleveldb.a leveldb/libmemenv.a *.gcda *.gcno */*.gcno wallet/*/*.gcno |
35b8af92 CF |
487 | |
488 | DISTCLEANFILES = obj/build.h | |
489 | ||
4ec57478 | 490 | EXTRA_DIST = leveldb |
35b8af92 CF |
491 | |
492 | clean-local: | |
493 | -$(MAKE) -C leveldb clean | |
4300876c | 494 | -$(MAKE) -C secp256k1 clean |
26d1b65c | 495 | rm -f leveldb/*/*.gcno leveldb/helpers/memenv/*.gcno |
54372482 | 496 | -rm -f config.h |
65e8ba4d | 497 | |
6b9f0d55 | 498 | .rc.o: |
70c71c50 | 499 | @test -f $(WINDRES) |
71697f97 | 500 | $(AM_V_GEN) $(WINDRES) -DWINDRES_PREPROC -i $< -o $@ |
6b9f0d55 CF |
501 | |
502 | .mm.o: | |
70c71c50 | 503 | $(AM_V_CXX) $(OBJCXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ |
6b9f0d55 CF |
504 | $(CPPFLAGS) $(AM_CXXFLAGS) $(QT_INCLUDES) $(CXXFLAGS) -c -o $@ $< |
505 | ||
a5e918a0 CF |
506 | check-symbols: $(bin_PROGRAMS) |
507 | if GLIBC_BACK_COMPAT | |
508 | @echo "Checking glibc back compat of [$(bin_PROGRAMS)]..." | |
509 | $(AM_V_at) READELF=$(READELF) CPPFILT=$(CPPFILT) $(top_srcdir)/contrib/devtools/symbol-check.py < $(bin_PROGRAMS) | |
510 | endif | |
511 | ||
56734f4b TH |
512 | check-security: $(bin_PROGRAMS) |
513 | if HARDEN | |
514 | @echo "Checking binary security of [$(bin_PROGRAMS)]..." | |
515 | $(AM_V_at) READELF=$(READELF) OBJDUMP=$(OBJDUMP) $(top_srcdir)/contrib/devtools/security-check.py < $(bin_PROGRAMS) | |
516 | endif | |
517 | ||
6b9f0d55 | 518 | %.pb.cc %.pb.h: %.proto |
70c71c50 CF |
519 | @test -f $(PROTOC) |
520 | $(AM_V_GEN) $(PROTOC) --cpp_out=$(@D) --proto_path=$(abspath $(<D) $<) | |
6b9f0d55 | 521 | |
65e8ba4d CF |
522 | if ENABLE_TESTS |
523 | include Makefile.test.include | |
6bd8e469 | 524 | include Makefile.gtest.include |
65e8ba4d CF |
525 | endif |
526 | ||
527 | if ENABLE_QT | |
528 | include Makefile.qt.include | |
529 | endif | |
530 | ||
531 | if ENABLE_QT_TESTS | |
532 | include Makefile.qttest.include | |
533 | endif | |
6e96cf08 SB |
534 | |
535 | include Makefile.zcash.include |