Add vecinit.r to the test-suite.

Ugh, I really need to take time out to do compile tests properly.
This commit is contained in:
Bill Currie 2012-12-10 21:09:53 +09:00
parent 3aa3a0945a
commit aeed16109f
2 changed files with 24 additions and 1 deletions

View file

@ -4,7 +4,7 @@ INCLUDES= -I$(top_srcdir)/include $(QFCC_INCS)
QFCC_DEP=$(builddir)/../source/qfcc$(EXEEXT)
QFCC=$(QFCC_DEP)
QCFLAGS=-qq -O -g --no-default-paths
QCFLAGS=-qq -O -g --no-default-paths -Werror
QCPPFLAGS=
QCOMPILE=$(QFCC) $(QCFLAGS) $(QCPPFLAGS)
@ -26,6 +26,7 @@ test_progs_dat=\
infloop.dat \
modulo.dat \
structptr.dat \
vecinit.dat \
while.dat
fail_progs_dat=\
@ -89,6 +90,13 @@ structptr.dat: $(structptr_obj) $(QFCC_DEP)
structptr.run: Makefile build-run
$(srcdir)/build-run $@
vecinit_dat_SOURCES=vecinit.r
vecinit_obj=$(vecinit_dat_SOURCES:.r=.qfo)
vecinit.dat: $(vecinit_obj) $(QFCC_DEP)
$(QFCC) $(QCFLAGS) -o $@ $(vecinit_obj)
vecinit.run: Makefile build-run
$(srcdir)/build-run $@
while_dat_SOURCES=while.r
while_obj=$(while_dat_SOURCES:.r=.qfo)
while.dat: $(while_obj) $(QFCC_DEP)

15
tools/qfcc/test/vecinit.r Normal file
View file

@ -0,0 +1,15 @@
vector
foo (float x, float y, float z)
{
vector v;
v.x = x;
v.y = y;
v.z = z;
return v;
}
int
main ()
{
return 0;
}