tcc 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (283) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +35 -0
  3. data/README.md +196 -0
  4. data/ext/tcc/extconf.rb +25 -0
  5. data/ext/tcc/tcc-0.9.26.patch +30 -0
  6. data/ext/tcc/tcc-0.9.26/COPYING +504 -0
  7. data/ext/tcc/tcc-0.9.26/Changelog +396 -0
  8. data/ext/tcc/tcc-0.9.26/Makefile +349 -0
  9. data/ext/tcc/tcc-0.9.26/README +101 -0
  10. data/ext/tcc/tcc-0.9.26/TODO +93 -0
  11. data/ext/tcc/tcc-0.9.26/VERSION +1 -0
  12. data/ext/tcc/tcc-0.9.26/arm-gen.c +2005 -0
  13. data/ext/tcc/tcc-0.9.26/c67-gen.c +2560 -0
  14. data/ext/tcc/tcc-0.9.26/coff.h +446 -0
  15. data/ext/tcc/tcc-0.9.26/config.h +8 -0
  16. data/ext/tcc/tcc-0.9.26/config.mak +28 -0
  17. data/ext/tcc/tcc-0.9.26/config.texi +1 -0
  18. data/ext/tcc/tcc-0.9.26/configure +540 -0
  19. data/ext/tcc/tcc-0.9.26/conftest.c +71 -0
  20. data/ext/tcc/tcc-0.9.26/elf.h +1731 -0
  21. data/ext/tcc/tcc-0.9.26/examples/ex1.c +8 -0
  22. data/ext/tcc/tcc-0.9.26/examples/ex2.c +98 -0
  23. data/ext/tcc/tcc-0.9.26/examples/ex3.c +24 -0
  24. data/ext/tcc/tcc-0.9.26/examples/ex4.c +26 -0
  25. data/ext/tcc/tcc-0.9.26/examples/ex5.c +8 -0
  26. data/ext/tcc/tcc-0.9.26/i386-asm.c +1498 -0
  27. data/ext/tcc/tcc-0.9.26/i386-asm.h +473 -0
  28. data/ext/tcc/tcc-0.9.26/i386-gen.c +1096 -0
  29. data/ext/tcc/tcc-0.9.26/i386-tok.h +243 -0
  30. data/ext/tcc/tcc-0.9.26/il-gen.c +667 -0
  31. data/ext/tcc/tcc-0.9.26/il-opcodes.h +251 -0
  32. data/ext/tcc/tcc-0.9.26/include/float.h +57 -0
  33. data/ext/tcc/tcc-0.9.26/include/stdarg.h +41 -0
  34. data/ext/tcc/tcc-0.9.26/include/stdbool.h +10 -0
  35. data/ext/tcc/tcc-0.9.26/include/stddef.h +28 -0
  36. data/ext/tcc/tcc-0.9.26/include/tcclib.h +78 -0
  37. data/ext/tcc/tcc-0.9.26/include/varargs.h +12 -0
  38. data/ext/tcc/tcc-0.9.26/lib/Makefile +102 -0
  39. data/ext/tcc/tcc-0.9.26/lib/alloca86-bt.S +47 -0
  40. data/ext/tcc/tcc-0.9.26/lib/alloca86.S +35 -0
  41. data/ext/tcc/tcc-0.9.26/lib/alloca86_64.S +42 -0
  42. data/ext/tcc/tcc-0.9.26/lib/bcheck.c +875 -0
  43. data/ext/tcc/tcc-0.9.26/lib/libtcc1.c +691 -0
  44. data/ext/tcc/tcc-0.9.26/libtcc.c +1941 -0
  45. data/ext/tcc/tcc-0.9.26/libtcc.h +103 -0
  46. data/ext/tcc/tcc-0.9.26/stab.def +234 -0
  47. data/ext/tcc/tcc-0.9.26/stab.h +17 -0
  48. data/ext/tcc/tcc-0.9.26/tcc-doc.html +2332 -0
  49. data/ext/tcc/tcc-0.9.26/tcc-doc.info +1151 -0
  50. data/ext/tcc/tcc-0.9.26/tcc-doc.texi +1268 -0
  51. data/ext/tcc/tcc-0.9.26/tcc.1 +415 -0
  52. data/ext/tcc/tcc-0.9.26/tcc.c +352 -0
  53. data/ext/tcc/tcc-0.9.26/tcc.h +1379 -0
  54. data/ext/tcc/tcc-0.9.26/tccasm.c +1118 -0
  55. data/ext/tcc/tcc-0.9.26/tcccoff.c +948 -0
  56. data/ext/tcc/tcc-0.9.26/tccelf.c +3129 -0
  57. data/ext/tcc/tcc-0.9.26/tccgen.c +5841 -0
  58. data/ext/tcc/tcc-0.9.26/tccpe.c +1887 -0
  59. data/ext/tcc/tcc-0.9.26/tccpp.c +3128 -0
  60. data/ext/tcc/tcc-0.9.26/tccrun.c +737 -0
  61. data/ext/tcc/tcc-0.9.26/tcctok.h +278 -0
  62. data/ext/tcc/tcc-0.9.26/tests/Makefile +199 -0
  63. data/ext/tcc/tcc-0.9.26/tests/asmtest.S +609 -0
  64. data/ext/tcc/tcc-0.9.26/tests/boundtest.c +233 -0
  65. data/ext/tcc/tcc-0.9.26/tests/gcctestsuite.sh +33 -0
  66. data/ext/tcc/tcc-0.9.26/tests/libtcc_test.c +76 -0
  67. data/ext/tcc/tcc-0.9.26/tests/tcctest.c +2713 -0
  68. data/ext/tcc/tcc-0.9.26/tests/tests2/00_assignment.c +18 -0
  69. data/ext/tcc/tcc-0.9.26/tests/tests2/00_assignment.expect +3 -0
  70. data/ext/tcc/tcc-0.9.26/tests/tests2/01_comment.c +14 -0
  71. data/ext/tcc/tcc-0.9.26/tests/tests2/01_comment.expect +5 -0
  72. data/ext/tcc/tcc-0.9.26/tests/tests2/02_printf.c +18 -0
  73. data/ext/tcc/tcc-0.9.26/tests/tests2/02_printf.expect +15 -0
  74. data/ext/tcc/tcc-0.9.26/tests/tests2/03_struct.c +31 -0
  75. data/ext/tcc/tcc-0.9.26/tests/tests2/03_struct.expect +6 -0
  76. data/ext/tcc/tcc-0.9.26/tests/tests2/04_for.c +15 -0
  77. data/ext/tcc/tcc-0.9.26/tests/tests2/04_for.expect +10 -0
  78. data/ext/tcc/tcc-0.9.26/tests/tests2/05_array.c +21 -0
  79. data/ext/tcc/tcc-0.9.26/tests/tests2/05_array.expect +10 -0
  80. data/ext/tcc/tcc-0.9.26/tests/tests2/06_case.c +29 -0
  81. data/ext/tcc/tcc-0.9.26/tests/tests2/06_case.expect +8 -0
  82. data/ext/tcc/tcc-0.9.26/tests/tests2/07_function.c +30 -0
  83. data/ext/tcc/tcc-0.9.26/tests/tests2/07_function.expect +4 -0
  84. data/ext/tcc/tcc-0.9.26/tests/tests2/08_while.c +24 -0
  85. data/ext/tcc/tcc-0.9.26/tests/tests2/08_while.expect +11 -0
  86. data/ext/tcc/tcc-0.9.26/tests/tests2/09_do_while.c +24 -0
  87. data/ext/tcc/tcc-0.9.26/tests/tests2/09_do_while.expect +11 -0
  88. data/ext/tcc/tcc-0.9.26/tests/tests2/10_pointer.c +40 -0
  89. data/ext/tcc/tcc-0.9.26/tests/tests2/10_pointer.expect +8 -0
  90. data/ext/tcc/tcc-0.9.26/tests/tests2/11_precedence.c +40 -0
  91. data/ext/tcc/tcc-0.9.26/tests/tests2/11_precedence.expect +15 -0
  92. data/ext/tcc/tcc-0.9.26/tests/tests2/12_hashdefine.c +14 -0
  93. data/ext/tcc/tcc-0.9.26/tests/tests2/12_hashdefine.expect +2 -0
  94. data/ext/tcc/tcc-0.9.26/tests/tests2/13_integer_literals.c +20 -0
  95. data/ext/tcc/tcc-0.9.26/tests/tests2/13_integer_literals.expect +5 -0
  96. data/ext/tcc/tcc-0.9.26/tests/tests2/14_if.c +21 -0
  97. data/ext/tcc/tcc-0.9.26/tests/tests2/14_if.expect +2 -0
  98. data/ext/tcc/tcc-0.9.26/tests/tests2/15_recursion.c +21 -0
  99. data/ext/tcc/tcc-0.9.26/tests/tests2/15_recursion.expect +10 -0
  100. data/ext/tcc/tcc-0.9.26/tests/tests2/16_nesting.c +21 -0
  101. data/ext/tcc/tcc-0.9.26/tests/tests2/16_nesting.expect +18 -0
  102. data/ext/tcc/tcc-0.9.26/tests/tests2/17_enum.c +29 -0
  103. data/ext/tcc/tcc-0.9.26/tests/tests2/17_enum.expect +3 -0
  104. data/ext/tcc/tcc-0.9.26/tests/tests2/18_include.c +12 -0
  105. data/ext/tcc/tcc-0.9.26/tests/tests2/18_include.expect +3 -0
  106. data/ext/tcc/tcc-0.9.26/tests/tests2/18_include.h +1 -0
  107. data/ext/tcc/tcc-0.9.26/tests/tests2/19_pointer_arithmetic.c +28 -0
  108. data/ext/tcc/tcc-0.9.26/tests/tests2/19_pointer_arithmetic.expect +3 -0
  109. data/ext/tcc/tcc-0.9.26/tests/tests2/20_pointer_comparison.c +24 -0
  110. data/ext/tcc/tcc-0.9.26/tests/tests2/20_pointer_comparison.expect +6 -0
  111. data/ext/tcc/tcc-0.9.26/tests/tests2/21_char_array.c +33 -0
  112. data/ext/tcc/tcc-0.9.26/tests/tests2/21_char_array.expect +7 -0
  113. data/ext/tcc/tcc-0.9.26/tests/tests2/22_floating_point.c +50 -0
  114. data/ext/tcc/tcc-0.9.26/tests/tests2/22_floating_point.expect +16 -0
  115. data/ext/tcc/tcc-0.9.26/tests/tests2/23_type_coercion.c +54 -0
  116. data/ext/tcc/tcc-0.9.26/tests/tests2/23_type_coercion.expect +12 -0
  117. data/ext/tcc/tcc-0.9.26/tests/tests2/24_math_library.c +28 -0
  118. data/ext/tcc/tcc-0.9.26/tests/tests2/24_math_library.expect +18 -0
  119. data/ext/tcc/tcc-0.9.26/tests/tests2/25_quicksort.c +83 -0
  120. data/ext/tcc/tcc-0.9.26/tests/tests2/25_quicksort.expect +2 -0
  121. data/ext/tcc/tcc-0.9.26/tests/tests2/26_character_constants.c +17 -0
  122. data/ext/tcc/tcc-0.9.26/tests/tests2/26_character_constants.expect +8 -0
  123. data/ext/tcc/tcc-0.9.26/tests/tests2/27_sizeof.c +16 -0
  124. data/ext/tcc/tcc-0.9.26/tests/tests2/27_sizeof.expect +3 -0
  125. data/ext/tcc/tcc-0.9.26/tests/tests2/28_strings.c +46 -0
  126. data/ext/tcc/tcc-0.9.26/tests/tests2/28_strings.expect +19 -0
  127. data/ext/tcc/tcc-0.9.26/tests/tests2/29_array_address.c +13 -0
  128. data/ext/tcc/tcc-0.9.26/tests/tests2/29_array_address.expect +1 -0
  129. data/ext/tcc/tcc-0.9.26/tests/tests2/30_hanoi.c +122 -0
  130. data/ext/tcc/tcc-0.9.26/tests/tests2/30_hanoi.expect +71 -0
  131. data/ext/tcc/tcc-0.9.26/tests/tests2/31_args.c +14 -0
  132. data/ext/tcc/tcc-0.9.26/tests/tests2/31_args.expect +7 -0
  133. data/ext/tcc/tcc-0.9.26/tests/tests2/32_led.c +266 -0
  134. data/ext/tcc/tcc-0.9.26/tests/tests2/32_led.expect +4 -0
  135. data/ext/tcc/tcc-0.9.26/tests/tests2/33_ternary_op.c +15 -0
  136. data/ext/tcc/tcc-0.9.26/tests/tests2/33_ternary_op.expect +10 -0
  137. data/ext/tcc/tcc-0.9.26/tests/tests2/34_array_assignment.c +23 -0
  138. data/ext/tcc/tcc-0.9.26/tests/tests2/34_array_assignment.expect +2 -0
  139. data/ext/tcc/tcc-0.9.26/tests/tests2/35_sizeof.c +14 -0
  140. data/ext/tcc/tcc-0.9.26/tests/tests2/35_sizeof.expect +2 -0
  141. data/ext/tcc/tcc-0.9.26/tests/tests2/36_array_initialisers.c +21 -0
  142. data/ext/tcc/tcc-0.9.26/tests/tests2/36_array_initialisers.expect +20 -0
  143. data/ext/tcc/tcc-0.9.26/tests/tests2/37_sprintf.c +17 -0
  144. data/ext/tcc/tcc-0.9.26/tests/tests2/37_sprintf.expect +20 -0
  145. data/ext/tcc/tcc-0.9.26/tests/tests2/38_multiple_array_index.c +32 -0
  146. data/ext/tcc/tcc-0.9.26/tests/tests2/38_multiple_array_index.expect +4 -0
  147. data/ext/tcc/tcc-0.9.26/tests/tests2/39_typedef.c +31 -0
  148. data/ext/tcc/tcc-0.9.26/tests/tests2/39_typedef.expect +3 -0
  149. data/ext/tcc/tcc-0.9.26/tests/tests2/40_stdio.c +52 -0
  150. data/ext/tcc/tcc-0.9.26/tests/tests2/40_stdio.expect +27 -0
  151. data/ext/tcc/tcc-0.9.26/tests/tests2/41_hashif.c +85 -0
  152. data/ext/tcc/tcc-0.9.26/tests/tests2/41_hashif.expect +6 -0
  153. data/ext/tcc/tcc-0.9.26/tests/tests2/42_function_pointer.c +18 -0
  154. data/ext/tcc/tcc-0.9.26/tests/tests2/42_function_pointer.expect +2 -0
  155. data/ext/tcc/tcc-0.9.26/tests/tests2/43_void_param.c +15 -0
  156. data/ext/tcc/tcc-0.9.26/tests/tests2/43_void_param.expect +1 -0
  157. data/ext/tcc/tcc-0.9.26/tests/tests2/44_scoped_declarations.c +17 -0
  158. data/ext/tcc/tcc-0.9.26/tests/tests2/44_scoped_declarations.expect +1 -0
  159. data/ext/tcc/tcc-0.9.26/tests/tests2/45_empty_for.c +18 -0
  160. data/ext/tcc/tcc-0.9.26/tests/tests2/45_empty_for.expect +10 -0
  161. data/ext/tcc/tcc-0.9.26/tests/tests2/46_grep.c +564 -0
  162. data/ext/tcc/tcc-0.9.26/tests/tests2/47_switch_return.c +24 -0
  163. data/ext/tcc/tcc-0.9.26/tests/tests2/47_switch_return.expect +4 -0
  164. data/ext/tcc/tcc-0.9.26/tests/tests2/48_nested_break.c +26 -0
  165. data/ext/tcc/tcc-0.9.26/tests/tests2/48_nested_break.expect +1 -0
  166. data/ext/tcc/tcc-0.9.26/tests/tests2/49_bracket_evaluation.c +23 -0
  167. data/ext/tcc/tcc-0.9.26/tests/tests2/49_bracket_evaluation.expect +1 -0
  168. data/ext/tcc/tcc-0.9.26/tests/tests2/50_logical_second_arg.c +29 -0
  169. data/ext/tcc/tcc-0.9.26/tests/tests2/50_logical_second_arg.expect +20 -0
  170. data/ext/tcc/tcc-0.9.26/tests/tests2/51_static.c +30 -0
  171. data/ext/tcc/tcc-0.9.26/tests/tests2/51_static.expect +8 -0
  172. data/ext/tcc/tcc-0.9.26/tests/tests2/52_unnamed_enum.c +27 -0
  173. data/ext/tcc/tcc-0.9.26/tests/tests2/52_unnamed_enum.expect +9 -0
  174. data/ext/tcc/tcc-0.9.26/tests/tests2/54_goto.c +56 -0
  175. data/ext/tcc/tcc-0.9.26/tests/tests2/54_goto.expect +8 -0
  176. data/ext/tcc/tcc-0.9.26/tests/tests2/55_lshift_type.c +52 -0
  177. data/ext/tcc/tcc-0.9.26/tests/tests2/55_lshift_type.expect +1 -0
  178. data/ext/tcc/tcc-0.9.26/tests/tests2/LICENSE +37 -0
  179. data/ext/tcc/tcc-0.9.26/tests/tests2/Makefile +98 -0
  180. data/ext/tcc/tcc-0.9.26/texi2pod.pl +427 -0
  181. data/ext/tcc/tcc-0.9.26/win32/build-tcc.bat +60 -0
  182. data/ext/tcc/tcc-0.9.26/win32/examples/dll.c +12 -0
  183. data/ext/tcc/tcc-0.9.26/win32/examples/fib.c +23 -0
  184. data/ext/tcc/tcc-0.9.26/win32/examples/hello_dll.c +19 -0
  185. data/ext/tcc/tcc-0.9.26/win32/examples/hello_win.c +163 -0
  186. data/ext/tcc/tcc-0.9.26/win32/include/_mingw.h +139 -0
  187. data/ext/tcc/tcc-0.9.26/win32/include/assert.h +54 -0
  188. data/ext/tcc/tcc-0.9.26/win32/include/conio.h +409 -0
  189. data/ext/tcc/tcc-0.9.26/win32/include/ctype.h +281 -0
  190. data/ext/tcc/tcc-0.9.26/win32/include/dir.h +31 -0
  191. data/ext/tcc/tcc-0.9.26/win32/include/direct.h +68 -0
  192. data/ext/tcc/tcc-0.9.26/win32/include/dirent.h +135 -0
  193. data/ext/tcc/tcc-0.9.26/win32/include/dos.h +55 -0
  194. data/ext/tcc/tcc-0.9.26/win32/include/errno.h +75 -0
  195. data/ext/tcc/tcc-0.9.26/win32/include/excpt.h +123 -0
  196. data/ext/tcc/tcc-0.9.26/win32/include/fcntl.h +52 -0
  197. data/ext/tcc/tcc-0.9.26/win32/include/fenv.h +108 -0
  198. data/ext/tcc/tcc-0.9.26/win32/include/inttypes.h +297 -0
  199. data/ext/tcc/tcc-0.9.26/win32/include/io.h +418 -0
  200. data/ext/tcc/tcc-0.9.26/win32/include/limits.h +111 -0
  201. data/ext/tcc/tcc-0.9.26/win32/include/locale.h +91 -0
  202. data/ext/tcc/tcc-0.9.26/win32/include/malloc.h +175 -0
  203. data/ext/tcc/tcc-0.9.26/win32/include/math.h +777 -0
  204. data/ext/tcc/tcc-0.9.26/win32/include/mem.h +13 -0
  205. data/ext/tcc/tcc-0.9.26/win32/include/memory.h +40 -0
  206. data/ext/tcc/tcc-0.9.26/win32/include/process.h +176 -0
  207. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/conio_s.h +42 -0
  208. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/crtdbg_s.h +19 -0
  209. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/io_s.h +33 -0
  210. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/mbstring_s.h +52 -0
  211. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/search_s.h +25 -0
  212. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/stdio_s.h +145 -0
  213. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/stdlib_s.h +67 -0
  214. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/stralign_s.h +30 -0
  215. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/string_s.h +41 -0
  216. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/sys/timeb_s.h +34 -0
  217. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/tchar_s.h +266 -0
  218. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/time_s.h +61 -0
  219. data/ext/tcc/tcc-0.9.26/win32/include/sec_api/wchar_s.h +128 -0
  220. data/ext/tcc/tcc-0.9.26/win32/include/setjmp.h +160 -0
  221. data/ext/tcc/tcc-0.9.26/win32/include/share.h +28 -0
  222. data/ext/tcc/tcc-0.9.26/win32/include/signal.h +63 -0
  223. data/ext/tcc/tcc-0.9.26/win32/include/stdint.h +209 -0
  224. data/ext/tcc/tcc-0.9.26/win32/include/stdio.h +429 -0
  225. data/ext/tcc/tcc-0.9.26/win32/include/stdlib.h +580 -0
  226. data/ext/tcc/tcc-0.9.26/win32/include/string.h +164 -0
  227. data/ext/tcc/tcc-0.9.26/win32/include/sys/fcntl.h +13 -0
  228. data/ext/tcc/tcc-0.9.26/win32/include/sys/file.h +14 -0
  229. data/ext/tcc/tcc-0.9.26/win32/include/sys/locking.h +30 -0
  230. data/ext/tcc/tcc-0.9.26/win32/include/sys/stat.h +290 -0
  231. data/ext/tcc/tcc-0.9.26/win32/include/sys/time.h +69 -0
  232. data/ext/tcc/tcc-0.9.26/win32/include/sys/timeb.h +133 -0
  233. data/ext/tcc/tcc-0.9.26/win32/include/sys/types.h +118 -0
  234. data/ext/tcc/tcc-0.9.26/win32/include/sys/unistd.h +14 -0
  235. data/ext/tcc/tcc-0.9.26/win32/include/sys/utime.h +146 -0
  236. data/ext/tcc/tcc-0.9.26/win32/include/tchar.h +1102 -0
  237. data/ext/tcc/tcc-0.9.26/win32/include/time.h +287 -0
  238. data/ext/tcc/tcc-0.9.26/win32/include/vadefs.h +11 -0
  239. data/ext/tcc/tcc-0.9.26/win32/include/values.h +4 -0
  240. data/ext/tcc/tcc-0.9.26/win32/include/wchar.h +871 -0
  241. data/ext/tcc/tcc-0.9.26/win32/include/wctype.h +172 -0
  242. data/ext/tcc/tcc-0.9.26/win32/include/winapi/basetsd.h +149 -0
  243. data/ext/tcc/tcc-0.9.26/win32/include/winapi/basetyps.h +85 -0
  244. data/ext/tcc/tcc-0.9.26/win32/include/winapi/guiddef.h +151 -0
  245. data/ext/tcc/tcc-0.9.26/win32/include/winapi/intrin.h +11 -0
  246. data/ext/tcc/tcc-0.9.26/win32/include/winapi/poppack.h +8 -0
  247. data/ext/tcc/tcc-0.9.26/win32/include/winapi/pshpack1.h +8 -0
  248. data/ext/tcc/tcc-0.9.26/win32/include/winapi/pshpack2.h +8 -0
  249. data/ext/tcc/tcc-0.9.26/win32/include/winapi/pshpack4.h +8 -0
  250. data/ext/tcc/tcc-0.9.26/win32/include/winapi/pshpack8.h +8 -0
  251. data/ext/tcc/tcc-0.9.26/win32/include/winapi/reason.h +80 -0
  252. data/ext/tcc/tcc-0.9.26/win32/include/winapi/specstrings.h +7 -0
  253. data/ext/tcc/tcc-0.9.26/win32/include/winapi/stralign.h +154 -0
  254. data/ext/tcc/tcc-0.9.26/win32/include/winapi/tvout.h +79 -0
  255. data/ext/tcc/tcc-0.9.26/win32/include/winapi/winbase.h +2951 -0
  256. data/ext/tcc/tcc-0.9.26/win32/include/winapi/wincon.h +301 -0
  257. data/ext/tcc/tcc-0.9.26/win32/include/winapi/windef.h +293 -0
  258. data/ext/tcc/tcc-0.9.26/win32/include/winapi/windows.h +123 -0
  259. data/ext/tcc/tcc-0.9.26/win32/include/winapi/winerror.h +3166 -0
  260. data/ext/tcc/tcc-0.9.26/win32/include/winapi/wingdi.h +4080 -0
  261. data/ext/tcc/tcc-0.9.26/win32/include/winapi/winnetwk.h +476 -0
  262. data/ext/tcc/tcc-0.9.26/win32/include/winapi/winnls.h +765 -0
  263. data/ext/tcc/tcc-0.9.26/win32/include/winapi/winnt.h +5770 -0
  264. data/ext/tcc/tcc-0.9.26/win32/include/winapi/winreg.h +272 -0
  265. data/ext/tcc/tcc-0.9.26/win32/include/winapi/winuser.h +5651 -0
  266. data/ext/tcc/tcc-0.9.26/win32/include/winapi/winver.h +160 -0
  267. data/ext/tcc/tcc-0.9.26/win32/lib/chkstk.S +191 -0
  268. data/ext/tcc/tcc-0.9.26/win32/lib/crt1.c +34 -0
  269. data/ext/tcc/tcc-0.9.26/win32/lib/dllcrt1.c +13 -0
  270. data/ext/tcc/tcc-0.9.26/win32/lib/dllmain.c +9 -0
  271. data/ext/tcc/tcc-0.9.26/win32/lib/gdi32.def +337 -0
  272. data/ext/tcc/tcc-0.9.26/win32/lib/kernel32.def +765 -0
  273. data/ext/tcc/tcc-0.9.26/win32/lib/msvcrt.def +1399 -0
  274. data/ext/tcc/tcc-0.9.26/win32/lib/user32.def +654 -0
  275. data/ext/tcc/tcc-0.9.26/win32/lib/wincrt1.c +64 -0
  276. data/ext/tcc/tcc-0.9.26/win32/tcc-win32.txt +156 -0
  277. data/ext/tcc/tcc-0.9.26/win32/tools/tiny_impdef.c +243 -0
  278. data/ext/tcc/tcc-0.9.26/win32/tools/tiny_libmaker.c +258 -0
  279. data/ext/tcc/tcc-0.9.26/x86_64-asm.h +448 -0
  280. data/ext/tcc/tcc-0.9.26/x86_64-gen.c +1701 -0
  281. data/lib/tcc.rb +291 -0
  282. data/tcc.gemspec +15 -0
  283. metadata +343 -0
