Uploaded image for project: 'Core ReactOS'
  1. Core ReactOS
  2. CORE-14607

VS2013 build fail on msvcrtex

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Won't Fix
    • Fix Version/s: None
    • Component/s: Build System
    • Labels:
      None

      Description

      I'm using only CMake and VS2013 without RosBE preinstalled with following command:

      @echo off
      :: CMake 3.11.1 x64
      set path=C:\Program Files\CMake\bin;%path%
      :: Visual Studio 2013 Professional Update 5 ver.12.0.40629.00
      call "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat" x86
      call configure.cmd VSSolution
      cd output-VS-i386-sln
      msbuild -m REACTOS.sln /t:sdk\lib\crt\msvcrtex
      pause
      

       

      This will result in 1 error when compile wcrtexe.c:

      c:\reactos\sdk\lib\crt\startup\crtexe.c(287): error C4013: '_ismbblead' undefined; assuming extern returning int [C:\reactos\output-VS-i386-sln\sdk\lib\crt\msvcrtex.vcxproj]
      

       

       wcrtexe.c itself only defines Unicode specific macros and #include "crtexe.c". The section that crtexe,c throws error looks like this:

      #ifdef _MBCS
          if (_ismbblead (*lpszCommandLine))
          {
              if (lpszCommandLine) /* FIXME: Why this check? Should I check for *lpszCommandLine != 0 too? */
                  lpszCommandLine++;
          }
      #endif
      

      MBCS stands for Multi Byte Character Set which is used for some Asian language where 1 byte can't encode all their characters. As such this is not a Unicode encoding.

      Adding #undef _MBCS before #include "crtexe.c" in wcrtexe.c seems to fix the build on msvcrtex. Though I think we need to fix some header files.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                bug zilla Bug Zilla
                Reporter:
                Yuntian Zhang Yuntian Zhang
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: