LIU Hao wrote:
> 在 2026-1-26 07:16, Pali Rohár 写道:
>> C++ header files are trying to put quick_exit and at_quick_exit functions
>> into :: or std:: namespace. If those functions are not declared then
>> compilation is failing with error:
>> error: 'at_quick_exit' has not been declared in '::'
>> And it does not matter if those functions are used or not.
>> ---
>>  mingw-w64-headers/crt/stdlib.h | 4 ----
>>  1 file changed, 4 deletions(-)
>
> Do such headers exist in the wild? Both libstdc++ and libc++ declare them 
> conditionally.

This is probably resulted from the fact that we were using libstdc++ headers 
configured for UCRT when we run tests for msvcrt{20,40}.dll, note condition 
"matrix.crt == ucrt":

```
      - name: Run testcases for msvcrt20.dll
        if: ${{ matrix.arch == 'i686' && matrix.crt == 'ucrt' }}
```

maybe using "matrix.crt == msvcrt" instead would solve this issue? This also 
means that we are linking static libstdc++ configured for UCRT when running 
tests for msvcrt{20,40}.dll, which may result in more issues in future.

>> commit 8552c9bf4dbd8d83945eff2c5d32b8c81f96fcfd
>> Author:     Kirill Makurin <[email protected]>
>> AuthorDate: 2026-01-17 19:43:19 +0900
>> Commit:     LIU Hao <[email protected]>
>> CommitDate: 2026-01-26 15:32:34 +0800
>>
>>     Try fix C++ linking
>>
>>     Signed-off-by: LIU Hao <[email protected]>
>
> Would you elaborate the purpose of this change?

Pali picked this commit from branch where we were running CI tests. There were 
link issues with undefined reference to __ms_vsnprintf and it seemed to do with 
link order. I initially pushed that commit just to see if it'll fix the issue.

- Kirill Makurin

_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to