Windows CE and CMarkup
CMarkup has been used on Windows CE since early in 2001, using the UNICODE build. CMarkup is great there because of its small footprint. But new releases of CMarkup are not tested on Windows CE so there have been small compile issues in some releases.
I think the problem you are describing is related to the saving and loading of files, not the processing. CMarkup
Load may have problems with Win CE because of the wide char (UNICODE UCS-2) files on Win CE. But we can figure this out without too much difficulty. I would look at the flags involved in saving the file, and trace through to make sure the xml
m_csData contains those default structures before it is saved. Also check into any differences between files on the two versions of the OS. UCS-2 has two bytes per character, ASCII is one byte per char, and UTF-8 is one byte per char for standard ASCII chars and more for others. The Save and Load were primarily built for UTF-8 but can be modified for Win CE.
Conversion functions were added to CMarkup in developer release 6.6.
Windows CE compatibility with the error string was cleaned up in release 8.3.
strerror was introduced as part of efforts to reduce platform specific dependencies, but
FormatMessage is used when
wcserror is not available. These are suggestions for doing your own fix prior to CMarkup 8.3:
- The quickest solution to get it to compile, inside the
#ifdef _WIN32_WCEat the top of Markup.cpp you can add
#define strerror(n) _T("file error")
errnois supported, you can replace each call to strerror with the error as just a number like
strError.Format( "errno %d", errno );
- To get the actual error string, you can use something like
// OS provides a system error string
DWORD dwError = GetLastError();
FormatMessage( FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
NULL, dwError, MAKELANGID(LANG_NEUTRAL,SUBLANG_DEFAULT),
csDescription.GetBuffer(255), nSize, NULL );
CMarkup release 8.3 has
x_GetLastError which uses the Windows API
GetLastError() when the relevant
wcserror function is not available.
It is done in CMarkup release 8.3 and the internal function used to get file errors is called
x_GetLastError though there is no affect on the public
/Gy compiler option. If the warning remains, based on my googling the warning apparently means it would be necessary to rewrite large functions into multiple smaller ones for the code to work correctly on certain TI 925 chips due to a bug on those chips.