Commit graph

83 commits

Author SHA1 Message Date
Ben Woosley
4138f42d24
Revert "Merge #12870: make clean removes src/qt/moc_ files"
As noted by theuni and Sjors in #12870, qt moc cleaning is handled
by CLEAN_QT via QT_MOC_CPP in Makefile.qt.include.

In my testing I configured, built and cleaned with qt4 and qt5 both,
absent the associated wildcard, and no MOC files were left after clean.
Propose we revert the change and reconsider if a specific file
is identified, then add that file to QT_MOC_CPP.

This reverts commit 1d540046fe, reversing
changes made to ad960f5771.
2018-05-16 20:13:30 -07:00
Qasim Javed
6674a75bfb [tests] Make rpcauth.py testable and add unit tests
refs #12995
2018-04-24 11:41:20 -07:00
Sjors Provoost
2ebad11cf9
make clean removes src/qt/moc_ files 2018-04-03 15:04:35 +02:00
Andrea Comand
a777244e48 Build: Add a makefile target for Doxygen documentation
You can now build the doxygen documentation with `make docs` and clean it with `make clean-docs`.

Fixes: #11949
2018-01-25 19:43:19 +01:00
Wladimir J. van der Laan
3c8f0a3b8e
Merge #11842: [build] Add missing stuff to clean-local
b341143 [build] Add missing stuff to clean-local - test/functional/test_framework/__pycache__ - test/cache (Karl-Johan Alm)

Pull request description:

  After doing
  ```
  ./autogen.sh && ./configure && make
  make clean
  make distclean
  ```
  and moving `.gitignore` aside, the following files still remain after this patch:
  ```
  	Makefile.in
  	aclocal.m4
  	autom4te.cache/
  	build-aux/compile
  	build-aux/config.guess
  	build-aux/config.sub
  	build-aux/depcomp
  	build-aux/install-sh
  	build-aux/ltmain.sh
  	build-aux/m4/libtool.m4
  	build-aux/m4/ltoptions.m4
  	build-aux/m4/ltsugar.m4
  	build-aux/m4/ltversion.m4
  	build-aux/m4/lt~obsolete.m4
  	build-aux/missing
  	build-aux/test-driver
  	configure
  	doc/man/Makefile.in
  	src/Makefile.in
  	src/config/bitcoin-config.h.in
  ```

  Most are automake related so I guess it's fine if they litter around.

Tree-SHA512: 7566f56a79932cc1d6ee6ff487d121e3909db57167775e1b27209d93bcc1c14e47b0fcc9c0c272c4b9df907c1bc0664f02006a21b3b6939fa50fc2a5762729e4
2017-12-14 17:42:35 +01:00
Karl-Johan Alm
b3411435ae
[build] Add missing stuff to clean-local
- test/functional/test_framework/__pycache__
- test/cache
2017-12-07 14:13:57 +09:00
Henrik Jonsson
3fdb29778a Rename rpcuser.py to rpcauth.py
This script creates `rpcauth` entries for bitcoin.conf,
not the deprecated `rpcuser` entry, so this changes the name
of the script to match.
2017-12-06 13:11:02 +00:00
James O'Beirne
af9103eb75 [build] Add a script for installing db4
Instead of maintaining not-easily-tested instructions for building BerkeleyDB
in doc/build-unix.md, package the installation as a script in contrib/. This
allows shared usage from a number of contexts, e.g. Docker.

Thanks to @jonasschnelli, @laanwj for feedback.
2017-11-16 11:49:19 -08:00
Wladimir J. van der Laan
bb9ab0fccf
Merge #11541: Build: Fix Automake warnings when running autogen.sh
cc5c39d [Build] Add AM_OBJCXXFLAGS and QT_PIE_FLAGS to OBJCXXFLAGS to future-proof darwin targets (fanquake)
f8c6697 Fix automake warnings when running autogen.sh (Evan Klitzke)

