Skip to content

Commit

Permalink
Merge pull request #141 from MyHush/dev
Browse files Browse the repository at this point in the history
Sync dev to master in prep of 3.5.0 release
  • Loading branch information
leto authored Sep 23, 2020
2 parents 8c0faf6 + 81f4872 commit 3a276a7
Show file tree
Hide file tree
Showing 606 changed files with 9,422 additions and 3,505 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
*.deb
src/bitcoin
src/test/test_bitcoin
src/core

*zcashTest.pk
*zcashTest.vk
Expand Down Expand Up @@ -156,7 +157,9 @@ src/Makefile.in
doc/man/Makefile.in
Makefile.in
src/libcc.so
src/libcc.dll
src/cc/customcc.so
src/cc/customcc.dll
src/HUSH3_7776
REGTEST_7776
src/cc/librogue.so
Expand Down
2 changes: 1 addition & 1 deletion COPYING
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.


The MIT software license (http://www.opensource.org/licenses/mit-license.php)
The MIT software license (https://www.opensource.org/licenses/mit-license.php)
above applies to the code directly included in this source distribution.
Dependencies downloaded as part of the build process may be covered by other
open-source licenses. For further details see 'contrib/debian/copyright'.
Expand Down
60 changes: 25 additions & 35 deletions configure.ac
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
dnl require autoconf 2.60 (AS_ECHO/AS_ECHO_N)
AC_PREREQ([2.60])
define(_CLIENT_VERSION_MAJOR, 3)
define(_CLIENT_VERSION_MINOR, 4)
define(_CLIENT_VERSION_MINOR, 5)
define(_CLIENT_VERSION_REVISION, 0)
define(_CLIENT_VERSION_BUILD, 50)
define(_CLIENT_VERSION_BUILD, 5)
define(_ZC_BUILD_VAL, m4_if(m4_eval(_CLIENT_VERSION_BUILD < 25), 1, m4_incr(_CLIENT_VERSION_BUILD), m4_eval(_CLIENT_VERSION_BUILD < 50), 1, m4_eval(_CLIENT_VERSION_BUILD - 24), m4_eval(_CLIENT_VERSION_BUILD == 50), 1, , m4_eval(_CLIENT_VERSION_BUILD - 50)))
define(_CLIENT_VERSION_SUFFIX, m4_if(m4_eval(_CLIENT_VERSION_BUILD < 25), 1, _CLIENT_VERSION_REVISION-beta$1, m4_eval(_CLIENT_VERSION_BUILD < 50), 1, _CLIENT_VERSION_REVISION-rc$1, m4_eval(_CLIENT_VERSION_BUILD == 50), 1, _CLIENT_VERSION_REVISION, _CLIENT_VERSION_REVISION-$1)))
define(_CLIENT_VERSION_IS_RELEASE, true)
Expand Down Expand Up @@ -96,12 +96,6 @@ AC_ARG_ENABLE([mining],
[enable_mining=$enableval],
[enable_mining=yes])

AC_ARG_ENABLE([proton],
[AS_HELP_STRING([--disable-proton],
[disable Proton (AMQP messaging)])],
[use_proton=$enableval],
[use_proton=yes])

AC_ARG_ENABLE(tests,
AS_HELP_STRING([--enable-tests],[compile tests (default is yes)]),
[use_tests=$enableval],
Expand Down Expand Up @@ -507,15 +501,24 @@ if test x$use_hardening != xno; then
HARDENED_CPPFLAGS="$HARDENED_CPPFLAGS -D_FORTIFY_SOURCE=2"
],[AC_MSG_ERROR(Cannot enable -D_FORTIFY_SOURCE=2)])

