Re: Enabling AddressSanitizer from Xcode
Re: Enabling AddressSanitizer from Xcode
- Subject: Re: Enabling AddressSanitizer from Xcode
- From: James Walker <email@hidden>
- Date: Thu, 14 Mar 2013 16:18:21 -0700
On 3/14/2013 11:06 AM, Sean McBride wrote:
On Thu, 14 Mar 2013 01:03:47 -0400, Jeff Smith said:
Since AddressSanitizer is part of LLVM/Clang, is it possible to enable
it from Xcode's Build Settings?
No. Apple uses their own fork of clang for Xcode, which does not include the Asan work google did. File a bug and wait forever (you can dupe mine <rdar://11056201>). In the mean time, build your own clang and point Xcode to it:
<http://blog.wadetregaskis.com/tot-clang-llvm-in-xcode/>
Cheers,
Using the current Clang as described in that blog, when I attempt to use
-fsanitize=address, I get link errors on symbols such as
___asan_after_dynamic_init. When I tried to use -fsanitize=undefined, I
got link errors on a different set of symbols such as
___ubsan_handle_add_overflow.
I did manage to get some code to link using
-fsanitize-undefined-trap-on-error -fsanitize=undefined-trap, but
whether that will find any bugs for me remains to be seen.
--
James W. Walker, Innoventive Software LLC
<http://www.frameforge3d.com/>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden