]> Git Repo - VerusCoin.git/blob - Makefile.am
Remove OSX and Windows files from Makefile + share directory.
[VerusCoin.git] / Makefile.am
1 ACLOCAL_AMFLAGS = -I build-aux/m4
2 SUBDIRS = src
3 if ENABLE_MAN
4 SUBDIRS += doc/man
5 endif
6 .PHONY: deploy FORCE
7
8 GZIP_ENV="-9n"
9
10 if BUILD_BITCOIN_LIBS
11 pkgconfigdir = $(libdir)/pkgconfig
12 pkgconfig_DATA = libzcashconsensus.pc
13 endif
14
15 BITCOIND_BIN=$(top_builddir)/src/$(BITCOIN_DAEMON_NAME)$(EXEEXT)
16 BITCOIN_CLI_BIN=$(top_builddir)/src/$(BITCOIN_CLI_NAME)$(EXEEXT)
17
18 DIST_DOCS = $(wildcard doc/*.md) $(wildcard doc/release-notes/*.md)
19
20 BIN_CHECKS=$(top_srcdir)/contrib/devtools/symbol-check.py \
21            $(top_srcdir)/contrib/devtools/security-check.py
22
23 COVERAGE_INFO = baseline_filtered_combined.info baseline.info \
24   leveldb_baseline.info test_bitcoin_filtered.info total_coverage.info \
25   baseline_filtered.info \
26   leveldb_baseline_filtered.info test_bitcoin_coverage.info test_bitcoin.info \
27   zcash-gtest.info zcash-gtest_filtered.info zcash-gtest_coverage.info
28
29 dist-hook:
30         -$(MAKE) -C $(top_distdir)/src/leveldb clean
31         -$(MAKE) -C $(top_distdir)/src/secp256k1 distclean
32         -$(GIT) archive --format=tar HEAD -- src/clientversion.cpp | $(AMTAR) -C $(top_distdir) -xf -
33
34 distcheck-hook:
35         $(MKDIR_P) $(top_distdir)/_build/src/leveldb
36         cp -rf $(top_srcdir)/src/leveldb/* $(top_distdir)/_build/src/leveldb/
37         -$(MAKE) -C $(top_distdir)/_build/src/leveldb clean
38
39 distcleancheck:
40         @:
41
42 $(if $(findstring src/,$(MAKECMDGOALS)),$(MAKECMDGOALS), none): FORCE
43         $(MAKE) -C src $(patsubst src/%,%,$@)
44
45 $(BITCOIND_BIN): FORCE
46         $(MAKE) -C src $(@F)
47
48 $(BITCOIN_CLI_BIN): FORCE
49         $(MAKE) -C src $(@F)
50
51 if USE_LCOV
52
53 baseline.info:
54         $(LCOV) -c -i -d $(abs_builddir)/src -o $@
55
56 baseline_filtered.info: baseline.info
57         $(LCOV) -r $< "/usr/include/*" \
58                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
59                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
60                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
61                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gtest/*" \
62                       "$(abs_builddir)/src/gtest/*" \
63                       "$(abs_builddir)/src/test/*" \
64                       "$(abs_builddir)/src/wallet/gtest/*" \
65                       "$(abs_builddir)/src/wallet/test/*" \
66                       -o $@
67
68 leveldb_baseline.info: baseline_filtered.info
69         $(LCOV) -c -i -d $(abs_builddir)/src/leveldb -b $(abs_builddir)/src/leveldb -o $@
70
71 leveldb_baseline_filtered.info: leveldb_baseline.info
72         $(LCOV) -r $< "/usr/include/*" \
73                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
74                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
75                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
76                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gtest/*" \
77                       "$(abs_builddir)/src/gtest/*" \
78                       "$(abs_builddir)/src/test/*" \
79                       "$(abs_builddir)/src/wallet/gtest/*" \
80                       "$(abs_builddir)/src/wallet/test/*" \
81                       -o $@
82
83 baseline_filtered_combined.info: leveldb_baseline_filtered.info baseline_filtered.info
84         $(LCOV) -a leveldb_baseline_filtered.info -a baseline_filtered.info -o $@
85
86 test_bitcoin.info: baseline_filtered_combined.info
87         $(MAKE) -C src/ bitcoin_test_check
88         $(LCOV) -c -d $(abs_builddir)/src -t test_bitcoin -o $@
89         $(LCOV) -z -d $(abs_builddir)/src
90         $(LCOV) -z -d $(abs_builddir)/src/leveldb
91
92 test_bitcoin_filtered.info: test_bitcoin.info
93         $(LCOV) -r $< "/usr/include/*" \
94                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
95                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
96                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
97                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gtest/*" \
98                       "$(abs_builddir)/src/gtest/*" \
99                       "$(abs_builddir)/src/test/*" \
100                       "$(abs_builddir)/src/wallet/gtest/*" \
101                       "$(abs_builddir)/src/wallet/test/*" \
102                       -o $@
103
104 zcash-gtest.info: baseline_filtered_combined.info
105         $(MAKE) -C src/ zcash-gtest_check
106         $(LCOV) -c -d $(abs_builddir)/src -t zcash-gtest -o $@
107         $(LCOV) -z -d $(abs_builddir)/src
108         $(LCOV) -z -d $(abs_builddir)/src/leveldb
109
110 zcash-gtest_filtered.info: zcash-gtest.info
111         $(LCOV) -r $< "/usr/include/*" \
112                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/*.h" \
113                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/boost/*" \
114                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gmock/*" \
115                       "$(abs_builddir)/depends/x86_64-unknown-linux-gnu/include/gtest/*" \
116                       "$(abs_builddir)/src/gtest/*" \
117                       "$(abs_builddir)/src/test/*" \
118                       "$(abs_builddir)/src/wallet/gtest/*" \
119                       "$(abs_builddir)/src/wallet/test/*" \
120                       -o $@
121
122 test_bitcoin_coverage.info: baseline_filtered_combined.info test_bitcoin_filtered.info
123         $(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_bitcoin_filtered.info -o $@
124
125 zcash-gtest_coverage.info: baseline_filtered_combined.info zcash-gtest_filtered.info
126         $(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a zcash-gtest_filtered.info -o $@
127
128 total_coverage.info:  baseline_filtered_combined.info test_bitcoin_filtered.info zcash-gtest_filtered.info
129         $(LCOV) -a baseline_filtered.info -a leveldb_baseline_filtered.info -a test_bitcoin_filtered.info -a zcash-gtest_filtered.info -o $@ | $(GREP) "\%" | $(AWK) '{ print substr($$3,2,50) "/" $$5 }' > coverage_percent.txt
130
131 test_bitcoin.coverage/.dirstamp:  test_bitcoin_coverage.info
132         $(GENHTML) -s $< -o $(@D)
133         @touch $@
134
135 zcash-gtest.coverage/.dirstamp:  zcash-gtest_coverage.info
136         $(GENHTML) -s $< -o $(@D)
137         @touch $@
138
139 cov-zcash: zcash-gtest.coverage/.dirstamp
140
141 total.coverage/.dirstamp: total_coverage.info
142         $(GENHTML) -s $< -o $(@D)
143         @touch $@
144
145 cov: test_bitcoin.coverage/.dirstamp cov-zcash total.coverage/.dirstamp
146
147 endif
148
149 dist_bin_SCRIPTS = zcutil/fetch-params.sh
150 dist_noinst_SCRIPTS = autogen.sh zcutil/build-debian-package.sh zcutil/build.sh
151
152 EXTRA_DIST = $(top_srcdir)/share/genbuild.sh qa/pull-tester/rpc-tests.sh qa/pull-tester/run-bitcoin-cli qa/rpc-tests qa/zcash $(DIST_DOCS) $(BIN_CHECKS)
153
154 install-exec-hook:
155         mv $(DESTDIR)$(bindir)/fetch-params.sh $(DESTDIR)$(bindir)/zcash-fetch-params
156
157 .INTERMEDIATE: $(COVERAGE_INFO)
158
159 DISTCHECK_CONFIGURE_FLAGS = --enable-man
160
161 clean-local:
162         rm -rf test_bitcoin.coverage/ zcash-gtest.coverage/ total.coverage/
This page took 0.035528 seconds and 4 git commands to generate.