#AX_CHECK_LINK_FLAG([[-Wl,-z,relro]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,-z,relro"],[AC_MSG_ERROR(Cannot enable RELRO)])
#AX_CHECK_LINK_FLAG([[-Wl,-z,now]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,-z,now"],[AC_MSG_ERROR(Cannot enable BIND_NOW)])
if test x$BUILD_OS = xdarwin || test x$TARGET_OS = xwindows; then
# Xcode's ld (at least ld64-302.3) doesn't support -z
# mingw-w64's ld (at least mingw-w64 4.0.4-2) also appears to not support -z
AX_CHECK_LINK_FLAG([[-Wl,-z,relro]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,-z,relro"],[AC_MSG_WARN(Cannot enable RELRO)])
AX_CHECK_LINK_FLAG([[-Wl,-z,now]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,-z,now"],[AC_MSG_WARN(Cannot enable BIND_NOW)])
else
AX_CHECK_LINK_FLAG([[-Wl,-z,relro]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,-z,relro"],[AC_MSG_ERROR(Cannot enable RELRO)])
AX_CHECK_LINK_FLAG([[-Wl,-z,now]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,-z,now"],[AC_MSG_ERROR(Cannot enable BIND_NOW)])
fi

if test x$TARGET_OS != xwindows; then
# All windows code is PIC, forcing it on just adds useless compile warnings
AX_CHECK_LINK_FLAG([[-Wl,-z,relro]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,-z,relro"],[AC_MSG_ERROR(Cannot enable RELRO)])
AX_CHECK_LINK_FLAG([[-Wl,-z,now]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,-z,now"],[AC_MSG_ERROR(Cannot enable BIND_NOW)])
AX_CHECK_COMPILE_FLAG([-fPIE],[HARDENED_CXXFLAGS="$HARDENED_CXXFLAGS -fPIE"],[AC_MSG_ERROR(Cannot enable -fPIE)])
AX_CHECK_LINK_FLAG([[-pie]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -pie"],[AC_MSG_ERROR(Cannot enable -pie)])
AX_CHECK_COMPILE_FLAG([-fPIE],[PIE_FLAGS="-fPIE"],[AC_MSG_ERROR(Cannot enable -fPIE)])
if test x$BUILD_OS = xdarwin; then
AX_CHECK_LINK_FLAG([[-Wl,-pie]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,-pie"],[AC_MSG_ERROR(Cannot enable -Wl,-pie)])
else
AX_CHECK_LINK_FLAG([[-pie]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -pie"],[AC_MSG_ERROR(Cannot enable -pie)])
fi
else
# These are only available on Windows.
AX_CHECK_LINK_FLAG([[-Wl,--dynamicbase]], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,--dynamicbase"],[AC_MSG_ERROR(Cannot enable --dynamicbase)])
Expand Down Expand Up @@ -596,23 +599,6 @@ if test x$enable_wallet != xno; then
BITCOIN_FIND_BDB62
fi

dnl Check Qpid Proton headers and library exist
if test x$use_proton = xyes; then
AC_CHECK_HEADERS([proton/connection.hpp],
[],
[AC_MSG_WARN([Proton headers not found, disabling Proton support])
use_proton=no])
AC_CHECK_LIB([qpid-proton-cpp], [main],
[PROTON_LIBS="-lqpid-proton-cpp -lqpid-proton"],
[AC_MSG_WARN([Proton libraries not found, disabling Proton support])
use_proton=no])
fi
if test x$use_proton = xyes; then
AC_DEFINE(ENABLE_PROTON, 1, [Define to 1 to enable Proton functions])
else
AC_DEFINE(ENABLE_PROTON, 0, [Define to 1 to enable Proton functions])
fi

if test x$build_bitcoin_utils$build_bitcoind$use_tests = xnonono; then
use_boost=no
else
Expand Down Expand Up @@ -756,6 +742,14 @@ fi
fi
fi

# These packages don't provide pkgconfig config files across all
# platforms, so we use older autoconf detection mechanisms:
AC_CHECK_HEADER([gmp.h],,AC_MSG_ERROR(libgmp headers missing))
AC_CHECK_LIB([gmp],[[__gmpn_sub_n]],GMP_LIBS=-lgmp, [AC_MSG_ERROR(libgmp missing)])

AC_CHECK_HEADER([gmpxx.h],,AC_MSG_ERROR(libgmpxx headers missing))
AC_CHECK_LIB([gmpxx],[main],GMPXX_LIBS=-lgmpxx, [AC_MSG_ERROR(libgmpxx missing)])

RUST_LIBS="-lrustzcash"
case $host in
*mingw*)
Expand Down Expand Up @@ -832,8 +826,6 @@ fi

AM_CONDITIONAL([ENABLE_ZMQ], [test "x$use_zmq" = "xyes"])

AM_CONDITIONAL([ENABLE_PROTON], [test "x$use_proton" = "xyes"])

AC_MSG_CHECKING([whether to build test_bitcoin])
if test x$use_tests = xyes; then
AC_MSG_RESULT([yes])
Expand Down Expand Up @@ -906,7 +898,6 @@ AC_SUBST(ZMQ_LIBS)
AC_SUBST(GMP_LIBS)
AC_SUBST(GMPXX_LIBS)
AC_SUBST(LIBZCASH_LIBS)
AC_SUBST(PROTON_LIBS)
AC_CONFIG_FILES([Makefile src/Makefile doc/man/Makefile 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.sh],[chmod +x qa/pull-tester/tests-config.sh])
Expand Down Expand Up @@ -953,7 +944,6 @@ esac
echo
echo "Options used to compile and link:"
echo " with wallet = $enable_wallet"
echo " with proton = $use_proton"
echo " with zmq = $use_zmq"
echo " with test = $use_tests"
echo " debug enabled = $enable_debug"
Expand Down
48 changes: 0 additions & 48 deletions contrib/amqp/amqp_sub.py

This file was deleted.

10 changes: 7 additions & 3 deletions contrib/checkpoints.pl
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/usr/bin/perl
# Copyright 2019 The Hush developers
# Copyright 2019-2020 The Hush developers
# Released under the GPLv3
use warnings;
use strict;
Expand All @@ -9,9 +9,13 @@
my $perday = 576;
my $hush = "./src/hush-cli";
my $gethash = "$hush getblockhash";
my $stride = shift || 1000;
my $stride = shift || 5000;
my $count = 0;
my $blocks = qx{$hush getblockcount};
if($?) {
print "ERROR, exiting...\n";
exit 1;
}
my $prev = $blocks - $perday;
my $last = 0;
my $now = time();
Expand Down Expand Up @@ -53,4 +57,4 @@
}
print "(int64_t) $time, // time of last checkpointed block\n";
print "(int64_t) $total_txs, // total txs\n";
print "(double) $txs_per_day, // txs in the last day before block $blocks\n";
print "(double) $txs_per_day // txs in the last day before block $blocks\n";
Loading

0 comments on commit 3a276a7

Please sign in to comment.