test/Makefile.in
author Ryan C. Gordon <icculus@icculus.org>
Thu, 09 Aug 2012 14:28:45 -0400
changeset 6390 3047baa4a5e0
parent 6320 6077a1310907
child 6412 628702b5d490
permissions -rw-r--r--
Nasty attempt to fix building of testnative across various platforms.

The world longs for a hero named CMake.
slouken@1380
     1
# Makefile to build the SDL tests
slouken@1380
     2
slouken@1380
     3
srcdir  = @srcdir@
slouken@1380
     4
slouken@1380
     5
CC      = @CC@
slouken@1380
     6
EXE	= @EXE@
slouken@1380
     7
CFLAGS  = @CFLAGS@
slouken@1380
     8
LIBS	= @LIBS@
slouken@1380
     9
slouken@5232
    10
TARGETS = \
slouken@5232
    11
	checkkeys$(EXE) \
slouken@5232
    12
	loopwave$(EXE) \
slouken@5232
    13
	testdraw2$(EXE) \
slouken@5232
    14
	testerror$(EXE) \
slouken@5232
    15
	testfile$(EXE) \
slouken@5232
    16
	testgesture$(EXE) \
slouken@5232
    17
	testgl2$(EXE) \
slouken@5232
    18
	testgles$(EXE) \
slouken@5232
    19
	testhaptic$(EXE) \
slouken@5508
    20
	testrumble$(EXE) \
slouken@5508
    21
	testthread$(EXE) \
slouken@5232
    22
	testiconv$(EXE) \
slouken@5232
    23
	testime$(EXE) \
slouken@5232
    24
	testintersections$(EXE) \
slouken@6311
    25
	testrelative$(EXE) \
slouken@5232
    26
	testjoystick$(EXE) \
slouken@5232
    27
	testkeys$(EXE) \
slouken@5232
    28
	testloadso$(EXE) \
slouken@5232
    29
	testlock$(EXE) \
slouken@5232
    30
	testmultiaudio$(EXE) \
slouken@6175
    31
	testnative$(EXE) \
slouken@5232
    32
	testoverlay2$(EXE) \
slouken@5232
    33
	testplatform$(EXE) \
slouken@5232
    34
	testpower$(EXE) \
slouken@6232
    35
	testrendertarget$(EXE) \
slouken@5232
    36
	testresample$(EXE) \
slouken@5240
    37
	testscale$(EXE) \
slouken@5232
    38
	testsem$(EXE) \
slouken@5232
    39
	testshader$(EXE) \
slouken@5232
    40
	testshape$(EXE) \
slouken@5232
    41
	testsprite2$(EXE) \
slouken@5232
    42
	testspriteminimal$(EXE) \
slouken@5254
    43
	teststreaming$(EXE) \
slouken@5232
    44
	testtimer$(EXE) \
slouken@5232
    45
	testver$(EXE) \
slouken@5232
    46
	testwm2$(EXE) \
slouken@5232
    47
	torturethread$(EXE) \
gabomdq@6320
    48
	testrendercopyex$(EXE) \
slouken@1380
    49
slouken@1914
    50
all: Makefile $(TARGETS)
slouken@1914
    51
slouken@1914
    52
Makefile: $(srcdir)/Makefile.in
slouken@1914
    53
	$(SHELL) config.status $@
slouken@1380
    54
slouken@1380
    55
checkkeys$(EXE): $(srcdir)/checkkeys.c
slouken@1380
    56
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1380
    57
slouken@1380
    58
loopwave$(EXE): $(srcdir)/loopwave.c
slouken@1380
    59
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1380
    60
icculus@3017
    61
testresample$(EXE): $(srcdir)/testresample.c
icculus@3017
    62
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
icculus@3017
    63
icculus@2049
    64
testaudioinfo$(EXE): $(srcdir)/testaudioinfo.c
icculus@2049
    65
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
icculus@2049
    66
icculus@2049
    67
testmultiaudio$(EXE): $(srcdir)/testmultiaudio.c
icculus@2049
    68
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
icculus@2049
    69
slouken@5254
    70
testatomic$(EXE): $(srcdir)/testatomic.c
slouken@5254
    71
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@5254
    72
slouken@2994
    73
