🛠️🐜 Antkeeper superbuild with dependencies included https://antkeeper.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

122 lines
4.0 KiB

  1. INCPATH+= -I"../include"
  2. LIBPATH = ..
  3. LIBS = SDL2.lib SDL2test.lib testutils.lib
  4. #CFLAGS+= -DHAVE_SDL_TTF
  5. #TTFLIBS = SDL2ttf.lib
  6. CFLAGS+= $(INCPATH)
  7. TARGETS = testatomic.exe testdisplayinfo.exe testbounds.exe testdraw2.exe &
  8. testdrawchessboard.exe testdropfile.exe testerror.exe testfile.exe &
  9. testfilesystem.exe testgamecontroller.exe testgeometry.exe testgesture.exe &
  10. testhittesting.exe testhotplug.exe testiconv.exe testime.exe testlocale.exe &
  11. testintersections.exe testjoystick.exe testkeys.exe testloadso.exe &
  12. testlock.exe testmessage.exe testoverlay2.exe testplatform.exe &
  13. testpower.exe testsensor.exe testrelative.exe testrendercopyex.exe &
  14. testrendertarget.exe testrumble.exe testscale.exe testsem.exe &
  15. testshader.exe testshape.exe testsprite2.exe testspriteminimal.exe &
  16. teststreaming.exe testthread.exe testtimer.exe testver.exe &
  17. testviewport.exe testwm2.exe torturethread.exe checkkeys.exe &
  18. checkkeysthreads.exe testmouse.exe testgles.exe testgles2.exe &
  19. controllermap.exe testhaptic.exe testqsort.exe testresample.exe &
  20. testaudioinfo.exe testaudiocapture.exe loopwave.exe loopwavequeue.exe &
  21. testsurround.exe testyuv.exe testgl2.exe testvulkan.exe testnative.exe &
  22. testautomation.exe testaudiohotplug.exe testcustomcursor.exe testmultiaudio.exe &
  23. testoffscreen.exe testurl.exe
  24. noninteractive = &
  25. testatomic.exe &
  26. testerror.exe &
  27. testfilesystem.exe &
  28. testkeys.exe &
  29. testlocale.exe &
  30. testplatform.exe &
  31. testpower.exe &
  32. testqsort.exe &
  33. testthread.exe &
  34. testtimer.exe &
  35. testver.exe
  36. needs_audio = &
  37. testaudioinfo.exe &
  38. testsurround.exe
  39. needs_display = &
  40. testbounds.exe &
  41. testdisplayinfo.exe
  42. TESTS = $(noninteractive) $(needs_audio) $(needs_display)
  43. # testautomation sources
  44. TASRCS = testautomation.c &
  45. testautomation_audio.c testautomation_clipboard.c &
  46. testautomation_events.c testautomation_guid.c &
  47. testautomation_hints.c testautomation_joystick.c &
  48. testautomation_keyboard.c testautomation_main.c &
  49. testautomation_math.c testautomation_mouse.c &
  50. testautomation_pixels.c testautomation_platform.c &
  51. testautomation_rect.c testautomation_render.c &
  52. testautomation_rwops.c testautomation_sdltest.c &
  53. testautomation_stdlib.c testautomation_surface.c &
  54. testautomation_syswm.c testautomation_timer.c &
  55. testautomation_video.c
  56. OBJS = $(TARGETS:.exe=.obj)
  57. COBJS = $(CSRCS:.c=.obj)
  58. TAOBJS = $(TASRCS:.c=.obj)
  59. TNOBJS = $(TNSRCS:.c=.obj)
  60. all: testutils.lib $(TARGETS)
  61. .c: ../src/test
  62. .obj.exe:
  63. wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
  64. .c.obj:
  65. wcc386 $(CFLAGS) -fo=$^@ $<
  66. # specials
  67. testvulkan.obj: testvulkan.c
  68. # new vulkan headers result in lots of W202 warnings
  69. wcc386 $(CFLAGS) -wcd=202 -fo=$^@ $<
  70. testautomation.exe: $(TAOBJS)
  71. wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
  72. testnative.exe: $(TNOBJS)
  73. wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
  74. testoverlay2.exe: testoverlay2.obj testyuv_cvt.obj
  75. wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
  76. testyuv.exe: testyuv.obj testyuv_cvt.obj
  77. wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
  78. testshader.exe: testshader.obj
  79. wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS) $(GLLIBS)} op q op el file {$<} name $@
  80. testime.exe: testime.obj
  81. wlink SYS $(SYSTEM) libpath $(LIBPATH) lib {$(LIBS) $(TTFLIBS)} op q op el file {$<} name $@
  82. testutils.lib: testutils.obj
  83. wlib -q -b -n -c -pa -s -t -zld -ii -io $@ $<
  84. check: .SYMBOLIC $(TESTS)
  85. @set SDL_AUDIODRIVER=dummy
  86. @set SDL_VIDEODRIVER=dummy
  87. @copy "../SDL2.dll" .
  88. @for %exe in ($(TESTS)) do %exe
  89. check-quick: .SYMBOLIC $(TESTS)
  90. @set SDL_TESTS_QUICK=1
  91. @set SDL_AUDIODRIVER=dummy
  92. @set SDL_VIDEODRIVER=dummy
  93. @copy "../SDL2.dll" .
  94. @for %exe in ($(TESTS)) do %exe
  95. clean: .SYMBOLIC
  96. rm -f *.obj *.err
  97. distclean: .SYMBOLIC clean
  98. rm -f *.exe *.lib