Skip to content

Commit

Permalink
LD_PRELOAD libasan for node
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-j-h committed Apr 3, 2017
1 parent c4122ad commit 46e5e6c
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -226,12 +226,18 @@ script:
- |
if [ -n "${ENABLE_NODE_BINDINGS}" ]; then
echo ">>> symbol-tag-node-osrm"
nm -D ../lib/binding/node-osrm.node | c++filt
echo ">>> symbol-tag-libosrm"
nm libosrm.a | c++filt
if [ -n "${ENABLE_SANITIZER}" ]; then
# Node module compiled with sanitizer needs to preload libasan,
# otherwise sanitizer-internal symbols will not be found.
# This is due to how node loads our node binding shared object.
export LD_PRELOAD='/usr/lib/x86_64-linux-gnu/libasan.so.2'
fi
npm run nodejs-tests
if [ -n "${ENABLE_SANITIZER}" ]; then
unset LD_PRELOAD
fi
fi
- popd
- yarn test
Expand Down

0 comments on commit 46e5e6c

Please sign in to comment.