Skip to content

Commit

Permalink
Merge litecoin 0.8.7.1
Browse files Browse the repository at this point in the history
* Upgrade gitian dependencies
* Many bug fixes from Bitcoin 0.8.7rc stable branch including
transaction malleability and mitigation backports from 0.9

Fixes dashpay#19
  • Loading branch information
erkmos committed Apr 28, 2014
2 parents e672120 + ccd9a1f commit 9898a59
Show file tree
Hide file tree
Showing 118 changed files with 965 additions and 352 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,4 @@ Info
Vertcoin-Qt.xcodeproj
Vertcoin-Qt.dmg

!src/leveldb-*/Makefile
!src/leveldb*/Makefile
45 changes: 4 additions & 41 deletions contrib/gitian-descriptors/README
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
Refer to doc/release-notes.md for directions on obtaining inputs/ and using gitian to build Litecoin.
================================================================

Gavin's notes on getting gitian builds up and running using KVM:
-----------------------------------------------

These instructions distilled from:
https://help.ubuntu.com/community/KVM/Installation
Expand All @@ -15,47 +19,6 @@ Sanity checks:
sudo service apt-cacher-ng status # Should return apt-cacher-ng is running
ls -l /dev/kvm # Should show a /dev/kvm device


Once you've got the right hardware and software:

git clone git://github.com/bitcoin/bitcoin.git
git clone git://github.com/devrandom/gitian-builder.git
mkdir gitian-builder/inputs
cd gitian-builder/inputs
# Inputs for Linux and Win32:
wget -O miniupnpc-1.6.tar.gz 'http://miniupnp.tuxfamily.org/files/download.php?file=miniupnpc-1.6.tar.gz'
wget 'http://fukuchi.org/works/qrencode/qrencode-3.2.0.tar.bz2'
# Inputs for Win32: (Linux has packages for these)
wget 'https://downloads.sourceforge.net/project/boost/boost/1.50.0/boost_1_50_0.tar.bz2'
wget 'http://www.openssl.org/source/openssl-1.0.1f.tar.gz'
wget 'http://download.oracle.com/berkeley-db/db-4.8.30.NC.tar.gz'
wget 'https://downloads.sourceforge.net/project/libpng/zlib/1.2.6/zlib-1.2.6.tar.gz'
wget 'https://downloads.sourceforge.net/project/libpng/libpng15/older-releases/1.5.9/libpng-1.5.9.tar.gz'
wget 'http://releases.qt-project.org/qt4/source/qt-everywhere-opensource-src-4.8.3.tar.gz'
cd ../..

cd gitian-builder
bin/make-base-vm --arch i386
bin/make-base-vm --arch amd64
cd ..

# Build Linux release:
cd bitcoin
git pull
cd ../gitian-builder
git pull
./bin/gbuild --commit bitcoin=HEAD ../bitcoin/contrib/gitian-descriptors/gitian.yml

# Build Win32 dependencies: (only needs to be done once, or when dependency versions change)
./bin/gbuild --commit bitcoin=HEAD ../bitcoin/contrib/gitian-descriptors/boost-win32.yml
./bin/gbuild --commit bitcoin=HEAD ../bitcoin/contrib/gitian-descriptors/deps-win32.yml
./bin/gbuild --commit bitcoin=HEAD ../bitcoin/contrib/gitian-descriptors/qt-win32.yml

# Build Win32 release:
./bin/gbuild --commit bitcoin=HEAD ../bitcoin/contrib/gitian-descriptors/gitian-win32.yml

---------------------

