diff --git a/Makefile.am b/Makefile.am index 266c75b43..09cd9b92e 100644 --- a/Makefile.am +++ b/Makefile.am @@ -31,8 +31,7 @@ BIN_CHECKS=$(top_srcdir)/contrib/devtools/symbol-check.py \ WINDOWS_PACKAGING = $(top_srcdir)/share/pixmaps/bitcoin.ico \ $(top_srcdir)/share/pixmaps/nsis-header.bmp \ - $(top_srcdir)/share/pixmaps/nsis-wizard.bmp \ - $(top_srcdir)/doc/README_windows.txt + $(top_srcdir)/share/pixmaps/nsis-wizard.bmp OSX_PACKAGING = $(OSX_DEPLOY_SCRIPT) $(OSX_FANCY_PLIST) $(OSX_INSTALLER_ICONS) $(OSX_BASE_LPROJ_DIR) \ $(top_srcdir)/contrib/macdeploy/$(OSX_BACKGROUND_IMAGE) \ @@ -261,7 +260,7 @@ endif dist_noinst_SCRIPTS = autogen.sh -EXTRA_DIST = $(top_srcdir)/share/genbuild.sh qa/pull-tester/rpc-tests.sh qa/pull-tester/run-bitcoin-cli qa/rpc-tests qa/zcash $(DIST_DOCS) $(WINDOWS_PACKAGING) $(OSX_PACKAGING) $(BIN_CHECKS) +EXTRA_DIST = $(top_srcdir)/share/genbuild.sh qa/pull-tester/rpc-tests.sh qa/pull-tester/run-bitcoin-cli qa/rpc-tests qa/zcash $(DIST_DOCS) $(BIN_CHECKS) CLEANFILES = $(OSX_DMG) $(BITCOIN_WIN_INSTALLER) diff --git a/configure.ac b/configure.ac index 7662c22e3..b1ec277ac 100644 --- a/configure.ac +++ b/configure.ac @@ -4,9 +4,11 @@ define(_CLIENT_VERSION_MAJOR, 1) define(_CLIENT_VERSION_MINOR, 0) define(_CLIENT_VERSION_REVISION, 0) define(_CLIENT_VERSION_BUILD, 1) +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, false) define(_COPYRIGHT_YEAR, 2016) -AC_INIT([Zcash],[_CLIENT_VERSION_MAJOR._CLIENT_VERSION_MINOR._CLIENT_VERSION_REVISION],[https://github.com/zcash/zcash/issues],[zcash]) +AC_INIT([Zcash],[_CLIENT_VERSION_MAJOR._CLIENT_VERSION_MINOR._CLIENT_VERSION_SUFFIX(_ZC_BUILD_VAL)],[https://github.com/zcash/zcash/issues],[zcash]) AC_CONFIG_SRCDIR([src/main.cpp]) AC_CONFIG_HEADERS([src/config/bitcoin-config.h]) AC_CONFIG_AUX_DIR([build-aux]) diff --git a/contrib/devtools/split-debug.sh b/contrib/devtools/split-debug.sh new file mode 100755 index 000000000..16fda3005 --- /dev/null +++ b/contrib/devtools/split-debug.sh @@ -0,0 +1,10 @@ +#!/bin/sh + +if [ $# -ne 3 ]; + then echo "usage: $0 " +fi + +/usr/bin/objcopy --enable-deterministic-archives -p --only-keep-debug $1 $3 +/usr/bin/objcopy --enable-deterministic-archives -p --strip-debug $1 $2 +/usr/bin/strip --enable-deterministic-archives -p -s $2 +/usr/bin/objcopy --enable-deterministic-archives -p --add-gnu-debuglink=$3 $2 diff --git a/contrib/gitian-descriptors/gitian-linux.yml b/contrib/gitian-descriptors/gitian-linux.yml index fbaf4c89a..7a006b343 100644 --- a/contrib/gitian-descriptors/gitian-linux.yml +++ b/contrib/gitian-descriptors/gitian-linux.yml @@ -1,37 +1,45 @@ --- -name: "bitcoin-linux-0.11" +name: "zcash-1.0.0-rc1" enable_cache: true +distro: "debian" suites: -- "trusty" +- "jessie" architectures: - "amd64" packages: -- "g++-multilib" -- "git-core" -- "pkg-config" - "autoconf" -- "libtool" - "automake" -- "faketime" - "bsdmainutils" - "binutils-gold" - "ca-certificates" +- "faketime" +- "g++-multilib" +- "git-core" +- "libc6-dev" +- "libtool" +- "m4" +- "ncurses-dev" +- "pkg-config" - "python" +- "unzip" +- "wget" +- "zlib1g-dev" remotes: -- "url": "https://github.com/bitcoin/bitcoin.git" - "dir": "bitcoin" +- "url": "https://github.com/zcash/zcash.git" + "dir": "zcash" files: [] script: | WRAP_DIR=$HOME/wrapped - HOSTS="i686-pc-linux-gnu x86_64-unknown-linux-gnu" - CONFIGFLAGS="--enable-glibc-back-compat --enable-reduce-exports --disable-bench --disable-gui-tests" + HOSTS="x86_64-unknown-linux-gnu" + CONFIGFLAGS="--enable-glibc-back-compat --enable-reduce-exports --disable-bench --disable-gui-tests --with-gui=no --enable-hardening" + MAKEOPTS="V=1 NO_QT=1" FAKETIME_HOST_PROGS="" FAKETIME_PROGS="date ar ranlib nm strip objcopy" - HOST_CFLAGS="-O2 -g" - HOST_CXXFLAGS="-O2 -g" + HOST_CFLAGS="-fwrapv -fno-strict-aliasing -Werror -g" + HOST_CXXFLAGS="-fwrapv -fno-strict-aliasing -Werror -g" HOST_LDFLAGS=-static-libstdc++ - export QT_RCC_TEST=1 + export QT_RCC_TEST=0 export GZIP="-9n" export TAR_OPTIONS="--mtime="$REFERENCE_DATE\\\ $REFERENCE_TIME"" export TZ="UTC" @@ -73,7 +81,7 @@ script: | create_global_faketime_wrappers "2000-01-01 12:00:00" create_per-host_faketime_wrappers "2000-01-01 12:00:00" - cd bitcoin + cd zcash BASEPREFIX=`pwd`/depends # Build dependencies for each host for i in $HOSTS; do @@ -88,13 +96,13 @@ script: | ./autogen.sh CONFIG_SITE=${BASEPREFIX}/`echo "${HOSTS}" | awk '{print $1;}'`/share/config.site ./configure --prefix=/ make dist - SOURCEDIST=`echo bitcoin-*.tar.gz` + SOURCEDIST=`echo zcash-*.tar.gz` DISTNAME=`echo ${SOURCEDIST} | sed 's/.tar.*//'` # Correct tar file order mkdir -p temp pushd temp tar xf ../$SOURCEDIST - find bitcoin-* | sort | tar --no-recursion --mode='u+rw,go+r-w,a+X' --owner=0 --group=0 -c -T - | gzip -9n > ../$SOURCEDIST + find zcash* | sort | tar --no-recursion --mode='u+rw,go+r-w,a+X' --owner=0 --group=0 -c -T - | gzip -9n > ../$SOURCEDIST popd ORIGPATH="$PATH" @@ -125,7 +133,5 @@ script: | mkdir -p $OUTDIR/src mv $SOURCEDIST $OUTDIR/src mv ${OUTDIR}/${DISTNAME}-x86_64-*-debug.tar.gz ${OUTDIR}/${DISTNAME}-linux64-debug.tar.gz - mv ${OUTDIR}/${DISTNAME}-i686-*-debug.tar.gz ${OUTDIR}/${DISTNAME}-linux32-debug.tar.gz mv ${OUTDIR}/${DISTNAME}-x86_64-*.tar.gz ${OUTDIR}/${DISTNAME}-linux64.tar.gz - mv ${OUTDIR}/${DISTNAME}-i686-*.tar.gz ${OUTDIR}/${DISTNAME}-linux32.tar.gz diff --git a/src/Makefile.am b/src/Makefile.am index e82754e00..9f8a18189 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -69,15 +69,16 @@ if BUILD_BITCOIN_UTILS bin_PROGRAMS += zcash-cli bitcoin-tx endif -# TODO: rename to libzcash LIBZCASH_H = \ - zcash/IncrementalMerkleTree.h \ + zcash/IncrementalMerkleTree.hpp \ zcash/NoteEncryption.hpp \ zcash/Address.hpp \ zcash/JoinSplit.hpp \ zcash/Note.hpp \ zcash/prf.h \ - zcash/util.h + zcash/Proof.hpp \ + zcash/util.h \ + zcash/Zcash.h .PHONY: FORCE check-symbols check-security # bitcoin core # @@ -194,6 +195,7 @@ libbitcoin_server_a_SOURCES = \ sendalert.cpp \ addrman.cpp \ alert.cpp \ + alertkeys.h \ asyncrpcoperation.cpp \ asyncrpcqueue.cpp \ bloom.cpp \ @@ -229,6 +231,7 @@ libbitcoin_server_a_SOURCES = \ libbitcoin_wallet_a_CPPFLAGS = $(BITCOIN_INCLUDES) libbitcoin_wallet_a_SOURCES = \ zcbenchmarks.cpp \ + zcbenchmarks.h \ wallet/asyncrpcoperation_sendmany.cpp \ wallet/crypter.cpp \ wallet/db.cpp \ @@ -246,6 +249,7 @@ crypto_libbitcoin_crypto_a_SOURCES = \ crypto/common.h \ crypto/equihash.cpp \ crypto/equihash.h \ + crypto/equihash.tcc \ crypto/hmac_sha256.cpp \ crypto/hmac_sha256.h \ crypto/hmac_sha512.cpp \ @@ -420,7 +424,13 @@ libzcash_a_SOURCES = \ zcash/Proof.cpp \ zcash/Note.cpp \ zcash/prf.cpp \ - zcash/util.cpp + zcash/util.cpp \ + zcash/circuit/commitment.tcc \ + zcash/circuit/gadget.tcc \ + zcash/circuit/merkle.tcc \ + zcash/circuit/note.tcc \ + zcash/circuit/prfs.tcc \ + zcash/circuit/utils.tcc libzcash_a_CPPFLAGS = -DMULTICORE -fopenmp -fPIC -DBINARY_OUTPUT -DCURVE_ALT_BN128 -DBOOST_SPIRIT_THREADSAFE -DHAVE_BUILD_INFO -D__STDC_FORMAT_MACROS $(HARDENED_CPPFLAGS) -pipe -O1 -g -Wstack-protector -fstack-protector-all -fPIE -fvisibility=hidden -DSTATIC $(BITCOIN_INCLUDES) diff --git a/src/Makefile.gtest.include b/src/Makefile.gtest.include index d08b7d607..d68c9a98a 100644 --- a/src/Makefile.gtest.include +++ b/src/Makefile.gtest.include @@ -6,6 +6,7 @@ zcash_gtest_SOURCES = \ gtest/main.cpp \ gtest/test_checktransaction.cpp \ gtest/json_test_vectors.cpp \ + gtest/json_test_vectors.h \ gtest/test_foundersreward.cpp \ gtest/test_wallet_zkeys.cpp \ gtest/test_jsonspirit.cpp \