mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-05-22 11:55:22 +02:00
Make the rpc tests work when src!=builddir
This commit is contained in:
@@ -940,6 +940,7 @@ AC_SUBST(MINIUPNPC_LIBS)
|
||||
AC_CONFIG_FILES([Makefile src/Makefile share/setup.nsi share/qt/Info.plist src/test/buildenv.py])
|
||||
AC_CONFIG_FILES([qa/pull-tester/run-bitcoind-for-test.sh],[chmod +x qa/pull-tester/run-bitcoind-for-test.sh])
|
||||
AC_CONFIG_FILES([qa/pull-tester/tests_config.py],[chmod +x qa/pull-tester/tests_config.py])
|
||||
AC_CONFIG_FILES([qa/pull-tester/rpc-tests.py:qa/pull-tester/rpc-tests.py],[chmod +x qa/pull-tester/rpc-tests.py])
|
||||
|
||||
dnl boost's m4 checks do something really nasty: they export these vars. As a
|
||||
dnl result, they leak into secp256k1's configure and crazy things happen.
|
||||
|
||||
@@ -62,6 +62,7 @@ for arg in sys.argv[1:]:
|
||||
|
||||
#Set env vars
|
||||
buildDir = BUILDDIR
|
||||
sourceDir = SOURCEDIR
|
||||
if "BITCOIND" not in os.environ:
|
||||
os.environ["BITCOIND"] = buildDir + '/src/bitcoind' + EXEEXT
|
||||
if "BITCOINCLI" not in os.environ:
|
||||
@@ -142,10 +143,10 @@ def runtests():
|
||||
print("Initializing coverage directory at %s\n" % coverage.dir)
|
||||
|
||||
if(ENABLE_WALLET == 1 and ENABLE_UTILS == 1 and ENABLE_BITCOIND == 1):
|
||||
rpcTestDir = buildDir + '/qa/rpc-tests/'
|
||||
rpcTestDir = sourceDir + '/qa/rpc-tests/'
|
||||
run_extended = '-extended' in opts
|
||||
cov_flag = coverage.flag if coverage else ''
|
||||
flags = " --srcdir %s/src %s %s" % (buildDir, cov_flag, passOn)
|
||||
flags = " --srcdir %s/src %s %s" % (sourceDir, cov_flag, passOn)
|
||||
|
||||
#Run Tests
|
||||
for i in range(len(testScripts)):
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
|
||||
BUILDDIR="@abs_top_builddir@"
|
||||
SOURCEDIR="@abs_top_srcdir@"
|
||||
EXEEXT="@EXEEXT@"
|
||||
|
||||
# These will turn into comments if they were disabled when configuring.
|
||||
|
||||
Reference in New Issue
Block a user