From db9e62aa52fe611d28a168ebbce4c454e349830c Mon Sep 17 00:00:00 2001 From: Xavier Leroy Date: Sat, 26 Aug 2017 10:10:38 +0200 Subject: test/: add a CCOMPOPTS make variable to pass additional compile-time flags E.g. "-Os" for testing in "optimize for size" mode, or "-mthumb" for testing ARM in Thumb2 mode. --- test/Makefile | 2 +- test/compression/Makefile | 2 +- test/raytracer/Makefile | 2 +- test/regression/Makefile | 2 +- test/spass/Makefile | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/test/Makefile b/test/Makefile index 5e9e0555..6e9a78d8 100644 --- a/test/Makefile +++ b/test/Makefile @@ -1,7 +1,7 @@ DIRS=c compression raytracer spass regression all: - for i in $(DIRS); do $(MAKE) -C $$i all; done + for i in $(DIRS); do $(MAKE) CCOMPOPTS='$(CCOMPOPTS)' -C $$i all; done test: set -e; for i in $(DIRS); do $(MAKE) SIMU='$(SIMU)' -C $$i test; done diff --git a/test/compression/Makefile b/test/compression/Makefile index fa73f0e6..4c5207f6 100644 --- a/test/compression/Makefile +++ b/test/compression/Makefile @@ -1,7 +1,7 @@ include ../../Makefile.config CC=../../ccomp -CFLAGS=-U__GNUC__ -stdlib ../../runtime -dclight -dasm +CFLAGS=$(CCOMPOPTS) -U__GNUC__ -stdlib ../../runtime -dclight -dasm LIBS= TIME=xtime -o /dev/null -mintime 1.0 diff --git a/test/raytracer/Makefile b/test/raytracer/Makefile index c481ff86..8f6541a1 100644 --- a/test/raytracer/Makefile +++ b/test/raytracer/Makefile @@ -1,7 +1,7 @@ include ../../Makefile.config CC=../../ccomp -CFLAGS=-stdlib ../../runtime -dparse -dclight -dasm -fstruct-return +CFLAGS=$(CCOMPOPTS) -stdlib ../../runtime -dparse -dclight -dasm -fstruct-return LIBS=$(LIBMATH) TIME=xtime diff --git a/test/regression/Makefile b/test/regression/Makefile index 25b47c7e..fd34bb1b 100644 --- a/test/regression/Makefile +++ b/test/regression/Makefile @@ -1,7 +1,7 @@ include ../../Makefile.config CCOMP=../../ccomp -CCOMPFLAGS=-stdlib ../../runtime -dparse -dc -dclight -dasm -fall +CCOMPFLAGS=$(CCOMPOPTS) -stdlib ../../runtime -dparse -dc -dclight -dasm -fall LIBS=$(LIBMATH) diff --git a/test/spass/Makefile b/test/spass/Makefile index 110359ad..0e89d6d1 100644 --- a/test/spass/Makefile +++ b/test/spass/Makefile @@ -1,7 +1,7 @@ include ../../Makefile.config CC=../../ccomp -CFLAGS=-stdlib ../../runtime -dparse -dclight -dasm -fstruct-return +CFLAGS=$(CCOMPOPTS) -stdlib ../../runtime -dparse -dclight -dasm -fstruct-return SRCS=analyze.c clause.c clock.c closure.c cnf.c component.c \ condensing.c context.c defs.c dfgparser.c dfgscanner.c doc-proof.c \ -- cgit