Skip to content

Commit

Permalink
Merge pull request #9 from absolute-community/v12.2.5PR14.11
Browse files Browse the repository at this point in the history
V12.2.5 PR14.11
  • Loading branch information
CryptoCentric authored Feb 27, 2019
2 parents c153baa + 7030eac commit ec4f61b
Show file tree
Hide file tree
Showing 84 changed files with 1,312 additions and 295 deletions.
3 changes: 0 additions & 3 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,6 @@ $(BITCOIN_WIN_INSTALLER): all-recursive
echo error: could not build $@
@echo built $@

$(if $(findstring src/,$(MAKECMDGOALS)),$(MAKECMDGOALS), none): FORCE
$(MAKE) -C src $(patsubst src/%,%,$@)

$(OSX_APP)/Contents/PkgInfo:
$(MKDIR_P) $(@D)
@echo "APPL????" > $@
Expand Down
26 changes: 26 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,13 @@ AC_ARG_ENABLE([debug],
[enable_debug=$enableval],
[enable_debug=no])

# Turn warnings into errors
AC_ARG_ENABLE([werror],
[AS_HELP_STRING([--enable-werror],
[Treat certain compiler warnings as errors (default is no)])],
[enable_werror=$enableval],
[enable_werror=no])

AC_LANG_PUSH([C++])
AX_CHECK_COMPILE_FLAG([-Werror],[CXXFLAG_WERROR="-Werror"],[CXXFLAG_WERROR=""])

Expand All @@ -204,10 +211,19 @@ if test "x$enable_debug" = xyes; then
fi
fi

ERROR_CXXFLAGS=
if test "x$enable_werror" = "xyes"; then
if test "x$CXXFLAG_WERROR" = "x"; then
AC_MSG_ERROR("enable-werror set but -Werror is not usable")
fi
AX_CHECK_COMPILE_FLAG([-Werror=vla],[ERROR_CXXFLAGS="$ERROR_CXXFLAGS -Werror=vla"],,[[$CXXFLAG_WERROR]])
fi

if test "x$CXXFLAGS_overridden" = "xno"; then
AX_CHECK_COMPILE_FLAG([-Wall],[CXXFLAGS="$CXXFLAGS -Wall"],,[[$CXXFLAG_WERROR]])
AX_CHECK_COMPILE_FLAG([-Wextra],[CXXFLAGS="$CXXFLAGS -Wextra"],,[[$CXXFLAG_WERROR]])
AX_CHECK_COMPILE_FLAG([-Wformat],[CXXFLAGS="$CXXFLAGS -Wformat"],,[[$CXXFLAG_WERROR]])
AX_CHECK_COMPILE_FLAG([-Wvla],[CXXFLAGS="$CXXFLAGS -Wvla"],,[[$CXXFLAG_WERROR]])
AX_CHECK_COMPILE_FLAG([-Wformat-security],[CXXFLAGS="$CXXFLAGS -Wformat-security"],,[[$CXXFLAG_WERROR]])

## Some compilers (gcc) ignore unknown -Wno-* options, but warn about all
Expand Down Expand Up @@ -539,6 +555,14 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <sys/socket.h>]],
[ AC_MSG_RESULT(no)]
)

dnl Check for mallopt(M_ARENA_MAX) (to set glibc arenas)
AC_MSG_CHECKING(for mallopt M_ARENA_MAX)
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <malloc.h>]],
[[ mallopt(M_ARENA_MAX, 1); ]])],
[ AC_MSG_RESULT(yes); AC_DEFINE(HAVE_MALLOPT_ARENA_MAX, 1,[Define this symbol if you have mallopt with M_ARENA_MAX]) ],
[ AC_MSG_RESULT(no)]
)

