koffi 0.9.18 → 0.9.19

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 (256) hide show
  1. package/CMakeLists.txt +16 -4
  2. package/README.md +14 -6
  3. package/package.json +1 -1
  4. package/src/call_x64_sysv_fwd.S +27 -22
  5. package/src/ffi.cc +16 -0
  6. package/test/registry/machines.json +143 -4
  7. package/test/registry/sha256sum.txt +21 -0
  8. package/test/test.js +2 -1
  9. package/test/tests/misc.js +1 -2
  10. package/test/tests/raylib.js +1 -2
  11. package/test/tests/sqlite.js +9 -5
  12. package/vendor/libcc/libcc.cc +32 -2
  13. package/vendor/libcc/libcc.hh +1 -1
  14. package/vendor/raylib/projects/VS2019/examples/audio_module_playing.vcxproj +387 -0
  15. package/vendor/raylib/projects/VS2019/examples/audio_multichannel_sound.vcxproj +387 -0
  16. package/vendor/raylib/projects/VS2019/examples/audio_music_stream.vcxproj +387 -0
  17. package/vendor/raylib/projects/VS2019/examples/audio_raw_stream.vcxproj +387 -0
  18. package/vendor/raylib/projects/VS2019/examples/audio_sound_loading.vcxproj +387 -0
  19. package/vendor/raylib/projects/VS2019/examples/core_2d_camera.vcxproj +387 -0
  20. package/vendor/raylib/projects/VS2019/examples/core_2d_camera_platformer.vcxproj +387 -0
  21. package/vendor/raylib/projects/VS2019/examples/core_3d_camera_first_person.vcxproj +387 -0
  22. package/vendor/raylib/projects/VS2019/examples/core_3d_camera_free.vcxproj +387 -0
  23. package/vendor/raylib/projects/VS2019/examples/core_3d_camera_mode.vcxproj +387 -0
  24. package/vendor/raylib/projects/VS2019/examples/core_3d_picking.vcxproj +387 -0
  25. package/vendor/raylib/projects/VS2019/examples/core_basic_window.vcxproj +387 -0
  26. package/vendor/raylib/projects/VS2019/examples/core_custom_logging.vcxproj +387 -0
  27. package/vendor/raylib/projects/VS2019/examples/core_drop_files.vcxproj +387 -0
  28. package/vendor/raylib/projects/VS2019/examples/core_input_gamepad.vcxproj +387 -0
  29. package/vendor/raylib/projects/VS2019/examples/core_input_gestures.vcxproj +387 -0
  30. package/vendor/raylib/projects/VS2019/examples/core_input_keys.vcxproj +387 -0
  31. package/vendor/raylib/projects/VS2019/examples/core_input_mouse.vcxproj +387 -0
  32. package/vendor/raylib/projects/VS2019/examples/core_input_mouse_wheel.vcxproj +387 -0
  33. package/vendor/raylib/projects/VS2019/examples/core_input_multitouch.vcxproj +387 -0
  34. package/vendor/raylib/projects/VS2019/examples/core_loading_thread.vcxproj +387 -0
  35. package/vendor/raylib/projects/VS2019/examples/core_quat_conversion.vcxproj +387 -0
  36. package/vendor/raylib/projects/VS2019/examples/core_random_values.vcxproj +387 -0
  37. package/vendor/raylib/projects/VS2019/examples/core_scissor_test.vcxproj +387 -0
  38. package/vendor/raylib/projects/VS2019/examples/core_split_screen.vcxproj +387 -0
  39. package/vendor/raylib/projects/VS2019/examples/core_storage_values.vcxproj +387 -0
  40. package/vendor/raylib/projects/VS2019/examples/core_vr_simulator.vcxproj +387 -0
  41. package/vendor/raylib/projects/VS2019/examples/core_window_flags.vcxproj +387 -0
  42. package/vendor/raylib/projects/VS2019/examples/core_window_letterbox.vcxproj +387 -0
  43. package/vendor/raylib/projects/VS2019/examples/core_world_screen.vcxproj +387 -0
  44. package/vendor/raylib/projects/VS2019/examples/easings_testbed.vcxproj +387 -0
  45. package/vendor/raylib/projects/VS2019/examples/embedded_files_loading.vcxproj +387 -0
  46. package/vendor/raylib/projects/VS2019/examples/models_animation.vcxproj +387 -0
  47. package/vendor/raylib/projects/VS2019/examples/models_billboard.vcxproj +387 -0
  48. package/vendor/raylib/projects/VS2019/examples/models_box_collisions.vcxproj +387 -0
  49. package/vendor/raylib/projects/VS2019/examples/models_cubicmap.vcxproj +387 -0
  50. package/vendor/raylib/projects/VS2019/examples/models_first_person_maze.vcxproj +387 -0
  51. package/vendor/raylib/projects/VS2019/examples/models_geometric_shapes.vcxproj +387 -0
  52. package/vendor/raylib/projects/VS2019/examples/models_heightmap.vcxproj +387 -0
  53. package/vendor/raylib/projects/VS2019/examples/models_loading.vcxproj +387 -0
  54. package/vendor/raylib/projects/VS2019/examples/models_loading_gltf.vcxproj +387 -0
  55. package/vendor/raylib/projects/VS2019/examples/models_loading_vox.vcxproj +387 -0
  56. package/vendor/raylib/projects/VS2019/examples/models_mesh_generation.vcxproj +387 -0
  57. package/vendor/raylib/projects/VS2019/examples/models_mesh_picking.vcxproj +387 -0
  58. package/vendor/raylib/projects/VS2019/examples/models_orthographic_projection.vcxproj +387 -0
  59. package/vendor/raylib/projects/VS2019/examples/models_rlgl_solar_system.vcxproj +387 -0
  60. package/vendor/raylib/projects/VS2019/examples/models_skybox.vcxproj +387 -0
  61. package/vendor/raylib/projects/VS2019/examples/models_waving_cubes.vcxproj +387 -0
  62. package/vendor/raylib/projects/VS2019/examples/models_yaw_pitch_roll.vcxproj +387 -0
  63. package/vendor/raylib/projects/VS2019/examples/physics_demo.vcxproj +387 -0
  64. package/vendor/raylib/projects/VS2019/examples/physics_friction.vcxproj +387 -0
  65. package/vendor/raylib/projects/VS2019/examples/physics_movement.vcxproj +387 -0
  66. package/vendor/raylib/projects/VS2019/examples/physics_restitution.vcxproj +387 -0
  67. package/vendor/raylib/projects/VS2019/examples/physics_shatter.vcxproj +387 -0
  68. package/vendor/raylib/projects/VS2019/examples/raudio_standalone.vcxproj +387 -0
  69. package/vendor/raylib/projects/VS2019/examples/rlgl_standalone.vcxproj +391 -0
  70. package/vendor/raylib/projects/VS2019/examples/shaders_basic_lighting.vcxproj +387 -0
  71. package/vendor/raylib/projects/VS2019/examples/shaders_custom_uniform.vcxproj +387 -0
  72. package/vendor/raylib/projects/VS2019/examples/shaders_eratosthenes.vcxproj +387 -0
  73. package/vendor/raylib/projects/VS2019/examples/shaders_fog.vcxproj +387 -0
  74. package/vendor/raylib/projects/VS2019/examples/shaders_hot_reloading.vcxproj +387 -0
  75. package/vendor/raylib/projects/VS2019/examples/shaders_julia_set.vcxproj +387 -0
  76. package/vendor/raylib/projects/VS2019/examples/shaders_mesh_instancing.vcxproj +387 -0
  77. package/vendor/raylib/projects/VS2019/examples/shaders_model_shader.vcxproj +387 -0
  78. package/vendor/raylib/projects/VS2019/examples/shaders_multi_sample2d.vcxproj +387 -0
  79. package/vendor/raylib/projects/VS2019/examples/shaders_palette_switch.vcxproj +387 -0
  80. package/vendor/raylib/projects/VS2019/examples/shaders_postprocessing.vcxproj +387 -0
  81. package/vendor/raylib/projects/VS2019/examples/shaders_raymarching.vcxproj +387 -0
  82. package/vendor/raylib/projects/VS2019/examples/shaders_shapes_textures.vcxproj +387 -0
  83. package/vendor/raylib/projects/VS2019/examples/shaders_simple_mask.vcxproj +387 -0
  84. package/vendor/raylib/projects/VS2019/examples/shaders_spotlight.vcxproj +387 -0
  85. package/vendor/raylib/projects/VS2019/examples/shaders_texture_drawing.vcxproj +387 -0
  86. package/vendor/raylib/projects/VS2019/examples/shaders_texture_waves.vcxproj +387 -0
  87. package/vendor/raylib/projects/VS2019/examples/shapes_basic_shapes.vcxproj +387 -0
  88. package/vendor/raylib/projects/VS2019/examples/shapes_bouncing_ball.vcxproj +387 -0
  89. package/vendor/raylib/projects/VS2019/examples/shapes_collision_area.vcxproj +387 -0
  90. package/vendor/raylib/projects/VS2019/examples/shapes_colors_palette.vcxproj +387 -0
  91. package/vendor/raylib/projects/VS2019/examples/shapes_draw_circle_sector.vcxproj +387 -0
  92. package/vendor/raylib/projects/VS2019/examples/shapes_draw_rectangle_rounded.vcxproj +387 -0
  93. package/vendor/raylib/projects/VS2019/examples/shapes_draw_ring.vcxproj +387 -0
  94. package/vendor/raylib/projects/VS2019/examples/shapes_easings_ball_anim.vcxproj +387 -0
  95. package/vendor/raylib/projects/VS2019/examples/shapes_easings_box_anim.vcxproj +387 -0
  96. package/vendor/raylib/projects/VS2019/examples/shapes_easings_rectangle_array.vcxproj +387 -0
  97. package/vendor/raylib/projects/VS2019/examples/shapes_following_eyes.vcxproj +387 -0
  98. package/vendor/raylib/projects/VS2019/examples/shapes_lines_bezier.vcxproj +387 -0
  99. package/vendor/raylib/projects/VS2019/examples/shapes_logo_raylib.vcxproj +387 -0
  100. package/vendor/raylib/projects/VS2019/examples/shapes_logo_raylib_anim.vcxproj +387 -0
  101. package/vendor/raylib/projects/VS2019/examples/shapes_rectangle_scaling.vcxproj +387 -0
  102. package/vendor/raylib/projects/VS2019/examples/shapes_top_down_lights.vcxproj +387 -0
  103. package/vendor/raylib/projects/VS2019/examples/text_font_filters.vcxproj +387 -0
  104. package/vendor/raylib/projects/VS2019/examples/text_font_loading.vcxproj +387 -0
  105. package/vendor/raylib/projects/VS2019/examples/text_font_sdf.vcxproj +387 -0
  106. package/vendor/raylib/projects/VS2019/examples/text_font_spritefont.vcxproj +387 -0
  107. package/vendor/raylib/projects/VS2019/examples/text_format_text.vcxproj +387 -0
  108. package/vendor/raylib/projects/VS2019/examples/text_input_box.vcxproj +387 -0
  109. package/vendor/raylib/projects/VS2019/examples/text_raylib_fonts.vcxproj +387 -0
  110. package/vendor/raylib/projects/VS2019/examples/text_rectangle_bounds.vcxproj +387 -0
  111. package/vendor/raylib/projects/VS2019/examples/text_unicode.vcxproj +387 -0
  112. package/vendor/raylib/projects/VS2019/examples/text_writing_anim.vcxproj +387 -0
  113. package/vendor/raylib/projects/VS2019/examples/textures_background_scrolling.vcxproj +387 -0
  114. package/vendor/raylib/projects/VS2019/examples/textures_blend_modes.vcxproj +387 -0
  115. package/vendor/raylib/projects/VS2019/examples/textures_bunnymark.vcxproj +387 -0
  116. package/vendor/raylib/projects/VS2019/examples/textures_draw_tiled.vcxproj +387 -0
  117. package/vendor/raylib/projects/VS2019/examples/textures_image_drawing.vcxproj +387 -0
  118. package/vendor/raylib/projects/VS2019/examples/textures_image_generation.vcxproj +387 -0
  119. package/vendor/raylib/projects/VS2019/examples/textures_image_loading.vcxproj +387 -0
  120. package/vendor/raylib/projects/VS2019/examples/textures_image_processing.vcxproj +387 -0
  121. package/vendor/raylib/projects/VS2019/examples/textures_image_text.vcxproj +387 -0
  122. package/vendor/raylib/projects/VS2019/examples/textures_logo_raylib.vcxproj +387 -0
  123. package/vendor/raylib/projects/VS2019/examples/textures_mouse_painting.vcxproj +387 -0
  124. package/vendor/raylib/projects/VS2019/examples/textures_npatch_drawing.vcxproj +387 -0
  125. package/vendor/raylib/projects/VS2019/examples/textures_particles_blending.vcxproj +387 -0
  126. package/vendor/raylib/projects/VS2019/examples/textures_raw_data.vcxproj +387 -0
  127. package/vendor/raylib/projects/VS2019/examples/textures_rectangle.vcxproj +387 -0
  128. package/vendor/raylib/projects/VS2019/examples/textures_sprite_button.vcxproj +387 -0
  129. package/vendor/raylib/projects/VS2019/examples/textures_sprite_explosion.vcxproj +387 -0
  130. package/vendor/raylib/projects/VS2019/examples/textures_srcrec_dstrec.vcxproj +387 -0
  131. package/vendor/raylib/projects/VS2019/examples/textures_to_image.vcxproj +387 -0
  132. package/vendor/raylib/projects/VS2019/raylib/raylib.vcxproj +341 -0
  133. package/vendor/raylib/projects/VS2019/raylib.sln +2293 -0
  134. package/vendor/raylib/projects/VS2019-Android/raylib_android/raylib_android.NativeActivity/raylib_android.NativeActivity.vcxproj +226 -0
  135. package/vendor/raylib/projects/VS2019-Android/raylib_android/raylib_android.NativeActivity/raylib_android.NativeActivity.vcxproj.filters +10 -0
  136. package/vendor/raylib/projects/VS2019-Android/raylib_android/raylib_android.NativeActivity/raylib_android.NativeActivity.vcxproj.user +4 -0
  137. package/vendor/raylib/projects/VS2019-Android/raylib_android.sln +75 -0
  138. package/vendor/raylib/projects/VS2022/examples/audio_module_playing.vcxproj +390 -0
  139. package/vendor/raylib/projects/VS2022/examples/audio_multichannel_sound.vcxproj +390 -0
  140. package/vendor/raylib/projects/VS2022/examples/audio_music_stream.vcxproj +390 -0
  141. package/vendor/raylib/projects/VS2022/examples/audio_raw_stream.vcxproj +390 -0
  142. package/vendor/raylib/projects/VS2022/examples/audio_sound_loading.vcxproj +390 -0
  143. package/vendor/raylib/projects/VS2022/examples/core_2d_camera.vcxproj +390 -0
  144. package/vendor/raylib/projects/VS2022/examples/core_2d_camera_platformer.vcxproj +390 -0
  145. package/vendor/raylib/projects/VS2022/examples/core_3d_camera_first_person.vcxproj +390 -0
  146. package/vendor/raylib/projects/VS2022/examples/core_3d_camera_free.vcxproj +390 -0
  147. package/vendor/raylib/projects/VS2022/examples/core_3d_camera_mode.vcxproj +390 -0
  148. package/vendor/raylib/projects/VS2022/examples/core_3d_picking.vcxproj +390 -0
  149. package/vendor/raylib/projects/VS2022/examples/core_basic_window.vcxproj +390 -0
  150. package/vendor/raylib/projects/VS2022/examples/core_custom_logging.vcxproj +390 -0
  151. package/vendor/raylib/projects/VS2022/examples/core_drop_files.vcxproj +390 -0
  152. package/vendor/raylib/projects/VS2022/examples/core_input_gamepad.vcxproj +387 -0
  153. package/vendor/raylib/projects/VS2022/examples/core_input_gestures.vcxproj +387 -0
  154. package/vendor/raylib/projects/VS2022/examples/core_input_keys.vcxproj +387 -0
  155. package/vendor/raylib/projects/VS2022/examples/core_input_mouse.vcxproj +387 -0
  156. package/vendor/raylib/projects/VS2022/examples/core_input_mouse_wheel.vcxproj +387 -0
  157. package/vendor/raylib/projects/VS2022/examples/core_input_multitouch.vcxproj +387 -0
  158. package/vendor/raylib/projects/VS2022/examples/core_loading_thread.vcxproj +387 -0
  159. package/vendor/raylib/projects/VS2022/examples/core_quat_conversion.vcxproj +387 -0
  160. package/vendor/raylib/projects/VS2022/examples/core_random_values.vcxproj +387 -0
  161. package/vendor/raylib/projects/VS2022/examples/core_scissor_test.vcxproj +387 -0
  162. package/vendor/raylib/projects/VS2022/examples/core_split_screen.vcxproj +387 -0
  163. package/vendor/raylib/projects/VS2022/examples/core_storage_values.vcxproj +387 -0
  164. package/vendor/raylib/projects/VS2022/examples/core_vr_simulator.vcxproj +387 -0
  165. package/vendor/raylib/projects/VS2022/examples/core_window_flags.vcxproj +387 -0
  166. package/vendor/raylib/projects/VS2022/examples/core_window_letterbox.vcxproj +387 -0
  167. package/vendor/raylib/projects/VS2022/examples/core_world_screen.vcxproj +387 -0
  168. package/vendor/raylib/projects/VS2022/examples/easings_testbed.vcxproj +387 -0
  169. package/vendor/raylib/projects/VS2022/examples/embedded_files_loading.vcxproj +387 -0
  170. package/vendor/raylib/projects/VS2022/examples/models_animation.vcxproj +387 -0
  171. package/vendor/raylib/projects/VS2022/examples/models_billboard.vcxproj +387 -0
  172. package/vendor/raylib/projects/VS2022/examples/models_box_collisions.vcxproj +387 -0
  173. package/vendor/raylib/projects/VS2022/examples/models_cubicmap.vcxproj +387 -0
  174. package/vendor/raylib/projects/VS2022/examples/models_first_person_maze.vcxproj +387 -0
  175. package/vendor/raylib/projects/VS2022/examples/models_geometric_shapes.vcxproj +387 -0
  176. package/vendor/raylib/projects/VS2022/examples/models_heightmap.vcxproj +387 -0
  177. package/vendor/raylib/projects/VS2022/examples/models_loading.vcxproj +387 -0
  178. package/vendor/raylib/projects/VS2022/examples/models_loading_gltf.vcxproj +387 -0
  179. package/vendor/raylib/projects/VS2022/examples/models_loading_vox.vcxproj +387 -0
  180. package/vendor/raylib/projects/VS2022/examples/models_mesh_generation.vcxproj +387 -0
  181. package/vendor/raylib/projects/VS2022/examples/models_mesh_picking.vcxproj +387 -0
  182. package/vendor/raylib/projects/VS2022/examples/models_orthographic_projection.vcxproj +387 -0
  183. package/vendor/raylib/projects/VS2022/examples/models_rlgl_solar_system.vcxproj +387 -0
  184. package/vendor/raylib/projects/VS2022/examples/models_skybox.vcxproj +387 -0
  185. package/vendor/raylib/projects/VS2022/examples/models_waving_cubes.vcxproj +387 -0
  186. package/vendor/raylib/projects/VS2022/examples/models_yaw_pitch_roll.vcxproj +387 -0
  187. package/vendor/raylib/projects/VS2022/examples/physics_demo.vcxproj +387 -0
  188. package/vendor/raylib/projects/VS2022/examples/physics_friction.vcxproj +387 -0
  189. package/vendor/raylib/projects/VS2022/examples/physics_movement.vcxproj +387 -0
  190. package/vendor/raylib/projects/VS2022/examples/physics_restitution.vcxproj +387 -0
  191. package/vendor/raylib/projects/VS2022/examples/physics_shatter.vcxproj +387 -0
  192. package/vendor/raylib/projects/VS2022/examples/raudio_standalone.vcxproj +387 -0
  193. package/vendor/raylib/projects/VS2022/examples/rlgl_standalone.vcxproj +391 -0
  194. package/vendor/raylib/projects/VS2022/examples/shaders_basic_lighting.vcxproj +387 -0
  195. package/vendor/raylib/projects/VS2022/examples/shaders_custom_uniform.vcxproj +387 -0
  196. package/vendor/raylib/projects/VS2022/examples/shaders_eratosthenes.vcxproj +387 -0
  197. package/vendor/raylib/projects/VS2022/examples/shaders_fog.vcxproj +387 -0
  198. package/vendor/raylib/projects/VS2022/examples/shaders_hot_reloading.vcxproj +387 -0
  199. package/vendor/raylib/projects/VS2022/examples/shaders_julia_set.vcxproj +387 -0
  200. package/vendor/raylib/projects/VS2022/examples/shaders_mesh_instancing.vcxproj +387 -0
  201. package/vendor/raylib/projects/VS2022/examples/shaders_model_shader.vcxproj +387 -0
  202. package/vendor/raylib/projects/VS2022/examples/shaders_multi_sample2d.vcxproj +387 -0
  203. package/vendor/raylib/projects/VS2022/examples/shaders_palette_switch.vcxproj +387 -0
  204. package/vendor/raylib/projects/VS2022/examples/shaders_postprocessing.vcxproj +387 -0
  205. package/vendor/raylib/projects/VS2022/examples/shaders_raymarching.vcxproj +387 -0
  206. package/vendor/raylib/projects/VS2022/examples/shaders_shapes_textures.vcxproj +387 -0
  207. package/vendor/raylib/projects/VS2022/examples/shaders_simple_mask.vcxproj +387 -0
  208. package/vendor/raylib/projects/VS2022/examples/shaders_spotlight.vcxproj +387 -0
  209. package/vendor/raylib/projects/VS2022/examples/shaders_texture_drawing.vcxproj +387 -0
  210. package/vendor/raylib/projects/VS2022/examples/shaders_texture_waves.vcxproj +387 -0
  211. package/vendor/raylib/projects/VS2022/examples/shapes_basic_shapes.vcxproj +387 -0
  212. package/vendor/raylib/projects/VS2022/examples/shapes_bouncing_ball.vcxproj +387 -0
  213. package/vendor/raylib/projects/VS2022/examples/shapes_collision_area.vcxproj +387 -0
  214. package/vendor/raylib/projects/VS2022/examples/shapes_colors_palette.vcxproj +387 -0
  215. package/vendor/raylib/projects/VS2022/examples/shapes_draw_circle_sector.vcxproj +387 -0
  216. package/vendor/raylib/projects/VS2022/examples/shapes_draw_rectangle_rounded.vcxproj +387 -0
  217. package/vendor/raylib/projects/VS2022/examples/shapes_draw_ring.vcxproj +387 -0
  218. package/vendor/raylib/projects/VS2022/examples/shapes_easings_ball_anim.vcxproj +387 -0
  219. package/vendor/raylib/projects/VS2022/examples/shapes_easings_box_anim.vcxproj +387 -0
  220. package/vendor/raylib/projects/VS2022/examples/shapes_easings_rectangle_array.vcxproj +387 -0
  221. package/vendor/raylib/projects/VS2022/examples/shapes_following_eyes.vcxproj +387 -0
  222. package/vendor/raylib/projects/VS2022/examples/shapes_lines_bezier.vcxproj +387 -0
  223. package/vendor/raylib/projects/VS2022/examples/shapes_logo_raylib.vcxproj +387 -0
  224. package/vendor/raylib/projects/VS2022/examples/shapes_logo_raylib_anim.vcxproj +387 -0
  225. package/vendor/raylib/projects/VS2022/examples/shapes_rectangle_scaling.vcxproj +387 -0
  226. package/vendor/raylib/projects/VS2022/examples/text_font_filters.vcxproj +387 -0
  227. package/vendor/raylib/projects/VS2022/examples/text_font_loading.vcxproj +387 -0
  228. package/vendor/raylib/projects/VS2022/examples/text_font_sdf.vcxproj +387 -0
  229. package/vendor/raylib/projects/VS2022/examples/text_font_spritefont.vcxproj +387 -0
  230. package/vendor/raylib/projects/VS2022/examples/text_format_text.vcxproj +387 -0
  231. package/vendor/raylib/projects/VS2022/examples/text_input_box.vcxproj +387 -0
  232. package/vendor/raylib/projects/VS2022/examples/text_raylib_fonts.vcxproj +387 -0
  233. package/vendor/raylib/projects/VS2022/examples/text_rectangle_bounds.vcxproj +387 -0
  234. package/vendor/raylib/projects/VS2022/examples/text_unicode.vcxproj +387 -0
  235. package/vendor/raylib/projects/VS2022/examples/text_writing_anim.vcxproj +387 -0
  236. package/vendor/raylib/projects/VS2022/examples/textures_background_scrolling.vcxproj +387 -0
  237. package/vendor/raylib/projects/VS2022/examples/textures_blend_modes.vcxproj +387 -0
  238. package/vendor/raylib/projects/VS2022/examples/textures_bunnymark.vcxproj +387 -0
  239. package/vendor/raylib/projects/VS2022/examples/textures_draw_tiled.vcxproj +387 -0
  240. package/vendor/raylib/projects/VS2022/examples/textures_image_drawing.vcxproj +387 -0
  241. package/vendor/raylib/projects/VS2022/examples/textures_image_generation.vcxproj +387 -0
  242. package/vendor/raylib/projects/VS2022/examples/textures_image_loading.vcxproj +387 -0
  243. package/vendor/raylib/projects/VS2022/examples/textures_image_processing.vcxproj +387 -0
  244. package/vendor/raylib/projects/VS2022/examples/textures_image_text.vcxproj +387 -0
  245. package/vendor/raylib/projects/VS2022/examples/textures_logo_raylib.vcxproj +387 -0
  246. package/vendor/raylib/projects/VS2022/examples/textures_mouse_painting.vcxproj +387 -0
  247. package/vendor/raylib/projects/VS2022/examples/textures_npatch_drawing.vcxproj +387 -0
  248. package/vendor/raylib/projects/VS2022/examples/textures_particles_blending.vcxproj +387 -0
  249. package/vendor/raylib/projects/VS2022/examples/textures_raw_data.vcxproj +387 -0
  250. package/vendor/raylib/projects/VS2022/examples/textures_rectangle.vcxproj +387 -0
  251. package/vendor/raylib/projects/VS2022/examples/textures_sprite_button.vcxproj +387 -0
  252. package/vendor/raylib/projects/VS2022/examples/textures_sprite_explosion.vcxproj +387 -0
  253. package/vendor/raylib/projects/VS2022/examples/textures_srcrec_dstrec.vcxproj +387 -0
  254. package/vendor/raylib/projects/VS2022/examples/textures_to_image.vcxproj +387 -0
  255. package/vendor/raylib/projects/VS2022/raylib/raylib.vcxproj +340 -0
  256. package/vendor/raylib/projects/VS2022/raylib.sln +2274 -0
