Skip to content

Commit 4ecd908

Browse files
committed
Update building docs
1 parent 7f1d5cc commit 4ecd908

File tree

7 files changed

+187
-284
lines changed

7 files changed

+187
-284
lines changed

INSTALL

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
Building Bitcoin
1+
Building NovaCoin
22

3-
See doc/readme-qt.rst for instructions on building Bitcoin QT,
3+
See doc/readme-qt.rst for instructions on building NovaCoin Qt,
44
the intended-for-end-users, nice-graphical-interface, reference
5-
implementation of Bitcoin.
5+
implementation of NovaCoin.
66

7-
See doc/build-*.txt for instructions on building bitcoind,
7+
See doc/build-*.txt for instructions on building novacoind,
88
the intended-for-services, no-graphical-interface, reference
9-
implementation of Bitcoin.
9+
implementation of NovaCoin.

doc/README

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
NovaCoin 0.4.4 BETA
1+
NovaCoin 0.5.0 BETA
22

33
Copyright (c) 2013 NovaCoin Developers
44
Copyright (c) 2011-2012 PPCoin Developers

doc/build-msw.txt

+12-12
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ Dependencies
2525
Libraries you need to download separately and build:
2626

2727
default path download
28-
OpenSSL \openssl-1.0.1b-mgw http://www.openssl.org/source/
29-
Berkeley DB \db-4.8.30.NC-mgw http://www.oracle.com/technology/software/products/berkeley-db/index.html
30-
Boost \boost-1.47.0-mgw http://www.boost.org/users/download/
31-
miniupnpc \miniupnpc-1.6-mgw http://miniupnp.tuxfamily.org/files/
28+
OpenSSL \openssl-1.0.1j-mgw http://www.openssl.org/source/
29+
Berkeley DB \db-6.0.20.NC-mgw http://www.oracle.com/technology/software/products/berkeley-db/index.html
30+
Boost \boost-1.57.0-mgw http://www.boost.org/users/download/
31+
miniupnpc \miniupnpc-1.9-mgw http://miniupnp.tuxfamily.org/files/
3232

3333
Their licenses:
3434
OpenSSL Old BSD license with the problematic advertising requirement
@@ -37,10 +37,10 @@ Boost MIT-like license
3737
miniupnpc New (3-clause) BSD license
3838

3939
Versions used in this release:
40-
OpenSSL 1.0.1b
41-
Berkeley DB 4.8.30.NC
42-
Boost 1.47.0
43-
miniupnpc 1.6
40+
OpenSSL 1.0.1j
41+
Berkeley DB 6.0.20.NC
42+
Boost 1.57.0
43+
miniupnpc 1.9
4444

4545

4646
OpenSSL
@@ -49,30 +49,30 @@ MSYS shell:
4949
un-tar sources with MSYS 'tar xfz' to avoid issue with symlinks (OpenSSL ticket 2377)
5050
change 'MAKE' env. variable from 'C:\MinGW32\bin\mingw32-make.exe' to '/c/MinGW32/bin/mingw32-make.exe'
5151

52-
cd /c/openssl-1.0.1b-mgw
52+
cd /c/openssl-1.0.1j-mgw
5353
./config
5454
make
5555

5656
Berkeley DB
5757
-----------
5858
MSYS shell:
59-
cd /c/db-4.8.30.NC-mgw/build_unix
59+
cd /c/db-6.0.20.NC-mgw/build_unix
6060
sh ../dist/configure --enable-mingw --enable-cxx
6161
make
6262

6363
Boost
6464
-----
6565
DOS prompt:
6666
downloaded boost jam 3.1.18
67-
cd \boost-1.47.0-mgw
67+
cd \boost-1.57.0-mgw
6868
bjam toolset=gcc --build-type=complete stage
6969

7070
MiniUPnPc
7171
---------
7272
UPnP support is optional, make with USE_UPNP= to disable it.
7373

