test/Makefile.in
author Andreas Schiffler <aschiffler@ferzkopp.net>
Wed, 26 Dec 2012 22:26:44 -0800
changeset 6773 5ebc5a9e35b4
parent 6772 5229a117ef97
child 6785 c094c438c0a6
permissions -rw-r--r--
Add surface test suite; minor improvements to render suite; refactor image saving into test lib compare function; fix for Haiku build
     1 # Makefile to build the SDL tests
     2 
     3 srcdir  = @srcdir@
     4 
     5 CC      = @CC@
     6 EXE	= @EXE@
     7 CFLAGS  = @CFLAGS@
     8 LIBS	= @LIBS@
     9 
    10 TARGETS = \
    11 	checkkeys$(EXE) \
    12 	loopwave$(EXE) \
    13 	testaudioinfo$(EXE) \
    14 	testautomation$(EXE) \
    15 	testdraw2$(EXE) \
    16 	testerror$(EXE) \
    17 	testfile$(EXE) \
    18 	testgamecontroller$(EXE) \
    19 	testgesture$(EXE) \
    20 	testgl2$(EXE) \
    21 	testgles$(EXE) \
    22 	testhaptic$(EXE) \
    23 	testrumble$(EXE) \
    24 	testthread$(EXE) \
    25 	testiconv$(EXE) \
    26 	testime$(EXE) \
    27 	testintersections$(EXE) \
    28 	testrelative$(EXE) \
    29 	testjoystick$(EXE) \
    30 	testkeys$(EXE) \
    31 	testloadso$(EXE) \
    32 	testlock$(EXE) \
    33 	testmultiaudio$(EXE) \
    34 	testnative$(EXE) \
    35 	testoverlay2$(EXE) \
    36 	testplatform$(EXE) \
    37 	testpower$(EXE) \
    38 	testrendertarget$(EXE) \
    39 	testresample$(EXE) \
    40 	testscale$(EXE) \
    41 	testsem$(EXE) \
    42 	testshader$(EXE) \
    43 	testshape$(EXE) \
    44 	testsprite2$(EXE) \
    45 	testspriteminimal$(EXE) \
    46 	teststreaming$(EXE) \
    47 	testtimer$(EXE) \
    48 	testver$(EXE) \
    49 	testwm2$(EXE) \
    50 	torturethread$(EXE) \
    51 	testrendercopyex$(EXE) \
    52 	testmessage$(EXE) \
    53 
    54 all: Makefile $(TARGETS)
    55 
    56 Makefile: $(srcdir)/Makefile.in
    57 	$(SHELL) config.status $@
    58 
    59 checkkeys$(EXE): $(srcdir)/checkkeys.c
    60 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
    61 
    62 loopwave$(EXE): $(srcdir)/loopwave.c
    63 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
    64 
    65 testresample$(EXE): $(srcdir)/testresample.c
    66 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
    67 
    68 testaudioinfo$(EXE): $(srcdir)/testaudioinfo.c
    69 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
    70 
    71 testautomation$(EXE): $(srcdir)/testautomation.c \
    72 		      $(srcdir)/testautomation_clipboard.c \
    73 		      $(srcdir)/testautomation_platform.c \
    74 		      $(srcdir)/testautomation_rect.c \
    75 		      $(srcdir)/testautomation_render.c \
    76 		      $(srcdir)/testautomation_rwops.c \
    77 		      $(srcdir)/testautomation_audio.c \
    78 		      $(srcdir)/testautomation_surface.c
    79 	$(CC) -o $@ $^ $(CFLAGS) -lSDL2_test $(LIBS) 
    80 
    81 testmultiaudio$(EXE): $(srcdir)/testmultiaudio.c
    82 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
    83 
    84 testatomic$(EXE): $(srcdir)/testatomic.c
    85 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
    86 
    87 testintersections$(EXE): $(srcdir)/testintersections.c $(srcdir)/common.c
    88 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
    89 
    90 testrelative$(EXE): $(srcdir)/testrelative.c $(srcdir)/common.c
    91 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
    92 
    93 testdraw2$(EXE): $(srcdir)/testdraw2.c $(srcdir)/common.c
    94 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
    95 
    96 testerror$(EXE): $(srcdir)/testerror.c
    97 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
    98 
    99 testfile$(EXE): $(srcdir)/testfile.c
   100 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   101 
   102 testgamecontroller$(EXE): $(srcdir)/testgamecontroller.c
   103 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   104  
   105 testgesture$(EXE): $(srcdir)/testgesture.c
   106 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS) @MATHLIB@
   107  
   108 testgl2$(EXE): $(srcdir)/testgl2.c $(srcdir)/common.c
   109 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS) @GLLIB@ @MATHLIB@
   110 
   111 testgles$(EXE): $(srcdir)/testgles.c $(srcdir)/common.c
   112 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS) @GLLIB@ @MATHLIB@
   113 
   114 testhaptic$(EXE): $(srcdir)/testhaptic.c
   115 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   116 
   117 testrumble$(EXE): $(srcdir)/testrumble.c
   118 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   119 
   120 testthread$(EXE): $(srcdir)/testthread.c
   121 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   122 
   123 testiconv$(EXE): $(srcdir)/testiconv.c
   124 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   125 
   126 testime$(EXE): $(srcdir)/testime.c $(srcdir)/common.c
   127 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS) @SDL_TTF_LIB@
   128 
   129 testjoystick$(EXE): $(srcdir)/testjoystick.c $(srcdir)/common.c
   130 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   131 
   132 testkeys$(EXE): $(srcdir)/testkeys.c
   133 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   134 
   135 testloadso$(EXE): $(srcdir)/testloadso.c
   136 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   137 
   138 testlock$(EXE): $(srcdir)/testlock.c
   139 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   140 
   141 ifeq (@ISMACOSX@,true)
   142 testnative$(EXE): $(srcdir)/testnative.c \
   143 			$(srcdir)/testnativecocoa.m \
   144 			$(srcdir)/testnativew32.c \
   145 			$(srcdir)/testnativex11.c
   146 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS) -L/usr/X11/lib -lX11 -framework Cocoa
   147 endif
   148 
   149 ifeq (@ISWINDOWS@,true)
   150 testnative$(EXE): $(srcdir)/testnative.c \
   151 			$(srcdir)/testnativew32.c
   152 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   153 endif
   154 
   155 ifeq (@ISUNIX@,true)
   156 testnative$(EXE): $(srcdir)/testnative.c \
   157 			$(srcdir)/testnativex11.c
   158 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS) -L/usr/X11/lib -lX11
   159 endif
   160 
   161 testoverlay2$(EXE): $(srcdir)/testoverlay2.c
   162 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   163 
   164 testplatform$(EXE): $(srcdir)/testplatform.c
   165 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   166 
   167 testpower$(EXE): $(srcdir)/testpower.c
   168 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   169 
   170 testrendertarget$(EXE): $(srcdir)/testrendertarget.c $(srcdir)/common.c
   171 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   172 
   173 testscale$(EXE): $(srcdir)/testscale.c $(srcdir)/common.c
   174 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   175 
   176 testsem$(EXE): $(srcdir)/testsem.c
   177 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   178 
   179 testshader$(EXE): $(srcdir)/testshader.c
   180 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS) @GLLIB@ @MATHLIB@
   181 
   182 testshape$(EXE): $(srcdir)/testshape.c
   183 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   184 
   185 testsprite2$(EXE): $(srcdir)/testsprite2.c $(srcdir)/common.c
   186 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS) @MATHLIB@
   187 
   188 testspriteminimal$(EXE): $(srcdir)/testspriteminimal.c
   189 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS) @MATHLIB@
   190 
   191 teststreaming$(EXE): $(srcdir)/teststreaming.c
   192 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS) @MATHLIB@
   193 
   194 testtimer$(EXE): $(srcdir)/testtimer.c
   195 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   196 
   197 testver$(EXE): $(srcdir)/testver.c
   198 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   199 
   200 testwm2$(EXE): $(srcdir)/testwm2.c $(srcdir)/common.c
   201 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   202 
   203 torturethread$(EXE): $(srcdir)/torturethread.c
   204 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   205 
   206 testrendercopyex$(EXE): $(srcdir)/testrendercopyex.c $(srcdir)/common.c
   207 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS) @MATHLIB@
   208 
   209 testmessage$(EXE): $(srcdir)/testmessage.c
   210 	$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
   211 
   212 clean:
   213 	rm -f $(TARGETS)
   214 
   215 distclean: clean
   216 	rm -f Makefile
   217 	rm -f config.status config.cache config.log
   218 	rm -rf $(srcdir)/autom4te*