The unit test problems aren't clang issues, they're OSX issues. So:
test-net.c:79: Assert failed: strcmp(net_ip2addr(&ip), "::5") == 0
test-net.c:83: Assert failed: strcmp(net_ip2addr(&ip), "::5") == 0
This is because OSX writes the address out as "::0.0.0.5" instead of "::5". I don't remember if the core code should be fixed or if it's just the unit test that needs fixing.
test-lib(26058,0x7fff95cf7380) malloc: *** mach_vm_map(size=9223372036854775808) failed (error code=3)
*** error: can't allocate region
*** set a breakpoint in malloc_error_break to debug
fatal_mempool_alloconly .............................................. : ok
test-lib(26058,0x7fff95cf7380) malloc: *** mach_vm_map(size=9223372036854775808) failed (error code=3)
*** error: can't allocate region
*** set a breakpoint in malloc_error_break to debug
fatal_mempool_allocfree .............................................. : ok
I'm pretty sure these are intentional. The unit tests are succeeding, and the unit tests are there to test failing memory allocations. OSX just wants to also write some extra errors to stderr.
The compiler returns many warnings, and the test returns two IPv6-related errors. I am attaching both logs as reference.
‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
We compile all core code with both gcc and clang. What sort of interesting things did you find?
Aki
Please, use clang instead of gcc. Code quality can only profit from it. I just compiled 2.3.4 and compiler stderr is full of interesting problems.
<compiler-stderr.log><test.log>