@@ -0,0 +1,301 @@
1
+ /**
2
+ * This file has no copyright assigned and is placed in the Public Domain.
3
+ * This file is part of the w64 mingw-runtime package.
4
+ * No warranty is given; refer to the file DISCLAIMER within this package.
5
+ */
6
+ #ifndef _WINCON_
7
+ #define _WINCON_
8
+
9
+ #ifdef __cplusplus
10
+ extern "C" {
11
+ #endif
12
+
13
+ typedef struct _COORD {
14
+ SHORT X;
15
+ SHORT Y;
16
+ } COORD,*PCOORD;
17
+
18
+ typedef struct _SMALL_RECT {
19
+ SHORT Left;
20
+ SHORT Top;
21
+ SHORT Right;
22
+ SHORT Bottom;
23
+ } SMALL_RECT,*PSMALL_RECT;
24
+
25
+ typedef struct _KEY_EVENT_RECORD {
26
+ WINBOOL bKeyDown;
27
+ WORD wRepeatCount;
28
+ WORD wVirtualKeyCode;
29
+ WORD wVirtualScanCode;
30
+ union {
31
+ WCHAR UnicodeChar;
32
+ CHAR AsciiChar;
33
+ } uChar;
34
+ DWORD dwControlKeyState;
35
+ } KEY_EVENT_RECORD,*PKEY_EVENT_RECORD;
36
+
37
+ #define RIGHT_ALT_PRESSED 0x1
38
+ #define LEFT_ALT_PRESSED 0x2
39
+ #define RIGHT_CTRL_PRESSED 0x4
40
+ #define LEFT_CTRL_PRESSED 0x8
41
+ #define SHIFT_PRESSED 0x10
42
+ #define NUMLOCK_ON 0x20
43
+ #define SCROLLLOCK_ON 0x40
44
+ #define CAPSLOCK_ON 0x80
45
+ #define ENHANCED_KEY 0x100
46
+ #define NLS_DBCSCHAR 0x10000
47
+ #define NLS_ALPHANUMERIC 0x0
48
+ #define NLS_KATAKANA 0x20000
49
+ #define NLS_HIRAGANA 0x40000
50
+ #define NLS_ROMAN 0x400000
51
+ #define NLS_IME_CONVERSION 0x800000
52
+ #define NLS_IME_DISABLE 0x20000000
53
+
54
+ typedef struct _MOUSE_EVENT_RECORD {
55
+ COORD dwMousePosition;
56
+ DWORD dwButtonState;
57
+ DWORD dwControlKeyState;
58
+ DWORD dwEventFlags;
59
+ } MOUSE_EVENT_RECORD,*PMOUSE_EVENT_RECORD;
60
+
61
+ #define FROM_LEFT_1ST_BUTTON_PRESSED 0x1
62
+ #define RIGHTMOST_BUTTON_PRESSED 0x2
63
+ #define FROM_LEFT_2ND_BUTTON_PRESSED 0x4
64
+ #define FROM_LEFT_3RD_BUTTON_PRESSED 0x8
65
+ #define FROM_LEFT_4TH_BUTTON_PRESSED 0x10
66
+
67
+ #define MOUSE_MOVED 0x1
68
+ #define DOUBLE_CLICK 0x2
69
+ #define MOUSE_WHEELED 0x4
70
+
71
+ typedef struct _WINDOW_BUFFER_SIZE_RECORD {
72
+ COORD dwSize;
73
+ } WINDOW_BUFFER_SIZE_RECORD,*PWINDOW_BUFFER_SIZE_RECORD;
74
+
75
+ typedef struct _MENU_EVENT_RECORD {
76
+ UINT dwCommandId;
77
+ } MENU_EVENT_RECORD,*PMENU_EVENT_RECORD;
78
+
79
+ typedef struct _FOCUS_EVENT_RECORD {
80
+ WINBOOL bSetFocus;
81
+ } FOCUS_EVENT_RECORD,*PFOCUS_EVENT_RECORD;
82
+
83
+ typedef struct _INPUT_RECORD {
84
+ WORD EventType;
85
+ union {
86
+ KEY_EVENT_RECORD KeyEvent;
87
+ MOUSE_EVENT_RECORD MouseEvent;
88
+ WINDOW_BUFFER_SIZE_RECORD WindowBufferSizeEvent;
89
+ MENU_EVENT_RECORD MenuEvent;
90
+ FOCUS_EVENT_RECORD FocusEvent;
91
+ } Event;
92
+ } INPUT_RECORD,*PINPUT_RECORD;
93
+
94
+ #define KEY_EVENT 0x1
95
+ #define MOUSE_EVENT 0x2
96
+ #define WINDOW_BUFFER_SIZE_EVENT 0x4
97
+ #define MENU_EVENT 0x8
98
+ #define FOCUS_EVENT 0x10
99
+
100
+ typedef struct _CHAR_INFO {
101
+ union {
102
+ WCHAR UnicodeChar;
103
+ CHAR AsciiChar;
104
+ } Char;
105
+ WORD Attributes;
106
+ } CHAR_INFO,*PCHAR_INFO;
107
+
108
+ #define FOREGROUND_BLUE 0x1
109
+ #define FOREGROUND_GREEN 0x2
110
+ #define FOREGROUND_RED 0x4
111
+ #define FOREGROUND_INTENSITY 0x8
112
+ #define BACKGROUND_BLUE 0x10
113
+ #define BACKGROUND_GREEN 0x20
114
+ #define BACKGROUND_RED 0x40
115
+ #define BACKGROUND_INTENSITY 0x80
116
+ #define COMMON_LVB_LEADING_BYTE 0x100
117
+ #define COMMON_LVB_TRAILING_BYTE 0x200
118
+ #define COMMON_LVB_GRID_HORIZONTAL 0x400
119
+ #define COMMON_LVB_GRID_LVERTICAL 0x800
120
+ #define COMMON_LVB_GRID_RVERTICAL 0x1000
121
+ #define COMMON_LVB_REVERSE_VIDEO 0x4000
122
+ #define COMMON_LVB_UNDERSCORE 0x8000
123
+
124
+ #define COMMON_LVB_SBCSDBCS 0x300
125
+
126
+ typedef struct _CONSOLE_SCREEN_BUFFER_INFO {
127
+ COORD dwSize;
128
+ COORD dwCursorPosition;
129
+ WORD wAttributes;
130
+ SMALL_RECT srWindow;
131
+ COORD dwMaximumWindowSize;
132
+ } CONSOLE_SCREEN_BUFFER_INFO,*PCONSOLE_SCREEN_BUFFER_INFO;
133
+
134
+ typedef struct _CONSOLE_CURSOR_INFO {
135
+ DWORD dwSize;
136
+ WINBOOL bVisible;
137
+ } CONSOLE_CURSOR_INFO,*PCONSOLE_CURSOR_INFO;
138
+
139
+ typedef struct _CONSOLE_FONT_INFO {
140
+ DWORD nFont;
141
+ COORD dwFontSize;
142
+ } CONSOLE_FONT_INFO,*PCONSOLE_FONT_INFO;
143
+
144
+ typedef struct _CONSOLE_SELECTION_INFO {
145
+ DWORD dwFlags;
146
+ COORD dwSelectionAnchor;
147
+ SMALL_RECT srSelection;
148
+ } CONSOLE_SELECTION_INFO,*PCONSOLE_SELECTION_INFO;
149
+
150
+ #define CONSOLE_NO_SELECTION 0x0
151
+ #define CONSOLE_SELECTION_IN_PROGRESS 0x1
152
+ #define CONSOLE_SELECTION_NOT_EMPTY 0x2
153
+ #define CONSOLE_MOUSE_SELECTION 0x4
154
+ #define CONSOLE_MOUSE_DOWN 0x8
155
+
156
+ typedef WINBOOL (WINAPI *PHANDLER_ROUTINE)(DWORD CtrlType);
157
+
158
+ #define CTRL_C_EVENT 0
159
+ #define CTRL_BREAK_EVENT 1
160
+ #define CTRL_CLOSE_EVENT 2
161
+
162
+ #define CTRL_LOGOFF_EVENT 5
163
+ #define CTRL_SHUTDOWN_EVENT 6
164
+
165
+ #define ENABLE_PROCESSED_INPUT 0x1
166
+ #define ENABLE_LINE_INPUT 0x2
167
+ #define ENABLE_ECHO_INPUT 0x4
168
+ #define ENABLE_WINDOW_INPUT 0x8
169
+ #define ENABLE_MOUSE_INPUT 0x10
170
+
171
+ #define ENABLE_PROCESSED_OUTPUT 0x1
172
+ #define ENABLE_WRAP_AT_EOL_OUTPUT 0x2
173
+
174
+ #ifdef UNICODE
175
+ #define PeekConsoleInput PeekConsoleInputW
176
+ #define ReadConsoleInput ReadConsoleInputW
177
+ #define WriteConsoleInput WriteConsoleInputW
178
+ #define ReadConsoleOutput ReadConsoleOutputW
179
+ #define WriteConsoleOutput WriteConsoleOutputW
180
+ #define ReadConsoleOutputCharacter ReadConsoleOutputCharacterW
181
+ #define WriteConsoleOutputCharacter WriteConsoleOutputCharacterW
182
+ #define FillConsoleOutputCharacter FillConsoleOutputCharacterW
183
+ #define ScrollConsoleScreenBuffer ScrollConsoleScreenBufferW
184
+ #define GetConsoleTitle GetConsoleTitleW
185
+ #define SetConsoleTitle SetConsoleTitleW
186
+ #define ReadConsole ReadConsoleW
187
+ #define WriteConsole WriteConsoleW
188
+ #define AddConsoleAlias AddConsoleAliasW
189
+ #define GetConsoleAlias GetConsoleAliasW
190
+ #define GetConsoleAliasesLength GetConsoleAliasesLengthW
191
+ #define GetConsoleAliasExesLength GetConsoleAliasExesLengthW
192
+ #define GetConsoleAliases GetConsoleAliasesW
193
+ #define GetConsoleAliasExes GetConsoleAliasExesW
194
+ #else
195
+ #define PeekConsoleInput PeekConsoleInputA
196
+ #define ReadConsoleInput ReadConsoleInputA
197
+ #define WriteConsoleInput WriteConsoleInputA
198
+ #define ReadConsoleOutput ReadConsoleOutputA
199
+ #define WriteConsoleOutput WriteConsoleOutputA
200
+ #define ReadConsoleOutputCharacter ReadConsoleOutputCharacterA
201
+ #define WriteConsoleOutputCharacter WriteConsoleOutputCharacterA
202
+ #define FillConsoleOutputCharacter FillConsoleOutputCharacterA
203
+ #define ScrollConsoleScreenBuffer ScrollConsoleScreenBufferA
204
+ #define GetConsoleTitle GetConsoleTitleA
205
+ #define SetConsoleTitle SetConsoleTitleA
206
+ #define ReadConsole ReadConsoleA
207
+ #define WriteConsole WriteConsoleA
208
+ #define AddConsoleAlias AddConsoleAliasA
209
+ #define GetConsoleAlias GetConsoleAliasA
210
+ #define GetConsoleAliasesLength GetConsoleAliasesLengthA
211
+ #define GetConsoleAliasExesLength GetConsoleAliasExesLengthA
212
+ #define GetConsoleAliases GetConsoleAliasesA
213
+ #define GetConsoleAliasExes GetConsoleAliasExesA
214
+ #endif
215
+
216
+ WINBASEAPI WINBOOL WINAPI PeekConsoleInputA(HANDLE hConsoleInput,PINPUT_RECORD lpBuffer,DWORD nLength,LPDWORD lpNumberOfEventsRead);
217
+ WINBASEAPI WINBOOL WINAPI PeekConsoleInputW(HANDLE hConsoleInput,PINPUT_RECORD lpBuffer,DWORD nLength,LPDWORD lpNumberOfEventsRead);
218
+ WINBASEAPI WINBOOL WINAPI ReadConsoleInputA(HANDLE hConsoleInput,PINPUT_RECORD lpBuffer,DWORD nLength,LPDWORD lpNumberOfEventsRead);
219
+ WINBASEAPI WINBOOL WINAPI ReadConsoleInputW(HANDLE hConsoleInput,PINPUT_RECORD lpBuffer,DWORD nLength,LPDWORD lpNumberOfEventsRead);
220
+ WINBASEAPI WINBOOL WINAPI WriteConsoleInputA(HANDLE hConsoleInput,CONST INPUT_RECORD *lpBuffer,DWORD nLength,LPDWORD lpNumberOfEventsWritten);
221
+ WINBASEAPI WINBOOL WINAPI WriteConsoleInputW(HANDLE hConsoleInput,CONST INPUT_RECORD *lpBuffer,DWORD nLength,LPDWORD lpNumberOfEventsWritten);
222
+ WINBASEAPI WINBOOL WINAPI ReadConsoleOutputA(HANDLE hConsoleOutput,PCHAR_INFO lpBuffer,COORD dwBufferSize,COORD dwBufferCoord,PSMALL_RECT lpReadRegion);
223
+ WINBASEAPI WINBOOL WINAPI ReadConsoleOutputW(HANDLE hConsoleOutput,PCHAR_INFO lpBuffer,COORD dwBufferSize,COORD dwBufferCoord,PSMALL_RECT lpReadRegion);
224
+ WINBASEAPI WINBOOL WINAPI WriteConsoleOutputA(HANDLE hConsoleOutput,CONST CHAR_INFO *lpBuffer,COORD dwBufferSize,COORD dwBufferCoord,PSMALL_RECT lpWriteRegion);
225
+ WINBASEAPI WINBOOL WINAPI WriteConsoleOutputW(HANDLE hConsoleOutput,CONST CHAR_INFO *lpBuffer,COORD dwBufferSize,COORD dwBufferCoord,PSMALL_RECT lpWriteRegion);
226
+ WINBASEAPI WINBOOL WINAPI ReadConsoleOutputCharacterA(HANDLE hConsoleOutput,LPSTR lpCharacter,DWORD nLength,COORD dwReadCoord,LPDWORD lpNumberOfCharsRead);
227
+ WINBASEAPI WINBOOL WINAPI ReadConsoleOutputCharacterW(HANDLE hConsoleOutput,LPWSTR lpCharacter,DWORD nLength,COORD dwReadCoord,LPDWORD lpNumberOfCharsRead);
228
+ WINBASEAPI WINBOOL WINAPI ReadConsoleOutputAttribute(HANDLE hConsoleOutput,LPWORD lpAttribute,DWORD nLength,COORD dwReadCoord,LPDWORD lpNumberOfAttrsRead);
229
+ WINBASEAPI WINBOOL WINAPI WriteConsoleOutputCharacterA(HANDLE hConsoleOutput,LPCSTR lpCharacter,DWORD nLength,COORD dwWriteCoord,LPDWORD lpNumberOfCharsWritten);
230
+ WINBASEAPI WINBOOL WINAPI WriteConsoleOutputCharacterW(HANDLE hConsoleOutput,LPCWSTR lpCharacter,DWORD nLength,COORD dwWriteCoord,LPDWORD lpNumberOfCharsWritten);
231
+ WINBASEAPI WINBOOL WINAPI WriteConsoleOutputAttribute(HANDLE hConsoleOutput,CONST WORD *lpAttribute,DWORD nLength,COORD dwWriteCoord,LPDWORD lpNumberOfAttrsWritten);
232
+ WINBASEAPI WINBOOL WINAPI FillConsoleOutputCharacterA(HANDLE hConsoleOutput,CHAR cCharacter,DWORD nLength,COORD dwWriteCoord,LPDWORD lpNumberOfCharsWritten);
233
+ WINBASEAPI WINBOOL WINAPI FillConsoleOutputCharacterW(HANDLE hConsoleOutput,WCHAR cCharacter,DWORD nLength,COORD dwWriteCoord,LPDWORD lpNumberOfCharsWritten);
234
+ WINBASEAPI WINBOOL WINAPI FillConsoleOutputAttribute(HANDLE hConsoleOutput,WORD wAttribute,DWORD nLength,COORD dwWriteCoord,LPDWORD lpNumberOfAttrsWritten);
235
+ WINBASEAPI WINBOOL WINAPI GetConsoleMode(HANDLE hConsoleHandle,LPDWORD lpMode);
236
+ WINBASEAPI WINBOOL WINAPI GetNumberOfConsoleInputEvents(HANDLE hConsoleInput,LPDWORD lpNumberOfEvents);
237
+ WINBASEAPI WINBOOL WINAPI GetConsoleScreenBufferInfo(HANDLE hConsoleOutput,PCONSOLE_SCREEN_BUFFER_INFO lpConsoleScreenBufferInfo);
238
+ WINBASEAPI COORD WINAPI GetLargestConsoleWindowSize(HANDLE hConsoleOutput);
239
+ WINBASEAPI WINBOOL WINAPI GetConsoleCursorInfo(HANDLE hConsoleOutput,PCONSOLE_CURSOR_INFO lpConsoleCursorInfo);
240
+ WINBASEAPI WINBOOL WINAPI GetCurrentConsoleFont(HANDLE hConsoleOutput,WINBOOL bMaximumWindow,PCONSOLE_FONT_INFO lpConsoleCurrentFont);
241
+ WINBASEAPI COORD WINAPI GetConsoleFontSize(HANDLE hConsoleOutput,DWORD nFont);
242
+ WINBASEAPI WINBOOL WINAPI GetConsoleSelectionInfo(PCONSOLE_SELECTION_INFO lpConsoleSelectionInfo);
243
+ WINBASEAPI WINBOOL WINAPI GetNumberOfConsoleMouseButtons(LPDWORD lpNumberOfMouseButtons);
244
+ WINBASEAPI WINBOOL WINAPI SetConsoleMode(HANDLE hConsoleHandle,DWORD dwMode);
245
+ WINBASEAPI WINBOOL WINAPI SetConsoleActiveScreenBuffer(HANDLE hConsoleOutput);
246
+ WINBASEAPI WINBOOL WINAPI FlushConsoleInputBuffer(HANDLE hConsoleInput);
247
+ WINBASEAPI WINBOOL WINAPI SetConsoleScreenBufferSize(HANDLE hConsoleOutput,COORD dwSize);
248
+ WINBASEAPI WINBOOL WINAPI SetConsoleCursorPosition(HANDLE hConsoleOutput,COORD dwCursorPosition);
249
+ WINBASEAPI WINBOOL WINAPI SetConsoleCursorInfo(HANDLE hConsoleOutput,CONST CONSOLE_CURSOR_INFO *lpConsoleCursorInfo);
250
+ WINBASEAPI WINBOOL WINAPI ScrollConsoleScreenBufferA(HANDLE hConsoleOutput,CONST SMALL_RECT *lpScrollRectangle,CONST SMALL_RECT *lpClipRectangle,COORD dwDestinationOrigin,CONST CHAR_INFO *lpFill);
251
+ WINBASEAPI WINBOOL WINAPI ScrollConsoleScreenBufferW(HANDLE hConsoleOutput,CONST SMALL_RECT *lpScrollRectangle,CONST SMALL_RECT *lpClipRectangle,COORD dwDestinationOrigin,CONST CHAR_INFO *lpFill);
252
+ WINBASEAPI WINBOOL WINAPI SetConsoleWindowInfo(HANDLE hConsoleOutput,WINBOOL bAbsolute,CONST SMALL_RECT *lpConsoleWindow);
253
+ WINBASEAPI WINBOOL WINAPI SetConsoleTextAttribute(HANDLE hConsoleOutput,WORD wAttributes);
254
+ WINBASEAPI WINBOOL WINAPI SetConsoleCtrlHandler(PHANDLER_ROUTINE HandlerRoutine,WINBOOL Add);
255
+ WINBASEAPI WINBOOL WINAPI GenerateConsoleCtrlEvent(DWORD dwCtrlEvent,DWORD dwProcessGroupId);
256
+ WINBASEAPI WINBOOL WINAPI AllocConsole(VOID);
257
+ WINBASEAPI WINBOOL WINAPI FreeConsole(VOID);
258
+ WINBASEAPI WINBOOL WINAPI AttachConsole(DWORD dwProcessId);
259
+
260
+ #define ATTACH_PARENT_PROCESS ((DWORD)-1)
261
+
262
+ WINBASEAPI DWORD WINAPI GetConsoleTitleA(LPSTR lpConsoleTitle,DWORD nSize);
263
+ WINBASEAPI DWORD WINAPI GetConsoleTitleW(LPWSTR lpConsoleTitle,DWORD nSize);
264
+ WINBASEAPI WINBOOL WINAPI SetConsoleTitleA(LPCSTR lpConsoleTitle);
265
+ WINBASEAPI WINBOOL WINAPI SetConsoleTitleW(LPCWSTR lpConsoleTitle);
266
+ WINBASEAPI WINBOOL WINAPI ReadConsoleA(HANDLE hConsoleInput,LPVOID lpBuffer,DWORD nNumberOfCharsToRead,LPDWORD lpNumberOfCharsRead,LPVOID lpReserved);
267
+ WINBASEAPI WINBOOL WINAPI ReadConsoleW(HANDLE hConsoleInput,LPVOID lpBuffer,DWORD nNumberOfCharsToRead,LPDWORD lpNumberOfCharsRead,LPVOID lpReserved);
268
+ WINBASEAPI WINBOOL WINAPI WriteConsoleA(HANDLE hConsoleOutput,CONST VOID *lpBuffer,DWORD nNumberOfCharsToWrite,LPDWORD lpNumberOfCharsWritten,LPVOID lpReserved);
269
+ WINBASEAPI WINBOOL WINAPI WriteConsoleW(HANDLE hConsoleOutput,CONST VOID *lpBuffer,DWORD nNumberOfCharsToWrite,LPDWORD lpNumberOfCharsWritten,LPVOID lpReserved);
270
+
271
+ #define CONSOLE_TEXTMODE_BUFFER 1
272
+
273
+ WINBASEAPI HANDLE WINAPI CreateConsoleScreenBuffer(DWORD dwDesiredAccess,DWORD dwShareMode,CONST SECURITY_ATTRIBUTES *lpSecurityAttributes,DWORD dwFlags,LPVOID lpScreenBufferData);
274
+ WINBASEAPI UINT WINAPI GetConsoleCP(VOID);
275
+ WINBASEAPI WINBOOL WINAPI SetConsoleCP(UINT wCodePageID);
276
+ WINBASEAPI UINT WINAPI GetConsoleOutputCP(VOID);
277
+ WINBASEAPI WINBOOL WINAPI SetConsoleOutputCP(UINT wCodePageID);
278
+
279
+ #define CONSOLE_FULLSCREEN 1
280
+ #define CONSOLE_FULLSCREEN_HARDWARE 2
281
+
282
+ WINBASEAPI WINBOOL WINAPI GetConsoleDisplayMode(LPDWORD lpModeFlags);
283
+ WINBASEAPI HWND WINAPI GetConsoleWindow(VOID);
284
+ WINBASEAPI DWORD WINAPI GetConsoleProcessList(LPDWORD lpdwProcessList,DWORD dwProcessCount);
285
+ WINBASEAPI WINBOOL WINAPI AddConsoleAliasA(LPSTR Source,LPSTR Target,LPSTR ExeName);
286
+ WINBASEAPI WINBOOL WINAPI AddConsoleAliasW(LPWSTR Source,LPWSTR Target,LPWSTR ExeName);
287
+ WINBASEAPI DWORD WINAPI GetConsoleAliasA(LPSTR Source,LPSTR TargetBuffer,DWORD TargetBufferLength,LPSTR ExeName);
288
+ WINBASEAPI DWORD WINAPI GetConsoleAliasW(LPWSTR Source,LPWSTR TargetBuffer,DWORD TargetBufferLength,LPWSTR ExeName);
289
+ WINBASEAPI DWORD WINAPI GetConsoleAliasesLengthA(LPSTR ExeName);
290
+ WINBASEAPI DWORD WINAPI GetConsoleAliasesLengthW(LPWSTR ExeName);
291
+ WINBASEAPI DWORD WINAPI GetConsoleAliasExesLengthA(VOID);
292
+ WINBASEAPI DWORD WINAPI GetConsoleAliasExesLengthW(VOID);
293
+ WINBASEAPI DWORD WINAPI GetConsoleAliasesA(LPSTR AliasBuffer,DWORD AliasBufferLength,LPSTR ExeName);
294
+ WINBASEAPI DWORD WINAPI GetConsoleAliasesW(LPWSTR AliasBuffer,DWORD AliasBufferLength,LPWSTR ExeName);
295
+ WINBASEAPI DWORD WINAPI GetConsoleAliasExesA(LPSTR ExeNameBuffer,DWORD ExeNameBufferLength);
296
+ WINBASEAPI DWORD WINAPI GetConsoleAliasExesW(LPWSTR ExeNameBuffer,DWORD ExeNameBufferLength);
297
+
298
+ #ifdef __cplusplus
299
+ }
300
+ #endif
301
+ #endif
@@ -0,0 +1,293 @@
1
+ /**
2
+ * This file has no copyright assigned and is placed in the Public Domain.
3
+ * This file is part of the w64 mingw-runtime package.
4
+ * No warranty is given; refer to the file DISCLAIMER within this package.
5
+ */
6
+ #ifndef _WINDEF_
7
+ #define _WINDEF_
8
+
9
+ #ifndef STRICT
10
+ #define STRICT 1
11
+ #endif
12
+
13
+ #ifdef __cplusplus
14
+ extern "C" {
15
+ #endif
16
+
17
+ #ifndef WINVER
18
+ #define WINVER 0x0502
19
+ #endif
20
+
21
+ #ifndef BASETYPES
22
+ #define BASETYPES
23
+ typedef unsigned long ULONG;
24
+ typedef ULONG *PULONG;
25
+ typedef unsigned short USHORT;
26
+ typedef USHORT *PUSHORT;
27
+ typedef unsigned char UCHAR;
28
+ typedef UCHAR *PUCHAR;
29
+ typedef char *PSZ;
30
+ #endif
31
+
32
+ #define MAX_PATH 260
33
+
34
+ #ifndef NULL
35
+ #ifdef __cplusplus
36
+ #define NULL 0
37
+ #else
38
+ #define NULL ((void *)0)
39
+ #endif
40
+ #endif
41
+
42
+ #ifndef FALSE
43
+ #define FALSE 0
44
+ #endif
45
+
46
+ #ifndef TRUE
47
+ #define TRUE 1
48
+ #endif
49
+
50
+ #ifndef IN
51
+ #define IN
52
+ #endif
53
+
54
+ #ifndef OUT
55
+ #define OUT
56
+ #endif
57
+
58
+ #ifndef OPTIONAL
59
+ #define OPTIONAL
60
+ #endif
61
+
62
+ #undef far
63
+ #undef near
64
+ #undef pascal
65
+
66
+ #define far
67
+ #define near
68
+ #define pascal __stdcall
69
+
70
+ #define cdecl
71
+ #ifndef CDECL
72
+ #define CDECL
73
+ #endif
74
+ #ifndef CALLBACK
75
+ #define CALLBACK __stdcall
76
+ #endif
77
+ #ifndef WINAPI
78
+ #define WINAPI __stdcall
79
+ #endif
80
+ #define WINAPIV __cdecl
81
+ #define APIENTRY WINAPI
82
+ #define APIPRIVATE WINAPI
83
+ #define PASCAL WINAPI
84
+ #define WINAPI_INLINE WINAPI
85
+
86
+ #undef FAR
87
+ #undef NEAR
88
+ #define FAR
89
+ #define NEAR
90
+ #ifndef CONST
91
+ #define CONST const
92
+ #endif
93
+
94
+ typedef unsigned long DWORD;
95
+ typedef int WINBOOL;
96
+ #define BOOL WINBOOL
97
+ typedef unsigned char BYTE;
98
+ typedef unsigned short WORD;
99
+ typedef float FLOAT;
100
+ typedef FLOAT *PFLOAT;
101
+ typedef WINBOOL *PBOOL;
102
+ typedef WINBOOL *LPBOOL;
103
+ typedef BYTE *PBYTE;
104
+ typedef BYTE *LPBYTE;
105
+ typedef int *PINT;
106
+ typedef int *LPINT;
107
+ typedef WORD *PWORD;
108
+ typedef WORD *LPWORD;
109
+ typedef long *LPLONG;
110
+ typedef DWORD *PDWORD;
111
+ typedef DWORD *LPDWORD;
112
+ typedef void *LPVOID;
113
+ #ifndef _LPCVOID_DEFINED
114
+ #define _LPCVOID_DEFINED
115
+ typedef CONST void *LPCVOID;
116
+ #endif
117
+ typedef int INT;
118
+ typedef unsigned int UINT;
119
+ typedef unsigned int *PUINT;
120
+
121
+ #ifndef NT_INCLUDED
122
+ #include <winnt.h>
123
+ #endif
124
+
125
+ #include <specstrings.h>
126
+
127
+ typedef UINT_PTR WPARAM;
128
+ typedef LONG_PTR LPARAM;
129
+ typedef LONG_PTR LRESULT;
130
+
131
+ #ifndef __cplusplus
132
+ #ifndef NOMINMAX
133
+ #ifndef max
134
+ #define max(a,b) (((a) > (b)) ? (a) : (b))
135
+ #endif
136
+
137
+ #ifndef min
138
+ #define min(a,b) (((a) < (b)) ? (a) : (b))
139
+ #endif
140
+ #endif
141
+ #endif
142
+
143
+ #define MAKEWORD(a,b) ((WORD)(((BYTE)((DWORD_PTR)(a) & 0xff)) | ((WORD)((BYTE)((DWORD_PTR)(b) & 0xff))) << 8))
144
+ #define MAKELONG(a,b) ((LONG)(((WORD)((DWORD_PTR)(a) & 0xffff)) | ((DWORD)((WORD)((DWORD_PTR)(b) & 0xffff))) << 16))
145
+ #define LOWORD(l) ((WORD)((DWORD_PTR)(l) & 0xffff))
146
+ #define HIWORD(l) ((WORD)((DWORD_PTR)(l) >> 16))
147
+ #define LOBYTE(w) ((BYTE)((DWORD_PTR)(w) & 0xff))
148
+ #define HIBYTE(w) ((BYTE)((DWORD_PTR)(w) >> 8))
149
+
150
+ #ifndef WIN_INTERNAL
151
+ DECLARE_HANDLE (HWND);
152
+ DECLARE_HANDLE (HHOOK);
153
+ #ifdef WINABLE
154
+ DECLARE_HANDLE (HEVENT);
155
+ #endif
156
+ #endif
157
+
158
+ typedef WORD ATOM;
159
+
160
+ typedef HANDLE *SPHANDLE;
161
+ typedef HANDLE *LPHANDLE;
162
+ typedef HANDLE HGLOBAL;
163
+ typedef HANDLE HLOCAL;
164
+ typedef HANDLE GLOBALHANDLE;
165
+ typedef HANDLE LOCALHANDLE;
166
+ #ifdef _WIN64
167
+ typedef INT_PTR (WINAPI *FARPROC)();
168
+ typedef INT_PTR (WINAPI *NEARPROC)();
169
+ typedef INT_PTR (WINAPI *PROC)();
170
+ #else
171
+ typedef int (WINAPI *FARPROC)();
172
+ typedef int (WINAPI *NEARPROC)();
173
+ typedef int (WINAPI *PROC)();
174
+ #endif
175
+
176
+ typedef void *HGDIOBJ;
177
+
178
+ DECLARE_HANDLE(HKEY);
179
+ typedef HKEY *PHKEY;
180
+
181
+ DECLARE_HANDLE(HACCEL);
182
+ DECLARE_HANDLE(HBITMAP);
183
+ DECLARE_HANDLE(HBRUSH);
184
+ DECLARE_HANDLE(HCOLORSPACE);
185
+ DECLARE_HANDLE(HDC);
186
+ DECLARE_HANDLE(HGLRC);
187
+ DECLARE_HANDLE(HDESK);
188
+ DECLARE_HANDLE(HENHMETAFILE);
189
+ DECLARE_HANDLE(HFONT);
190
+ DECLARE_HANDLE(HICON);
191
+ DECLARE_HANDLE(HMENU);
192
+ DECLARE_HANDLE(HMETAFILE);
193
+ DECLARE_HANDLE(HINSTANCE);
194
+ typedef HINSTANCE HMODULE;
195
+ DECLARE_HANDLE(HPALETTE);
196
+ DECLARE_HANDLE(HPEN);
197
+ DECLARE_HANDLE(HRGN);
198
+ DECLARE_HANDLE(HRSRC);
199
+ DECLARE_HANDLE(HSTR);
200
+ DECLARE_HANDLE(HTASK);
201
+ DECLARE_HANDLE(HWINSTA);
202
+ DECLARE_HANDLE(HKL);
203
+ DECLARE_HANDLE(HMONITOR);
204
+ DECLARE_HANDLE(HWINEVENTHOOK);
205
+ DECLARE_HANDLE(HUMPD);
206
+
207
+ typedef int HFILE;
208
+ typedef HICON HCURSOR;
209
+ typedef DWORD COLORREF;
210
+ typedef DWORD *LPCOLORREF;
211
+
212
+ #define HFILE_ERROR ((HFILE)-1)
213
+
214
+ typedef struct tagRECT {
215
+ LONG left;
216
+ LONG top;
217
+ LONG right;
218
+ LONG bottom;
219
+ } RECT,*PRECT,*NPRECT,*LPRECT;
220
+
221
+ typedef const RECT *LPCRECT;
222
+
223
+ typedef struct _RECTL {
224
+ LONG left;
225
+ LONG top;
226
+ LONG right;
227
+ LONG bottom;
228
+ } RECTL,*PRECTL,*LPRECTL;
229
+
230
+ typedef const RECTL *LPCRECTL;
231
+
232
+ typedef struct tagPOINT {
233
+ LONG x;
234
+ LONG y;
235
+ } POINT,*PPOINT,*NPPOINT,*LPPOINT;
236
+
237
+ typedef struct _POINTL {
238
+ LONG x;
239
+ LONG y;
240
+ } POINTL,*PPOINTL;
241
+
242
+ typedef struct tagSIZE {
243
+ LONG cx;
244
+ LONG cy;
245
+ } SIZE,*PSIZE,*LPSIZE;
246
+
247
+ typedef SIZE SIZEL;
248
+ typedef SIZE *PSIZEL,*LPSIZEL;
249
+
250
+ typedef struct tagPOINTS {
251
+ SHORT x;
252
+ SHORT y;
253
+ } POINTS,*PPOINTS,*LPPOINTS;
254
+
255
+ typedef struct _FILETIME {
256
+ DWORD dwLowDateTime;
257
+ DWORD dwHighDateTime;
258
+ } FILETIME,*PFILETIME,*LPFILETIME;
259
+ #define _FILETIME_
260
+
261
+ #define DM_UPDATE 1
262
+ #define DM_COPY 2
263
+ #define DM_PROMPT 4
264
+ #define DM_MODIFY 8
265
+
266
+ #define DM_IN_BUFFER DM_MODIFY
267
+ #define DM_IN_PROMPT DM_PROMPT
268
+ #define DM_OUT_BUFFER DM_COPY
269
+ #define DM_OUT_DEFAULT DM_UPDATE
270
+
271
+ #define DC_FIELDS 1
272
+ #define DC_PAPERS 2
273
+ #define DC_PAPERSIZE 3
274
+ #define DC_MINEXTENT 4
275
+ #define DC_MAXEXTENT 5
276
+ #define DC_BINS 6
277
+ #define DC_DUPLEX 7
278
+ #define DC_SIZE 8
279
+ #define DC_EXTRA 9
280
+ #define DC_VERSION 10
281
+ #define DC_DRIVER 11
282
+ #define DC_BINNAMES 12
283
+ #define DC_ENUMRESOLUTIONS 13
284
+ #define DC_FILEDEPENDENCIES 14
285
+ #define DC_TRUETYPE 15
286
+ #define DC_PAPERNAMES 16
287
+ #define DC_ORIENTATION 17
288
+ #define DC_COPIES 18
289
+
290
+ #ifdef __cplusplus
291
+ }
292
+ #endif
293
+ #endif