https://sourceware.org/bugzilla/show_bug.cgi?id=33561

            Bug ID: 33561
           Summary: mingw binutils/ld -r bug
           Product: binutils
           Version: 2.45
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: ld
          Assignee: unassigned at sourceware dot org
          Reporter: tmb148 at gmail dot com
  Target Milestone: ---

The following code "test.cpp":

#include <stdio.h>
#include <stdarg.h>

void
log(const char *format, ...)
{
    va_list var_args;
    va_start(var_args, format);
    char buf[512];
    vsprintf_s(&buf[0], 512, format, var_args);
    va_end(var_args);
}



Compiled with
>g++ -g -nostdlib -nostdlib++ -Wl,-r test.cpp -o tmp.o

and then linked with
>ld -r tmp.o -o tmp2.o

produces this error:
>ld: tmp.o: warning: COMDAT symbol '.debug_frame$_vsprintf_s_l' does not match 
>section name '.debug_frame'


Note that this is a error and not just a warning.
The build/link completes despite the error.
Sounds like this bug: https://sourceware.org/bugzilla/show_bug.cgi?id=15041


>g++ --version
g++ (MinGW-W64 x86_64-ucrt-posix-seh, built by Brecht Sanders, r1) 15.2.0

>ld --version
GNU ld (Binutils for MinGW-W64 x86_64, built by Brecht Sanders, r1) 2.45

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Reply via email to