package/CMakeLists.txt CHANGED
@@ -83,10 +83,6 @@ target_include_directories(raylib PRIVATE vendor/raylib/src/external/glfw/includ
83
83
  target_compile_definitions(raylib PRIVATE PLATFORM_DESKTOP GRAPHICS_API_OPENGL_21
84
84
  BUILD_LIBTYPE_SHARED NDEBUG)
85
85
 
86
- if(WIN32)
87
- target_compile_definitions(raylib PRIVATE _CRT_SECURE_NO_WARNINGS _CRT_NONSTDC_NO_DEPRECATE)
88
- target_link_libraries(raylib PRIVATE winmm)
89
- endif()
90
86
  if(MSVC)
91
87
  target_compile_options(raylib PRIVATE /wd4244 /wd4305)
92
88
  else()
@@ -96,6 +92,22 @@ else()
96
92
  -Wno-unused-result)
97
93
  endif()
98
94
 
95
+ if(WIN32)
96
+ target_compile_definitions(raylib PRIVATE _CRT_SECURE_NO_WARNINGS _CRT_NONSTDC_NO_DEPRECATE)
97
+ target_link_libraries(raylib PRIVATE winmm)
98
+ endif()
99
+
100
+ if(CMAKE_SYSTEM_NAME MATCHES "BSD")
101
+ target_include_directories(raylib PRIVATE /usr/local/include)
102
+ endif()
103
+
104
+ if(APPLE)
105
+ target_compile_options(raylib PRIVATE -Wno-unknown-warning-option -Wno-macro-redefined)
106
+ target_compile_definitions(raylib PRIVATE GL_SILENCE_DEPRECATION)
107
+ set_source_files_properties(vendor/raylib/src/rglfw.c PROPERTIES COMPILE_FLAGS "-x objective-c")
108
+ target_link_libraries(raylib PRIVATE "-framework Cocoa" "-framework IOKit" "-framework CoreFoundation" "-framework OpenGL")
109
+ endif()
110
+
99
111
  # ---- SQLite ----
