Skip to content

Commit 96df327

Browse files
committed
Merge remote-tracking branch 'upstream/master'
Conflicts: src/qt/overviewpage.cpp src/qt/transactiondesc.cpp
2 parents 2e4fee2 + 1fedd65 commit 96df327

File tree

331 files changed

+19555
-8425
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

331 files changed

+19555
-8425
lines changed

.gitignore

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,19 @@ autom4te.cache/
1313
config.log
1414
config.status
1515
configure
16-
src/bitcoin-config.h
17-
src/bitcoin-config.h.in
16+
src/config/bitcoin-config.h
17+
src/config/bitcoin-config.h.in
18+
src/config/stamp-h1
1819
src/build-aux/
19-
src/stamp-h1
2020
share/setup.nsi
2121
share/qt/Info.plist
22+
# Libtool
23+
libtool
24+
src/m4/libtool.m4
25+
src/m4/ltoptions.m4
26+
src/m4/ltsugar.m4
27+
src/m4/ltversion.m4
28+
src/m4/lt~obsolete.m4
2229

2330
src/qt/*.moc
2431
src/qt/moc_*.cpp

COPYING

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Copyright (c) 2009-2013 Bitcoin Developers
1+
Copyright (c) 2009-2014 Bitcoin Developers
22

33
Permission is hereby granted, free of charge, to any person obtaining a copy
44
of this software and associated documentation files (the "Software"), to deal

Makefile.am

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
ACLOCAL_AMFLAGS = -I src/m4
22
SUBDIRS = src
3-
.PHONY: deploy
3+
.PHONY: deploy FORCE
44

55
GZIP_ENV="-9n"
66

@@ -35,6 +35,7 @@ COVERAGE_INFO = baseline_filtered_combined.info baseline.info block_test.info \
3535

3636
dist-hook:
3737
-$(MAKE) -C $(top_distdir)/src/leveldb clean
38+
-$(MAKE) -C $(top_distdir)/src/secp256k1 distclean
3839
-$(GIT) archive --format=tar HEAD -- src/version.cpp | $(AMTAR) -C $(top_distdir) -xf -
3940

4041
distcheck-hook:
@@ -53,8 +54,8 @@ $(BITCOIN_WIN_INSTALLER): $(BITCOIND_BIN) $(BITCOIN_QT_BIN) $(BITCOIN_CLI_BIN)
5354
@test -f $(MAKENSIS) && $(MAKENSIS) $(top_builddir)/share/setup.nsi || \
5455
echo error: could not build $@
5556

56-
$(BITCOIND_BIN) $(BITCOIN_QT_BIN) $(BITCOIN_CLI_BIN):
57-
make -C $(dir $@) $(notdir $@)
57+
$(if $(findstring src/,$(MAKECMDGOALS)),$(MAKECMDGOALS), none): FORCE
58+
$(MAKE) -C src $(patsubst src/%,%,$@)
5859

5960
$(OSX_APP)/Contents/PkgInfo:
6061
$(MKDIR_P) $(@D)

README.md

Lines changed: 43 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Bitcoin Core integration/staging tree
22
=====================================
33

4-
http://www.bitcoin.org
4+
https://www.bitcoin.org
55

66
Copyright (c) 2009-2014 Bitcoin Core Developers
77

@@ -15,7 +15,7 @@ out collectively by the network. Bitcoin Core is the name of open source
1515
software which enables the use of this currency.
1616

1717
For more information, as well as an immediately useable, binary version of
18-
the Bitcoin Core software, see http://www.bitcoin.org/en/download.
18+
the Bitcoin Core software, see https://www.bitcoin.org/en/download.
1919

2020
License
2121
-------
@@ -49,8 +49,8 @@ Testing
4949
-------
5050

5151
Testing and code review is the bottleneck for development; we get more pull
52-
requests than we can review and test. Please be patient and help out, and
53-
remember this is a security-critical project where any mistake might cost people
52+
requests than we can review and test on short notice. Please be patient and help out by testing
53+
other people's pull requests, and remember this is a security-critical project where any mistake might cost people
5454
lots of money.
5555

5656
### Automated Testing
@@ -76,8 +76,45 @@ Translations
7676
Changes to translations as well as new translations can be submitted to
7777
[Bitcoin Core's Transifex page](https://www.transifex.com/projects/p/bitcoin/).
7878

79-
Periodically the translations are pulled from Transifex and merged into the git repository. See the
79+
Translations are periodically pulled from Transifex and merged into the git repository. See the
8080
[translation process](doc/translation_process.md) for details on how this works.
8181

82-
**Important**: We do not accept translation changes as github pull request because the next
82+
**Important**: We do not accept translation changes as GitHub pull requests because the next
8383
pull from Transifex would automatically overwrite them again.
84+
85+
Translators should also subscribe to the [mailing list](https://groups.google.com/forum/#!forum/bitcoin-translators).
86+
87+
Development tips and tricks
88+
---------------------------
89+
90+
**compiling for debugging**
91+
92+
Run configure with the --enable-debug option, then make. Or run configure with
93+
CXXFLAGS="-g -ggdb -O0" or whatever debug flags you need.
94+
95+
**debug.log**
96+
97+
If the code is behaving strangely, take a look in the debug.log file in the data directory;
98+
error and debugging message are written there.
99+
100+
The -debug=... command-line option controls debugging; running with just -debug will turn
101+
on all categories (and give you a very large debug.log file).
102+
103+
The Qt code routes qDebug() output to debug.log under category "qt": run with -debug=qt
104+
to see it.
105+
106+
**testnet and regtest modes**
107+
108+
Run with the -testnet option to run with "play bitcoins" on the test network, if you
109+
are testing multi-machine code that needs to operate across the internet.
110+
111+
If you are testing something that can run on one machine, run with the -regtest option.
112+
In regression test mode blocks can be created on-demand; see qa/rpc-tests/ for tests
113+
that run in -regest mode.
114+
115+
**DEBUG_LOCKORDER**
116+
117+
Bitcoin Core is a multithreaded application, and deadlocks or other multithreading bugs
118+
can be very difficult to track down. Compiling with -DDEBUG_LOCKORDER (configure
119+
CXXFLAGS="-DDEBUG_LOCKORDER -g") inserts run-time checks to keep track of what locks
120+
are held, and adds warning to the debug.log file if inconsistencies are detected.

autogen.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,7 @@
22
set -e
33
srcdir="$(dirname $0)"
44
cd "$srcdir"
5+
if [ -z ${LIBTOOLIZE} ] && GLIBTOOLIZE="`which glibtoolize 2>/dev/null`"; then
6+
export LIBTOOLIZE="${GLIBTOOLIZE}"
7+
fi
58
autoreconf --install --force

configure.ac

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ define(_COPYRIGHT_YEAR, 2014)
99
AC_INIT([Bitcoin Core],[_CLIENT_VERSION_MAJOR._CLIENT_VERSION_MINOR._CLIENT_VERSION_REVISION],[[email protected]],[bitcoin])
1010
AC_CONFIG_AUX_DIR([src/build-aux])
1111
AC_CONFIG_MACRO_DIR([src/m4])
12+
LT_INIT([disable-shared])
1213
AC_CANONICAL_HOST
1314
AH_TOP([#ifndef BITCOIN_CONFIG_H])
1415
AH_TOP([#define BITCOIN_CONFIG_H])
@@ -111,7 +112,7 @@ AC_ARG_WITH([protoc-bindir],[AS_HELP_STRING([--with-protoc-bindir=BIN_DIR],[spec
111112

112113

113114
AC_CONFIG_SRCDIR([src])
114-
AC_CONFIG_HEADERS([src/bitcoin-config.h])
115+
AC_CONFIG_HEADERS([src/config/bitcoin-config.h])
115116

116117
dnl Checks for programs.
117118
AC_PROG_CXX
@@ -303,6 +304,8 @@ INCLUDES="$INCLUDES $PTHREAD_CFLAGS"
303304
# they also need to be passed down to any subprojects. Pull the results out of
304305
# the cache and add them to CPPFLAGS.
305306
AC_SYS_LARGEFILE
307+
# detect POSIX or GNU variant of strerror_r
308+
AC_FUNC_STRERROR_R
306309

307310
if test x$ac_cv_sys_file_offset_bits != x &&
308311
test x$ac_cv_sys_file_offset_bits != xno &&
@@ -366,7 +369,14 @@ if test x$TARGET_OS = xdarwin; then
366369
AX_CHECK_LINK_FLAG([[-Wl,-dead_strip]], [LDFLAGS="$LDFLAGS -Wl,-dead_strip"])
367370
fi
368371

369-
AC_CHECK_HEADERS([stdio.h stdlib.h unistd.h strings.h sys/types.h sys/stat.h])
372+
AC_CHECK_HEADERS([endian.h stdio.h stdlib.h unistd.h strings.h sys/types.h sys/stat.h sys/select.h])
373+
AC_SEARCH_LIBS([getaddrinfo_a], [anl], [AC_DEFINE(HAVE_GETADDRINFO_A, 1, [Define this symbol if you have getaddrinfo_a])])
374+
AC_SEARCH_LIBS([inet_pton], [nsl resolv], [AC_DEFINE(HAVE_INET_PTON, 1, [Define this symbol if you have inet_pton])])
375+
376+
AC_CHECK_DECLS([le32toh, le64toh, htole32, htole64, be32toh, be64toh, htobe32, htobe64],,,
377+
[#if HAVE_ENDIAN_H
378+
#include <endian.h>
379+
#endif])
370380

371381
dnl Check for MSG_NOSIGNAL
372382
AC_MSG_CHECKING(for MSG_NOSIGNAL)
@@ -664,11 +674,15 @@ AM_CONDITIONAL([TARGET_DARWIN], [test x$TARGET_OS = xdarwin])
664674
AM_CONDITIONAL([BUILD_DARWIN], [test x$BUILD_OS = xdarwin])
665675
AM_CONDITIONAL([TARGET_WINDOWS], [test x$TARGET_OS = xwindows])
666676
AM_CONDITIONAL([ENABLE_WALLET],[test x$enable_wallet == xyes])
677+
AM_CONDITIONAL([ENABLE_TESTS],[test x$use_tests == xyes])
678+
AM_CONDITIONAL([ENABLE_QT],[test x$bitcoin_enable_qt == xyes])
679+
AM_CONDITIONAL([ENABLE_QT_TESTS],[test x$use_tests$bitcoin_enable_qt_test = xyesyes])
667680
AM_CONDITIONAL([USE_QRCODE], [test x$use_qr = xyes])
668681
AM_CONDITIONAL([USE_LCOV],[test x$use_lcov == xyes])
669682
AM_CONDITIONAL([USE_COMPARISON_TOOL],[test x$use_comparison_tool != xno])
670683
AM_CONDITIONAL([USE_COMPARISON_TOOL_REORG_TESTS],[test x$use_comparison_tool_reorg_test != xno])
671684
AM_CONDITIONAL([GLIBC_BACK_COMPAT],[test x$use_glibc_compat = xyes])
685+
AM_CONDITIONAL([USE_LIBSECP256K1],[test x$use_libsecp256k1 = xyes])
672686

673687
AC_DEFINE(CLIENT_VERSION_MAJOR, _CLIENT_VERSION_MAJOR, [Major version])
674688
AC_DEFINE(CLIENT_VERSION_MINOR, _CLIENT_VERSION_MINOR, [Minor version])
@@ -693,7 +707,7 @@ AC_SUBST(LEVELDB_TARGET_FLAGS)
693707
AC_SUBST(BUILD_TEST)
694708
AC_SUBST(BUILD_QT)
695709
AC_SUBST(BUILD_TEST_QT)
696-
AC_CONFIG_FILES([Makefile src/Makefile src/test/Makefile src/qt/Makefile src/qt/test/Makefile share/setup.nsi share/qt/Info.plist])
710+
AC_CONFIG_FILES([Makefile src/Makefile share/setup.nsi share/qt/Info.plist])
697711
AC_CONFIG_FILES([qa/pull-tester/run-bitcoind-for-test.sh],[chmod +x qa/pull-tester/run-bitcoind-for-test.sh])
698712
AC_CONFIG_FILES([qa/pull-tester/build-tests.sh],[chmod +x qa/pull-tester/build-tests.sh])
699713
AC_OUTPUT

contrib/bitrpc/bitrpc.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,18 @@
2222
print access.backupwallet(path)
2323
except:
2424
print "\n---An error occurred---\n"
25+
26+
elif cmd == "encryptwallet":
27+
try:
28+
pwd = getpass.getpass(prompt="Enter passphrase: ")
29+
pwd2 = getpass.getpass(prompt="Repeat passphrase: ")
30+
if pwd == pwd2:
31+
access.encryptwallet(pwd)
32+
print "\n---Wallet encrypted. Server stopping, restart to run with encrypted wallet---\n"
33+
else:
34+
print "\n---Passphrases do not match---\n"
35+
except:
36+
print "\n---An error occurred---\n"
2537

2638
elif cmd == "getaccount":
2739
try:

contrib/debian/control

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ Uploaders: Micah Anderson <[email protected]>
66
Build-Depends: debhelper,
77
devscripts,
88
automake,
9+
libtool,
910
bash-completion,
1011
libboost-system-dev (>> 1.35) | libboost-system1.35-dev,
1112
libdb4.8++-dev,

contrib/debian/examples/bitcoin.conf

Lines changed: 63 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,79 +1,110 @@
1-
# bitcoin.conf configuration file. Lines beginning with # are comments.
2-
3-
1+
##
2+
## bitcoin.conf configuration file. Lines beginning with # are comments.
3+
##
4+
45
# Network-related settings:
56

67
# Run on the test network instead of the real bitcoin network.
7-
#testnet=1
8+
#testnet=0
9+
10+
# Run a regression test network
11+
#regtest=0
812

913
# Connect via a socks4 proxy
1014
#proxy=127.0.0.1:9050
1115

16+
##############################################################
17+
## Quick Primer on addnode vs connect ##
18+
## Let's say for instance you use addnode=4.2.2.4 ##
19+
## addnode will connect you to and tell you about the ##
20+
## nodes connected to 4.2.2.4. In addition it will tell ##
21+
## the other nodes connected to it that you exist so ##
22+
## they can connect to you. ##
23+
## connect will not do the above when you 'connect' to it. ##
24+
## It will *only* connect you to 4.2.2.4 and no one else.##
25+
## ##
26+
## So if you're behind a firewall, or have other problems ##
27+
## finding nodes, add some using 'addnode'. ##
28+
## ##
29+
## If you want to stay private, use 'connect' to only ##
30+
## connect to "trusted" nodes. ##
31+
## ##
32+
## If you run multiple nodes on a LAN, there's no need for ##
33+
## all of them to open lots of connections. Instead ##
34+
## 'connect' them all to one node that is port forwarded ##
35+
## and has lots of connections. ##
36+
## Thanks goes to [Noodle] on Freenode. ##
37+
##############################################################
38+
1239
# Use as many addnode= settings as you like to connect to specific peers
1340
#addnode=69.164.218.197
1441
#addnode=10.0.0.2:8333
1542

16-
# ... or use as many connect= settings as you like to connect ONLY
17-
# to specific peers:
43+
# Alternatively use as many connect= settings as you like to connect ONLY to specific peers
1844
#connect=69.164.218.197
1945
#connect=10.0.0.1:8333
2046

47+
# Listening mode, enabled by default except when 'connect' is being used
48+
#listen=1
49+
2150
# Maximum number of inbound+outbound connections.
2251
#maxconnections=
2352

24-
53+
#
2554
# JSON-RPC options (for controlling a running Bitcoin/bitcoind process)
55+
#
2656

27-
# server=1 tells Bitcoin to accept JSON-RPC commands.
28-
#server=1
57+
# server=1 tells Bitcoin-QT and bitcoind to accept JSON-RPC commands
58+
#server=0
2959

3060
# You must set rpcuser and rpcpassword to secure the JSON-RPC api
3161
#rpcuser=Ulysseys
32-
#rpcpassword=YourSuperGreatPasswordNumber_385593
62+
#rpcpassword=YourSuperGreatPasswordNumber_DO_NOT_USE_THIS_OR_YOU_WILL_GET_ROBBED_385593
63+
64+
# How many seconds bitcoin will wait for a complete RPC HTTP request.
65+
# after the HTTP connection is established.
66+
#rpctimeout=30
3367

34-
# By default, only RPC connections from localhost are allowed. Specify
35-
# as many rpcallowip= settings as you like to allow connections from
36-
# other hosts (and you may use * as a wildcard character):
37-
#rpcallowip=10.1.1.34
38-
#rpcallowip=192.168.1.*
68+
# By default, only RPC connections from localhost are allowed.
69+
# Specify as many rpcallowip= settings as you like to allow connections from other hosts,
70+
# either as a single IPv4/IPv6 or with a subnet specification.
71+
72+
# NOTE: opening up the RPC port to hosts outside your local trusted network is NOT RECOMMENDED,
73+
# because the rpcpassword is transmitted over the network unencrypted.
74+
75+
# server=1 tells Bitcoin-QT to accept JSON-RPC commands.
76+
# it is also read by bitcoind to determine if RPC should be enabled
77+
#rpcallowip=10.1.1.34/255.255.255.0
78+
#rpcallowip=1.2.3.4/24
79+
#rpcallowip=2001:db8:85a3:0:0:8a2e:370:7334/96
3980

4081
# Listen for RPC connections on this TCP port:
41-
rpcport=8332
82+
#rpcport=8332
4283

4384
# You can use Bitcoin or bitcoind to send commands to Bitcoin/bitcoind
4485
# running on another host using this option:
45-
rpcconnect=127.0.0.1
86+
#rpcconnect=127.0.0.1
4687

4788
# Use Secure Sockets Layer (also known as TLS or HTTPS) to communicate
4889
# with Bitcoin -server or bitcoind
4990
#rpcssl=1
5091

5192
# OpenSSL settings used when rpcssl=1
52-
rpcsslciphers=TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH
53-
rpcsslcertificatechainfile=server.cert
54-
rpcsslprivatekeyfile=server.pem
93+
#rpcsslciphers=TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH
94+
#rpcsslcertificatechainfile=server.cert
95+
#rpcsslprivatekeyfile=server.pem
5596

5697

5798
# Miscellaneous options
5899

59-
# Set gen=1 to attempt to generate bitcoins
60-
gen=0
61-
62-
# Use SSE instructions to try to generate bitcoins faster.
63-
#4way=1
64-
65100
# Pre-generate this many public/private key pairs, so wallet backups will be valid for
66101
# both prior transactions and several dozen future transactions.
67-
keypool=100
102+
#keypool=100
68103

69104
# Pay an optional transaction fee every time you send bitcoins. Transactions with fees
70105
# are more likely than free transactions to be included in generated blocks, so may
71106
# be validated sooner.
72-
paytxfee=0.00
73-
74-
# Allow direct connections for the 'pay via IP address' feature.
75-
#allowreceivebyip=1
76-
107+
#paytxfee=0.00
77108

78109
# User interface options
79110

contrib/debian/manpages/bitcoin-qt.1

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,9 @@ Execute command when the best block changes (%s in cmd is replaced by block hash
139139
\fB\-walletnotify=\fR<cmd>
140140
Execute command when a wallet transaction changes (%s in cmd is replaced by TxID)
141141
.TP
142+
\fB\-respendnotify=\fR<cmd>
143+
Execute command when a network tx respends wallet tx input (%s=respend TxID, %t=wallet TxID)
144+
.TP
142145
\fB\-alertnotify=\fR<cmd>
143146
Execute command when a relevant alert is received (%s in cmd is replaced by message)
144147
.TP

0 commit comments

Comments
 (0)