Subversion Repositories Kolibri OS

Rev

Rev 548 | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed

  1. ;*****************************************************************************
  2. ;*
  3. ;*                            Open Watcom Project
  4. ;*
  5. ;*    Portions Copyright (c) 1983-2002 Sybase, Inc. All Rights Reserved.
  6. ;*
  7. ;*  ========================================================================
  8. ;*
  9. ;*    This file contains Original Code and/or Modifications of Original
  10. ;*    Code as defined in and that are subject to the Sybase Open Watcom
  11. ;*    Public License version 1.0 (the 'License'). You may not use this file
  12. ;*    except in compliance with the License. BY USING THIS FILE YOU AGREE TO
  13. ;*    ALL TERMS AND CONDITIONS OF THE LICENSE. A copy of the License is
  14. ;*    provided with the Original Code and Modifications, and is also
  15. ;*    available at www.sybase.com/developer/opensource.
  16. ;*
  17. ;*    The Original Code and all software distributed under the License are
  18. ;*    distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  19. ;*    EXPRESS OR IMPLIED, AND SYBASE AND ALL CONTRIBUTORS HEREBY DISCLAIM
  20. ;*    ALL SUCH WARRANTIES, INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF
  21. ;*    MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR
  22. ;*    NON-INFRINGEMENT. Please see the License for the specific language
  23. ;*    governing rights and limitations under the License.
  24. ;*
  25. ;*  ========================================================================
  26. ;*
  27. ;* Description:  C runtime read/write data (386 version).
  28. ;*
  29. ;*****************************************************************************
  30.  
  31.  
  32.         name    crwdata
  33.  
  34. .387
  35. .386p
  36.  
  37.         assume  nothing
  38.  
  39. DGROUP group _DATA
  40.  
  41. _TEXT segment byte public 'CODE'
  42.         assume cs:_TEXT
  43. __null_FPE_rtn proc near
  44.         ret
  45. __null_FPE_rtn endp
  46. _TEXT ends
  47.  
  48. _DATA   segment dword public 'DATA'
  49.  
  50.         assume  DS:DGROUP
  51.        
  52.         extrn ___cmdline : near
  53.         extrn ___pgmname : near
  54.  
  55. _LpCmdLine   dd offset ___cmdline    ; pointer to raw command line
  56. _LpPgmName   dd offset ___pgmname    ; pointer to program name (for argv[0])
  57.  
  58.  
  59. ifndef __NETWARE__
  60. _dynend      dd 0               ; top of dynamic data area
  61. _curbrk      dd 0               ; top of usable memory
  62. endif
  63.  
  64. _STACKLOW    dd 0               ; lowest address in stack
  65. _STACKTOP    dd 0               ; highest address in stack
  66. __EFG_printf dd 0
  67. __EFG_scanf  dd 0
  68. __ASTACKSIZ  dd 0               ; alternate stack size
  69. __ASTACKPTR  dd 0               ; alternate stack pointer
  70.  
  71. ifndef __NETWARE__
  72. _cbyte     dd 0                 ; used by getch, getche
  73. _cbyte2    dd 0                 ; used by getch, getche
  74. _child     dd 0                 ; non-zero => a spawned process is running
  75. endif
  76.  
  77. __no87     dw 0                 ; non-zero => "NO87" environment var present
  78. ifndef __NETWARE__
  79. ifdef __DOS__
  80. _Extender         db 0          ; see clib\h\extender.inc for values
  81. _ExtenderSubtype  db 0          ; non-zero -> variant of extender
  82. __X32VM    db 0                 ; non-zero => X-32VM DOS Extender
  83. endif
  84. _Envptr    dd 0                 ; offset part of environment pointer
  85. _Envseg    dw 0                 ; segment containing environment strings
  86. ifndef __QNX__
  87. ifndef __LINUX__
  88. _osmajor   db 0                 ; major DOS version number
  89. _osminor   db 0                 ; minor DOS version number
  90. ifdef __NT__
  91. _osbuild   dw 0                 ; operating system build number
  92. _osver     dd 0                 ; operating system build number
  93. _winmajor  dd 0                 ; operating system major version number
  94. _winminor  dd 0                 ; operating system minor version number
  95. _winver    dd 0                 ; operating system version number
  96. endif
  97. endif
  98. endif
  99. endif
  100. __FPE_handler dd __null_FPE_rtn ; FPE handler
  101.  
  102.  
  103. ifndef __QNX__
  104. ifndef __LINUX__
  105. ifndef __NETWARE__
  106.         public  "C",_osmajor
  107.         public  "C",_osminor
  108. ifdef __NT__
  109.         public  "C",_osbuild
  110.         public  "C",_osver
  111.         public  "C",_winmajor
  112.         public  "C",_winminor
  113.         public  "C",_winver
  114.         public  "C",__EFG_printf
  115.         public  "C",__EFG_scanf
  116. endif
  117. endif
  118. ifdef __DOS__
  119.         public  "C",_psp
  120.         public  "C",_Extender
  121.         public  "C",_ExtenderSubtype
  122.         public  __X32VM
  123.         public  __x386_stacklow
  124. endif
  125. ifndef _NETWARE_LIBC
  126.         public  "C",_LpCmdLine
  127.         public  "C",_LpPgmName
  128. endif
  129. ifdef __NT__
  130.         public  "C",_LpCmdLine
  131.         public  "C",_LpPgmName
  132. endif
  133. ifdef __OS2__
  134.         public  "C",_LpDllName
  135.         public  "C",_LpwCmdLine
  136.         public  "C",_LpwPgmName
  137.         public  "C",_LpwDllName
  138. endif
  139. endif
  140. endif
  141. ifndef __NETWARE__
  142.         public  "C",_dynend
  143.         public  "C",_curbrk
  144. endif
  145.         public  "C",_STACKLOW
  146.         public  "C",_STACKTOP
  147.         public  __ASTACKSIZ
  148.         public  __ASTACKPTR
  149. ifndef __NETWARE__
  150.         public  "C",_cbyte
  151.         public  "C",_cbyte2
  152.         public  "C",_child
  153.         public  "C",_Envptr
  154.         public  "C",_Envseg
  155. endif
  156.         public  __no87
  157.         public  "C",__FPE_handler
  158.  
  159. _DATA   ends
  160.  
  161.         end
  162.