testintersections$(EXE): $(srcdir)/testintersections.c $(srcdir)/common.c
slouken@2994
    74
	$(CC) -o $@ $(srcdir)/testintersections.c $(srcdir)/common.c $(CFLAGS) $(LIBS)
slouken@2994
    75
slouken@6311
    76
testrelative$(EXE): $(srcdir)/testrelative.c $(srcdir)/common.c
slouken@6311
    77
	$(CC) -o $@ $(srcdir)/testrelative.c $(srcdir)/common.c $(CFLAGS) $(LIBS)
slouken@6311
    78
slouken@2914
    79
testdraw2$(EXE): $(srcdir)/testdraw2.c $(srcdir)/common.c
slouken@2914
    80
	$(CC) -o $@ $(srcdir)/testdraw2.c $(srcdir)/common.c $(CFLAGS) $(LIBS)
slouken@2914
    81
slouken@1380
    82
testerror$(EXE): $(srcdir)/testerror.c
slouken@1380
    83
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1380
    84
slouken@1453
    85
testfile$(EXE): $(srcdir)/testfile.c
slouken@1453
    86
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1453
    87
slouken@5254
    88
testgesture$(EXE): $(srcdir)/testgesture.c
slouken@1380
    89
	$(CC) -o $@ $? $(CFLAGS) $(LIBS) @MATHLIB@
slouken@5254
    90
 
slouken@1915
    91
testgl2$(EXE): $(srcdir)/testgl2.c $(srcdir)/common.c
slouken@1915
    92
	$(CC) -o $@ $(srcdir)/testgl2.c $(srcdir)/common.c $(CFLAGS) $(LIBS) @GLLIB@ @MATHLIB@
slouken@1914
    93
slouken@3087
    94
testgles$(EXE): $(srcdir)/testgles.c $(srcdir)/common.c
slouken@3087
    95
	$(CC) -o $@ $(srcdir)/testgles.c $(srcdir)/common.c $(CFLAGS) $(LIBS) @GLLIB@ @MATHLIB@
slouken@3087
    96
slouken@5254
    97
testhaptic$(EXE): $(srcdir)/testhaptic.c
slouken@5254
    98
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@5254
    99
slouken@5360
   100
testrumble$(EXE): $(srcdir)/testrumble.c
slouken@5360
   101
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@5360
   102
slouken@5508
   103
testthread$(EXE): $(srcdir)/testthread.c
slouken@1380
   104
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1380
   105
slouken@1501
   106
testiconv$(EXE): $(srcdir)/testiconv.c
slouken@1501
   107
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1501
   108
dimitris@6318
   109
testime$(EXE): $(srcdir)/testime.c $(srcdir)/common.c
dimitris@6318
   110
	$(CC) -o $@ $(srcdir)/testime.c $(srcdir)/common.c $(CFLAGS) $(LIBS) @SDL_TTF_LIB@
slouken@5254
   111
slouken@1380
   112
testjoystick$(EXE): $(srcdir)/testjoystick.c
slouken@1380
   113
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1380
   114
slouken@1380
   115
testkeys$(EXE): $(srcdir)/testkeys.c
slouken@1380
   116
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1380
   117
slouken@5254
   118
testloadso$(EXE): $(srcdir)/testloadso.c
slouken@5254
   119
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@5254
   120
slouken@1380
   121
testlock$(EXE): $(srcdir)/testlock.c
slouken@1380
   122
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1380
   123
icculus@6390
   124
ifeq (@ISMACOSX@,true)
slouken@6175
   125
testnative$(EXE): $(srcdir)/testnative.c \
slouken@6175
   126
			$(srcdir)/testnativecocoa.m \
slouken@6175
   127
			$(srcdir)/testnativew32.c \
slouken@6175
   128
			$(srcdir)/testnativex11.c
slouken@6175
   129
	$(CC) -o $@ $? $(CFLAGS) $(LIBS) -L/usr/X11/lib -lX11 -framework Cocoa
icculus@6390
   130
endif
icculus@6390
   131
icculus@6390
   132
ifeq (@ISWINDOWS@,true)
icculus@6390
   133
testnative$(EXE): $(srcdir)/testnative.c \
icculus@6390
   134
			$(srcdir)/testnativew32.c
icculus@6390
   135
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
icculus@6390
   136
endif
icculus@6390
   137
icculus@6390
   138
ifeq (@ISUNIX@,true)
icculus@6390
   139
