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.

68 lines
1.5 KiB

  1. /***
  2. *crt0init.c - Initialization segment declarations.
  3. *
  4. * Copyright (c) 1992-1994, Microsoft Corporation. All rights reserved.
  5. *
  6. *Purpose:
  7. * Do initialization segment declarations.
  8. *
  9. *Notes:
  10. * In the 16-bit C world, the X*B and X*E segments were empty except for
  11. * a label. This will not work with COFF since COFF throws out empty
  12. * sections. Therefore we must put a zero value in them. (Zero because
  13. * the routine to traverse the initializers will skip over zero entries.)
  14. *
  15. *Revision History:
  16. * 03-19-92 SKS Module created.
  17. * 03-24-92 SKS Added MIPS support (NO_UNDERSCORE)
  18. * 08-06-92 SKS Revised to use new section names and macros
  19. * 10-19-93 SKS Add .DiRECTiVE section for MIPS, too!
  20. * 10-28-93 GJF Rewritten in C
  21. * 10-28-94 SKS Add user32.lib as a default library
  22. * 02-27-95 CFW Remove user32.lib as a default library
  23. *
  24. *******************************************************************************/
  25. #ifdef _MSC_VER
  26. #include <stdio.h>
  27. #include <internal.h>
  28. #pragma data_seg(".CRT$XIA")
  29. _PVFV __xi_a[] = { NULL };
  30. #pragma data_seg(".CRT$XIZ")
  31. _PVFV __xi_z[] = { NULL };
  32. #pragma data_seg(".CRT$XCA")
  33. _PVFV __xc_a[] = { NULL };
  34. #pragma data_seg(".CRT$XCZ")
  35. _PVFV __xc_z[] = { NULL };
  36. #pragma data_seg(".CRT$XPA")
  37. _PVFV __xp_a[] = { NULL };
  38. #pragma data_seg(".CRT$XPZ")
  39. _PVFV __xp_z[] = { NULL };
  40. #pragma data_seg(".CRT$XTA")
  41. _PVFV __xt_a[] = { NULL };
  42. #pragma data_seg(".CRT$XTZ")
  43. _PVFV __xt_z[] = { NULL };
  44. #pragma data_seg() /* reset */
  45. #pragma comment(linker, "-merge:.CRT=.data")
  46. #endif /* _MSC_VER */