Bug#17632386: WITH_ASAN CONFLICTS WITH -WL,--NO-UNDEFINED
-Wl,--no-undefined (=-z defs) gives linking errors when used with WITH_ASAN. According to the documentation: "When linking shared libraries, the AddressSanitizer run-time is not linked, so -Wl,-z,defs may cause link errors (don’t use it with AddressSanitizer)." This patch turns off -Wl,--no-undefined if WITH_ASAN is used.
This commit is contained in:
parent
c5896384bd
commit
63a205d4a0
@ -1,5 +1,5 @@
|
||||
|
||||
# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@ -33,7 +33,10 @@ ENDFOREACH()
|
||||
|
||||
# Ensure we have clean build for shared libraries
|
||||
# without unresolved symbols
|
||||
SET(LINK_FLAG_NO_UNDEFINED "-Wl,--no-undefined")
|
||||
# Not supported with AddressSanitizer
|
||||
IF(NOT WITH_ASAN)
|
||||
SET(LINK_FLAG_NO_UNDEFINED "-Wl,--no-undefined")
|
||||
ENDIF()
|
||||
|
||||
# 64 bit file offset support flag
|
||||
SET(_FILE_OFFSET_BITS 64)
|
||||
|
Loading…
x
Reference in New Issue
Block a user