Closed
Bug 1316276
Opened 8 years ago
Closed 7 years ago
Gyp builds violate ODR
Categories
(NSS :: Build, defect)
NSS
Build
Tracking
(Not tracked)
RESOLVED
FIXED
3.30
People
(Reporter: franziskus, Assigned: ttaubert)
References
Details
Building gyp with asan shows that there are a couple odr violations. We should fix them so that we can remove ASAN_OPTIONS=detect_odr_violation=0.
Comment 1•8 years ago
|
||
What's broken here?
Reporter | ||
Comment 2•8 years ago
|
||
You can reproduce errors like the one below when running for example ssl_gtest after building with asan (./build.sh --asan)
> ==18211==ERROR: AddressSanitizer: odr-violation (0x000000d43600):
> [1] size=144 'SSL_ImplementedCiphers' ../../lib/ssl/sslenum.c:57:16
> [2] size=144 'SSL_ImplementedCiphers' ../../lib/ssl/sslenum.c:57:16
> These globals were registered at these points:
> [1]:
> #0 0x484d60 in __asan_register_globals.part.10 (/home/franziskus/Code/dist/Debug/bin/ssl_gtest+0x484d60)
> #1 0x92bb3b in asan.module_ctor (/home/franziskus/Code/dist/Debug/bin/ssl_gtest+0x92bb3b)
>
> [2]:
> #0 0x484d60 in __asan_register_globals.part.10 (/home/franziskus/Code/dist/Debug/bin/ssl_gtest+0x484d60)
> #1 0x7fc5e5b9936b in asan.module_ctor (/home/franziskus/Code/dist/Debug/lib/libssl3.so+0x10c36b)
>
> ==18211==HINT: if you don't care about these errors you may set ASAN_OPTIONS=detect_odr_violation=0
> SUMMARY: AddressSanitizer: odr-violation: global 'SSL_ImplementedCiphers' at ../../lib/ssl/sslenum.c:57:16
> ==18211==ABORTING
Comment 3•8 years ago
|
||
Aha! ssl_gtest depends on libssl.a: https://dxr.mozilla.org/nss/rev/3169aa4875171a86fd5b457ff2f494741afd2b78/nss/gtests/ssl_gtest/ssl_gtest.gyp#51 but gtests/common/common.gyp links it against libssl.so as well: https://dxr.mozilla.org/nss/rev/3169aa4875171a86fd5b457ff2f494741afd2b78/nss/gtests/common/common.gyp#21
Reporter | ||
Comment 4•8 years ago
|
||
That's correct, but that doesn't solve the problem :(
Assignee | ||
Comment 5•7 years ago
|
||
Should be fixed by bug 1333361.
Assignee | ||
Comment 6•7 years ago
|
||
Bug 1333361 landed.
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → 3.30
You need to log in
before you can comment on or make changes to this bug.
Description
•