Pull request description:

  Adjusted @eklitzke's commit to completely remove GZIP_ENV.
  Added a commit to address OBJCXXFLAGS.
  Rebased on master.
  Relevant info from @theuni & #11013 below.

  --------
  GZIP_ENV was indeed added for determinism, but gitian exports this as needed, so it's not really necessary. I'd rather just remove it.

  The mm.o rule was added to support XCode 4.2's ancient version of automake. That's irrelevant now, so it makes sense to remove that too.

  All darwin targets are PIE by default, so we don't technically need the flags, but I'd be more comfortable if we hooked up the OBJCXXFLAGS in case future ones are added.

  --------

  The second commit addresses the last point, but could probably use a better commit message.
  These warnings are removed from autogen output:
  ```
  Makefile.am:12: warning: user variable 'GZIP_ENV' defined here ...
  /usr/local/Cellar/automake/1.15.1/share/automake-1.15/am/distdir.am: ... overrides Automake variable 'GZIP_ENV' defined here
  src/Makefile.am: installing 'build-aux/depcomp'
  src/Makefile.am:503: warning: user target '.mm.o' defined here ...
  /usr/local/Cellar/automake/1.15.1/share/automake-1.15/am/depend2.am: ... overrides Automake target '.mm.o' defined here
  ```

Tree-SHA512: bd59df5f6d3aafe35d5e36925bfe61cc71e774583a0438d7dd946c9e7ecf6e59d42f90a58b8cfef0faa404c81050338ad4cefe721b4a949af881e73b6ab254d4
2017-10-29 18:28:21 +01:00
Wladimir J. van der Laan
cf8c4a7633
Merge #11530: Add share/rpcuser to dist. source code archive
fa81534 Add share/rpcuser to dist. source code archive (MarcoFalke)

Pull request description:

  As the legacy rpcuser and rpcpassword are deprected since 0.12.0, we should actually include the script to generate the new auth pair in the distributed source code archive.

  Ref: #6753

  (Tagging for backport, since it is a trivial bugfix)

Tree-SHA512: f2737957a92396444573f41071a785be5fb318df9efeb3ade7e56b3b56d512e5f9ca36723365fe5be8aaee69c5e8d8ed1178510bf02186c848b3910ee001ecb9
2017-10-26 17:27:39 +02:00
Evan Klitzke
f8c66972dd
Fix automake warnings when running autogen.sh 2017-10-21 12:05:36 +08:00
MarcoFalke
fa81534d06 Add share/rpcuser to dist. source code archive 2017-10-19 22:13:49 +02:00
Matt Corallo
28d4542a0a Disallow uncompressed pubkeys in bitcoin-tx [multisig] output adds 2017-09-20 23:29:59 -04:00
Andrew Chow
d5711f4a2d Filter subtrees and and benchmarks from coverage report
Remove leveldb baseline coverage gathering.

