Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion sdk/lib/crt/msvcrtex.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ list(APPEND MSVCRTEX_SOURCE
misc/fltused.c
misc/isblank.c
misc/iswblank.c
misc/ofmt_stub.c)
misc/ofmt_stub.c
stdio/acrt_iob_func.c)

if(MSVC)
list(APPEND MSVCRTEX_SOURCE
Expand Down
24 changes: 24 additions & 0 deletions sdk/lib/crt/stdio/acrt_iob_func.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
/*
* PROJECT: ReactOS CRT library
* LICENSE: LGPL-2.1-or-later (https://spdx.org/licenses/LGPL-2.1-or-later)
* PURPOSE: __acrt_iob_func implementation
* COPYRIGHT: Victor Perevertkin <victor.perevertkin@reactos.org>
*/

// Evil hack necessary, because we're linking to the RosBE-provided libstdc++ when using GCC.
// This can only be solved cleanly by adding a GCC-compatible C++ standard library to our tree.
#ifdef __GNUC__

#include <precomp.h>

/*********************************************************************
* __acrt_iob_func(MSVCRT.@)
*/
FILE * CDECL __acrt_iob_func(int index)
{
return &__iob_func()[index];
}

const void* _imp____acrt_iob_func = __acrt_iob_func;

#endif