7474
MSYS shell:
75-
cd /c/miniupnpc-1.6-mgw
75+
cd /c/miniupnpc-1.9-mgw
7676
make -f Makefile.mingw
7777
mkdir miniupnpc
7878
cp *.h miniupnpc/

doc/build-osx.txt

+118-37
Original file line numberDiff line numberDiff line change
@@ -1,55 +1,136 @@
1-
Copyright (c) 2009-2012 Bitcoin Developers
2-
Copyright (c) 2013 NovaCoin Developers
3-
Distributed under the MIT/X11 software license, see the accompanying file
4-
license.txt or http://www.opensource.org/licenses/mit-license.php. This
5-
product includes software developed by the OpenSSL Project for use in the
6-
OpenSSL Toolkit (http://www.openssl.org/). This product includes cryptographic
7-
software written by Eric Young ([email protected]) and UPnP software written by
8-
Thomas Bernard.
1+
Mac OS X Build Instructions and Notes
2+
====================================
3+
This guide will show you how to build novacoind(headless client) for OSX.
94

5+
Notes
6+
-----
107

11-
Mac OS X novacoind build instructions
12-
Laszlo Hanyecz <[email protected]>
13-
Douglas Huff <[email protected]>
8+
* Tested on OS X 10.7 through 10.10 on 64-bit Intel processors only.
149

10+
* All of the commands should be executed in a Terminal application. The
11+
built-in one is located in `/Applications/Utilities`.
1512

16-
See readme-qt.rst for instructions on building NovaCoin QT, the
17-
graphical user interface.
13+
Preparation
14+
-----------
1815

19-
Tested on 10.5 and 10.6 intel. PPC is not supported because it's big-endian.
16+
You need to install XCode with all the options checked so that the compiler
17+
and everything is available in /usr not just /Developer. XCode should be
18+
available on your OS X installation media, but if not, you can get the
19+
current version from https://developer.apple.com/xcode/. If you install
20+
Xcode 4.3 or later, you'll need to install its command line tools. This can
21+
be done in `Xcode > Preferences > Downloads > Components` and generally must
22+
be re-done or updated every time Xcode is updated.
2023

21-
All of the commands should be executed in Terminal.app.. it's in
22-
/Applications/Utilities
24+
There's also an assumption that you already have `git` installed. If
25+
not, it's the path of least resistance to install [Github for Mac](https://mac.github.com/)
26+
(OS X 10.7+) or
27+
[Git for OS X](https://code.google.com/p/git-osx-installer/). It is also
28+
available via Homebrew.
2329

24-
You need to install XCode with all the options checked so that the compiler and
25-
everything is available in /usr not just /Developer I think it comes on the DVD
26-
but you can get the current version from http://developer.apple.com
30+
You will also need to install [Homebrew](http://brew.sh) in order to install library
31+
dependencies.
2732

33+
The installation of the actual dependencies is covered in the Instructions
34+
sections below.
2835

29-
1. Clone the github tree to get the source code:
36+
Instructions: Homebrew
37+
----------------------
3038

31-
git clone https://github.com/novacoin-project/novacoin
39+
#### Install dependencies using Homebrew
3240

33-
2. Download and install MacPorts from http://www.macports.org/
41+
brew install autoconf automake libtool boost miniupnpc openssl pkg-config protobuf qt qrencode
3442

35-
2a. (for 10.7 Lion)
36-
Edit /opt/local/etc/macports/macports.conf and uncomment "build_arch i386"
43+
#### Installing berkeley-db4 using Homebrew
3744

38-
3. Install dependencies from MacPorts
45+
The homebrew package for berkeley-db4 has been broken for some time. It will install without Java though.
3946

40-
sudo port install boost db48 openssl miniupnpc
47+
Running this command takes you into brew's interactive mode, which allows you to configure, make, and install by hand:
48+
```
49+
$ brew install https://raw.github.com/mxcl/homebrew/master/Library/Formula/berkeley-db4.rb -–without-java
50+
```
4151

42-
Optionally install qrencode (and set USE_QRCODE=1):
43-
sudo port install qrencode
52+
The rest of these commands are run inside brew interactive mode:
53+
```
54+
/private/tmp/berkeley-db4-UGpd0O/db-4.8.30 $ cd ..
55+
/private/tmp/berkeley-db4-UGpd0O $ db-4.8.30/dist/configure --prefix=/usr/local/Cellar/berkeley-db4/4.8.30 --mandir=/usr/local/Cellar/berkeley-db4/4.8.30/share/man --enable-cxx
56+
/private/tmp/berkeley-db4-UGpd0O $ make
57+
/private/tmp/berkeley-db4-UGpd0O $ make install
58+
/private/tmp/berkeley-db4-UGpd0O $ exit
59+
```
4460

45-
4. Now you should be able to build novacoind:
61+
After exiting, you'll get a warning that the install is keg-only, which means it wasn't symlinked to `/usr/local`. You don't need it to link it to build novacoin, but if you want to, here's how:
4662

47-
cd novacoin/src
48-
make -f makefile.osx
63+
$ brew link --force berkeley-db4
4964

50-
Run:
51-
./novacoind --help # for a list of command-line options.
52-
Run
53-
./novacoind -daemon # to start the novacoin daemon.
54-
Run
55-
./novacoind help # When the daemon is running, to get a list of RPC commands
65+
66+
### Building `novacoind`
67+
68+
1. Clone the github tree to get the source code and go into the directory.
69+
70+
git clone https://github.com/novacoin-project/novacoin.git
71+
cd novacoin
72+
73+
2. Build NovaCoin-Qt application:
74+
qmake
75+
make
76+
77+
3. Build bitcoind:
78+
cd src
79+
make -f makefile.osx novacoind
80+
81+
Use Qt Creator as IDE
82+
------------------------
83+
You can use Qt Creator as IDE, for debugging and for manipulating forms, etc.
84+
Download Qt Creator from http://www.qt.io/download/. Download the "community edition" and only install Qt Creator (uncheck the rest during the installation process).
85+
86+
1. Make sure you installed everything through homebrew mentioned above
87+
2. In Qt Creator do "File" -> "Open Project"
88+
3. Select novacoin-qt.pro as project file.
89+
4. In the "Projects" tab select "Manage Kits..."
90+
5. Select the default "Desktop" kit and select "Clang (x86 64bit in /usr/bin)" as compiler
91+
6. Select LLDB as debugger (you might need to set the path to your installtion)
92+
7. Start debugging with Qt Creator
93+
94+
Creating a release build
95+
------------------------
96+
You can ignore this section if you are building `novacoind` for your own use.
97+
98+
novacoind binary isn't included in the NovaCoin-Qt.app bundle.
99+
100+
If you are building `novacoind` or `NovaCoin-Qt` for others, your build machine should be set up
101+
as follows for maximum compatibility:
102+
103+
All dependencies should be compiled with these flags:
104+
105+
-mmacosx-version-min=10.7
106+
-arch x86_64
107+
-isysroot $(xcode-select --print-path)/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.7.sdk
108+
109+
Once dependencies are compiled, you can create the .dmg disk image:
110+
111+
./contrib/macdeploy/macdeployqtplus NovaCoin-Qt.app -dmg -fancy ./contrib/macdeploy/fancy.plist
112+
113+
Running
114+
-------
115+
116+
It's now available at `./novacoind`, provided that you are still in the `src`
117+
directory. We have to first create the RPC configuration file, though.
118+
119+
Run `./novacoind` to get the filename where it should be put, or just try these
120+
commands:
121+
122+
echo -e "rpcuser=novacoinrpc\nrpcpassword=$(xxd -l 16 -p /dev/urandom)" > "/Users/${USER}/Library/Application Support/NovaCoin/novacoin.conf"
123+
chmod 600 "/Users/${USER}/Library/Application Support/NovaCoin/novacoin.conf"
124+
125+
The next time you run it, it will start downloading the blockchain, but it won't
126+
output anything while it's doing this. This process may take several hours;
127+
you can monitor its process by looking at the debug.log file, like this:
128+
129+
tail -f $HOME/Library/Application\ Support/NovaCoin/debug.log
130+
131+
Other commands:
132+
-------
133+
134+
./novacoind -daemon # to start the bitcoin daemon.
135+
./novacoind --help # for a list of command-line options.
136+
./novacoind help # When the daemon is running, to get a list of RPC commands

doc/readme-qt.rst

+51-7
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,26 @@ Debian
88
-------
99

1010
First, make sure that the required packages for Qt4 development of your
11-
distribution are installed, for Debian and Ubuntu these are:
11+
distribution are installed, these are
12+
13+
::
14+
15+
for Debian and Ubuntu <= 11.10 :
1216

1317
::
1418

1519
apt-get install qt4-qmake libqt4-dev build-essential libboost-dev libboost-system-dev \
1620
libboost-filesystem-dev libboost-program-options-dev libboost-thread-dev \
1721
libssl-dev libdb4.8++-dev
1822

23+
for Ubuntu >= 12.04 (please read the 'Berkely DB version warning' below):
24+
25+
::
26+
27+
apt-get install qt4-qmake libqt4-dev build-essential libboost-dev libboost-system-dev \
28+
libboost-filesystem-dev libboost-program-options-dev libboost-thread-dev \
29+
libssl-dev libdb++-dev libminiupnpc-dev
30+
1931
then execute the following:
2032

2133
::
@@ -70,6 +82,42 @@ Mac OS X
7082
Build configuration options
7183
============================
7284

85+
LevelDB transaction index
86+
--------------------------
87+
88+
To use LevelDB for transaction index, pass the following argument to qmake:
89+
90+
::
91+
92+
qmake "USE_LEVELDB=1"
93+
94+
No additional external dependencies are required. If you're running this on your current sources tree then don't forget tu run
95+
96+
::
97+
98+
make distclean
99+
100+
prior to running qmake.
101+
102+
Assembler implementation of scrypt hashing
103+
------------------------------------------
104+
105+
To use optimized scrypt implementation instead of generic scrypt module, pass the following argument to qmake:
106+
107+
::
108+
109+
qmake "USE_ASM=1"
110+
111+
112+
If you're using clang compiler then you need to unroll macroses before compiling. Following commands will do this for you:
113+
114+
::
115+
116+
cd src/
117+
../contrib/clang/nomacro.pl
118+
119+
No additional external dependencies required. Note that only x86, x86_64 and ARM processors are supported.
120+
73121
UPNnP port forwarding
74122
---------------------
75123

@@ -123,17 +171,13 @@ Berkely DB version warning
123171

124172
A warning for people using the *static binary* version of Novacoin on a Linux/UNIX-ish system (tl;dr: **Berkely DB databases are not forward compatible**).
125173

126-
The static binary version of Novacoin is linked against libdb4.8 (see also `this Debian issue`_).
174+
The static binary version of Novacoin is linked against libdb5.3.
127175

128-
Now the nasty thing is that databases from 5.X are not compatible with 4.X.
129-
130-
If the globally installed development package of Berkely DB installed on your system is 5.X, any source you
176+
If the globally installed development package of Berkely DB installed on your system is 5.X, for example, any source you
131177
build yourself will be linked against that. The first time you run with a 5.X version the database will be upgraded,
132178
and 4.X cannot open the new format. This means that you cannot go back to the old statically linked version without
133179
significant hassle!
134180

135-
.. _`this Debian issue`: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=621425
136-
137181
Ubuntu 11.10 warning
138182
====================
139183

0 commit comments

Comments
 (0)