]>
Commit | Line | Data |
---|---|---|
dee632cc | 1 | include Makefile.include |
eb12a14d LD |
2 | |
3 | AM_CPPFLAGS += -I$(top_srcdir)/src/leveldb/helpers/memenv \ | |
4 | -I$(builddir) | |
35b8af92 | 5 | |
0b47fe6b | 6 | noinst_LIBRARIES = libbitcoin_server.a libbitcoin_common.a libbitcoin_cli.a |
4f9e993b WL |
7 | if ENABLE_WALLET |
8 | noinst_LIBRARIES += libbitcoin_wallet.a | |
9 | endif | |
35b8af92 | 10 | |
2a03a390 | 11 | bin_PROGRAMS = bitcoind bitcoin-cli |
35b8af92 CF |
12 | |
13 | SUBDIRS = . $(BUILD_QT) $(BUILD_TEST) | |
14 | DIST_SUBDIRS = . qt test | |
15 | .PHONY: FORCE | |
16 | # bitcoin core # | |
17 | BITCOIN_CORE_H = addrman.h alert.h allocators.h base58.h bignum.h \ | |
fb78cc23 WL |
18 | rpcclient.h \ |
19 | rpcprotocol.h \ | |
20 | rpcserver.h \ | |
21 | bloom.h chainparams.h checkpoints.h checkqueue.h \ | |
6a86c24d | 22 | clientversion.h coincontrol.h compat.h core.h coins.h crypter.h db.h hash.h init.h \ |
b64187d0 | 23 | key.h keystore.h leveldbwrapper.h limitedmap.h main.h miner.h mruset.h \ |
51ed9ec9 | 24 | netbase.h net.h noui.h protocol.h script.h serialize.h sync.h threadsafety.h \ |
319b1160 | 25 | txdb.h txmempool.h ui_interface.h uint256.h util.h version.h walletdb.h wallet.h |
35b8af92 CF |
26 | |
27 | JSON_H = json/json_spirit.h json/json_spirit_error_position.h \ | |
28 | json/json_spirit_reader.h json/json_spirit_reader_template.h \ | |
29 | json/json_spirit_stream_reader.h json/json_spirit_utils.h \ | |
30 | json/json_spirit_value.h json/json_spirit_writer.h \ | |
31 | json/json_spirit_writer_template.h | |
32 | ||
33 | obj/build.h: FORCE | |
34 | @$(MKDIR_P) $(abs_top_builddir)/src/obj | |
35 | @$(top_srcdir)/share/genbuild.sh $(abs_top_builddir)/src/obj/build.h \ | |
36 | $(abs_top_srcdir) | |
37 | version.o: obj/build.h | |
38 | ||
4f9e993b WL |
39 | libbitcoin_server_a_SOURCES = \ |
40 | addrman.cpp \ | |
41 | alert.cpp \ | |
fb78cc23 WL |
42 | rpcserver.cpp \ |
43 | bloom.cpp \ | |
4f9e993b WL |
44 | chainparams.cpp \ |
45 | checkpoints.cpp \ | |
46 | coins.cpp \ | |
47 | init.cpp \ | |
48 | keystore.cpp \ | |
49 | leveldbwrapper.cpp \ | |
50 | main.cpp \ | |
51 | net.cpp \ | |
52 | noui.cpp \ | |
53 | rpcblockchain.cpp \ | |
54 | rpcnet.cpp \ | |
55 | rpcrawtransaction.cpp \ | |
56 | txdb.cpp \ | |
57 | txmempool.cpp \ | |
58 | $(JSON_H) \ | |
59 | $(BITCOIN_CORE_H) | |
60 | ||
61 | libbitcoin_wallet_a_SOURCES = \ | |
62 | db.cpp \ | |
829c9203 | 63 | crypter.cpp \ |
4f9e993b WL |
64 | miner.cpp \ |
65 | rpcdump.cpp \ | |
66 | rpcmining.cpp \ | |
67 | rpcwallet.cpp \ | |
68 | wallet.cpp \ | |
69 | walletdb.cpp \ | |
0b47fe6b WL |
70 | $(BITCOIN_CORE_H) |
71 | ||
72 | libbitcoin_common_a_SOURCES = \ | |
73 | allocators.cpp \ | |
74 | chainparams.cpp \ | |
75 | core.cpp \ | |
76 | hash.cpp \ | |
77 | key.cpp \ | |
78 | netbase.cpp \ | |
79 | protocol.cpp \ | |
80 | rpcprotocol.cpp \ | |
81 | script.cpp \ | |
82 | sync.cpp \ | |
83 | util.cpp \ | |
84 | version.cpp \ | |
35b8af92 CF |
85 | $(BITCOIN_CORE_H) |
86 | ||
0b47fe6b WL |
87 | libbitcoin_cli_a_SOURCES = \ |
88 | rpcclient.cpp \ | |
89 | $(BITCOIN_CORE_H) | |
90 | ||
91 | nodist_libbitcoin_common_a_SOURCES = $(top_srcdir)/src/obj/build.h | |
35b8af92 CF |
92 | # |
93 | ||
94 | # bitcoind binary # | |
0b47fe6b | 95 | bitcoind_LDADD = libbitcoin_server.a libbitcoin_cli.a libbitcoin_common.a leveldb/libleveldb.a leveldb/libmemenv.a \ |
35b8af92 | 96 | $(BOOST_LIBS) |
4f9e993b WL |
97 | if ENABLE_WALLET |
98 | bitcoind_LDADD += libbitcoin_wallet.a | |
99 | endif | |
35b8af92 CF |
100 | bitcoind_SOURCES = bitcoind.cpp |
101 | # | |
102 | ||
dee632cc | 103 | if TARGET_WINDOWS |
cbf87fc4 | 104 | bitcoind_SOURCES += bitcoind-res.rc |
dee632cc CF |
105 | endif |
106 | ||
941dba17 LD |
107 | AM_CPPFLAGS += $(BDB_CPPFLAGS) |
108 | bitcoind_LDADD += $(BDB_LIBS) | |
109 | ||
2a03a390 | 110 | # bitcoin-cli binary # |
0b47fe6b | 111 | bitcoin_cli_LDADD = libbitcoin_cli.a libbitcoin_common.a $(BOOST_LIBS) |
2a03a390 WL |
112 | bitcoin_cli_SOURCES = bitcoin-cli.cpp |
113 | # | |
114 | ||
115 | if TARGET_WINDOWS | |
116 | bitcoin_cli_SOURCES += bitcoin-cli-res.rc | |
117 | endif | |
2a03a390 | 118 | |
cae63be6 | 119 | leveldb/libleveldb.a: leveldb/libmemenv.a |
35b8af92 | 120 | |
cae63be6 CF |
121 | leveldb/%.a: |
122 | @echo "Building LevelDB ..." && $(MAKE) -C $(@D) $(@F) CXX="$(CXX)" \ | |
123 | CC="$(CC)" PLATFORM=$(TARGET_OS) AR="$(AR)" $(LEVELDB_TARGET_FLAGS) \ | |
124 | OPT="$(CXXFLAGS) $(CPPFLAGS)" | |
35b8af92 | 125 | |
0b47fe6b | 126 | qt/bitcoinstrings.cpp: $(libbitcoin_server_a_SOURCES) $(libbitcoin_common_a_SOURCES) $(libbitcoin_cli_a_SOURCES) |
21ffa3ce CF |
127 | @test -n $(XGETTEXT) || echo "xgettext is required for updating translations" |
128 | @cd $(top_srcdir); XGETTEXT=$(XGETTEXT) share/qt/extract_strings_qt.py | |
129 | ||
35b8af92 CF |
130 | CLEANFILES = leveldb/libleveldb.a leveldb/libmemenv.a *.gcda *.gcno |
131 | ||
132 | DISTCLEANFILES = obj/build.h | |
133 | ||
134 | EXTRA_DIST = leveldb Makefile.include | |
135 | ||
136 | clean-local: | |
137 | -$(MAKE) -C leveldb clean | |
26d1b65c | 138 | rm -f leveldb/*/*.gcno leveldb/helpers/memenv/*.gcno |