Browse Source

Merge pull request 'merging master into dev' (#9) from master into dev

Reviewed-on: https://git.hush.is/jahway603/hush-docs/pulls/9
pull/10/head
jahway603 2 years ago
parent
commit
e9b91518e4
  1. 6
      README.md
  2. 166
      advanced/build-hush-full-node-win-bins.md
  3. 121
      advanced/compile-qt5-from-source.md
  4. 106
      advanced/creating-silent-dragon-msi-installer-for-windows-with-wixl.md
  5. 111
      advanced/cross-compile-hush-full-node-to-aarch64-with-docker.md
  6. 103
      advanced/cross-compile-silent-dragon-for-windows-with-mxe.md
  7. 2
      hush-lite-server.md
  8. BIN
      images/banana-go-bananas.gif
  9. BIN
      images/bob-ross-happy.gif

6
README.md

@ -49,6 +49,12 @@ If you want to mine Hush, then the following documents are for you:
- [Setup your Hush Innosilicon Miner for pool mining](mining/mine-innosilicon.md)
- [Setup your Hush Innosilicon Miner for SOLO mining](mining/solo-mining.md)
#### Translations
See https://git.hush.is/onryo/translate-sd-sdl for detailed documentation on making Hush translations and https://git.hush.is/hush/translations for an overview of how we deal with translations in the Hush community.
#### Servers?
![computer on fire](images/servers.gif)

166
advanced/build-hush-full-node-win-bins.md

@ -0,0 +1,166 @@
# Cross-compile & Package Hush Full Node Binaries for Windows
These instructions are how to cross-compile and package fresh Hush Windows executables from Ubuntu 18.04. In addition to creating fresh win bins, this tutorial will also shine light on how to use a virtual machine with docker engine. This process also aids in keeping your local machine free of unwanted packages and on exit of the interactive docker terminal, the image is destroyed.
## Requirements
- [Docker Engine](https://docs.docker.com/engine/install)
### Launch a docker image in interactive mode, rm on exit of container and bind tmp directory to actual tmp
```
sudo docker run -it --rm -v /tmp:/tmp ubuntu:bionic
```
### Verify building on correct OS version
```
cat /etc/*-release
```
### Install dependencies
```
apt update && apt-get install build-essential pkg-config libc6-dev m4 g++-multilib \
autoconf libtool ncurses-dev unzip git python zlib1g-dev wget \
bsdmainutils automake curl unzip nano libsodium-dev g++-mingw-w64-x86-64 git zip
```
### Clone Hush source
```
git clone https://git.hush.is/hush/hush3.git && cd hush3
```
### Prepare directory for zipping
```
mkdir hush-vX.X.X-win
```
### Compile fresh Hush Windows binaries
```
./zcutil/build-win.sh
```
### Copy binaries to hush-vX.X.X-win folder
```
cd src/ && cp hushd.exe hush-tx.exe hush-cli.exe ../hush-vX.X.X-win/ && cd ..
```
### Copy sapling params to hush-vX.X.X-win folder
```
cp sapling-output.params sapling-spend.params hush-vX.X.X-win/
```
### Copy asmap to hush-vX.X.X-win folder
```
cp asmap.dat hush-vX.X.X-win/
```
### Create README.txt
```
nano hush-vX.X.X-win/README.txt
```
#### Edit / Copy & Paste
```
___====-_ _-====___
_--~~~#####// ' ` \\#####~~~--_
-~##########// ( ) \\##########~-_
-############// |\^^/| \\############-
_~############// (O||O) \\############~_
~#############(( \\// ))#############~
-###############\\ (oo) //###############-
-#################\\ / `' \ //#################-
-###################\\/ () \//###################-
_#/|##########/\######( (()) )######/\##########|\#_
|/ |#/\#/\#/\/ \#/\##| \()/ |##/\#/ \/\#/\#/\#| \|
` |/ V V ` V )|| |()| ||( V ' V /\ \| '
` ` ` ` / | |()| | \ ' '<||> '
( | |()| | )\ /|/
__\ |__|()|__| /__\______/|/
(vvv(vvvv)(vvvv)vvv)______|/
HUSH vX.X.X Windows Binaries
Download new binaries from: https://git.hush.is/hush/hush3/releases
Thanks to all the people who made this possible, including:
-DukeLeto
-oDinZu
-Jahway603
-Onryo
-Fekt0r
-Hush Community
INSTRUCTIONS:
0.) Verify checksum matches downloaded file with: certutil -hashfile .\hush-vX.X.X-win.zip SHA256
1.) Extract archive: right-click extract here
2.) Open up powershell or command prompt by pressing WIN+R, type powershell or cmd.
3.) Launch hushd full node by typing: ./hushd.exe or hushd if in command prompt; you will see the hush full node begin downloading the hush blockchain.
4.) In another powershell or command prompt window, you can use hushd -help and hush-cli help for managing your wallet/full-node with command line interface (CLI). As an example, to create a new z-addr, type: hush-cli z_getnewaddress OR .\hush-cli.exe getalldata.
5.) Press WIN+R, type %APPDATA% and open up your Hush folder, then see your debug.txt file and your HUSH3.conf file. The user/pass is anonymously generated, you can change these if you desire so.
Notes:
- If you are running out of memory syncing blockchain and hushd is silently exiting without any errors. Run hushd without using other resources.
- Always close hushd with hush-cli stop; an incorrect shutdown may result in a corrupt wallet.
Community & Socials:
See our new YouTube channel for more info: https://hush.is/yt
And also https://videos.hush.is
Explorer: https://explorer.hush.is
Join Telegram main channel for announcements: https://hush.is/tg
Join Telegram for official support: https://hush.is/tg_support
```
#### Save README.txt
```
CTRL+X
SHIFT+Y
ENTER
```
### Compress hush-vX.X.X-win folder and all its files
```
zip -r hush-vX.X.X-win.zip hush-vX.X.X-win/
```
### Create SHA256 Checksum for integrity
```
sha256sum hush-vX.X.X-win.zip
```
I.E. b558c52c4bdbf3290f28b2a7beaa3cd1a93aa6b110ef2db59c2ad17faff60314 hush-3.9.0-win.zip
### Copy hush-vX.X.X-win.zip to actual machine directory /tmp/
```
cp hush-vX.X.X-win.zip /tmp/hush-vX.X.X-win.zip
```
### Test fresh Hush Windows binaries
*You will need a Windows 10 OS to test these binaries*
**Follow the README.txt**
### Upload ZIP to Hush Gitea via [Releases](https://git.hush.is/hush/hush3/releases) page
```
cp /tmp/hush-vX.X.X-win.zip /home/username/Downloads
```
#### Add checksum to Gitea releases page
```
b558c52c4bdbf3290f28b2a7beaa3cd1a93aa6b110ef2db59c2ad17faff60314 hush-3.9.0-win.zip
```
### Exit & destroy docker container
```
exit
```
### Congratulations
![I Am A Banana](../images/banana-go-bananas.gif)
## Support, Socials and Licensing
<a href="https://git.hush.is/hush/hush3#support-and-socials"> Support, Socials and Licensing</a>

121
advanced/compile-qt5-from-source.md

@ -0,0 +1,121 @@
## Configure, Build, Install & Setup Qt 5.15.2 Source on Ubuntu 18.04 with X11 Support
This tutorial will teach you how to compile from source via CLI (command-line interface) and enable customization for building Qt5 apps on different operating systems andor hardware architectures like RPI400.
When compiling Qt5 yourself, you are empowered with a configuration that is constant throughout the Linux Universe. This process is also very similar with compiling Qt apps on your (AArch64) ARM64 devices like RPi 400, Rock64 & PineBook64.
*Note: This tutorial doesn't include json Qtwebengine*
## What is Qt?
"Qt is a cross-platform application development framework for desktop, embedded and mobile." [Qt Wiki]
## Let's Begin!
### Remove & purge all Qt packages
```
sudo apt -y remove qt5* libqt5* qtcreator && sudo autoremove
```
### Download Qt 5.15.2 Source to qt5-sources folder
```
mkdir qt5-sources && cd qt5-sources && mkdir build-shadow
wget https://download.qt.io/official_releases/qt/5.15/5.15.2/single/qt-everywhere-src-5.15.2.tar.xz
```
#### Verify MD5 hash
```
md5sum qt-everywhere-src-5.15.2.tar.xz
```
```
e1447db4f06c841d8947f0a6ce83a7b5 qt-everywhere-src-5.15.2.tar.xz
```
#### Un-tar Qt5 archive
```
tar xf qt-everywhere-src-5.15.2.tar.xz
```
#### Move into build-shadow directory to configure your Qt 5.15.2
```
cd build-shadow
```
### Install Qt5 Minimal Dependencies
```
sudo apt update
sudo apt install build-essential libfontconfig1-dev libdbus-1-dev libfreetype6-dev libicu-dev libinput-dev libxkbcommon-dev libsqlite3-dev libssl-dev libpng-dev libjpeg-dev libglib2.0-dev
```
#### (Optional) Install VC4 Drivers for RPi 4 type devices (i.e. cortex-a53 & cortex-a72)
```
sudo apt install libgles2-mesa-dev libgbm-dev libdrm-dev
```
### Install X11 Support Dependencies
```
sudo apt install libx11-dev libxcb1-dev libxext-dev libxi-dev libxcomposite-dev libxcursor-dev libxtst-dev libxrandr-dev libfontconfig1-dev libfreetype6-dev libx11-xcb-dev libxext-dev libxfixes-dev libxi-dev libxrender-dev libxcb1-dev libxcb-glx0-dev libxcb-keysyms1-dev libxcb-image0-dev libxcb-shm0-dev libxcb-icccm4-dev libxcb-sync-dev libxcb-xfixes0-dev libxcb-shape0-dev libxcb-randr0-dev libxcb-render-util0-dev libxcb-util0-dev libxcb-xinerama0-dev libxcb-xkb-dev libxkbcommon-dev libxkbcommon-x11-dev
```
### Configure Qt 5.15.2
```
../qt-everywhere-src-5.15.2/configure -v -bundled-xcb-xinput -opensource -confirm-license -release -ssl -glib -no-feature-geoservices_mapboxgl -qt-pcre -nomake examples -no-compile-examples -nomake tests -reduce-exports -system-freetype -fontconfig -qpa xcb
```
#### Make the configuration *(-j 4 is number of cpus you want to use)*
```
make -j 4
```
#### Install Qt5 into: *(default) /usr/local/*
```
sudo make install
```
*Note: Check and make sure ./configure has required deps; if you installed the deps, but still receiving errors, remove config.cache and ./configure again.*
**Tip:** *If you want to view your configuration summary, you may do so via nano config.summary from build-shadow directory*
### Update profile to know where Qt5.15.2 bins are
```
nano ~/.bashrc
```
#### Add this at the bottom of your .bashrc file.
```
# set PATH for Qt 5.15.2
export PATH="/usr/local/Qt-5.15.2/bin:$PATH"
```
#### Reload your ~/.bashrc file & create new shell window.
```
source ~/.bashrc
CTRL+SHIFT+T
ALT+1
exit
```
#### Verify Qt 5.15.2 has been installed
```
qmake --version
```
```
QMake version 3.1
Using Qt version 5.15.2 in /usr/local/Qt-5.15.2/lib
```
### Build your happy Qt5 app
```
./build.sh
```
![happy little apps](../images/bob-ross-happy.gif)
### References
[tal.org/rpi](https://www.tal.org/tutorials/building-qt-515-raspberry-pi)
[doc.qt.io/qtmodules](https://doc.qt.io/qt-5/qtmodules.html)
[wiki.qt.io/about](https://wiki.qt.io/About_Qt)
## Support
[Hush Tech Support Telegram channel](https://t.me/hush8support)

106
advanced/creating-silent-dragon-msi-installer-for-windows-with-wixl.md

@ -0,0 +1,106 @@
# Creating SilentDragon MSI installer for Windows with msitools and wixl
This documentation is for creating a SilentDragon MSI installer for Windows using msitools and wixl. Documentation for msitools is here: https://wiki.gnome.org/msitools Documentation for wixl can refer to WiX toolset as it tries to share the same syntax: https://wixtoolset.org/documentation/manual/v3/
This was tested on Debian 11 (Bullseye)
## Install msitools and wixl
```
sudo apt-get -y install msitools wixl
```
## Download latest SilentDragon Windows release and unzip
Latest releases located here: https://git.hush.is/hush/SilentDragon/releases Example below is for SilentDragon 1.3.0
```
wget https://git.hush.is/attachments/a95d4c43-b662-49bc-a3af-a6fbdd4b9724
unzip a95d4c43-b662-49bc-a3af-a6fbdd4b9724
```
This will unzip into a directory named SilentDragon-1.3.0-win
```
cd SilentDragon-1.3.0-win
```
## Copy silentdragon.ico to SilentDragon directory
The icon file `silentdragon.ico` is currently not included in release zip, but is required to create an MSI installer with a smaller size. Setting icon SourceFile in the .wxs file to silentdragon.exe will duplicate the .exe and make the installer over 100MB instead of ~80MB. How you get this .ico file is up to you. I extracted from .exe on Windows. Maybe it will be included in .zip release in the future to make this easier for anyone trying to create a MSI file for the first time.
## Create WiX source file (.wxs)
This is an XML file. You should name it what you want the .msi file to be named IE: `SilentDragon-1.3.0.wxs`
Below is a copy of the contents of the `SilentDragon-1.3.0.wxs` file Note that GUID's all need to be unique. This will create shortcuts to SilentDragon on desktop and in the start menu as well as have uninstall support from Add/Remove Programs. A tutorial that explains the basics of creating these files can be found here: https://www.firegiant.com/wix/tutorial/
```
<?xml version='1.0' encoding='windows-1252'?>
<Wix xmlns='http://schemas.microsoft.com/wix/2006/wi'>
<Product Name='SilentDragon' Id='c8fae41c-889b-4621-b343-76491cd91b1c' UpgradeCode='a41d7a93-a6cb-41fb-89d2-706a8c22bc99'
Language='1033' Codepage='1252' Version='1.3.0' Manufacturer='HUSH'>
<Package Id='*' Keywords='Installer' Description="HUSH SilentDragon Installer"
Comments='' Manufacturer='HUSH'
InstallerVersion='100' Languages='1033' Compressed='yes' SummaryCodepage='1252' />
<Media Id='1' Cabinet='SilentDragon.cab' EmbedCab='yes' DiskPrompt="CD-ROM #1" />
<Property Id='DiskPrompt' Value="HUSH SilentDragon 1.3.0 Installation [1]" />
<Directory Id='TARGETDIR' Name='SourceDir'>
<Directory Id='ProgramFilesFolder' Name='PFiles'>
<Directory Id='HUSH' Name='HUSH'>
<Directory Id='INSTALLDIR' Name='SilentDragon'>
<Component Id='MainExecutable' Guid='56443570-635d-48e4-8448-8ffd0d7c415a'>
<File Id='SilentDragonEXE' Name='silentdragon.exe' DiskId='1' Source='silentdragon.exe' KeyPath='yes'>
<Shortcut Id="startmenuSilentDragon" Directory="ProgramMenuDir" Name="SilentDragon" WorkingDirectory='INSTALLDIR' Icon="silentdragon.exe" IconIndex="0" Advertise="yes" />
<Shortcut Id="desktopSilentDragon" Directory="DesktopFolder" Name="SilentDragon" WorkingDirectory='INSTALLDIR' Icon="silentdragon.exe" IconIndex="0" Advertise="yes" />
</File>
</Component>
<Component Id="asmap" Guid="190ad39b-44fa-4b22-94ee-d42aca7acc7b">
<File Id="asmap.dat" DiskId='1' Source="asmap.dat" KeyPath="yes"/>
</Component>
<Component Id="hush-cli" Guid="e19e8fd8-aeb9-4dad-99bd-70da0a0aa92c2">
<File Id="hush-cli.exe" DiskId='1' Source="hush-cli.exe" KeyPath="yes"/>
</Component>
<Component Id="hush-tx" Guid="f96b2a39-4734-4a8d-abc3-895006052e97">
<File Id="hush-tx.exe" DiskId='1' Source="hush-tx.exe" KeyPath="yes"/>
</Component>
<Component Id="hushd" Guid="fa66588f-8788-4b29-b6d6-c4a903e49d79">
<File Id="hushd.exe" DiskId='1' Source="hushd.exe" KeyPath="yes"/>
</Component>
<Component Id="READMEFILE" Guid="b20b11de-ded8-4f3c-9797-9bc72c70b42a">
<File Id="README" DiskId='1' Source="README" KeyPath="yes"/>
</Component>
<Component Id="sapling-output" Guid="1ecc1590-ddf3-4f6d-94c5-6bf091aef77a">
<File Id="sapling-output.params" DiskId='1' Source="sapling-output.params" KeyPath="yes"/>
</Component>
<Component Id="sapling-spend" Guid="828d3827-5f2b-47c6-8717-8a664054a2af">
<File Id="sapling-spend.params" DiskId='1' Source="sapling-spend.params" KeyPath="yes"/>
</Component>
</Directory>
</Directory>
</Directory>
<Directory Id="ProgramMenuFolder" Name="Programs">
<Directory Id="ProgramMenuDir" Name="SilentDragon">
<Component Id="ProgramMenuDir" Guid="7ac6af1f-1377-4158-915f-c410cc5cd2a9">
<RemoveFolder Id='ProgramMenuDir' On='uninstall' />
<RegistryValue Root='HKCU' Key='Software\[Manufacturer]\[ProductName]' Type='string' Value='' KeyPath='yes' />
</Component>
</Directory>
</Directory>
<Directory Id="DesktopFolder" Name="Desktop" />
</Directory>
<Feature Id='Complete' Level='1'>
<ComponentRef Id='MainExecutable' />
<ComponentRef Id='ProgramMenuDir' />
<ComponentRef Id='asmap' />
<ComponentRef Id='hush-cli' />
<ComponentRef Id='hush-tx' />
<ComponentRef Id='hushd' />
<ComponentRef Id='READMEFILE' />
<ComponentRef Id='sapling-output' />
<ComponentRef Id='sapling-spend' />
</Feature>
<Icon Id="silentdragon.exe" SourceFile="silentdragon.ico" />
</Product>
</Wix>
```
## Build MSI file from WiX source file
```
wixl -v SilentDragon-1.3.0.wxs
```
This will create a `SilentDragon-1.3.0.msi` file in the same directory which can then be distributed. If it created without error and is larger than 0kb, congratulations!

111
advanced/cross-compile-hush-full-node-to-aarch64-with-docker.md

@ -0,0 +1,111 @@
# Cross compiling a Hush full node daemon from AMD64 to ARM64(aarch64) CPU architecture with Docker.
**Requirements:** Docker-Engine & arm64(aarch64) architecture with Debian operating system like a <a href="https://www.raspberrypi.org/products/raspberry-pi-400/specifications/">Raspberry Pi 400</a>
*For this documentation, I setup <a href="https://dietpi.com/">DietPi</a> It is a Debian:buster OS build.*
0. ## Summary
Cross compiling a Hush full node daemon from **AMD64** to **ARM64(aarch64)** CPU architecture with Docker.
The following instructions enables a smoother transition between your desktop/laptop to the raspberry pi device.
Some issues I encountered *without* the virtual environment was **glibc** version differences on two different machines. Initially, I tested the installation by building & compiling on the **Broadcom BCM2711** quad-core Cortex-A72 (ARM v8) 64-bit SoC @ 1.8GHz device by itself through the normal hush3 instructions provided, but I ran into another set of problems with <a href="https://gcc.gnu.org/">gcc(g++)</a> <a href="https://packages.debian.org/sid/g++-multilib">**g++-multilib**</a> for the arm64(aarch64) architecture; there are no multilib packages for the arm64(aarch64) architecture.
*Note: This should work on all types of arm64(aarch64) devices. By cross compiling (building) on another machine for another machine type, we bypass the ARMv7 requirements. We copy over the binaries built to the Raspberry Pi. Cross compiling is where we compile on one machine to be used on another machine type; this is useful for machines that don't have lots of hardware resources to compile on or in our case, **G++-multilib** isn't built for ARM64(aarch64) devices (at this point in spacetime) and hushd requires it to compile the fresh binaries.*
1. ### Let's Begin!
- Install & setup Docker-Engine <a href="https://docs.docker.com/engine/install/ubuntu/"> Docker-Engine Installation </a>
`sudo docker run -it --rm -v /tmp:/tmp debian:buster`
*Note: we chose this debian type because it has the same ldd --version (glibc) on it. At the moment, there is no DietPi docker image to pull from.*
This creates a container with the latest version of Debian. A bind mount is created mapping the /tmp directory on the host machine to the /tmp directory on the container. The additional options mean the container will run in interactive mode with a terminal, and the container will be destroyed when you stop(exit) it.
`apt-get -y update && apt-get -y upgrade`
2. ### Install Hush build depedencies
*Note: the dependencies for arm64(aarch64) are slightly different; the extra deps are **libboost-dev**, **libdb++-dev**, **libwolssl-dev** and **g++-aarch64-linux-gnu**; libwolf and g++-arch-linux-gnu will be installed later*
`apt-get -y install build-essential pkg-config libc6-dev m4 g++-multilib autoconf libtool ncurses-dev unzip git python zlib1g-dev wget bsdmainutils automake nano curl unzip libsodium-dev libboost-dev libdb++-dev`
3. ### Add to sources list
To install a dep *wolfssl-dev* that isn't on the normal *debian:latest*, we must add to our */etc/apt/sources.list*.
`nano /etc/apt/sources.list`
At the bottom of the list, type or copy/paste the following line
#### libwolfssl-dev dependency
`deb http://ftp.us.debian.org/debian buster-backports main`
CTRL + X then Y for Yes to confirm and save changes.
`apt-get -y update`
#### Install mo dependencies:
*Note: We install these deps later because of other dep requirements.*
`apt-get -y install libwolfssl-dev`
- Install GNU C++ compiler for the arm64(aarch64) architecture
`apt-get -y install g++-aarch64-linux-gnu`
4. ### Pull or clone latest hush3 from git.hush.is
`git clone https://git.hush.is/hush/hush3.git && cd hush3`
5. ### Build and compile for aarch64-linux-gnu device
`HOST=aarch64-linux-gnu ./build.sh -j$(nproc)`
Relax and let the code flow [cat drinking coffee meme] [matrix meme] It normally takes 15-30min to compile successfully for me.
6. ### Copy binaries to ARM64(aarch64) device.
On success of building the Hush binaries, we copy them to our ARM64(aarch64) device and exit the Docker container.
The following cp command used in the **Docker container terminal** copies from docker container to actual machine environment.
`cp -rv ../hush3/ /tmp/hush-arm64`
On the actual **machine environment terminal** we copy all folders and files to raspberry pi drive. The installation location is up to you, but for simplicity sake, I added **/home/user/hush3-foler-name** as a placeholder. If you have a GUI, you can simply drag / drop or CTRL + C and CTRL + V the folder to the drive if copying between drives is troublesome. Remember though, if copying with GUI, you may run into permission problems.
`sudo cp -rv /tmp/hush-arm64/ /media/username/external-drive/home/username/hush-arm64`
#### Changing permissions recursively for every file and folder
*Tip: chmod 755: Only owner can write, read and execute for everyone.*
`sudo chmod 755 -Rv /tmp/hush-arm64`
#### Changing ownership of file/folder for rpi device
*Tip: for security purposes, I recommend creating a new username for the rpi hush server; using root for any application is bad security practice*
`sudo chown -Rv rpi-username /media/username/external-drive/home/dietpi/hush-arm64/`
`exit` ***Note: on `exit`, the docker container will be completely destroyed!***.
7. ### Launch a fresh hush daemon(node) puppy on ARM64(aarch64)
`./src/hushd --version`
We have successfully cross-compiled a hushd for a arm64(aarch64) from amd64 or other architecture.
*Note: this has only been tested from amd64 architecture; we will update this list later for other tested hardware; the process will almost be identical, but other deps may be needed*
Happy Hacking! [Hooray!]
<img src="https://git.hush.is/hush/memes/raw/branch/master/hush/hush-puppy-rocket.gif">
## Automation with Docker
I will update the steps required to automatically build and run hushd with a Dockerfile. This is useful for testing and also aids in other hush puppies who don't need to deep dive into developer chores and maintainance. Required dep is Docker-Engine.
### Create Hush docker image
0. `git clone https://git.hush.is/hush/hush3.git && cd hush3/`
1. `docker build -t hush:3.8.0 .`
### List docker images & run Hush docker image
2. `docker images`
3. Look for the docker image ID for hush:3.x.x
4. `docker run imageID`
5. `hushd --version`
## Support, Socials and Licensing
<a href="https://git.hush.is/hush/hush3#support-and-socials"> Support, Socials and Licensing</a>
This documentation, formatting, testing, hacking and many headaches created this after about ~34 hours of tedious focus and work.

