Search
lxdream.org :: lxdream/test/Makefile.in
lxdream 0.9.1
released Jun 29
Download Now
filename test/Makefile.in
changeset 808:da414654f3fa
prev794:879c5929c7ef
next812:8cc61d5ea1f8
author nkeynes
date Sat Aug 09 09:13:29 2008 +0000 (14 years ago)
permissions -rw-r--r--
last change Add failing test case for the MMU flush-cache case
view annotate diff log raw
     1 srcdir = @srcdir@
     2 top_srcdir = @top_srcdir@
     3 VPATH = @srcdir@
     4 mkdir_p = @mkdir_p@
     6 # host compiler and flags
     7 HOSTCC		= @CC@
     8 HOSTCFLAGS	= @CFLAGS@
    10 SH4CC		= @SHCC@
    11 SH4INC          = -I$(srcdir)/include
    12 SH4CFLAGS	= $(SH4INC) -D_arch_dreamcast -D_arch_sub_pristine \
    13                   -O2 -fno-builtin -fno-strict-aliasing -ml -m4-single-only \
    14                   -fno-optimize-sibling-calls
    15 SH4LD		= @SHLD@
    16 SH4LDFLAGS      = -fno-builtin -fno-strict-aliasing  -ml -m4-single-only \
    17                   -Wl,-T$(srcdir)/dc.x -nostartfiles -nostdlib -L$(srcdir)/lib
    18 SH4LIBS         = -Wl,--start-group -lc -lgcc -lm -Wl,--end-group
    19 SH4OBJCOPY      = @SHOBJCOPY@ -O binary
    21 ARMCC		= @ARMCC@
    22 ARMCFLAGS	= -O2
    23 ARMLD		= @ARMLD@
    24 ARMOBJCOPY	= @ARMOBJCOPY@
    26 RUNTEST		= ../src/lxdream -c $(srcdir)/lxdream.rc -puH -A null
    27 RUNTESTX	= ../src/lxdream -c $(srcdir)/lxdream.rc -xpuH -A null
    29 %.ao: %.c
    30 	$(ARMCC) $(ARMCFLAGS) -o $@ -c $< 
    32 %.ao: %.s
    33 	$(ARMCC) $(ARMCFLAGS) -o $@ -c $< 
    35 %.so: %.c
    36 	$(SH4CC) $(SH4CFLAGS) -o $@ -c $< 
    38 %.so: %.ac
    39 	$(SH4CC) $(SH4CFLAGS) -o $@ -c $< 
    41 %.so: %.s
    42 	$(SH4CC) $(SH4CFLAGS) -o $@ -c $< -Wa,-I$(srcdir)
    44 %.so: %.S
    45 	$(SH4CC) $(SH4CFLAGS) -o $@ -c $< 
    47 %.o: %.c
    48 	$(HOSTCC) $(HOSTCFLAGS) -o $@ -c $<
    50 %.arm: %.ao arm_crt0.ao
    51 	$(ARMCC) -Wl,-Ttext,0x00000000 -nostartfiles -nostdlib -e reset -o $@ arm_crt0.ao $< -lgcc
    54 %.bin: %.arm
    55 	$(ARMOBJCOPY) -O binary $< $@
    57 %.aso: %.bin bin2c
    58 	./bin2c $< $<.c
    59 	$(SH4CC) $(SH4CFLAGS) -o $@ -c $<.c
    61 all:
    63 check: build-tests
    64 	$(RUNTEST) testsh4
    65 	$(RUNTESTX) testsh4
    66 	$(RUNTEST) testmmu
    67 	$(RUNTEST) testregs
    68 	cat $(srcdir)/testta.data $(srcdir)/testta2.data $(srcdir)/testta3.data $(srcdir)/testta4.data $(srcdir)/testta5.data | $(RUNTEST) testta
    69 	cat $(srcdir)/testsort.data | $(RUNTEST) testta
    70 #	$(RUNTEST) testide -d ../disc/test.nrg
    73 build-tests: testsh4 testmath testide testta testregs testrend testdisp testspu testmmu
    75 testsh4: crt0.so sh4/testsh4.so timer.so interrupt.so \
    76 	 sh4/add.so sh4/addc.so sh4/addv.so sh4/and.so sh4/andi.so \
    77 	 sh4/bf.so sh4/bsr.so sh4/bt.so sh4/cmp.so sh4/cmpstr.so \
    78 	 sh4/div0.so sh4/div1.so sh4/float.so sh4/fmov.so sh4/ftrc.so \
    79 	 sh4/mac.so \
    80 	 sh4/rot.so sh4/shl.so sh4/shld.so sh4/sub.so sh4/subc.so \
    81 	 sh4/trapa.so sh4/tas.so sh4/xtrct.so \
    82 	 sh4/excslot.so sh4/undef.so sh4/tlb.so sh4/vmexit.so
    83 	$(SH4CC) $(SH4LDFLAGS) $^ -o $@ $(SH4LIBS)
    84 	$(SH4OBJCOPY) testsh4 testsh4.bin
    86 testide: crt0.so testide.so ide.so lib.so testdata.so
    87 	$(SH4CC) $(SH4LDFLAGS) $^ -o $@ $(SH4LIBS)
    88 	$(SH4OBJCOPY) testide testide.bin
    90 testmmu: crt0.so testmmu.so lib.so 
    91 	$(SH4CC) $(SH4LDFLAGS) $^ -o $@ $(SH4LIBS)
    92 	$(SH4OBJCOPY) testmmu testmmu.bin
    94 testmath: crt0.so $(SHARED_OBJECTS) testmath.so math.so
    95 	$(SH4CC) $(SH4LDFLAGS) $^  -o $@ $(SH4LIBS)
    97 testregs: crt0.so $(SHARED_OBJECTS) testregs.so ide.so
    98 	$(SH4CC) $(SH4LDFLAGS) $^  -o $@ $(SH4LIBS)
    99 	$(SH4OBJCOPY) testregs testregs.bin
   101 testta: crt0.so $(SHARED_OBJECTS) testta.so pvr.so dmac.so asic.so lib.so testdata.so
   102 	$(SH4CC) $(SH4LDFLAGS) $^  -o $@ $(SH4LIBS)
   103 	$(SH4OBJCOPY) testta testta.bin
   105 testrend: crt0.so $(SHARED_OBJECTS) testrend.so pvr.so dmac.so asic.so lib.so testdata.so
   106 	$(SH4CC) $(SH4LDFLAGS) $^  -o $@ $(SH4LIBS)
   107 	$(SH4OBJCOPY) testrend testrend.bin
   109 testblend: crt0.so $(SHARED_OBJECTS) testblend.so pvr.so dmac.so asic.so lib.so testdata.so
   110 	$(SH4CC) $(SH4LDFLAGS) $^  -o $@ $(SH4LIBS)
   111 	$(SH4OBJCOPY) testblend testblend.bin
   113 testdisp: crt0.so $(SHARED_OBJECTS) testdisp.so pvr.so asic.so lib.so testdata.so timer.so
   114 	$(SH4CC) $(SH4LDFLAGS) $^  -o $@ $(SH4LIBS)
   115 	$(SH4OBJCOPY) testdisp testdisp.bin
   117 testyuv: crt0.so $(SHARED_OBJECTS) testyuv.so pvr.so asic.so lib.so testdata.so timer.so dmac.so
   118 	$(SH4CC) $(SH4LDFLAGS) $^  -o $@ $(SH4LIBS)
   119 	$(SH4OBJCOPY) testyuv testyuv.bin
   121 testspu: crt0.so $(SHARED_OBJECTS) testspu.so asic.so lib.so testdata.so timer.so dmac.so
   122 	$(SH4CC) $(SH4LDFLAGS) $^  -o $@ $(SH4LIBS)
   123 	$(SH4OBJCOPY) testspu testspu.bin
   125 testg2: crt0.so $(SHARED_OBJECTS) testg2.so asic.so lib.so testdata.so timer.so dmac.so
   126 	$(SH4CC) $(SH4LDFLAGS) $^  -o $@ $(SH4LIBS)
   127 	$(SH4OBJCOPY) testg2 testg2.bin
   129 readdata: crt0.so readdata.so
   130 	$(SH4CC) $(SH4LDFLAGS) $^ -o $@ $(SH4LIBS)
   132 rend: crt0.so rendload.so asic.so lib.so timer.so pvr.so
   133 	$(SH4CC) $(SH4LDFLAGS) $^ -o $@ $(SH4LIBS)
   134 	$(SH4OBJCOPY) rend rend.bin
   136 testFF10: crt0.so testFF10.so lib.so
   137 	$(SH4CC) $(SH4LDFLAGS) $^  -o $@ $(SH4LIBS)
   138 	$(SH4OBJCOPY) testFF10 testFF10.bin
   140 .PHONY : clean
   141 clean:
   142 	rm -f *.o *.so *.ao *.ac *.bin sh4/*.so mapleid ide readmem dumpasic \
   143 	   testsh4 testta testdisp testregs testide testmath testmmu \
   144 	   testrend testspu dcflash.rom
   146 distclean: clean
   147 	rm -f Makefile
   149 install:
   151 installcheck:
   153 uninstall:
   155 DISTFILES = asic.c asic.h bin2c.c crt0.s dma.h dmac.c ide.c ide.h interrupt.s \
   156         lib.c lib.h math.s pvr.c pvr.h rendload.c sh4/add.s sh4/addc.s \
   157         sh4/addv.s sh4/and.s sh4/andi.s sh4/bf.s sh4/bsr.s sh4/bt.s sh4/cmp.s \
   158         sh4/cmpstr.s sh4/div0.s sh4/div1.s sh4/excslot.s sh4/float.s sh4/fmov.s \
   159         sh4/ftrc.s sh4/inc.s sh4/mac.s sh4/rot.s sh4/shl.s sh4/shld.s sh4/sub.s \
   160         sh4/subc.s sh4/tas.s sh4/testsh4.c sh4/tlb.s sh4/vmexit.s sh4/trapa.s sh4/undef.s \
   161         sh4/xtrct.s testdata.c testdata.h testdisp.c testide.c testmath.c \
   162         testmmu.c testregs.c testrend.c testspu.c testta.c testyuv.c timer.c timer.h \
   163         testta.data testta2.data testta3.data testta4.data testta5.data testsort.data \
   164         lxdream.rc dc.x lib/libc.a lib/libm.a lib/newlib-1.8.2-dc.patch \
   165 	include/_ansi.h include/_syslist.h include/ar.h include/assert.h include/ctype.h \
   166 	include/dirent.h include/errno.h include/fastmath.h include/fcntl.h include/grp.h \
   167 	include/ieeefp.h include/locale.h include/machine/fastmath.h include/machine/ieeefp.h \
   168 	include/machine/setjmp-dj.h include/machine/setjmp.h include/machine/time.h \
   169 	include/machine/types.h include/malloc.h include/math.h include/paths.h \
   170 	include/process.h include/pwd.h include/reent.h include/regdef.h include/setjmp.h \
   171 	include/signal.h include/stdio.h include/stdlib.h include/string.h include/sys/_types.h \
   172 	include/sys/config.h include/sys/dirent.h include/sys/errno.h include/sys/fcntl.h \
   173 	include/sys/file.h include/sys/param.h include/sys/reent.h include/sys/resource.h \
   174 	include/sys/signal.h include/sys/stat-dj.h include/sys/stat.h include/sys/time.h \
   175 	include/sys/timeb.h include/sys/times.h include/sys/types.h include/sys/unistd.h \
   176 	include/sys/utime.h include/sys/wait.h include/termios.h include/time.h \
   177 	include/unctrl.h include/unistd.h include/utime.h include/utmp.h
   181 distdir:
   182 	$(mkdir_p) $(distdir)/sh4 $(distdir)/lib $(distdir)/include
   183 	@srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
   184 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \
   185 	list='$(DISTFILES)'; for file in $$list; do \
   186 	  case $$file in \
   187 	    $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
   188 	    $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \
   189 	  esac; \
   190 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
   191 	  dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \
   192 	  if test "$$dir" != "$$file" && test "$$dir" != "."; then \
   193 	    dir="/$$dir"; \
   194 	    $(mkdir_p) "$(distdir)$$dir"; \
   195 	  else \
   196 	    dir=''; \
   197 	  fi; \
   198 	  if test -d $$d/$$file; then \
   199 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
   200 	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
   201 	    fi; \
   202 	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
   203 	  else \
   204 	    test -f $(distdir)/$$file \
   205 	    || cp -p $$d/$$file $(distdir)/$$file \
   206 	    || exit 1; \
   207 	  fi; \
   208 	done
   210 dvi:
.