gitian-builder now also supports building using LXC. See
https://help.ubuntu.com/12.04/serverguide/lxc.html
... for how to get LXC up and running under Ubuntu.
Expand Down
1 change: 0 additions & 1 deletion contrib/gitian-descriptors/boost-win32.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,4 +64,3 @@ script: |
export FAKETIME=$REFERENCE_DATETIME
zip -r boost-win32-1.55.0-gitian-r6.zip *
cp boost-win32-1.55.0-gitian-r6.zip $OUTDIR
36 changes: 22 additions & 14 deletions contrib/gitian-descriptors/deps-win32.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,25 @@ remotes: []
files:
- "openssl-1.0.1g.tar.gz"
- "db-4.8.30.NC.tar.gz"
- "miniupnpc-1.6.tar.gz"
- "zlib-1.2.6.tar.gz"
- "libpng-1.5.9.tar.gz"
- "qrencode-3.2.0.tar.bz2"
- "miniupnpc-1.9.20140401.tar.gz"
- "zlib-1.2.8.tar.gz"
- "libpng-1.6.10.tar.gz"
- "qrencode-3.4.3.tar.bz2"
script: |
#
export LD_PRELOAD=/usr/lib/faketime/libfaketime.so.1
export FAKETIME=$REFERENCE_DATETIME
export TZ=UTC
export INSTALLPREFIX=$OUTDIR/staging/deps
export HOST=i686-w64-mingw32
# Integrity Check
echo "53cb818c3b90e507a8348f4f5eaedb05d8bfe5358aabb508b7263cc670c3e028 openssl-1.0.1g.tar.gz" | sha256sum -c
echo "12edc0df75bf9abd7f82f821795bcee50f42cb2e5f76a6a281b85732798364ef db-4.8.30.NC.tar.gz" | sha256sum -c
echo "d02670112125300f7a3d61421714d99105edd90190bf12542d16785f16f017aa miniupnpc-1.9.20140401.tar.gz" | sha256sum -c
echo "36658cb768a54c1d4dec43c3116c27ed893e88b02ecfcb44f2166f9c0b7f2a0d zlib-1.2.8.tar.gz" | sha256sum -c
echo "b0206a22b49c91fc5521b2cfb1c251433a37aed0a645bc504ab3d061f27e4d51 libpng-1.6.10.tar.gz" | sha256sum -c
echo "dfd71487513c871bad485806bfd1fdb304dedc84d2b01a8fb8e0940b50597a98 qrencode-3.4.3.tar.bz2" | sha256sum -c
#
mkdir -p $INSTALLPREFIX
Expand All @@ -44,8 +52,8 @@ script: |
make install_lib install_include
cd ../..
#
tar xzf miniupnpc-1.6.tar.gz
cd miniupnpc-1.6
tar xzf miniupnpc-1.9.20140401.tar.gz
cd miniupnpc-1.9.20140401
echo "
--- miniupnpc-1.6/Makefile.mingw.orig 2013-09-29 18:52:51.014087958 -1000
+++ miniupnpc-1.6/Makefile.mingw 2013-09-29 19:09:29.663318691 -1000
Expand All @@ -68,26 +76,26 @@ script: |
install libminiupnpc.a $INSTALLPREFIX/lib
cd ..
#
tar xzf zlib-1.2.6.tar.gz
cd zlib-1.2.6
tar xzf zlib-1.2.8.tar.gz
cd zlib-1.2.8
CROSS_PREFIX=$HOST- ./configure --prefix=$INSTALLPREFIX --static
make
make install
cd ..
#
tar xzf libpng-1.5.9.tar.gz
cd libpng-1.5.9
CFLAGS="-I$INSTALLPREFIX/include" LDFLAGS="-L$INSTALLPREFIX/lib" ./configure --disable-shared --prefix=$INSTALLPREFIX --host=$HOST
tar xzf libpng-1.6.10.tar.gz
cd libpng-1.6.10
CPPFLAGS="-I$INSTALLPREFIX/include" LDFLAGS="-L$INSTALLPREFIX/lib" ./configure --disable-shared --prefix=$INSTALLPREFIX --host=$HOST
make $MAKEOPTS
make install
cd ..
#
tar xjf qrencode-3.2.0.tar.bz2
cd qrencode-3.2.0
tar xjf qrencode-3.4.3.tar.bz2
cd qrencode-3.4.3
png_CFLAGS="-I$INSTALLPREFIX/include" png_LIBS="-L$INSTALLPREFIX/lib -lpng" ./configure --prefix=$INSTALLPREFIX --host=$HOST
make
make install
cd ..
#
cd $INSTALLPREFIX
zip -r $OUTDIR/vertcoin-deps-win32-gitian-r1.zip include lib
zip -r $OUTDIR/vertcoin-deps-win32-gitian-r2.zip include lib
12 changes: 6 additions & 6 deletions contrib/gitian-descriptors/gitian-win64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,22 +13,22 @@ packages:
- "faketime"
reference_datetime: "2011-01-30 00:00:00"
remotes:
- "url": "https://github.com/vertcoin/vertcoin.git"
- "url": "https://github.com/erkmos/vertcoin.git"
"dir": "vertcoin"
files:
- "qt-win32-4.8.3-gitian-r4.zip"
- "qt-win32-4.8.5-gitian-r5.zip"
- "boost-win32-1.55.0-gitian-r6.zip"
- "vertcoin-deps-win32-gitian-r1.zip"
- "vertcoin-deps-win32-gitian-r2.zip"
script: |
#
STAGING=$HOME/staging
HOST=i686-w64-mingw32
#
mkdir -p $STAGING
cd $STAGING
unzip ../build/qt-win32-4.8.3-gitian-r4.zip
unzip ../build/qt-win32-4.8.5-gitian-r5.zip
unzip ../build/boost-win32-1.55.0-gitian-r6.zip
unzip ../build/vertcoin-deps-win32-gitian-r1.zip
unzip ../build/vertcoin-deps-win32-gitian-r2.zip
cd $HOME/build/
#
cd vertcoin
Expand All @@ -41,7 +41,7 @@ script: |
export FAKETIME=$REFERENCE_DATETIME
export TZ=UTC
ln -s $STAGING $HOME/qt
$HOME/staging/host/bin/qmake -spec unsupported/win32-g++-cross MINIUPNPC_LIB_PATH=$STAGING MINIUPNPC_INCLUDE_PATH=$STAGING BDB_LIB_PATH=$STAGING BDB_INCLUDE_PATH=$STAGING BOOST_LIB_PATH=$STAGING BOOST_INCLUDE_PATH=$STAGING BOOST_LIB_SUFFIX=-mt-s BOOST_THREAD_LIB_SUFFIX=_win32-mt-s OPENSSL_LIB_PATH=$STAGING OPENSSL_INCLUDE_PATH=$STAGING QRENCODE_LIB_PATH=$STAGING QRENCODE_INCLUDE_PATH=$STAGING USE_QRCODE=1 INCLUDEPATH=$STAGING DEFINES=BOOST_THREAD_USE_LIB BITCOIN_NEED_QT_PLUGINS=1 QMAKE_LRELEASE=lrelease QMAKE_CXXFLAGS=-frandom-seed=vertcoin USE_BUILD_INFO=1 USE_SSE2=1
$HOME/staging/host/bin/qmake -spec unsupported/win32-g++-cross MINIUPNPC_LIB_PATH=$STAGING MINIUPNPC_INCLUDE_PATH=$STAGING BDB_LIB_PATH=$STAGING BDB_INCLUDE_PATH=$STAGING BOOST_LIB_PATH=$STAGING BOOST_INCLUDE_PATH=$STAGING BOOST_LIB_SUFFIX=-mt-s BOOST_THREAD_LIB_SUFFIX=_win32-mt-s OPENSSL_LIB_PATH=$STAGING OPENSSL_INCLUDE_PATH=$STAGING QRENCODE_LIB_PATH=$STAGING QRENCODE_INCLUDE_PATH=$STAGING USE_QRCODE=1 INCLUDEPATH=$STAGING DEFINES=BOOST_THREAD_USE_LIB BITCOIN_NEED_QT_PLUGINS=1 QMAKE_LRELEASE=lrelease QMAKE_CXXFLAGS=-frandom-seed=vertcoin USE_BUILD_INFO=1 USE_SSE2=1 USE_UPNP=1
make $MAKEOPTS
$HOST-strip release/vertcoin-qt.exe
cp release/vertcoin-qt.exe $OUTDIR/
Expand Down
2 changes: 1 addition & 1 deletion contrib/gitian-descriptors/gitian.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ packages:
- "libpng12-dev"
reference_datetime: "2011-01-30 00:00:00"
remotes:
- "url": "https://github.com/vertcoin/vertcoin.git"
- "url": "https://github.com/erkmos/vertcoin.git"
"dir": "vertcoin"
files:
- "vertcoin-deps-linux32-gitian-r1.zip"
Expand Down
11 changes: 6 additions & 5 deletions contrib/gitian-descriptors/qt-win32.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,22 +10,23 @@ packages:
- "zip"
- "unzip"
- "faketime"
- "unzip"
reference_datetime: "2011-01-30 00:00:00"
remotes: []
files:
- "qt-everywhere-opensource-src-4.8.5.tar.gz"
- "vertcoin-deps-win32-gitian-r1.zip"
- "vertcoin-deps-win32-gitian-r2.zip"
script: |
#
HOST=i686-w64-mingw32
INSTDIR="$HOME/qt/"
# Integrity Check
echo "eb728f8268831dc4373be6403b7dd5d5dde03c169ad6882f9a8cb560df6aa138 qt-everywhere-opensource-src-4.8.5.tar.gz" | sha256sum -c
#
mkdir $INSTDIR
mkdir -p $INSTDIR/host/bin
#
# Need mingw-compiled openssl from bitcoin-deps:
unzip vertcoin-deps-win32-gitian-r1.zip
# Need mingw-compiled openssl from vertcoin-deps:
unzip vertcoin-deps-win32-gitian-r2.zip
DEPSDIR=`pwd`
#
tar xzf qt-everywhere-opensource-src-4.8.5.tar.gz
Expand Down Expand Up @@ -60,4 +61,4 @@ script: |
# as zip stores file timestamps, use faketime to intercept stat calls to set dates for all files to reference date
export LD_PRELOAD=/usr/lib/faketime/libfaketime.so.1
zip -r $OUTDIR/qt-win32-4.8.3-gitian-r4.zip *
zip -r $OUTDIR/qt-win32-4.8.5-gitian-r5.zip *
2 changes: 1 addition & 1 deletion doc/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Vertcoin 0.8.x BETA
====================

