Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

88 lines
1.9 KiB

  1. // cestubs.h - This is stuff that we need from elsewhere to compile (even if we don't
  2. // use the OS functions that these data structures imply
  3. // c runtime functions that we have to simulate or replace
  4. #ifndef _CESTUBS_H_
  5. #define _CESTUBS_H_
  6. #ifdef UNDER_CE
  7. #define CETEXT(x) L##x
  8. // Can't use ASSERT or putc from inside CE (porky uses them for debugging only
  9. #undef ASSERT
  10. #define ASSERT(x)
  11. //#define putc(x, y)
  12. #define OFS_MAXPATHNAME 128
  13. typedef struct _OFSTRUCT {
  14. BYTE cBytes;
  15. BYTE fFixedDisk;
  16. WORD nErrCode;
  17. WORD Reserved1;
  18. WORD Reserved2;
  19. CHAR szPathName[OFS_MAXPATHNAME];
  20. } OFSTRUCT, *LPOFSTRUCT, *POFSTRUCT;
  21. #ifndef _FILE_DEFINED
  22. struct _iobuf {
  23. char *_ptr;
  24. int _cnt;
  25. char *_base;
  26. int _flag;
  27. int _file;
  28. int _charbuf;
  29. int _bufsiz;
  30. char *_tmpfname;
  31. };
  32. typedef struct _iobuf FILE;
  33. #define _FILE_DEFINED
  34. #endif
  35. #ifndef VOID
  36. #define VOID void
  37. typedef char CHAR;
  38. typedef short SHORT;
  39. typedef long LONG;
  40. #endif
  41. #define NOPENAPPS
  42. #define NOPENDICT
  43. #define NOPENRC1
  44. #define NOPENVIRTEVENT
  45. #define NOPENAPIFUN
  46. //int islower( int c );
  47. //int toupper( int c );
  48. #define toupper towupper
  49. //#define islower iswlower
  50. // HACK ALERT! HACK ALERT!
  51. // Problem - the WinCE compiler can't find these three symbols which are related
  52. // to floating point. We did the long term fix by changing the code to use
  53. // fixed point instead on WinCE, but if we go back to floating, we will have
  54. // to solve this problem (perhaps a later version of the WinCE Extensions for VC
  55. // will fix the problem, I saw it while using a beta. If you uncomment, add the
  56. // actual vars back in to cestubs.c
  57. //extern int __gts;
  58. //extern int __gtd;
  59. //extern int __ltd;
  60. #else // UNDER_CE not defined
  61. #ifdef UNICODE
  62. #define CETEXT(x) L##x
  63. #else
  64. #define CETEXT(x) x
  65. #endif
  66. #endif
  67. #endif _CESTUBS_H_