AC_MSG_CHECKING([for visibility attribute])
AC_LINK_IFELSE([AC_LANG_SOURCE([
int foo_def( void ) __attribute__((visibility("default")));
Expand Down Expand Up @@ -1061,6 +1085,7 @@ AC_SUBST(BITCOIN_CLI_NAME)
AC_SUBST(BITCOIN_TX_NAME)

AC_SUBST(RELDFLAGS)
AC_SUBST(ERROR_CXXFLAGS)
AC_SUBST(HARDENED_CXXFLAGS)
AC_SUBST(HARDENED_CPPFLAGS)
AC_SUBST(HARDENED_LDFLAGS)
Expand Down Expand Up @@ -1150,6 +1175,7 @@ echo " with test = $use_tests"
echo " with bench = $use_bench"
echo " with upnp = $use_upnp"
echo " debug enabled = $enable_debug"
echo " werror = $enable_werror"
echo
echo " target os = $TARGET_OS"
echo " build os = $BUILD_OS"
Expand Down
57 changes: 57 additions & 0 deletions contrib/debian/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,60 @@
bitcoin (0.14.1-trusty4) trusty; urgency=medium

* Re-enable UPnP support.

-- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Fri, 05 May 2017 13:28:00 -0400

bitcoin (0.14.1-trusty3) trusty; urgency=medium

* Build with qt5 if we are on a non-Ubuntu (ie non-Unity) distro.

-- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Thu, 04 May 2017 17:13:00 -0400

bitcoin (0.14.1-trusty2) trusty; urgency=medium

* Bump minimum boost version in deps.

-- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Thu, 04 May 2017 17:12:00 -0400

bitcoin (0.14.1-trusty1) trusty; urgency=medium

* New upstream release.

-- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Sat, 22 Apr 2017 17:10:00 -0400

bitcoin (0.14.0-trusty1) trusty; urgency=medium

* New upstream release.

-- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Wed, 08 Mar 2017 10:30:00 -0500

bitcoin (0.13.2-trusty1) trusty; urgency=medium

* New upstream release.

-- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Thu, 05 Jan 2017 09:59:00 -0500

bitcoin (0.13.1-trusty2) trusty; urgency=medium

* Revert to Qt4, due to https://github.com/bitcoin/bitcoin/issues/9038

-- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Mon, 31 Oct 2016 11:16:00 -0400

bitcoin (0.13.1-trusty1) trusty; urgency=medium

* New upstream release.
* Backport updated bitcoin-qt.desktop from upstream master
* Add zmq dependency
* Switch to Qt5 (breaks precise, but that was already broken by C++11)

-- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Thu, 27 Oct 2016 17:32:00 -0400

bitcoin (0.13.0-trusty1) trusty; urgency=medium

* New upstream release.

-- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Sun, 04 Sep 2016 22:09:00 -0400

bitcoin (0.12.1-trusty1) trusty; urgency=medium

* New upstream release.
Expand Down
20 changes: 11 additions & 9 deletions contrib/debian/control
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,19 @@ Build-Depends: debhelper,
libssl-dev,
pkg-config,
libevent-dev,
libboost-system1.48-dev | libboost-system-dev (>> 1.35),
libboost-filesystem1.48-dev | libboost-filesystem-dev (>> 1.35),
libboost-program-options1.48-dev | libboost-program-options-dev (>> 1.35),
libboost-thread1.48-dev | libboost-thread-dev (>> 1.35),
libboost-test1.48-dev | libboost-test-dev (>> 1.35),
libboost-chrono1.48-dev | libboost-chrono-dev (>> 1.35),
qt4-qmake,
libqt4-dev,
libboost-system1.48-dev | libboost-system-dev (>> 1.47),
libboost-filesystem1.48-dev | libboost-filesystem-dev (>> 1.47),
libboost-program-options1.48-dev | libboost-program-options-dev (>> 1.47),
libboost-thread1.48-dev | libboost-thread-dev (>> 1.47),
libboost-test1.48-dev | libboost-test-dev (>> 1.47),
libboost-chrono1.48-dev | libboost-chrono-dev (>> 1.47),
libminiupnpc8-dev | libminiupnpc-dev,
qt4-qmake, libqt4-dev,
qttools5-dev-tools, qttools5-dev,
libqrencode-dev,
libprotobuf-dev, protobuf-compiler,
python
python,
libzmq3-dev
Standards-Version: 3.9.2
Homepage: https://absolutecoin.net
Vcs-Git: git://github.com/absolutecrypto/absolutecoin.git
Expand Down
4 changes: 3 additions & 1 deletion contrib/debian/rules
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,12 @@ override_dh_auto_clean:
if [ -f Makefile ]; then $(MAKE) distclean; fi
rm -rf Makefile.in aclocal.m4 configure src/Makefile.in src/absolute-config.h.in src/build-aux src/qt/Makefile.in src/qt/test/Makefile.in src/test/Makefile.in

QT=$(shell dpkg-vendor --derives-from Ubuntu && echo qt4 || echo qt5)

# Yea, autogen should be run on the source archive, but I like doing git archive
override_dh_auto_configure:
./autogen.sh
./configure --without-miniupnpc --with-gui=qt4
./configure --with-gui=$(QT)

override_dh_auto_test:
make check
2 changes: 1 addition & 1 deletion contrib/init/absoluted.openrcconf
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#BITCOIND_NICE=0

# Additional options (avoid -conf and -datadir, use flags above)
BITCOIND_OPTS="-disablewallet"
#BITCOIND_OPTS=""

# The timeout in seconds OpenRC will wait for bitcoind to terminate
# after a SIGTERM has been raised.
Expand Down
2 changes: 1 addition & 1 deletion contrib/seeds/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ and remove old versions as necessary.

The seeds compiled into the release are created from sipa's DNS seed data, like this:

curl -s http://bitcoin.sipa.be/seeds.txt > seeds_main.txt
curl -s http://bitcoin.sipa.be/seeds.txt.gz | gzip -dc > seeds_main.txt
python3 makeseeds.py < seeds_main.txt > nodes_main.txt
python3 generate-seeds.py . > ../../src/chainparamsseeds.h

Expand Down
4 changes: 2 additions & 2 deletions depends/packages/miniupnpc.mk
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package=miniupnpc
$(package)_version=2.0
$(package)_version=2.0.20170509
$(package)_download_path=http://miniupnp.free.fr/files
$(package)_file_name=$(package)-$($(package)_version).tar.gz
$(package)_sha256_hash=d434ceb8986efbe199c5ca53f90ed53eab290b1e6d0530b717eb6fa49d61f93b
$(package)_sha256_hash=d3c368627f5cdfb66d3ebd64ca39ba54d6ff14a61966dbecb8dd296b7039f16a

define $(package)_set_vars
$(package)_build_opts=CC="$($(package)_cc)"
Expand Down
3 changes: 2 additions & 1 deletion depends/packages/native_cctools.mk
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ $(package)_cxx=$($(package)_extract_dir)/toolchain/bin/clang++
endef

define $(package)_preprocess_cmds
cd $($(package)_build_subdir); ./autogen.sh
cd $($(package)_build_subdir); ./autogen.sh && \
sed -i.old "/define HAVE_PTHREADS/d" ld64/src/ld/InputFiles.h
endef

define $(package)_config_cmds
Expand Down
4 changes: 3 additions & 1 deletion depends/packages/zlib.mk
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,10 @@ $(package)_sha256_hash=c3e5e9fdd5004dcb542feda5ee4f0ff0744628baf8ed2dd5d66f8ca11
define $(package)_set_vars
$(package)_build_opts= CC="$($(package)_cc)"
$(package)_build_opts+=CFLAGS="$($(package)_cflags) $($(package)_cppflags) -fPIC"
$(package)_build_opts+=AR="$($(package)_ar)"
$(package)_build_opts+=RANLIB="$($(package)_ranlib)"
$(package)_build_opts+=AR="$($(package)_ar)"
$(package)_build_opts_darwin+=AR="$($(package)_libtool)"
$(package)_build_opts_darwin+=ARFLAGS="-o"
endef

define $(package)_config_cmds
Expand Down
1 change: 1 addition & 0 deletions doc/bips.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ BIPs that are implemented by Bitcoin Core (up-to-date up to **v0.13.0**):
* [`BIP 66`](https://github.com/bitcoin/bips/blob/master/bip-0066.mediawiki): The strict DER rules and associated version 3 blocks have been implemented since **v0.10.0** ([PR #5713](https://github.com/bitcoin/bitcoin/pull/5713)).
* [`BIP 68`](https://github.com/bitcoin/bips/blob/master/bip-0068.mediawiki): Sequence locks have been implemented as of **v0.12.1** ([PR #7184](https://github.com/bitcoin/bitcoin/pull/7184)), and have been activated since *block 419328*.
* [`BIP 70`](https://github.com/bitcoin/bips/blob/master/bip-0070.mediawiki) [`71`](https://github.com/bitcoin/bips/blob/master/bip-0071.mediawiki) [`72`](https://github.com/bitcoin/bips/blob/master/bip-0072.mediawiki): Payment Protocol support has been available in Bitcoin Core GUI since **v0.9.0** ([PR #5216](https://github.com/bitcoin/bitcoin/pull/5216)).
* [`BIP 90`](https://github.com/bitcoin/bips/blob/master/bip-0090.mediawiki): Trigger mechanism for activation of BIPs 34, 65, and 66 has been simplified to block height checks since **v0.14.0** ([PR #8391](https://github.com/bitcoin/bitcoin/pull/8391)).
* [`BIP 111`](https://github.com/bitcoin/bips/blob/master/bip-0111.mediawiki): `NODE_BLOOM` service bit added, and enforced for all peer versions as of **v0.13.0** ([PR #6579](https://github.com/bitcoin/bitcoin/pull/6579) and [PR #6641](https://github.com/bitcoin/bitcoin/pull/6641)).
* [`BIP 112`](https://github.com/bitcoin/bips/blob/master/bip-0112.mediawiki): The CHECKSEQUENCEVERIFY opcode has been implemented since **v0.12.1** ([PR #7524](https://github.com/bitcoin/bitcoin/pull/7524)) and has been activated since *block 419328*.
* [`BIP 113`](https://github.com/bitcoin/bips/blob/master/bip-0113.mediawiki): Median time past lock-time calculations have been implemented since **v0.12.1** ([PR #6566](https://github.com/bitcoin/bitcoin/pull/6566)) and have been activated since *block 419328*.
Expand Down
6 changes: 3 additions & 3 deletions doc/build-osx.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@ Install the OS X command line tools:

When the popup appears, click `Install`.

Then install [Homebrew](http://brew.sh).
Then install [Homebrew](https://brew.sh).

Dependencies
----------------------

brew install automake berkeley-db4 libtool boost --c++11 miniupnpc openssl pkg-config protobuf --c++11 qt5 libevent
brew install automake berkeley-db4 libtool boost --c++11 miniupnpc openssl pkg-config protobuf qt libevent

In case you want to build the disk image with `make deploy` (.dmg / optional), you need RSVG
If you want to build the disk image with `make deploy` (.dmg / optional), you need RSVG

brew install librsvg

Expand Down
6 changes: 4 additions & 2 deletions doc/build-unix.md
Original file line number Diff line number Diff line change
Expand Up @@ -317,8 +317,10 @@ Clang is installed by default as `cc` compiler, this makes it easier to get
started than on [OpenBSD](build-openbsd.md). Installing dependencies:

pkg install autoconf automake libtool pkgconf
pkg install boost-libs openssl libevent2
pkg install boost-libs openssl libevent
pkg install gmake

You need to use GNU make (`gmake`) instead of `make`.
(`libressl` instead of `openssl` will also work)

For the wallet (optional):
Expand All @@ -334,7 +336,7 @@ Then build using:

./autogen.sh
./configure --with-incompatible-bdb BDB_CFLAGS="-I/usr/local/include/db5" BDB_LIBS="-L/usr/local/lib -ldb_cxx-5"
make
gmake

*Note on debugging*: The version of `gdb` installed by default is [ancient and considered harmful](https://wiki.freebsd.org/GdbRetirement).
It is not suitable for debugging a multi-threaded C++ program, not even for getting backtraces. Please install the package `gdb` and
Expand Down
14 changes: 13 additions & 1 deletion doc/man/Makefile.am
Original file line number Diff line number Diff line change
@@ -1 +1,13 @@
dist_man1_MANS=absoluted.1 absolute-qt.1 absolute-cli.1 absolute-tx.1
dist_man1_MANS=

if BUILD_BITCOIND
dist_man1_MANS+=absoluted.1
endif

if ENABLE_QT
dist_man1_MANS+=absolute-qt.1
endif

if BUILD_BITCOIN_UTILS
dist_man1_MANS+=absolute-cli.1 absolute-tx.1
endif
5 changes: 3 additions & 2 deletions qa/rpc-tests/fundrawtransaction-hd.py
Original file line number Diff line number Diff line change
Expand Up @@ -441,8 +441,9 @@ def run_test(self):
# locked wallet test
self.nodes[1].encryptwallet("test")
self.nodes.pop(1)
stop_nodes(self.nodes)
wait_bitcoinds()
stop_node(self.nodes[0], 0)
stop_node(self.nodes[1], 2)
stop_node(self.nodes[2], 3)

self.nodes = start_nodes(4, self.options.tmpdir, [['-usehd=1'], ['-usehd=1'], ['-usehd=1'], ['-usehd=1']], redirect_stderr=True)
# This test is not meant to test fee estimation and we'd like
Expand Down
9 changes: 8 additions & 1 deletion qa/rpc-tests/fundrawtransaction.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,11 @@ def run_test(self):
self.nodes[0].generate(121)
self.sync_all()

# ensure that setting changePosition in fundraw with an exact match is handled properly
rawmatch = self.nodes[2].createrawtransaction([], {self.nodes[2].getnewaddress():500})
rawmatch = self.nodes[2].fundrawtransaction(rawmatch, {"changePosition":1, "subtractFeeFromOutputs":[0]})
assert_equal(rawmatch["changepos"], -1)

watchonly_address = self.nodes[0].getnewaddress()
watchonly_pubkey = self.nodes[0].validateaddress(watchonly_address)["pubkey"]
watchonly_amount = Decimal(2000)
Expand Down Expand Up @@ -468,7 +473,9 @@ def run_test(self):
# locked wallet test
self.nodes[1].encryptwallet("test")
self.nodes.pop(1)
stop_nodes(self.nodes)
stop_node(self.nodes[0], 0)
stop_node(self.nodes[1], 2)
stop_node(self.nodes[2], 3)

self.nodes = start_nodes(self.num_nodes, self.options.tmpdir, [['-usehd=0'], ['-usehd=0'], ['-usehd=0'], ['-usehd=0']])
# This test is not meant to test fee estimation and we'd like
Expand Down
12 changes: 12 additions & 0 deletions qa/rpc-tests/mempool_packages.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,18 @@ def run_test(self):
assert_equal(mempool[x], v_descendants[x])
assert(chain[0] not in v_descendants.keys())

# Check that ancestor modified fees includes fee deltas from
# prioritisetransaction
self.nodes[0].prioritisetransaction(chain[0], 0, 1000)
mempool = self.nodes[0].getrawmempool(True)
ancestor_fees = 0
for x in chain:
ancestor_fees += mempool[x]['fee']
assert_equal(mempool[x]['ancestorfees'], ancestor_fees * COIN + 1000)

# Undo the prioritisetransaction for later tests
self.nodes[0].prioritisetransaction(chain[0], 0, -1000)

# Check that descendant modified fees includes fee deltas from
# prioritisetransaction
self.nodes[0].prioritisetransaction(chain[-1], 0, 1000)
Expand Down
15 changes: 14 additions & 1 deletion qa/rpc-tests/prioritise_transaction.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class PrioritiseTransactionTest(BitcoinTestFramework):
def __init__(self):
super().__init__()
self.setup_clean_chain = True
self.num_nodes = 1
self.num_nodes = 2

self.txouts = gen_return_txouts()

Expand All @@ -25,6 +25,8 @@ def setup_network(self):
self.is_network_split = False

self.nodes.append(start_node(0, self.options.tmpdir, ["-debug", "-printpriority=1"]))
self.nodes.append(start_node(1, self.options.tmpdir, ["-debug", "-printpriority=1"])) # TODO move this to extra_args when Bitcoin #10198 gets backported
connect_nodes(self.nodes[0], 1) # TODO remove this when Bitcoin #10198 gets backported
self.relayfee = self.nodes[0].getnetworkinfo()['relayfee']

def run_test(self):
Expand Down Expand Up @@ -139,5 +141,16 @@ def run_test(self):
assert_equal(self.nodes[0].sendrawtransaction(tx2_hex), tx2_id)
assert(tx2_id in self.nodes[0].getrawmempool())

# Test that calling prioritisetransaction is sufficient to trigger
# getblocktemplate to (eventually) return a new block.
mock_time = int(time.time())
self.nodes[0].setmocktime(mock_time)
template = self.nodes[0].getblocktemplate()
self.nodes[0].prioritisetransaction(tx2_id, 0, -int(self.relayfee*COIN))
self.nodes[0].setmocktime(mock_time+10)
new_template = self.nodes[0].getblocktemplate()

assert(template != new_template)

if __name__ == '__main__':
PrioritiseTransactionTest().main()
Loading

0 comments on commit ec4f61b

Please sign in to comment.