Opened 11 years ago
Last modified 10 years ago
#41366 assigned defect
gcc48: asan (address sanitizer) is broken
Reported by: | akimd (Akim Demaille) | Owned by: | larryv (Lawrence Velázquez) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.2.1 |
Keywords: | Cc: | cooljeanius (Eric Gallager), anddam (Andrea D'Amore), mww@… | |
Port: | gcc48 |
Description
address sanitizer is broken with 4.8, probably because its library is not installed. It works with 4.9:
$ cat foo.cc int main() {} $ gcc-mp-4.9 -fsanitize=address foo.cc $ g++-mp-4.8 -fsanitize=address foo.cc ld: library not found for -lasan collect2: error: ld returned 1 exit status
(C vs. C++ is irrelevant)
Note that neither thread sanitizers work properly:
$ gcc-mp-4.9 -fsanitize=thread foo.cc Undefined symbols for architecture x86_64: "___tsan_init", referenced from: __GLOBAL__sub_I_00099_0_foo.cc in ccs9M1Tr.o ld: symbol(s) not found for architecture x86_64 collect2: error: ld returned 1 exit status $ gcc-mp-4.8 -fsanitize=thread foo.cc Undefined symbols for architecture x86_64: "___tsan_init", referenced from: __GLOBAL__sub_I_00099_0_foo.cc in ccx7nFfX.o ld: symbol(s) not found for architecture x86_64 collect2: error: ld returned 1 exit status
Change History (10)
comment:1 Changed 11 years ago by ryandesign (Ryan Carsten Schmidt)
Owner: | changed from macports-tickets@… to mww@… |
---|---|
Summary: | asan (address sanitizer) is broken → gcc48: asan (address sanitizer) is broken |
comment:2 Changed 11 years ago by cooljeanius (Eric Gallager)
Cc: | egall@… added |
---|
comment:4 Changed 10 years ago by anddam (Andrea D'Amore)
Port gcc48 got at least one update since the ticket was opened.
At the moment I cannot reproduce the issue, please check your system and confirm you still can.
comment:6 Changed 10 years ago by akimd (Akim Demaille)
No change.
$ cat > foo.cc int main() {} $ gcc-mp-4.9 -fsanitize=address foo.cc $ gcc-mp-4.8 -fsanitize=address foo.cc ld: library not found for -lasan collect2: error: ld returned 1 exit status $ gcc-mp-4.8 --version gcc-mp-4.8 (MacPorts gcc48 4.8.3_1) 4.8.3 Copyright (C) 2013 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
comment:8 follow-up: 9 Changed 10 years ago by larryv (Lawrence Velázquez)
Cc: | mww@… added; larryv@… removed |
---|---|
Owner: | changed from mww@… to larryv@… |
Status: | new → assigned |
Replying to akim.demaille@…:
Note that neither thread sanitizers work properly:
Could you open a new ticket for this? I’d like to track that issue separately.
comment:9 Changed 10 years ago by akimd (Akim Demaille)
comment:10 Changed 10 years ago by Veence (Vincent)
libasan is not installed by gcc-4.x (actually, it's a link) but by libgcc that seems to fail to create (or install) it properly (it is missing).
Note: See
TracTickets for help on using
tickets.
Cc Me!