Skip to content

Commit 72a322a

Browse files
committed
doc: consistently use ```sh tags for correct shell highlighting
1 parent 2b3cdd6 commit 72a322a

File tree

1 file changed

+88
-38
lines changed

1 file changed

+88
-38
lines changed

doc/build-unix.md

+88-38
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,17 @@ Note
99
Always use absolute paths to configure and compile Dash Core and the dependencies.
1010
For example, when specifying the path of the dependency:
1111

12-
../dist/configure --enable-cxx --disable-shared --with-pic --prefix=$BDB_PREFIX
12+
```sh
13+
../dist/configure --enable-cxx --disable-shared --with-pic --prefix=$BDB_PREFIX
14+
```
1315

14-
Here BDB_PREFIX must be an absolute path - it is defined using $(pwd) which ensures
16+
Here `BDB_PREFIX` must be an absolute path - it is defined using $(pwd) which ensures
1517
the usage of the absolute path.
1618

1719
To Build
1820
---------------------
1921

20-
```bash
22+
```sh
2123
./autogen.sh
2224
./configure
2325
make
@@ -59,7 +61,9 @@ memory available when compiling Dash Core. On systems with less, gcc can be
5961
tuned to conserve memory with additional CXXFLAGS:
6062

6163

62-
./configure CXXFLAGS="--param ggc-min-expand=1 --param ggc-min-heapsize=32768"
64+
```sh
65+
./configure CXXFLAGS="--param ggc-min-expand=1 --param ggc-min-heapsize=32768"
66+
```
6367

6468

6569
## Linux Distribution Specific Instructions
@@ -70,11 +74,15 @@ tuned to conserve memory with additional CXXFLAGS:
7074

7175
Build requirements:
7276

73-
sudo apt-get install build-essential libtool autotools-dev automake pkg-config bsdmainutils bison python3
77+
```sh
78+
sudo apt-get install build-essential libtool autotools-dev automake pkg-config bsdmainutils bison python3
79+
```
7480

7581
Now, you can either build from self-compiled [depends](/depends/README.md) or install the required dependencies:
7682

77-
sudo apt-get install libevent-dev libboost-system-dev libboost-filesystem-dev libboost-test-dev
83+
```sh
84+
sudo apt-get install libevent-dev libboost-system-dev libboost-filesystem-dev libboost-test-dev
85+
```
7886

7987
Berkeley DB is required for the wallet.
8088

@@ -87,21 +95,29 @@ Otherwise, you can build Berkeley DB [yourself](#berkeley-db).
8795

8896
SQLite is required for the wallet:
8997

90-
sudo apt-get install libsqlite3-dev
98+
```sh
99+
sudo apt-get install libsqlite3-dev
100+
```
91101

92102
To build Dash Core without wallet, see [*Disable-wallet mode*](#disable-wallet-mode)
93103

94104
Optional port mapping libraries (see: `--with-miniupnpc` and `--with-natpmp`):
95105

96-
sudo apt-get install libminiupnpc-dev libnatpmp-dev
106+
```sh
107+
sudo apt-get install libminiupnpc-dev libnatpmp-dev
108+
```
97109

98110
ZMQ dependencies (provides ZMQ API):
99111

100-
sudo apt-get install libzmq3-dev
112+
```sh
113+
sudo apt-get install libzmq3-dev
114+
```
101115

102116
GMP dependencies (provides platform-optimized routines):
103117

104-
sudo apt-get install libgmp-dev
118+
```sh
119+
sudo apt-get install libgmp-dev
120+
```
105121

106122
GUI dependencies:
107123

@@ -111,15 +127,21 @@ To build without GUI pass `--without-gui`.
111127

112128
To build with Qt 5 you need the following:
113129

114-
sudo apt-get install libqt5gui5 libqt5core5a libqt5dbus5 qttools5-dev qttools5-dev-tools
130+
```sh
131+
sudo apt-get install libqt5gui5 libqt5core5a libqt5dbus5 qttools5-dev qttools5-dev-tools
132+
```
115133

116134
Additionally, to support Wayland protocol for modern desktop environments:
117135

118-
sudo apt-get install qtwayland5
136+
```sh
137+
sudo apt-get install qtwayland5
138+
```
119139

120140
libqrencode (optional) can be installed with:
121141

122-
sudo apt-get install libqrencode-dev
142+
```sh
143+
sudo apt-get install libqrencode-dev
144+
```
123145

124146
Once these are installed, they will be found by configure and a dash-qt executable will be
125147
built by default.
@@ -131,15 +153,21 @@ built by default.
131153

132154
Build requirements:
133155

134-
sudo dnf install gcc-c++ libtool make autoconf automake python3
156+
```sh
157+
sudo dnf install gcc-c++ libtool make autoconf automake python3
158+
```
135159

136160
Now, you can either build from self-compiled [depends](/depends/README.md) or install the required dependencies:
137161

138-
sudo dnf install libevent-devel boost-devel
162+
```sh
163+
sudo dnf install libevent-devel boost-devel
164+
```
139165

140166
Berkeley DB is required for the wallet:
141167

142-
sudo dnf install libdb4-devel libdb4-cxx-devel
168+
```sh
169+
sudo dnf install libdb4-devel libdb4-cxx-devel
170+
```
143171

144172
Newer Fedora releases, since Fedora 33, have only `libdb-devel` and `libdb-cxx-devel` packages, but these will install
145173
Berkeley DB 5.3 or later. This will break binary wallet compatibility with the distributed executables, which
@@ -150,21 +178,29 @@ Otherwise, you can build Berkeley DB [yourself](#berkeley-db).
150178

151179
SQLite is required for the wallet:
152180

153-
sudo dnf install sqlite-devel
181+
```sh
182+
sudo dnf install sqlite-devel
183+
```
154184

155185
To build Dash Core without wallet, see [*Disable-wallet mode*](#disable-wallet-mode)
156186

157187
Optional port mapping libraries (see: `--with-miniupnpc` and `--with-natpmp`):
158188

159-
sudo dnf install miniupnpc-devel libnatpmp-devel
189+
```sh
190+
sudo dnf install miniupnpc-devel libnatpmp-devel
191+
```
160192

161193
ZMQ dependencies (provides ZMQ API):
162194

163-
sudo dnf install zeromq-devel
195+
```sh
196+
sudo dnf install zeromq-devel
197+
```
164198

165199
GMP dependencies (provides platform-optimized routines):
166200

167-
sudo dnf install gmp-devel
201+
```sh
202+
sudo dnf install gmp-devel
203+
```
168204

169205
GUI dependencies:
170206

@@ -174,15 +210,21 @@ To build without GUI pass `--without-gui`.
174210

175211
To build with Qt 5 you need the following:
176212

177-
sudo dnf install qt5-qttools-devel qt5-qtbase-devel
213+
```sh
214+
sudo dnf install qt5-qttools-devel qt5-qtbase-devel
215+
```
178216

179217
Additionally, to support Wayland protocol for modern desktop environments:
180218

181-
sudo dnf install qt5-qtwayland
219+
```sh
220+
sudo dnf install qt5-qtwayland
221+
```
182222

183223
libqrencode (optional) can be installed with:
184224

185-
sudo dnf install qrencode-devel
225+
```sh
226+
sudo dnf install qrencode-devel
227+
```
186228

187229
Once these are installed, they will be found by configure and a dash-qt executable will be
188230
built by default.
@@ -213,7 +255,7 @@ It is recommended to use Berkeley DB 4.8. If you have to build it yourself,
213255
you can use [the installation script included in contrib/](contrib/install_db4.sh)
214256
like so:
215257

216-
```shell
258+
```sh
217259
./contrib/install_db4.sh `pwd`
218260
```
219261