testnative$(EXE): $(srcdir)/testnative.c \
icculus@6390
   140
			$(srcdir)/testnativex11.c
icculus@6390
   141
	$(CC) -o $@ $? $(CFLAGS) $(LIBS) -L/usr/X11/lib -lX11
icculus@6390
   142
endif
slouken@6175
   143
slouken@1380
   144
testoverlay2$(EXE): $(srcdir)/testoverlay2.c
slouken@1380
   145
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1380
   146
slouken@1421
   147
testplatform$(EXE): $(srcdir)/testplatform.c
slouken@1421
   148
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1421
   149
slouken@5254
   150
testpower$(EXE): $(srcdir)/testpower.c
slouken@5254
   151
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@5254
   152
slouken@6232
   153
testrendertarget$(EXE): $(srcdir)/testrendertarget.c $(srcdir)/common.c
slouken@6232
   154
	$(CC) -o $@ $(srcdir)/testrendertarget.c $(srcdir)/common.c $(CFLAGS) $(LIBS)
slouken@6232
   155
slouken@5240
   156
testscale$(EXE): $(srcdir)/testscale.c $(srcdir)/common.c
slouken@5240
   157
	$(CC) -o $@ $(srcdir)/testscale.c $(srcdir)/common.c $(CFLAGS) $(LIBS)
slouken@5240
   158
slouken@1380
   159
testsem$(EXE): $(srcdir)/testsem.c
slouken@1380
   160
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1380
   161
slouken@5232
   162
testshader$(EXE): $(srcdir)/testshader.c
slouken@5232
   163
	$(CC) -o $@ $(srcdir)/testshader.c $(CFLAGS) $(LIBS) @GLLIB@ @MATHLIB@
slouken@5232
   164
eligottlieb@4799
   165
testshape$(EXE): $(srcdir)/testshape.c
eligottlieb@4799
   166
	$(CC) -o $@ $? -std=c99 $(CFLAGS) $(LIBS)
eligottlieb@4799
   167
slouken@1914
   168
testsprite2$(EXE): $(srcdir)/testsprite2.c $(srcdir)/common.c
slouken@1914
   169
	$(CC) -o $@ $(srcdir)/testsprite2.c $(srcdir)/common.c $(CFLAGS) $(LIBS) @MATHLIB@
slouken@1895
   170
slouken@5254
   171
testspriteminimal$(EXE): $(srcdir)/testspriteminimal.c
slouken@5254
   172
	$(CC) -o $@ $? $(CFLAGS) $(LIBS) @MATHLIB@
slouken@5254
   173
slouken@5254
   174
teststreaming$(EXE): $(srcdir)/teststreaming.c
slouken@5254
   175
	$(CC) -o $@ $? $(CFLAGS) $(LIBS) @MATHLIB@
slouken@5254
   176
slouken@1380
   177
testtimer$(EXE): $(srcdir)/testtimer.c
slouken@1380
   178
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1380
   179
slouken@1380
   180
testver$(EXE): $(srcdir)/testver.c
slouken@1380
   181
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1380
   182
slouken@1933
   183
testwm2$(EXE): $(srcdir)/testwm2.c $(srcdir)/common.c
slouken@1933
   184
	$(CC) -o $@ $(srcdir)/testwm2.c $(srcdir)/common.c $(CFLAGS) $(LIBS)
slouken@1895
   185
slouken@1380
   186
torturethread$(EXE): $(srcdir)/torturethread.c
slouken@1380
   187
	$(CC) -o $@ $? $(CFLAGS) $(LIBS)
slouken@1380
   188
gabomdq@6320
   189
testrendercopyex$(EXE): $(srcdir)/testrendercopyex.c $(srcdir)/common.c
gabomdq@6320
   190
	$(CC) -o $@ $(srcdir)/testrendercopyex.c $(srcdir)/common.c $(CFLAGS) $(LIBS) @MATHLIB@
gabomdq@6320
   191
	
slouken@1380
   192
clean:
slouken@1380
   193
	rm -f $(TARGETS)
slouken@1380
   194
slouken@1380
   195
distclean: clean
slouken@1380
   196
	rm -f Makefile
slouken@1380
   197
	rm -f config.status config.cache config.log
slouken@1380
   198
	rm -rf $(srcdir)/autom4te*