minor update to Makefile.os2, added a test/Makefile.os2.
2.1 --- a/Makefile.os2 Mon Nov 19 21:35:59 2018 -0800
2.2 +++ b/Makefile.os2 Tue Nov 20 10:55:00 2018 +0300
2.3 @@ -25,7 +25,7 @@
2.4 CFLAGS+= -bd
2.5 # the include paths :
2.6 CFLAGS+= $(INCPATH)
2.7 -# building SDL itself:
2.8 +# building SDL itself (for DECLSPEC):
2.9 CFLAGS+= -DBUILD_SDL
2.10
2.11 MSRCS= e_atan2.c e_exp.c e_fmod.c e_log10.c e_log.c e_pow.c e_rem_pio2.c e_sqrt.c &
3.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
3.2 +++ b/test/Makefile.os2 Tue Nov 20 10:55:00 2018 +0300
3.3 @@ -0,0 +1,91 @@
3.4 +BINPATH = .
3.5 +
3.6 +TARGETS = testatomic.exe testdisplayinfo.exe testbounds.exe testdraw2.exe &
3.7 + testdrawchessboard.exe testdropfile.exe testerror.exe testfile.exe &
3.8 + testfilesystem.exe testgamecontroller.exe testgesture.exe &
3.9 + testhittesting.exe testhotplug.exe testiconv.exe testime.exe &
3.10 + testintersections.exe testjoystick.exe testkeys.exe testloadso.exe &
3.11 + testlock.exe testmessage.exe testoverlay2.exe testplatform.exe &
3.12 + testpower.exe testsensor.exe testrelative.exe testrendercopyex.exe &
3.13 + testrendertarget.exe testrumble.exe testscale.exe testsem.exe &
3.14 + testshader.exe testshape.exe testsprite2.exe testspriteminimal.exe &
3.15 + teststreaming.exe testthread.exe testtimer.exe testver.exe &
3.16 + testviewport.exe testwm2.exe torturethread.exe checkkeys.exe &
3.17 + controllermap.exe testhaptic.exe testqsort.exe testresample.exe &
3.18 + testaudioinfo.exe testaudiocapture.exe loopwave.exe loopwavequeue.exe &
3.19 + testyuv.exe testgl2.exe testvulkan.exe testautomation.exe
3.20 +
3.21 +# SDL2test.lib sources (../src/test)
3.22 +
3.23 +CSRCS = SDL_test_assert.c SDL_test_common.c SDL_test_compare.c &
3.24 + SDL_test_crc32.c SDL_test_font.c SDL_test_fuzzer.c SDL_test_harness.c &
3.25 + SDL_test_imageBlit.c SDL_test_imageBlitBlend.c SDL_test_imageFace.c &
3.26 + SDL_test_imagePrimitives.c SDL_test_imagePrimitivesBlend.c &
3.27 + SDL_test_log.c SDL_test_md5.c SDL_test_random.c SDL_test_memory.c
3.28 +TESTLIB = SDL2test.lib
3.29 +
3.30 +# testautomation sources
3.31 +
3.32 +TASRCS = testautomation.c testautomation_audio.c testautomation_clipboard.c &
3.33 + testautomation_events.c testautomation_hints.c &
3.34 + testautomation_keyboard.c testautomation_main.c &
3.35 + testautomation_mouse.c testautomation_pixels.c &
3.36 + testautomation_platform.c testautomation_rect.c &
3.37 + testautomation_render.c testautomation_rwops.c &
3.38 + testautomation_sdltest.c testautomation_stdlib.c &
3.39 + testautomation_surface.c testautomation_syswm.c &
3.40 + testautomation_timer.c testautomation_video.c
3.41 +
3.42 +OBJS = $(TARGETS:.exe=.obj)
3.43 +COBJS = $(CSRCS:.c=.obj)
3.44 +TAOBJS = $(TASRCS:.c=.obj)
3.45 +
3.46 +all: $(TARGETS)
3.47 +
3.48 +INCPATH = -I$(%WATCOM)/h/os2 -I$(%WATCOM)/h -I../include
3.49 +
3.50 +CFLAGS = $(INCPATH) -bt=os2 -d0 -q -bm -5s -fp5 -fpi87 -sg -oteanbmier -ei
3.51 +
3.52 +LIBPATH = ..
3.53 +LIBS = SDL2.lib $(TESTLIB)
3.54 +
3.55 +#CFLAGS+= -DHAVE_SDL_TTF
3.56 +#LIBS_TTF = SDL2ttf.lib
3.57 +
3.58 +.c: ../src/test
3.59 +
3.60 +$(TESTLIB): $(COBJS)
3.61 + wlib -q -b -n $@ $(COBJS)
3.62 +
3.63 +.obj.exe:
3.64 + @%make $(TESTLIB)
3.65 + wlink SYS os2v2 libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
3.66 +
3.67 +.c.obj:
3.68 + wcc386 $(CFLAGS) -wcd=107 -fo=$^@ $<
3.69 +
3.70 +# specials
3.71 +testautomation.exe: $(TAOBJS)
3.72 + @%make $(TESTLIB)
3.73 + wlink SYS os2v2 libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
3.74 +
3.75 +testoverlay2.exe: testoverlay2.obj testyuv_cvt.obj
3.76 + @%make $(TESTLIB)
3.77 + wlink SYS os2v2 libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
3.78 +
3.79 +testyuv.exe: testyuv.obj testyuv_cvt.obj
3.80 + @%make $(TESTLIB)
3.81 + wlink SYS os2v2 libpath $(LIBPATH) lib {$(LIBS)} op q op el file {$<} name $@
3.82 +
3.83 +testime.exe: testime.obj
3.84 + @%make $(TESTLIB)
3.85 + wlink SYS os2v2 libpath $(LIBPATH) lib {$(LIBS) $(LIBS_TTF)} op q op el file {$<} name $@
3.86 +
3.87 +clean: .SYMBOLIC
3.88 + @echo * Clean tests in $(BINPATH)
3.89 + @if exist *.obj rm *.obj
3.90 + @if exist *.err rm *.err
3.91 +
3.92 +distclean: .SYMBOLIC clean
3.93 + @if exist *.exe rm *.exe
3.94 + @if exist $(TESTLIB) rm $(TESTLIB)