100
112
 
101
113
  add_library(sqlite3 SHARED vendor/sqlite3/sqlite3.c)
package/README.md CHANGED
@@ -11,7 +11,7 @@
11
11
 
12
12
  Koffi is a fast and easy-to-use FFI module for Node.js, with support for complex data types such as structs.
13
13
 
14
- The following platforms __are supported__ at the moment:
14
+ The following platforms __are officially supported and tested__ at the moment:
15
15
 
16
16
  * Windows x86 *(cdecl, stdcall, fastcall)*
17
17
  * Windows x86_64
@@ -19,13 +19,21 @@ The following platforms __are supported__ at the moment:
19
19
  * Linux x86_64
20
20
  * Linux ARM32+VFP Little Endian
21
21
  * Linux ARM64 Little Endian
22
+ * FreeBSD x86
23
+ * FreeBSD x86_64
24
+ * FreeBSD ARM64 Little Endian
25
+ * macOS x86_64
22
26
 
23
- The following platforms are __not yet supported__ but will be soon:
27
+ The following platforms will __soon be officially supported__:
24
28
 
25
- * macOS x86_64
26
29
  * macOS ARM64
27
- * FreeBSD/NetBSD/OpenBSD x86_64
28
- * FreeBSD/NetBSD/OpenBSD ARM64
30
+
31
+ The following platforms __may be supported__ but are not tested:
32
+
33
+ * NetBSD x86_64
34
+ * NetBSD ARM64
35
+ * OpenBSD x86_64
36
+ * OpenBSD ARM64
29
37
 