Copyright (c) 2009-2013 Bitcoin Developers
Copyright (c) 2011-2013 Litecoin Developers
Copyright (c) 2011-2013 Vertcoin Developers
Copyright (c) 2014 Vertcoin Developers

Distributed under the MIT/X11 software license, see the accompanying
Expand Down
4 changes: 2 additions & 2 deletions doc/build-msw.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ MSYS shell:

Boost
-----
DOS prompt:
MSYS shell:

downloaded boost jam 3.1.18
cd \boost-1.50.0-mgw
Expand All @@ -82,7 +82,7 @@ MSYS shell:

Vertcoin
-------
DOS prompt:
MSYS shell:

cd \vertcoin\src
mingw32-make -f makefile.mingw
Expand Down
9 changes: 9 additions & 0 deletions doc/release-notes.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
0.8.7.1 changes
=============
- Mac and Windows Official Gitian Builds: upgrade to openssl-1.0.1g for CVE-2014-0160
Linux was not vulnerable with Lucid openssl-0.9.8k
Older versions were only vulnerable with rarely used RPC SSL
- If you build from source, be sure that your openssl is patched for CVE-2014-0160.
- Upgrade openssl, qt, miniupnpc, zlib, libpng, qrencode
- Many bug fixes from Bitcoin 0.8.7rc stable branch
including transaction malleability mitigation backports from 0.9

