Martin Fuchs martin-fuchs at
Sat Oct 9 06:38:54 CDT 2004


can anyone explain to me, what's the exact reason for the following
error message in wine/include/tchar.h:

#if defined(_UNICODE) || defined(_MBCS)
#error You must use msvcrt when building in Unicode/MBCS mode

It disallows inclusion of this <tchar.h> header file when using the
_UNICODE define.  Just a few lines later in this file there are the
following definitions:

 * tchar mappings
#ifndef _UNICODE
#  ifndef _MBCS
#    include <string.h>
#    define WINE_tchar_routine(std,mbcs,unicode) std
#  else
#    include <mbstring.h>
#    define WINE_tchar_routine(std,mbcs,unicode) mbcs
#  endif
#else /* _UNICODE */
#  include <wchar.h>
#  define WINE_tchar_routine(std,mbcs,unicode) unicode

Again asking for "_UNICODE" !
So something can't be right with this.
The <tchar.h> header should really define constants like _tcschr
dependend on the _UNICODE define. But currently this doesn't
work because of the error message described above.

Either there should be a overriding "wine/include/msvcrt/tchar.h"
file with different defintions. Or the error message "You must use
msvcrt when building in Unicode/MBCS mode" is simply superfluous.



More information about the wine-devel mailing list