30
38
  This is still in development, bugs are to expected. More tests will come in the near future.
31
39
 
@@ -123,7 +131,7 @@ const Font = koffi.struct('Font', {
123
131
  });
124
132
 
125
133
  // Fix the path to Raylib DLL if needed
126
- let lib = koffi.load('build/raylib' + (process.platform == 'win32' ? '.dll' : '.so'));
134
+ let lib = koffi.load('build/raylib' + koffi.extension);
127
135
 
128
136
  const InitWindow = lib.cdecl('InitWindow', 'void', ['int', 'int', 'string']);
129
137
  const SetTargetFPS = lib.cdecl('SetTargetFPS', 'void', ['int']);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "koffi",
3
- "version": "0.9.18",
3
+ "version": "0.9.19",
4
4
  "description": "Fast and simple FFI (foreign function interface) for Node.js",
5
5
  "keywords": [
6
6
  "foreign",
@@ -11,20 +11,26 @@
11
11
  // You should have received a copy of the GNU Affero General Public License
12
12
  // along with this program. If not, see https://www.gnu.org/licenses/.
13
13
 
14
+ #ifdef __APPLE__
15
+ #define SYMBOL(Symbol) _ ## Symbol
16
+ #else
17
+ #define SYMBOL(Symbol) Symbol
18
+ #endif
19
+
14
20
  // These five are the same, but they differ (in the C side) by their return type.
15
21
  // Unlike the five next functions, these ones don't forward XMM argument registers.
16
- .global ForwardCallGG
17
- .global ForwardCallF
18
- .global ForwardCallDG
19
- .global ForwardCallGD
20
- .global ForwardCallDD
22
+ .global SYMBOL(ForwardCallGG)
23
+ .global SYMBOL(ForwardCallF)
24
+ .global SYMBOL(ForwardCallDG)
25
+ .global SYMBOL(ForwardCallGD)
26
+ .global SYMBOL(ForwardCallDD)
21
27
 
22
28
  // The X variants are slightly slower, and are used when XMM arguments must be forwarded.
23
- .global ForwardCallXGG
24
- .global ForwardCallXF
25
- .global ForwardCallXDG
26
- .global ForwardCallXGD
27
- .global ForwardCallXDD
29
+ .global SYMBOL(ForwardCallXGG)
30
+ .global SYMBOL(ForwardCallXF)
31
+ .global SYMBOL(ForwardCallXDG)
32
+ .global SYMBOL(ForwardCallXGD)
33
+ .global SYMBOL(ForwardCallXDD)
28
34
 
29
35
  // Copy function pointer to RAX, in order to save it through argument forwarding.
30
36
  // Save RSP in RBX (non-volatile), and use carefully assembled stack provided by caller.
@@ -37,8 +43,7 @@
37
43
  .cfi_def_cfa rsp, 16
38
44
  movq %rsp, %rbx
39
45
  .cfi_def_cfa rbx, 16
40
- movq %rsi, %rsp
41
- addq $112, %rsp
46
+ leaq 112(%rsi), %rsp
42
47
  .endm
43
48
 
44
49
  // Call native function.
@@ -75,56 +80,56 @@
75
80
  movsd 48(%rsi), %xmm0
76
81
  .endm
77
82
 
78
- ForwardCallGG:
83
+ SYMBOL(ForwardCallGG):
79
84
  prologue
80
85
  forward_int
81
86
  epilogue
82
87
 
83
- ForwardCallF:
88
+ SYMBOL(ForwardCallF):
84
89
  prologue
85
90
  forward_int
86
91
  epilogue
87
92
 
88
- ForwardCallDG:
93
+ SYMBOL(ForwardCallDG):
89
94
  prologue
90
95
  forward_int
91
96
  epilogue
92
97
 
93
- ForwardCallGD:
98
+ SYMBOL(ForwardCallGD):
94
99
  prologue
95
100
  forward_int
96
101
  epilogue
97
102
 
98
- ForwardCallDD:
103
+ SYMBOL(ForwardCallDD):
99
104
  prologue
100
105
  forward_int
101
106
  epilogue
102
107
 
103
- ForwardCallXGG:
108
+ SYMBOL(ForwardCallXGG):
104
109
  prologue
105
110
  forward_xmm
106
111
  forward_int
107
112
  epilogue
108
113
 
109
- ForwardCallXF:
114
+ SYMBOL(ForwardCallXF):
110
115
  prologue
111
116
  forward_xmm
112
117
  forward_int
113
118
  epilogue
114
119
 
115
- ForwardCallXDG:
120
+ SYMBOL(ForwardCallXDG):
116
121
  prologue
117
122
  forward_xmm
118
123
  forward_int
119
124
  epilogue
120
125
 
121
- ForwardCallXGD:
126
+ SYMBOL(ForwardCallXGD):
122
127
  prologue
123
128
  forward_xmm
124
129
  forward_int
125
130
  epilogue
126
131
 
127
- ForwardCallXDD:
132
+ SYMBOL(ForwardCallXDD):
128
133
  prologue
129
134
  forward_xmm
130
135
  forward_int
package/src/ffi.cc CHANGED
@@ -611,7 +611,15 @@ static void InitInternal(v8::Local<v8::Object> target, v8::Local<v8::Value>,
611
611
  SetValue(env, target, "in", Napi::Function::New(env_napi, MarkIn));
612
612
  SetValue(env, target, "out", Napi::Function::New(env_napi, MarkOut));
613
613
  SetValue(env, target, "inout", Napi::Function::New(env_napi, MarkInOut));
614
+
614
615
  SetValue(env, target, "internal", Napi::Boolean::New(env_napi, true));
616
+ #if defined(_WIN32)
617
+ SetValue(env, target, "extension", Napi::String::New(env_napi, ".dll"));
618
+ #elif defined(__APPLE__)
619
+ SetValue(env, target, "extension", Napi::String::New(env_napi, ".dylib"));
620
+ #else
621
+ SetValue(env, target, "extension", Napi::String::New(env_napi, ".so"));
622
+ #endif
615
623
 
616
624
  Napi::Object types = InitBaseTypes(env_cxx);
617
625
  SetValue(env, target, "types", types);
@@ -636,7 +644,15 @@ static Napi::Object InitModule(Napi::Env env, Napi::Object exports)
636
644
  exports.Set("in", Napi::Function::New(env, MarkIn));
637
645
  exports.Set("out", Napi::Function::New(env, MarkOut));
638
646
  exports.Set("inout", Napi::Function::New(env, MarkInOut));
647
+
639
648
  exports.Set("internal", Napi::Boolean::New(env, false));
649
+ #if defined(_WIN32)
650
+ exports.Set("extension", Napi::String::New(env, ".dll"));
651
+ #elif defined(__APPLE__)
652
+ exports.Set("extension", Napi::String::New(env, ".dylib"));
653
+ #else
654
+ exports.Set("extension", Napi::String::New(env, ".so"));
655
+ #endif
640
656
 
641
657
  Napi::Object types = InitBaseTypes(env);
642
658
  exports.Set("types", types);
@@ -4,7 +4,7 @@
4
4
 
5
5
  "qemu": {
6
6
  "binary": "qemu-system-arm",
7
- "arguments": ["-M", "virt", "-cpu", "cortex-a15", "-m", "2G", "-smp", 2, "-kernel", "vmlinuz-5.10.0-12-armmp-lpae", "-initrd", "initrd.img-5.10.0-12-armmp-lpae", "-append", "root=/dev/vda2 apparmor=0", "-drive", "if=none,file=disk.qcow2,format=qcow2,id=hd", "-device", "virtio-blk-device,drive=hd", "-netdev", "user,id=mynet,hostfwd=tcp::22201-:22", "-device", "virtio-net-device,netdev=mynet", "-vnc", "127.0.0.1:11"]
7
+ "arguments": ["-M", "virt", "-cpu", "cortex-a15", "-m", "1G", "-smp", 2, "-kernel", "vmlinuz-5.10.0-12-armmp-lpae", "-initrd", "initrd.img-5.10.0-12-armmp-lpae", "-append", "root=/dev/vda2 apparmor=0", "-drive", "if=none,file=disk.qcow2,format=qcow2,id=hd", "-device", "virtio-blk-device,drive=hd", "-netdev", "user,id=mynet,hostfwd=tcp::22201-:22", "-device", "virtio-net-device,netdev=mynet", "-vnc", "127.0.0.1:11"]
8
8
  },
9
9
 
10
10
  "info": {
@@ -39,7 +39,7 @@
39
39
 
40
40
  "qemu": {
41
41
  "binary": "qemu-system-aarch64",
42
- "arguments": ["-M", "virt", "-cpu", "cortex-a53", "-m", "2G", "-smp", 2, "-kernel", "vmlinuz-5.10.0-12-arm64", "-initrd", "initrd.img-5.10.0-12-arm64", "-append", "root=/dev/vda2 apparmor=0", "-drive", "if=none,file=disk.qcow2,format=qcow2,id=hd", "-device", "virtio-blk-device,drive=hd", "-netdev", "user,id=mynet,hostfwd=tcp::22202-:22", "-device", "virtio-net-device,netdev=mynet", "-vnc", "127.0.0.1:12"]
42
+ "arguments": ["-M", "virt", "-cpu", "cortex-a53", "-m", "1G", "-smp", 2, "-kernel", "vmlinuz-5.10.0-12-arm64", "-initrd", "initrd.img-5.10.0-12-arm64", "-append", "root=/dev/vda2 apparmor=0", "-drive", "if=none,file=disk.qcow2,format=qcow2,id=hd", "-device", "virtio-blk-device,drive=hd", "-netdev", "user,id=mynet,hostfwd=tcp::22202-:22", "-device", "virtio-net-device,netdev=mynet", "-vnc", "127.0.0.1:12"]
43
43
  },
44
44
 
45
45
  "info": {
@@ -74,7 +74,7 @@
74
74
 
75
75
  "qemu": {
76
76
  "binary": "qemu-system-i386",
77
- "arguments": ["-cpu", "max", "-m", "2G", "-smp", 2, "-kernel", "vmlinuz-5.10.0-12-686-pae", "-initrd", "initrd.img-5.10.0-12-686-pae", "-append", "root=/dev/sda1 apparmor=0", "-hda", "disk.qcow2", "-netdev", "user,id=mynet,hostfwd=tcp::22203-:22", "-device", "e1000,netdev=mynet", "-vnc", "127.0.0.1:13"]
77
+ "arguments": ["-cpu", "max", "-m", "1G", "-smp", 2, "-kernel", "vmlinuz-5.10.0-12-686-pae", "-initrd", "initrd.img-5.10.0-12-686-pae", "-append", "root=/dev/sda1 apparmor=0", "-hda", "disk.qcow2", "-netdev", "user,id=mynet,hostfwd=tcp::22203-:22", "-device", "e1000,netdev=mynet", "-vnc", "127.0.0.1:13"]
78
78
  },
79
79
 
80
80
  "info": {
@@ -109,7 +109,7 @@
109
109
 
110
110
  "qemu": {
111
111
  "binary": "qemu-system-x86_64",
112
- "arguments": ["-m", "2G", "-smp", 2, "-kernel", "vmlinuz-5.10.0-12-amd64", "-initrd", "initrd.img-5.10.0-12-amd64", "-append", "root=/dev/sda1 apparmor=0", "-hda", "disk.qcow2", "-netdev", "user,id=mynet,hostfwd=tcp::22204-:22", "-device", "e1000,netdev=mynet", "-vnc", "127.0.0.1:14"]
112
+ "arguments": ["-m", "1G", "-smp", 2, "-kernel", "vmlinuz-5.10.0-12-amd64", "-initrd", "initrd.img-5.10.0-12-amd64", "-append", "root=/dev/sda1 apparmor=0", "-hda", "disk.qcow2", "-netdev", "user,id=mynet,hostfwd=tcp::22204-:22", "-device", "e1000,netdev=mynet", "-vnc", "127.0.0.1:14"]
113
113
  },
114
114
 
115
115
  "info": {
@@ -182,5 +182,144 @@
182
182
  }
183
183
  }
184
184
  }
185
+ },
186
+
187
+ "freebsd_x64": {
188
+ "name": "FreeBSD x64",
189
+
190
+ "qemu": {
191
+ "binary": "qemu-system-x86_64",
192
+ "arguments": ["-m", "1G", "-smp", 2, "-hda", "disk.qcow2", "-netdev", "user,id=mynet,hostfwd=tcp::22206-:22", "-device", "e1000,netdev=mynet", "-vnc", "127.0.0.1:16"]
193
+ },
194
+
195
+ "info": {
196
+ "version": 1,
197
+ "platform": "freebsd",
198
+ "arch": "x64",
199
+
200
+ "ssh_port": 22206,
201
+ "vnc_port": 5916,
202
+
203
+ "username": "freebsd",
204
+ "password": "freebsd",
205
+
206
+ "shutdown": "sudo poweroff"
207
+ },
208
+
209
+ "tests": {
210
+ "FreeBSD x64": {
211
+ "directory": "/home/freebsd/luigi",
212
+ "build": "npm install --production",
213
+ "commands": {
214
+ "Test Raylib": "xvfb-run node test/tests/raylib.js",
215
+ "Test Misc": "node test/tests/misc.js",
216
+ "Test SQLite": "node test/tests/sqlite.js"
217
+ }
218
+ }
219
+ }
220
+ },
221
+
222
+ "freebsd_i386": {
223
+ "name": "FreeBSD i386",
224
+
225
+ "qemu": {
226
+ "binary": "qemu-system-i386",
227
+ "arguments": ["-m", "1G", "-smp", 2, "-hda", "disk.qcow2", "-netdev", "user,id=mynet,hostfwd=tcp::22207-:22", "-device", "e1000,netdev=mynet", "-vnc", "127.0.0.1:17"]
228
+ },
229
+
230
+ "info": {
231
+ "version": 1,
232
+ "platform": "freebsd",
233
+ "arch": "ia32",
234
+
235
+ "ssh_port": 22207,
236
+ "vnc_port": 5917,
237
+
238
+ "username": "freebsd",
239
+ "password": "freebsd",
240
+
241
+ "shutdown": "sudo poweroff"
242
+ },
243
+
244
+ "tests": {
245
+ "FreeBSD i386": {
246
+ "directory": "/home/freebsd/luigi",
247
+ "build": "npm install --production",
248
+ "commands": {
249
+ "Test Raylib": "xvfb-run node test/tests/raylib.js",
250
+ "Test Misc": "node test/tests/misc.js",
251
+ "Test SQLite": "node test/tests/sqlite.js"
252
+ }
253
+ }
254
+ }
255
+ },
256
+
257
+ "freebsd_arm64": {
258
+ "name": "FreeBSD ARM64",
259
+
260
+ "qemu": {
261
+ "binary": "qemu-system-aarch64",
262
+ "arguments": ["-M", "virt", "-cpu", "cortex-a53", "-m", "1G", "-smp", 2, "-drive", "if=pflash,format=raw,file=QEMU_EFI.img", "-drive", "if=pflash,file=varstore.img", "-drive", "if=virtio,file=disk.qcow2,format=qcow2", "-netdev", "user,id=mynet,hostfwd=tcp::22208-:22", "-device", "virtio-net-device,netdev=mynet", "-vnc", "127.0.0.1:18"]
263
+ },
264
+
265
+ "info": {
266
+ "version": 1,
267
+ "platform": "freebsd",
268
+ "arch": "arm64",
269
+
270
+ "ssh_port": 22208,
271
+ "vnc_port": 5918,
272
+
273
+ "username": "freebsd",
274
+ "password": "freebsd",
275
+
276
+ "shutdown": "sudo poweroff"
277
+ },
278
+
279
+ "tests": {
280
+ "FreeBSD ARM64": {
281
+ "directory": "/home/freebsd/luigi",
282
+ "build": "npm install --production",
283
+ "commands": {
284
+ "Test Raylib": "xvfb-run node test/tests/raylib.js",
285
+ "Test Misc": "node test/tests/misc.js",
286
+ "Test SQLite": "node test/tests/sqlite.js"
287
+ }
288
+ }
289
+ }
290
+ },
291
+
292
+ "macos_x64": {
293
+ "name": "macOS x64",
294
+
295
+ "qemu": {
296
+ "binary": "qemu-system-x86_64",
297
+ "arguments": ["-m", "3G", "-machine", "q35", "-smp", 2, "-cpu", "Penryn,vendor=GenuineIntel,kvm=on,+sse3,+sse4.2,+aes,+xsave,+avx,+xsaveopt,+xsavec,+xgetbv1,+avx2,+bmi2,+smep,+bmi1,+fma,+movbe,+invtsc", "-device", "isa-applesmc,osk=ourhardworkbythesewordsguardedpleasedontsteal(c)AppleComputerInc", "-smbios", "type=2", "-drive", "if=pflash,format=raw,readonly=on,file=OVMF_CODE.fd", "-drive", "if=pflash,format=raw,file=OVMF_VARS-1024x768.fd", "-vga", "qxl", "-device", "ich9-intel-hda", "-device", "hda-output", "-usb", "-device", "usb-kbd", "-device", "usb-tablet", "-netdev", "user,id=net0,hostfwd=tcp::22209-:22", "-device", "e1000-82545em,netdev=net0,id=net0,mac=52:54:00:c9:18:27", "-device", "ich9-ahci,id=sata", "-drive", "id=ESP,if=none,format=qcow2,file=ESP.qcow2", "-device", "ide-hd,bus=sata.2,drive=ESP", "-drive", "id=SystemDisk,if=none,file=macOS.qcow2", "-device", "ide-hd,bus=sata.4,drive=SystemDisk", "-vnc", "127.0.0.1:19"]
298
+ },
299
+
300
+ "info": {
301
+ "version": 1,
302
+ "platform": "darwin",
303
+ "arch": "x64",
304
+
305
+ "ssh_port": 22209,
306
+ "vnc_port": 5919,
307
+
308
+ "username": "macos",
309
+ "password": "macos",
310
+
311
+ "shutdown": "sudo shutdown -h now"
312
+ },
313
+
314
+ "tests": {
315
+ "macOS x64": {
316
+ "directory": "/Users/macos/luigi",
317
+ "build": "PATH=/usr/local/bin:/usr/bin:/bin npm install --production && PATH=/usr/local/bin:/usr/bin:/bin SDKROOT=/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk ../cnoke/cnoke.js",
318
+ "commands": {
319
+ "Test Misc": "PATH=/usr/local/bin:/usr/bin:/bin node test/tests/misc.js",
320
+ "Test SQLite": "PATH=/usr/local/bin:/usr/bin:/bin node test/tests/sqlite.js"
321
+ }
322
+ }
323
+ }
185
324
  }
186
325
  }
@@ -22,3 +22,24 @@ ed05b84b7759ec945bb5422305a3a3c5b61d89e231844656ea31e07d89451a20 *qemu/debian_i3
22
22
  292a61c415a99a9c63a9337f1e074bea6c5df594e16bc40ded76141963c67ea4 *qemu/debian_i386/install.sh
23
23
  8dc1360e1c23ea21931f5eb94461d15fac6bcec00cf42bf1e590b7fb937e80c1 *qemu/debian_i386/initrd.img-5.10.0-12-686-pae
24
24
  338602d969f953cd88c2df736b9f8f7ee53029d233c83c7398258ae5bcb4e286 *qemu/debian_i386/disk.qcow2
25
+ 6b86b273ff34fce19d6b804eff5a3f5747ada4eaa22f1d49c01e52ddb7875b4b *qemu/freebsd_arm64/VERSION
26
+ 5daea533330eb8d2f8df946561680e09f8dacc467fbf03d28caa2115d94386b5 *qemu/freebsd_arm64/QEMU_EFI.img
27
+ a083e4e1f58f477e4a9e8ae30f75660e82275b88f77b5e2c7f5d6ee1deb43b41 *qemu/freebsd_arm64/varstore.img
28
+ 53a4dc48317e1c9de4a088cd45ba39a1810f0bafad75c7f810e18d4e3eb340e3 *qemu/freebsd_arm64/install.sh
29
+ a19ad06aec7972f3b95a56fb9bb8ac8a6afcd61b586f398691d58c704e8c466e *qemu/freebsd_arm64/disk.qcow2
30
+ 10f2bc603b171368cacda43485f8f72567af0a9a490b7e0fa0c14c983ae66f16 *qemu/freebsd_arm64/xvfb-run.sh
31
+ 6b86b273ff34fce19d6b804eff5a3f5747ada4eaa22f1d49c01e52ddb7875b4b *qemu/freebsd_x64/VERSION
32
+ 06eef544fe9c61d3905b0e588c306d1dedac7ee7d4c01df154ff6ed64e25ef77 *qemu/freebsd_x64/install.sh
33
+ 060b66901313ddfcd434c20a7b13052b3e5126e43c4e44884b85191560bd99eb *qemu/freebsd_x64/disk.qcow2
34
+ 10f2bc603b171368cacda43485f8f72567af0a9a490b7e0fa0c14c983ae66f16 *qemu/freebsd_x64/xvfb-run.sh
35
+ 6b86b273ff34fce19d6b804eff5a3f5747ada4eaa22f1d49c01e52ddb7875b4b *qemu/freebsd_i386/VERSION
36
+ bdeac2cca1d22d70c2d388a50709d5cba3069bbd4bd1bcb102955b0ee12ca3e9 *qemu/freebsd_i386/install.sh
37
+ 8191cea63d738cdca6df0b2d2d6953675e1dd33cac4d98fff88ba4367b182b64 *qemu/freebsd_i386/disk.qcow2
38
+ 10f2bc603b171368cacda43485f8f72567af0a9a490b7e0fa0c14c983ae66f16 *qemu/freebsd_i386/xvfb-run.sh
39
+ 16a4f09b3e70b97f5cfb1cf9b913d67d0ec45c4342d202cc9a2b2cfee852a8de *qemu/macos_x64/ESP.qcow2
40
+ 35abfe68efe9bb81b21399a41ebdf9074c377e09079d9b55ae6f8c6da0580a06 *qemu/macos_x64/install.md
41
+ 5d2ac383371b408398accee7ec27c8c09ea5b74a0de0ceea6513388b15be5d1e *qemu/macos_x64/OVMF_VARS.fd
42
+ fd0c3cbabd3f9744fc82f1b9b290c215cd8400b8501767b61ce7b7b30438db7c *qemu/macos_x64/macOS.qcow2
43
+ 51d13e3b6a6c579019f45a1b500fb41f4bfebef227cd605d3e07247d37476963 *qemu/macos_x64/OVMF_VARS-1024x768.fd
44
+ 4355a46b19d348dc2f57c046f8ef63d4538ebb936000f3c9ee954a27460dd865 *qemu/macos_x64/VERSION
45
+ 2a247500e8ad9aa479994097ba5976bd881fde4de1516abd14491f3dba9fe060 *qemu/macos_x64/OVMF_CODE.fd
package/test/test.js CHANGED
@@ -572,7 +572,8 @@ async function join(machine, tries) {
572
572
  host: '127.0.0.1',
573
573
  port: machine.info.ssh_port,
574
574
  username: machine.info.username,
575
- password: machine.info.password
575
+ password: machine.info.password,
576
+ tryKeyboard: true
576
577
  });