0.8.6.4 changes
===============
Expand Down
61 changes: 13 additions & 48 deletions doc/release-process.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Release Process

###tag version in git

git tag -a v0.8.0
git tag -s v0.8.7

###write release notes. git shortlog helps a lot, for example:

Expand All @@ -27,20 +27,20 @@ Release Process
From a directory containing the vertcoin source, gitian-builder and gitian.sigs

export SIGNER=(your gitian key, ie bluematt, sipa, etc)
export VERSION=0.8.0
export VERSION=0.8.7
cd ./gitian-builder

Fetch and build inputs: (first time, or when dependency versions change)

mkdir -p inputs; cd inputs/
wget 'http://miniupnp.free.fr/files/download.php?file=miniupnpc-1.6.tar.gz' -O miniupnpc-1.6.tar.gz
wget 'http://www.openssl.org/source/openssl-1.0.1c.tar.gz'
wget 'http://miniupnp.free.fr/files/download.php?file=miniupnpc-1.9.20140401.tar.gz' -O miniupnpc-1.9.20140401.tar.gz'
wget 'http://www.openssl.org/source/openssl-1.0.1g.tar.gz'
wget 'http://download.oracle.com/berkeley-db/db-4.8.30.NC.tar.gz'
wget 'http://zlib.net/zlib-1.2.6.tar.gz'
wget 'ftp://ftp.simplesystems.org/pub/libpng/png/src/libpng-1.5.9.tar.gz'
wget 'http://fukuchi.org/works/qrencode/qrencode-3.2.0.tar.bz2'
wget 'http://downloads.sourceforge.net/project/boost/boost/1.50.0/boost_1_50_0.tar.bz2'
wget 'http://releases.qt-project.org/qt4/source/qt-everywhere-opensource-src-4.8.3.tar.gz'
wget 'http://zlib.net/zlib-1.2.8.tar.gz'
wget 'ftp://ftp.simplesystems.org/pub/libpng/png/src/history/libpng16/libpng-1.6.8.tar.gz'
wget 'http://fukuchi.org/works/qrencode/qrencode-3.4.3.tar.bz2'
wget 'http://downloads.sourceforge.net/project/boost/boost/1.55.0/boost_1_55_0.tar.bz2'
wget 'http://download.qt-project.org/official_releases/qt/4.8/4.8.5/qt-everywhere-opensource-src-4.8.5.tar.gz'
cd ..
./bin/gbuild ../vertcoin/contrib/gitian-descriptors/boost-win32.yml
mv build/out/boost-win32-1.50.0-gitian2.zip inputs/
Expand Down Expand Up @@ -87,16 +87,17 @@ repackage gitian builds for release as stand-alone zip/tar/installer exe

