The Monero package provides a daemon and wallet tool for accessing the Monero, or XMR, crypto currency. The wallet tool provided by this package is command-line only.
There is a GUI wallet tool made by the Monero project, but it only has support for Qt-5, no longer in BLFS, and Qt-5 in older versions of BLFS no longer builds properly. Thus, you may have to use a third-party GUI wallet tool, which is not recommended, find a way to build Qt-5, or stick with the command-line wallet tool.
This may take a while to build. Feel free to do something else while this is building.
Boost, CMake, libsodium-1.0.21, Unbound, and libzmq-4.3.5
HIDAPI-0.15.0, libunwind, libusb, and Protobuf
Create a list of the needed tarballs that will be downloaded:
cat > monero-list << "EOF"
monero-project/monero/archive/v0.18.4.5/monero-0.18.4.5.tar.gz
google/googletest/archive/b514bdc898e2951020cbdca1304b75f5950d1f59.tar.gz
miniupnp/miniupnp/archive/544e6fcc73c5ad9af48a8985c94f0f1d742ef2e0.tar.gz
tevador/RandomX/archive/102f8acf90a7649ada410de5499a7ec62e49e1da.tar.gz
Tencent/rapidjson/archive/129d19ba7f496df5e33658527a7158c79b99c21c.tar.gz
monero-project/supercop/archive/633500ad8c8759995049ccd022107d1fa8a1bbc9.tar.gz
EOF
Now download the package, its submodules, and needed patches if applicable, using Wget:
mkdir monero &&
cd monero &&
grep -v '^#' ../monero-list | wget -i- -c \
-B https://github.com
There should be a dedicated user and group to take control of the
monerod daemon after
it is started. Issue the following commands as the root user:
groupadd -fg 66 monero &&
useradd -c "Monero Full Node" -d /var/lib/monero -u 66 \
-g monero -s /bin/false monero
Extract all the tarballs:
for i in *.tar.?z*; do echo "Extracting $i..." tar -xf $i done
Now that everything has been extracted, the required extracted
submodules need to be moved into monero-0.18.4.5. Do that by running the following
commands:
mv -T googletest-* monero-0.18.4.5/external/gtest && mv -T miniupnp-* monero-0.18.4.5/external/miniupnp && mv -T RandomX-* monero-0.18.4.5/external/randomx && mv -T rapidjson-* monero-0.18.4.5/external/rapidjson && mv -T supercop-* monero-0.18.4.5/external/supercop
Now go into the monero-0.18.4.5
directory:
cd monero-0.18.4.5
Ensure Protobuf has the right C++ standard set:
sed 's|std=c++11|std=c++17|g' \ -i contrib/depends/protobuf.mk
Install Monero by running the following commands:
mkdir build &&
cd build &&
cmake -D CMAKE_INSTALL_PREFIX=/usr \
-D CMAKE_BUILD_TYPE=Release \
-D BUILD_GUI_DEPS=ON \
-G Ninja -W no-dev .. &&
ninja
Now, as the root user:
install -vDm755 bin/* -t /usr/bin/
Now install Systemd-specific files as the root user:
install -vDm644 ../utils/conf/monerod.conf -t /etc/ &&
install -vDm644 ../utils/systemd/monerod.service -t /usr/lib/systemd/system/ &&
install -vDm644 /dev/stdin /usr/lib/tmpfiles.d/monero.conf << "EOF"
d /var/lib/monero 0770 monero monero - -
EOF
If you want the monerod daemon to start
automatically when the system is booted, run the following
command as the root user:
systemctl enable monerod
The monerod daemon can take up RAM and CPU resources. This will depend on the system, so you should look at the resources used and see if you want it started at every boot.
-D BUILD_GUI_DEPS=ON: This
parameter ensures the dependencies for the GUI wallet are built, in
case the GUI wallet tool gains support for Qt-6, GTK, or something
else.