577
578
 
578
579
  break;
@@ -36,8 +36,7 @@ async function main() {
36
36
  }
37
37
 
38
38
  async function test() {
39
- let lib_filename = path.dirname(__filename) + '/../../build/misc' +
40
- (process.platform == 'win32' ? '.dll' : '.so');
39
+ let lib_filename = path.dirname(__filename) + '/../../build/misc' + koffi.extension;
41
40
  let lib = koffi.load(lib_filename);
42
41
 
43
42
  const FillPack3 = lib.cdecl('FillPack3', 'void', ['int', 'int', 'int', koffi.out(koffi.pointer(Pack3))]);
@@ -83,8 +83,7 @@ async function main() {
83
83
  }
84
84
 
85
85
  async function test() {
86
- let lib_filename = path.dirname(__filename) + '/../../build/raylib' +
87
- (process.platform == 'win32' ? '.dll' : '.so');
86
+ let lib_filename = path.dirname(__filename) + '/../../build/raylib' + koffi.extension;
88
87
  let lib = koffi.load(lib_filename);
89
88
 
90
89
  const InitWindow = lib.cdecl('InitWindow', 'void', ['int', 'int', 'string']);
@@ -36,8 +36,7 @@ async function main() {
36
36
  }
37
37
 
38
38
  async function test() {
39
- let lib_filename = path.dirname(__filename) + '/../../build/sqlite3' +
40
- (process.platform == 'win32' ? '.dll' : '.so');
39
+ let lib_filename = path.dirname(__filename) + '/../../build/sqlite3' + koffi.extension;
41
40
  let lib = koffi.load(lib_filename);
42
41
 
43
42
  const sqlite3_open_v2 = lib.cdecl('sqlite3_open_v2', 'int', ['string', koffi.out(koffi.pointer(sqlite3_db)), 'int', 'string']);
@@ -50,7 +49,7 @@ async function test() {
50
49
  const sqlite3_finalize = lib.cdecl('sqlite3_finalize', 'int', [sqlite3_stmt]);
51
50
  const sqlite3_close_v2 = lib.cdecl('sqlite3_close_v2', 'int', [sqlite3_db]);
52
51
 
53
- let filename = create_temporary_file(path.join(os.tmpdir(), 'test_sqlite'));
52
+ let filename = await create_temporary_file(path.join(os.tmpdir(), 'test_sqlite'));
54
53
  let db = {};
55
54
 
56
55
  try {
@@ -78,7 +77,7 @@ async function test() {
78
77
  }
79
78
  }
80
79
 
81
- function create_temporary_file(prefix) {
80
+ async function create_temporary_file(prefix) {
82
81
  let buf = Buffer.allocUnsafe(4);
83
82
 
84
83
  for (;;) {
@@ -88,7 +87,12 @@ function create_temporary_file(prefix) {
88
87
  let suffix = buf.toString('hex').padStart(8, '0');
89
88
  let filename = `${prefix}.${suffix}`;
90
89
 
91
- let file = fs.createWriteStream(filename, { flags: 'wx', mode: 0o644 });
90
+ let file = await new Promise((resolve, reject) => {
91
+ let file = fs.createWriteStream(filename, { flags: 'wx', mode: 0o644 });
92
+
93
+ file.on('open', () => resolve(file));
94
+ file.on('error', reject);
95
+ });
92
96
  file.close();
93
97
 
94
98
  return filename;
@@ -82,6 +82,7 @@
82
82
  extern char **environ;
83
83
  #endif
84
84
  #ifdef __APPLE__
85
+ #include <sys/random.h>
85
86
  #include <mach-o/dyld.h>
86
87
 
87
88
  #define off64_t off_t
@@ -4295,12 +4296,23 @@ bool NotifySystemd()
4295
4296
  return false;
4296
4297
  }
4297
4298
 
4299
+ #ifdef __APPLE__
4300
+ int fd = socket(AF_UNIX, SOCK_DGRAM, 0);
4301
+ if (fd < 0) {
4302
+ LogError("Failed to create UNIX socket: %1", strerror(errno));
4303
+ return false;
4304
+ }
4305
+ RG_DEFER { close(fd); };
4306
+
4307
+ fcntl(fd, F_SETFD, FD_CLOEXEC);
4308
+ #else
4298
4309
  int fd = socket(AF_UNIX, SOCK_DGRAM | SOCK_CLOEXEC, 0);
4299
4310
  if (fd < 0) {
4300
4311
  LogError("Failed to create UNIX socket: %1", strerror(errno));
4301
4312
  return false;
4302
4313
  }
4303
4314
  RG_DEFER { close(fd); };
4315
+ #endif
4304
4316
 
4305
4317
  struct iovec iov = {};
4306
4318
  struct msghdr msg = {};
@@ -4880,13 +4892,22 @@ int OpenUnixSocket(const char *path, SocketMode mode)
4880
4892
  case SocketMode::Messages: { flags = SOCK_SEQPACKET; } break;
4881
4893
  }
4882
4894
 
4883
- #ifdef _WIN32
4895
+ #if defined(_WIN32)
4884
4896
  SOCKET fd = socket(AF_UNIX, flags, 0);
4885
4897
  if (fd == INVALID_SOCKET) {
4886
4898
  LogError("Failed to create AF_UNIX socket: %1", strerror(errno));
4887
4899
  return -1;
4888
4900
  }
4889
4901
  RG_DEFER_N(err_guard) { closesocket(fd); };
4902
+ #elif defined(__APPLE__)
4903
+ int fd = (int)socket(AF_UNIX, flags, 0);
4904
+ if (fd < 0) {
4905
+ LogError("Failed to create AF_UNIX socket: %1", strerror(errno));
4906
+ return -1;
4907
+ }
4908
+ RG_DEFER_N(err_guard) { close(fd); };
4909
+
4910
+ fcntl(fd, F_SETFD, FD_CLOEXEC);
4890
4911
  #else
4891
4912
  flags |= SOCK_CLOEXEC;
4892
4913
 
@@ -4924,13 +4945,22 @@ int ConnectToUnixSocket(const char *path, SocketMode mode)
4924
4945
  case SocketMode::Messages: { flags = SOCK_SEQPACKET; } break;
4925
4946
  }
4926
4947
 
4927
- #ifdef _WIN32
4948
+ #if defined(_WIN32)
4928
4949
  SOCKET fd = socket(AF_UNIX, flags, 0);
4929
4950
  if (fd == INVALID_SOCKET) {
4930
4951
  LogError("Failed to create AF_UNIX socket: %1", strerror(errno));
4931
4952
  return -1;
4932
4953
  }
4933
4954
  RG_DEFER_N(err_guard) { closesocket(fd); };
4955
+ #elif defined(__APPLE__)
4956
+ int fd = (int)socket(AF_UNIX, flags, 0);
4957
+ if (fd < 0) {
4958
+ LogError("Failed to create AF_UNIX socket: %1", strerror(errno));
4959
+ return -1;
4960
+ }
4961
+ RG_DEFER_N(err_guard) { close(fd); };
4962
+
4963
+ fcntl(fd, F_SETFD, FD_CLOEXEC);
4934
4964
  #else
4935
4965
  flags |= SOCK_CLOEXEC;
4936
4966
 
@@ -35,7 +35,7 @@
35
35
  #include <utility>
36
36
  #if defined(_WIN32)
37
37
  #include <intrin.h>
38
- #elif !defined(__linux__) || defined(__GLIBC__)
38
+ #elif !defined(__APPLE__) && (!defined(__linux__) || defined(__GLIBC__))
39
39
  #define RG_FIBER_USE_UCONTEXT
40
40
  #include <ucontext.h>
41
41
  #else