**Perform Mac build:**

OSX binaries are created by Gavin Andresen on a 32-bit, OSX 10.6 machine.
OSX binaries are created on a dedicated 32-bit, OSX 10.6.8 machine.
Vertcoin 0.8.x is built with MacPorts. 0.9.x will be Homebrew only.

qmake RELEASE=1 USE_UPNP=1 USE_QRCODE=1 vertcoin-qt.pro
make
export QTDIR=/opt/local/share/qt4 # needed to find translations/qt_*.qm files
T=$(contrib/qt_translations.py $QTDIR/translations src/qt/locale)
python2.7 share/qt/clean_mac_info_plist.py
python2.7 contrib/macdeploy/macdeployqtplus Bitcoin-Qt.app -add-qt-tr $T -dmg -fancy contrib/macdeploy/fancy.plist
python2.7 contrib/macdeploy/macdeployqtplus Vertcoin-Qt.app -add-qt-tr $T -dmg -fancy contrib/macdeploy/fancy.plist

Build output expected: Bitcoin-Qt.dmg
Build output expected: Vertcoin-Qt.dmg

###Next steps:

Expand All @@ -114,8 +115,6 @@ repackage gitian builds for release as stand-alone zip/tar/installer exe

* update wiki download links

* update wiki changelog: [https://en.vertcoin.it/wiki/Changelog](https://en.bitcoin.it/wiki/Changelog)

Commit your signature to gitian.sigs:

pushd gitian.sigs
Expand All @@ -125,37 +124,3 @@ Commit your signature to gitian.sigs:
git push # Assuming you can push to the gitian.sigs tree
popd

-------------------------------------------------------------------------

### After 3 or more people have gitian-built, repackage gitian-signed zips:

From a directory containing vertcoin source, gitian.sigs and gitian zips

export VERSION=0.5.1
mkdir vertcoin-${VERSION}-linux-gitian
pushd vertcoin-${VERSION}-linux-gitian
unzip ../vertcoin-${VERSION}-linux-gitian.zip
mkdir gitian
cp ../vertcoin/contrib/gitian-downloader/*.pgp ./gitian/
for signer in $(ls ../gitian.sigs/${VERSION}/); do
cp ../gitian.sigs/${VERSION}/${signer}/vertcoin-build.assert ./gitian/${signer}-build.assert
cp ../gitian.sigs/${VERSION}/${signer}/vertcoin-build.assert.sig ./gitian/${signer}-build.assert.sig
done
zip -r vertcoin-${VERSION}-linux-gitian.zip *
cp vertcoin-${VERSION}-linux-gitian.zip ../
popd
mkdir vertcoin-${VERSION}-win32-gitian
pushd vertcoin-${VERSION}-win32-gitian
unzip ../vertcoin-${VERSION}-win32-gitian.zip
mkdir gitian
cp ../vertcoin/contrib/gitian-downloader/*.pgp ./gitian/
for signer in $(ls ../gitian.sigs/${VERSION}-win32/); do
cp ../gitian.sigs/${VERSION}-win32/${signer}/vertcoin-build.assert ./gitian/${signer}-build.assert
cp ../gitian.sigs/${VERSION}-win32/${signer}/vertcoin-build.assert.sig ./gitian/${signer}-build.assert.sig
done
zip -r vertcoin-${VERSION}-win32-gitian.zip *
cp vertcoin-${VERSION}-win32-gitian.zip ../
popd

- Upload gitian zips to SourceForge
- Celebrate
Loading

0 comments on commit 9898a59

Please sign in to comment.