73be0c8fb13ba05e02e9db126d5e6d6dac3e5451
[novacoin.git] / doc / readme-qt.rst
1 Novacoin-qt: Qt4 GUI for Novacoin
2 ===============================
3
4 Build instructions
5 ===================
6
7 Debian
8 -------
9
10 First, make sure that the required packages for Qt4 development of your
11 distribution are installed, these are
12
13 ::
14
15 for Debian and Ubuntu  <= 11.10 :
16
17 ::
18
19     apt-get install qt4-qmake libqt4-dev build-essential libboost-dev libboost-system-dev \
20         libboost-filesystem-dev libboost-program-options-dev libboost-thread-dev \
21         libssl-dev libdb4.8++-dev
22
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
31 then execute the following:
32
33 ::
34
35     qmake
36     make
37
38 Alternatively, install Qt Creator and open the `novacoin-qt.pro` file.
39
40 An executable named `novacoin-qt` will be built.
41
42
43 Windows
44 --------
45
46 Windows build instructions:
47
48 - Download the `QT Windows SDK`_ and install it. You don't need the Symbian stuff, just the desktop Qt.
49
50 - Download and extract the `dependencies archive`_  [#]_, or compile openssl, boost and dbcxx yourself.
51
52 - Copy the contents of the folder "deps" to "X:\\QtSDK\\mingw", replace X:\\ with the location where you installed the Qt SDK. Make sure that the contents of "deps\\include" end up in the current "include" directory.
53
54 - Open the .pro file in QT creator and build as normal (ctrl-B)
55
56 .. _`QT Windows SDK`: http://qt.nokia.com/downloads/sdk-windows-cpp
57 .. _`dependencies archive`: https://download.visucore.com/bitcoin/qtgui_deps_1.zip
58 .. [#] PGP signature: https://download.visucore.com/bitcoin/qtgui_deps_1.zip.sig (signed with RSA key ID `610945D0`_)
59 .. _`610945D0`: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x610945D0
60
61
62 Mac OS X
63 --------
64
65 - Download and install the `Qt Mac OS X SDK`_. It is recommended to also install Apple's Xcode with UNIX tools.
66
67 - Download and install `MacPorts`_.
68
69 - Execute the following commands in a terminal to get the dependencies:
70
71 ::
72
73         sudo port selfupdate
74         sudo port install boost db48 miniupnpc
75
76 - Open the .pro file in Qt Creator and build as normal (cmd-B)
77
78 .. _`Qt Mac OS X SDK`: http://qt.nokia.com/downloads/sdk-mac-os-cpp
79 .. _`MacPorts`: http://www.macports.org/install.php
80
81
82 Build configuration options
83 ============================
84
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 to 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
121 UPNnP port forwarding
122 ---------------------
123
124 To use UPnP for port forwarding behind a NAT router (recommended, as more connections overall allow for a faster and more stable novacoin experience), pass the following argument to qmake:
125
126 ::
127
128     qmake "USE_UPNP=1"
129
130 (in **Qt Creator**, you can find the setting for additional qmake arguments under "Projects" -> "Build Settings" -> "Build Steps", then click "Details" next to **qmake**)
131
132 This requires miniupnpc for UPnP port mapping.  It can be downloaded from
133 http://miniupnp.tuxfamily.org/files/.  UPnP support is not compiled in by default.
134
135 Set USE_UPNP to a different value to control this:
136
137 +------------+--------------------------------------------------------------------------+
138 | USE_UPNP=- | no UPnP support, miniupnpc not required;                                 |
139 +------------+--------------------------------------------------------------------------+
140 | USE_UPNP=0 | (the default) built with UPnP, support turned off by default at runtime; |
141 +------------+--------------------------------------------------------------------------+
142 | USE_UPNP=1 | build with UPnP support turned on by default at runtime.                 |
143 +------------+--------------------------------------------------------------------------+
144
145 Notification support for recent (k)ubuntu versions
146 ---------------------------------------------------
147
148 To see desktop notifications on (k)ubuntu versions starting from 10.04, enable usage of the
149 FreeDesktop notification interface through DBUS using the following qmake option:
150
151 ::
152
153     qmake "USE_DBUS=1"
154
155 Generation of QR codes
156 -----------------------
157
158 libqrencode is used to generate QRCode images for payment requests.
159 It can be downloaded from http://fukuchi.org/works/qrencode/index.html.en, or installed via your package manager.
160
161 Berkely DB version warning
162 ==========================
163
164 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**).
165
166 The static binary version of Novacoin is linked against libdb5.3.
167
168 If the globally installed development package of Berkely DB installed on your system is 5.X, for example, any source you
169 build yourself will be linked against that. The first time you run with a 5.X version the database will be upgraded,
170 and 4.X cannot open the new format. This means that you cannot go back to the old statically linked version without
171 significant hassle!
172
173 Ubuntu 11.10 warning
174 ====================
175
176 Ubuntu 11.10 has a package called 'qt-at-spi' installed by default.  At the time of writing, having that package
177 installed causes novacoin-qt to crash intermittently.  The issue has been reported as `launchpad bug 857790`_, but
178 isn't yet fixed.
179
180 Until the bug is fixed, you can remove the qt-at-spi package to work around the problem, though this will presumably
181 disable screen reader functionality for Qt apps:
182
183 ::
184
185     sudo apt-get remove qt-at-spi
186
187 .. _`launchpad bug 857790`: https://bugs.launchpad.net/ubuntu/+source/qt-at-spi/+bug/857790