103
advanced/cross-compile-silent-dragon-for-windows-with-mxe.md

@ -0,0 +1,103 @@
# Cross-Compiling SilentDragon for Windows with MXE
This document explains how to build Windows binaries from a Linux system. This was tested and created on Debian 11 (Bullseye).
## Install Build dependencies
```
sudo apt-get -y install clang g++ build-essential make mingw-w64 git pkg-config libc6-dev m4 g++-multilib autoconf libncurses-dev libtool-bin unzip python zlib1g-dev wget curl bsdmainutils automake libgl1-mesa-dev libglu1-mesa-dev libfontconfig1-dev autopoint libssl-dev
```
## Install QT packages
```
sudo apt-get -y install qtdeclarative5-dev qt5-qmake libqt5websockets5-dev qtcreator
```
## Install MXE dependencies
Current list of dependencies is here: http://mxe.cc/#requirements-debian
```
sudo apt-get install \
autoconf \
automake \
autopoint \
bash \
bison \
bzip2 \
flex \
g++ \
g++-multilib \
gettext \
git \
gperf \
intltool \
libc6-dev-i386 \
libgdk-pixbuf2.0-dev \
libltdl-dev \
libssl-dev \
libtool-bin \
libxml-parser-perl \
lzip \
make \
openssl \
p7zip-full \
patch \
perl \
python \
ruby \
sed \
unzip \
wget \
xz-utils
```
## Clone MXE
```
git clone https://github.com/mxe/mxe.git
```
## Build MXE
Add `MXE_TARGETS` so we get both 32-bit and 64-bit Windows binaries.
```
cd mxe
make MXE_TARGETS='x86_64-w64-mingw32.static i686-w64-mingw32.static' openssl qtbase qtwebsockets
```
## Add path to MXE and /usr/bin
`export PATH=$PATH:`_/your/mxe/path_`/usr/bin`
## Clone SilentDragon source
```
git clone https://git.hush.is/hush/SilentDragon.git
cd SilentDragon
```
## Build latest translations
Either
`
./build.sh linguist
`
Or
`
./win-build.sh linguist
`
## Build SilentDragon Windows binaries
Within your SilentDragon repository run build script:
```
./win-build.sh release
```
Executable should be created and located within SilentDragon repository, IE: SilentDragon/release/silentdragon.exe
**Note:** Options for `win-build.sh` include: `clean`, `cleanbuild`, `linguist`, and `release`. No option specified will build debug version by default. `winbuild.sh` compiles 64-bit binary only, but can be modified to compile 32-bit.
**Targeting 32-bit or 64-bit**
Modify qbuild_release target in `winbuild.sh` to specify 32-bit or 64-bit
To make 32-bit Windows GUI executable
`
i686-w64-mingw32.static-qmake-qt5 $CONF CONFIG+=release
`
To make 64-bit Windows GUI executable (default)
`
x86_64-w64-mingw32.static-qmake-qt5 $CONF CONFIG+=release
`

2
hush-lite-server.md

@ -42,7 +42,7 @@ Install your preferred distro. In this example I am using a VPS running Ubuntu 2
1. Then check if the Hush blockchain is downloading by noticing if the blockchain directory is increasing.
```shell script
du -h ~/.komodo/HUSH3/blocks/
du -h ~/.hush/HUSH3/blocks/
```
1. The blockchain download will take some time, so feel free to take a break and wait or open another terminal (or GNU screen) and continue to install Hush lightwalletd.

BIN
images/banana-go-bananas.gif

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 KiB

BIN
images/bob-ross-happy.gif

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 MiB

Loading…
Cancel
Save