Skip to content

Commit

Permalink
DAOS-15799 build: Add libsanitize
Browse files Browse the repository at this point in the history
Add libsanitize for debugging stack smashing occuring on LRZ servers.

Skip-test: true
Required-githooks: true

Signed-off-by: Cedric Koch-Hofer <[email protected]>
  • Loading branch information
kanard38 authored and Cedric Koch-Hofer committed May 31, 2024
1 parent bf9ac88 commit 4d2d40f
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 1 deletion.
3 changes: 3 additions & 0 deletions site_scons/site_tools/compiler_setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@
# Compiler flags for stack hardening
DESIRED_FLAGS.extend(['-fstack-protector-strong', '-fstack-clash-protection'])

# Compiler flags for fast memory error detector
DESIRED_FLAGS.extend(['-fsanitize=address'])

PP_ONLY_FLAGS = ['-Wno-parentheses-equality', '-Wno-builtin-requires-header',
'-Wno-unused-function']

Expand Down
8 changes: 7 additions & 1 deletion utils/rpms/daos.spec
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

Name: daos
Version: 2.4.2
Release: 4%{?relval}%{?dist}
Release: 5%{?relval}%{?dist}
Summary: DAOS Storage Engine

License: BSD-2-Clause-Patent
Expand Down Expand Up @@ -114,6 +114,9 @@ BuildRequires: libuct-devel
BuildRequires: ucx-devel
%endif

# Needed for support tasks
BuildRequires: libasan

Requires: openssl
# This should only be temporary until we can get a stable upstream release
# of mercury, at which time the autoprov shared library version should
Expand Down Expand Up @@ -555,6 +558,9 @@ getent passwd daos_agent >/dev/null || useradd -s /sbin/nologin -r -g daos_agent
# No files in a shim package

%changelog
* Fri May 31 2024 Cedric Koch-Hofer <[email protected]> 2.4.2-5
- Support release candidate for 2.4.2

* Mon Mar 04 2024 Phillip Henderson <[email protected]> 2.4.2-4
- Third release candidate for 2.4.2

Expand Down
1 change: 1 addition & 0 deletions utils/scripts/install-el8.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ dnf --nodocs install \
java-1.8.0-openjdk \
json-c-devel \
libaio-devel \
lbasan \
libcmocka-devel \
libevent-devel \
libiscsi-devel \
Expand Down
1 change: 1 addition & 0 deletions utils/scripts/install-el9.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ dnf --nodocs install \
java-1.8.0-openjdk \
json-c-devel \
libaio-devel \
libasan \
libcmocka-devel \
libevent-devel \
libipmctl-devel \
Expand Down
1 change: 1 addition & 0 deletions utils/scripts/install-leap15.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ dnf --nodocs install \
hwloc-devel \
java-1_8_0-openjdk-devel \
libaio-devel \
libasan \
libcmocka-devel \
libcapstone-devel \
libevent-devel \
Expand Down
1 change: 1 addition & 0 deletions utils/scripts/install-ubuntu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ apt-get install \
golang-go \
kmod \
libaio-dev \
libasan \
libboost-dev \
libcapstone-dev \
libcmocka-dev \
Expand Down

0 comments on commit 4d2d40f

Please sign in to comment.