build: link with lld if available

Change-Id: Iaf1e7110e629fa1fa16bbd8b8cc1418fafd2408b
diff --git a/.jenkins.d/00-deps.sh b/.jenkins.d/00-deps.sh
index 12b5de3..5f358cd 100755
--- a/.jenkins.d/00-deps.sh
+++ b/.jenkins.d/00-deps.sh
@@ -39,6 +39,6 @@
     fi
 
 elif [[ $ID_LIKE == *fedora* ]]; then
-    sudo dnf -y install gcc-c++ libasan pkgconf-pkg-config python3 \
+    sudo dnf -y install gcc-c++ libasan lld pkgconf-pkg-config python3 \
                         boost-devel openssl-devel sqlite-devel
 fi
diff --git a/.waf-tools/default-compiler-flags.py b/.waf-tools/default-compiler-flags.py
index 78cf40d..536e3d3 100644
--- a/.waf-tools/default-compiler-flags.py
+++ b/.waf-tools/default-compiler-flags.py
@@ -137,9 +137,7 @@
     def getGeneralFlags(self, conf):
         flags = super(GccBasicFlags, self).getGeneralFlags(conf)
         flags['CXXFLAGS'] += ['-std=c++14']
-        if Utils.unversioned_sys_platform() == 'linux':
-            flags['LINKFLAGS'] += ['-fuse-ld=gold']
-        elif Utils.unversioned_sys_platform() == 'freebsd':
+        if Utils.unversioned_sys_platform() != 'darwin':
             flags['LINKFLAGS'] += ['-fuse-ld=lld']
         return flags
 
diff --git a/docs/INSTALL.rst b/docs/INSTALL.rst
index 9f0f02b..dd394ec 100644
--- a/docs/INSTALL.rst
+++ b/docs/INSTALL.rst
@@ -23,7 +23,7 @@
 - Fedora >= 29
 - Gentoo Linux
 - Raspberry Pi OS (formerly Raspbian) >= 2019-06-20
-- FreeBSD >= 12.0
+- FreeBSD >= 12.2
 
 Prerequisites
 -------------
@@ -123,7 +123,7 @@
 
   .. code-block:: sh
 
-    sudo pkg install doxygen graphviz py37-sphinx
+    sudo pkg install doxygen graphviz py39-sphinx
 
 Build
 -----