@@ -293,19 +335,23 @@ Additional Configure Flags
293335
--------------------------
294336
A list of additional configure flags can be displayed with:
295337

296-
./configure --help
338+
```sh
339+
./configure --help
340+
```
297341

298342

299343
Setup and Build Example: Arch Linux
300344
-----------------------------------
301345
This example lists the steps necessary to setup and build a command line only, non-wallet distribution of the latest changes on Arch Linux:
302346

303-
pacman -S git base-devel boost libevent python
304-
git clone https://github.com/dashpay/dash.git
305-
cd dash/
306-
./autogen.sh
307-
./configure --disable-wallet --without-gui --without-miniupnpc
308-
make check
347+
```sh
348+
pacman -S git base-devel boost libevent python
349+
git clone https://github.com/dashpay/dash.git
350+
cd dash/
351+
./autogen.sh
352+
./configure --disable-wallet --without-gui --without-miniupnpc
353+
make check
354+
```
309355

310356
Note:
311357
Enabling wallet support requires either compiling against a Berkeley DB newer than 4.8 (package `db`) using `--with-incompatible-bdb`,
@@ -324,16 +370,20 @@ installing the toolchain will be different.
324370
Make sure you install the build requirements mentioned above.
325371
Then, install the toolchain and curl:
326372

327-
sudo apt-get install g++-arm-linux-gnueabihf curl
373+
```sh
374+
sudo apt-get install g++-arm-linux-gnueabihf curl
375+
```
328376

329377
To build executables for ARM:
330378

331-
cd depends
332-
make HOST=arm-linux-gnueabihf NO_QT=1
333-
cd ..
334-
./autogen.sh
335-
CONFIG_SITE=$PWD/depends/arm-linux-gnueabihf/share/config.site ./configure --enable-reduce-exports LDFLAGS=-static-libstdc++
336-
make
379+
```sh
380+
cd depends
381+
make HOST=arm-linux-gnueabihf NO_QT=1
382+
cd ..
383+
./autogen.sh
384+
CONFIG_SITE=$PWD/depends/arm-linux-gnueabihf/share/config.site ./configure --enable-reduce-exports LDFLAGS=-static-libstdc++
385+
make
386+
```
337387

338388

339389
For further documentation on the depends system see [README.md](../depends/README.md) in the depends directory.

0 commit comments

Comments
 (0)