Skip to content

Commit

Permalink
Add asan build script
Browse files Browse the repository at this point in the history
  • Loading branch information
jcoffland committed Jan 15, 2025
1 parent 6fc619f commit 393020a
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions scripts/build-with-asan.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/bin/bash -e

if [ "$CBANG_HOME" == "" ]; then
echo CBANG_HOME not set
exit 1
fi

CCFLAGS=-fsanitize=address
LDFLAGS="-fsanitize=address -static-libasan"

export SCONS_OPTIONS="ccflags='$CCFLAGS' linkflags='$LDFLAGS' libs=bfd debug=1"

scons -C "$CBANG_HOME" "$@"

0 comments on commit 393020a

Please sign in to comment.