Added filter rules to remove all of the subtress (leveldb, secp256k1, ctaes, univalue) and
benchmarking from the coverage report. These items are unnecessary as we do not test for any
of the subtrees and benchmark coverage is unneeded.
2017-06-12 15:53:30 -07:00
Andrew Chow
405b86a92a Replace lcov -r commands with faster way
Instead of using lcov -r (which is extremely slow), first use a python script to perform bulk cleanup of the /usr/include/* coverage. Then use lcov -a to remove the duplicate entries. This has the same effect of lcov -r but runs significantly faster
2017-06-09 12:24:48 -07:00
Andrew Chow
c8914b9dbb Have make cov optionally include branch coverage statistics
Added an option to configure to allow for branch coverage statistics gathering.

Disabled logprint macro when coverage testing is on so that unnecessary branches are not analyzed.
2017-06-07 14:19:01 -07:00
John Newbery
8ad5bdef78 Merge bctest.py into bitcoin-util-test.py
bctest.py is only used as an import by bitcoin-util-test.py. There's no
value in keeping it as a separate module, so let's merge them into a
single module to keep building and packaging simpler.

bitcoin-test-util is importable as a module, so if any future modules
really want to import the code from bctest.py, they can import
bitcoin-test-util and call the bctest functions by name.
2017-06-06 16:42:38 -04:00
John Newbery
89fcd3586c Use an .ini config file for environment vars in bitcoin-util-test.py 2017-05-03 14:18:14 -04:00
Cory Fields
3577603701 build: remove wonky auto top-level convenience targets
These were meant to help build subdir targets from the top builddir, but cause
infinite recursion when going the other way.

If anyone actually uses these, we can add back specific targets.
2017-04-18 19:12:20 -04:00
John Newbery
63d66ba20a Move src/test/bitcoin-util-test.py to test/util/bitcoin-util-test.py 2017-03-20 10:40:31 -04:00
John Newbery
5b0bff4581 Rename --enable-extended-rpc-tests to --enable-extended-functional-tests 2017-03-20 10:40:31 -04:00
John Newbery
a9bd622a65 Rename test/pull-tester/rpc-tests.py to test/functional/test_runner.py 2017-03-20 10:40:31 -04:00
John Newbery
c28ee91db0 Rename rpc-tests directory to functional 2017-03-20 10:40:31 -04:00
John Newbery
00902c48cd Rename qa directory to test 2017-03-20 10:40:31 -04:00
John Newbery
1581ecbc33 Use configparser in rpc-tests.py
Remove the use of wildcard imports in rpc-tests.py and replace with
configparser.
2017-01-31 18:03:14 -08:00
Cory Fields
09aefb5177
build: Fix 'make deploy' for OSX
Native OSX uses system tools rather than 3rd party dependencies. rsvg-convert
is still required, though.
2016-12-23 09:48:52 +01:00
Wladimir J. van der Laan
078900df75
Merge #8568: new var DIST_CONTRIB adds useful things for packagers from contrib
1ee6f91 new var DIST_CONTRIB adds useful things for packagers from contrib/ to EXTRA_DIST (nomnombtc)
2016-11-07 13:06:47 +01:00
nomnombtc
1ee6f9116a new var DIST_CONTRIB adds useful things for packagers from contrib/ to EXTRA_DIST 2016-11-07 13:05:31 +01:00
Luke Dashjr
f4dffdd6bf Add MIT license to Makefiles 2016-09-21 22:35:12 +00:00
nomnombtc
dc84b6f419 add doc/man to subdir if configure flag --enable-man is set 2016-08-27 01:09:22 +02:00
Wladimir J. van der Laan
3c5251daeb test: Remove java comparison tool 2016-08-13 16:04:29 +02:00
Cory Fields
340012d9c9 build: add temporary fix for "bad magic number" error in out-of-tree builds
This was caused by an pyc files hanging around from previous
python2 invocations, when the matching .py missing from that path.

This should not be a problem with python3's tagged caches.
2016-06-03 14:48:21 -04:00
Cory Fields
92e37a3689 build: fix out-of-tree 'make deploy' for osx
The plist is generated, lives in builddir.
2016-06-01 22:20:59 -04:00
Cory Fields
ab95d5df3d build: a few ugly hacks to get the rpc tests working out-of-tree
- Link pull-tester/rpc-tests.py to the build dir
- Add the build-dir's config to the python path so that tests can find it
- The tests themselves are in srcdir
- Clean up __pycache__ in 'make clean'
2016-06-01 20:31:55 -04:00
Cory Fields
0cb0f2626e build: out-of-tree fixups
Don't glob the leveldb for dist. That means we need to enumerate the headers.
2016-06-01 20:31:55 -04:00
Cory Fields
0dbf6e4b40 build: define base filenames for use elsewhere in the buildsystem
Unfortunately, the target namees defined at the Makefile.am level can't be used
for *.in substitution. So these new defines will have to stay synced up with
those targets.

Using the new variables for the deploy targets in the main Makefile.am will
ensure that they stay in sync, otherwise build tests will fail.
2016-04-11 04:01:23 +00:00
Wladimir J. van der Laan
18f05c765c build: python 3 compatibility
Ubuntu 16.04 "xenial xerus" does not come with Python 2.x by default.
It is possible to install a python-2.7 package, but this has its own
problem: no `python` or `python2` symlink (see #7717).

This fixes the following scripts to work with python 3:
- `make check` (bctest,py, bitcoin-util-test.py)
- `make translate` (extract_strings_qt.py)
- `make symbols-check` (symbol-check.py)
- `make security-check` (security-check.py)

Explicitly call the python commands using $(PYTHON) instead
of relying on the interpreter line at the top of the scripts.
2016-03-29 17:20:16 +02:00
Luke Dashjr
a68bb9f5e7 Merge branch 'master' into single_prodname 2016-02-03 05:41:13 +00:00
Cory Fields
f3d3eaf78e release: add check-symbols and check-security make targets
These are not added to the default checks because some of them depend on
release-build configs.
2016-01-26 23:07:04 -05:00
Cory Fields
de619a37fd depends: Pass PYTHONPATH along to configure 2015-12-22 04:37:46 +00:00
Luke Dashjr
e611b6e329 macdeploy: Use rsvg-convert rather than cairosvg 2015-12-22 04:37:45 +00:00
Luke Dashjr
63bcdc5227 More complicated package name substitution for Mac deployment 2015-12-22 03:24:21 +00:00
Cory Fields
392d3c5846 build: Set osx permissions in the dmg to make Gatekeeper happy 2015-11-24 16:22:24 -05:00
Wladimir J. van der Laan
ff2a2af64c build: don't distribute tests_config.py
This file is dynamically generated by configure based on the platform,
it doesn't belong in the distribution archive.

Fixes #6929.
2015-11-02 04:15:58 +01:00
dexX7
d80e3cbece
Support gathering of code coverage data for RPC tests
The RPC tests (via `qa/pull-tester/rpc-tests.py`) are now executed,
when gathering code coverage data, for example with `make cov`.

Generating coverage data requires `lcov`, which can installed with:

    sudo apt-get install lcov

To also use the BitcoinJ tests, get the test tool:

    TOOL_URL=https://github.com/theuni/bitcoind-comparisontool/raw/master/pull-tests-8c6666f.jar
    TOOL_HASH=a865332b3827abcde684ab79f5f43c083b0b6a4c97ff5508c79f29fee24f11cd
    wget $TOOL_URL -O ./share/BitcoindComparisonTool.jar
    echo "$TOOL_HASH  ./share/BitcoindComparisonTool.jar" | shasum --algorithm 256 --check

The coverage data can be generated with:

    ./autogen.sh
    ./configure --enable-lcov --with-comparison-tool=./share/BitcoindComparisonTool.jar
    make
    make cov

Optionally the options `--enable-extended-rpc-tests` and
`--enable-comparison-tool-reorg-tests` may be used to enable more time
consuming tests.

It then runs the tests and generates two HTML reports:

 - test_bitcoin.coverage/index.html
 - total.coverage/index.html
2015-10-23 22:09:24 +02:00
dexX7
e3b5e6c39c
Run extended BitcoinJ tests for coverage based on config
The configuration option `--enable-comparison-tool-reorg-tests` may be
used to enable extended tests via BitcoinJ also for coverage testing.
2015-10-23 22:09:20 +02:00
dexX7
d425877557
Remove coverage and test related files, when cleaning up
Until now there were quite a few leftovers, and only the coverage
related files in `src/` were cleaned, while the ones in the other dirs
remained. `qa/tmp/` is related to the BitcoinJ tests, and `cache/` is
related to RPC tests.
2015-10-23 22:09:14 +02:00
ptschip
5467820be5 Migrated rpc-tests.sh to all python rpc-tests.py
1) created rpc-tests.py
2) deleted rpc-tests.sh
3) travis.yml points to rpc-tests.py
4) Modified Makefile.am
5) Updated README.md
6) Added tests_config.py and deleted tests-config.sh
7) Modified configure.ac with script to set correct path in tests_config.py
2015-10-01 11:28:11 -07:00
ptschip
060058e955 Enable python tests for Native Windows
1) Multiplatorm support for devnull
2) Fixed a bug in the handling of cache files
3) Deleted run-bitcoin-cli as no longer needed
2015-08-26 10:59:22 -07:00
randy-waterhouse
60d5432697 Add autogen.sh to source tarball. 2015-07-11 15:39:45 +12:00