Skip to content

Commit

Permalink
build: link with lld if available
Browse files Browse the repository at this point in the history
Change-Id: Iaf1e7110e629fa1fa16bbd8b8cc1418fafd2408b
  • Loading branch information
Pesa committed Oct 5, 2022
1 parent e16ac86 commit ea5ce49
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .jenkins.d/00-deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,6 @@ elif [[ $ID_LIKE == *debian* ]]; then
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
4 changes: 1 addition & 3 deletions .waf-tools/default-compiler-flags.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,9 +137,7 @@ class GccBasicFlags(CompilerFlags):
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

Expand Down
4 changes: 2 additions & 2 deletions docs/INSTALL.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ supported:
- Fedora >= 29
- Gentoo Linux
- Raspberry Pi OS (formerly Raspbian) >= 2019-06-20
- FreeBSD >= 12.0
- FreeBSD >= 12.2

Prerequisites
-------------
Expand Down Expand Up @@ -123,7 +123,7 @@ The following lists the steps to install these prerequisites on various common p

.. code-block:: sh
sudo pkg install doxygen graphviz py37-sphinx
sudo pkg install doxygen graphviz py39-sphinx
Build
-----
Expand Down

0 comments on commit ea5ce49

Please sign in to comment.