[Tizen] Support Autoconf 2.71
[platform/upstream/SDL.git] / test / Makefile.os2
1 BINPATH = .
2
3 TARGETS = testatomic.exe testdisplayinfo.exe testbounds.exe testdraw2.exe &
4           testdrawchessboard.exe testdropfile.exe testerror.exe testfile.exe &
5           testfilesystem.exe testgamecontroller.exe testgesture.exe &
6           testhittesting.exe testhotplug.exe testiconv.exe testime.exe testlocale.exe &
7           testintersections.exe testjoystick.exe testkeys.exe testloadso.exe &
8           testlock.exe testmessage.exe testoverlay2.exe testplatform.exe &
9           testpower.exe testsensor.exe testrelative.exe testrendercopyex.exe &
10           testrendertarget.exe testrumble.exe testscale.exe testsem.exe &
11           testshader.exe testshape.exe testsprite2.exe testspriteminimal.exe &
12           teststreaming.exe testthread.exe testtimer.exe testver.exe &
13           testviewport.exe testwm2.exe torturethread.exe checkkeys.exe &
14           controllermap.exe testhaptic.exe testqsort.exe testresample.exe &
15           testaudioinfo.exe testaudiocapture.exe loopwave.exe loopwavequeue.exe &
16           testyuv.exe testgl2.exe testvulkan.exe testnative.exe testautomation.exe
17
18 # SDL2test.lib sources (../src/test)
19
20 CSRCS = SDL_test_assert.c SDL_test_common.c SDL_test_compare.c &
21         SDL_test_crc32.c SDL_test_font.c SDL_test_fuzzer.c SDL_test_harness.c &
22         SDL_test_imageBlit.c SDL_test_imageBlitBlend.c SDL_test_imageFace.c &
23         SDL_test_imagePrimitives.c SDL_test_imagePrimitivesBlend.c &
24         SDL_test_log.c SDL_test_md5.c SDL_test_random.c SDL_test_memory.c
25 TESTLIB = SDL2test.lib
26
27 # testautomation sources
28
29 TASRCS = testautomation.c testautomation_audio.c testautomation_clipboard.c &
30          testautomation_events.c testautomation_hints.c &
31          testautomation_keyboard.c testautomation_main.c &
32          testautomation_mouse.c testautomation_pixels.c &
33          testautomation_platform.c testautomation_rect.c &
34          testautomation_render.c testautomation_rwops.c &
35          testautomation_sdltest.c testautomation_stdlib.c &
36          testautomation_surface.c testautomation_syswm.c &
37          testautomation_timer.c testautomation_video.c
38
39 OBJS = $(TARGETS:.exe=.obj)
40 COBJS = $(CSRCS:.c=.obj)
41 TAOBJS = $(TASRCS:.c=.obj)
42
43 all: $(TARGETS)
44
45 INCPATH = -I$(%WATCOM)/h/os2 -I$(%WATCOM)/h -I../include
46
47 CFLAGS = $(INCPATH) -bt=os2 -d0 -q -bm -5s -fp5 -fpi87 -sg -oteanbmier -ei
48
49 LIBPATH = ..
50 LIBS    = SDL2.lib $(TESTLIB)
51
52 #CFLAGS+= -DHAVE_SDL_TTF
53 #LIBS_TTF = SDL2ttf.lib
54
55 .c: ../src/test
56
57 $(TESTLIB): $(COBJS)
58   wlib -q -b -n -c $@ $(COBJS)
59
60 .obj.exe:
61   @%make $(TESTLIB)
62   wlink SYS os2v2 libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
63
64 .c.obj:
65   wcc386 $(CFLAGS) -fo=$^@ $<
66
67 # specials
68 testautomation.exe: $(TAOBJS)
69   @%make $(TESTLIB)
70   wlink SYS os2v2 libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
71
72 testnative.exe: testnative.obj testnativeos2.obj
73   @%make $(TESTLIB)
74   wlink SYS os2v2 libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
75
76 testoverlay2.exe: testoverlay2.obj testyuv_cvt.obj
77   @%make $(TESTLIB)
78   wlink SYS os2v2 libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
79
80 testyuv.exe: testyuv.obj testyuv_cvt.obj
81   @%make $(TESTLIB)
82   wlink SYS os2v2 libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
83
84 testime.exe: testime.obj
85   @%make $(TESTLIB)
86   wlink SYS os2v2 libpath $(LIBPATH) lib {$(LIBS) $(LIBS_TTF)} op q op el file {$<} name $@
87
88 clean: .SYMBOLIC
89   @echo * Clean tests in $(BINPATH)
90   @if exist *.obj rm *.obj
91   @if exist *.err rm *.err
92
93 distclean: .SYMBOLIC clean
94   @if exist *.exe rm *.exe
95   @if exist $(TESTLIB) rm $(TESTLIB)