From: mrdudz Date: Tue, 25 Nov 2014 11:56:45 +0000 (+0100) Subject: use 'testwrk' dir for bdiff X-Git-Tag: V2.15~29^2~5 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=9c03326360d2f8bc374b3a519a7529714bf0acb5;p=cc65 use 'testwrk' dir for bdiff --- diff --git a/.gitignore b/.gitignore index 1d5928af7..196cdc3d7 100644 --- a/.gitignore +++ b/.gitignore @@ -8,5 +8,6 @@ /mou/ /ser/ /targetutil/ +/testwrk/ /tgi/ /wrk/ diff --git a/test/Makefile b/test/Makefile index f5f10c029..be0360c41 100644 --- a/test/Makefile +++ b/test/Makefile @@ -8,21 +8,28 @@ ifneq ($(shell echo),) endif ifdef CMD_EXE -RM := del /f -EXE := .exe + RM := del /f + EXE := .exe + MKDIR = mkdir else -RM := rm -f -EXE := + RM := rm -f + EXE := + MKDIR = mkdir -p endif +WORKDIR := ../testwrk + .PHONY: dotests clean all: dotests -bdiff: - @$(CC) -o bdiff$(EXE) bdiff.c +$(WORKDIR): + @$(MKDIR) $(WORKDIR) + +$(WORKDIR)/bdiff$(EXE): $(WORKDIR) + @$(CC) -o $(WORKDIR)/bdiff$(EXE) bdiff.c -dotests: bdiff +dotests: $(WORKDIR)/bdiff$(EXE) @$(MAKE) -C val clean all @$(MAKE) -C ref clean all @$(MAKE) -C err clean all @@ -33,4 +40,4 @@ clean: @$(MAKE) -C ref clean @$(MAKE) -C err clean @$(MAKE) -C misc clean - @$(RM) bdiff$(EXE) + @$(RM) $(WORKDIR)/bdiff$(EXE) diff --git a/test/err/Makefile b/test/err/Makefile index 3ced60bc8..fd18bf752 100644 --- a/test/err/Makefile +++ b/test/err/Makefile @@ -15,6 +15,8 @@ else RM := rm -f endif +WORKDIR := ./../../testwrk + .PHONY: all clean TESTS := $(patsubst %.c,%.prg,$(wildcard *.c)) diff --git a/test/misc/Makefile b/test/misc/Makefile index e3d60269d..43cb6f576 100644 --- a/test/misc/Makefile +++ b/test/misc/Makefile @@ -17,7 +17,9 @@ else RM := rm -f endif -DIFF := ./../bdiff +WORKDIR := ./../../testwrk + +DIFF := $(WORKDIR)/bdiff .PHONY: all clean diff --git a/test/ref/Makefile b/test/ref/Makefile index ccb52c3ba..a8d87c4c3 100644 --- a/test/ref/Makefile +++ b/test/ref/Makefile @@ -18,7 +18,9 @@ else RM := rm -f endif -DIFF := ./../bdiff +WORKDIR := ./../../testwrk + +DIFF := $(WORKDIR)/bdiff CFLAGS := -O2 -Wall -W -Wextra -fwrapv -fno-strict-overflow diff --git a/test/val/Makefile b/test/val/Makefile index e4841bd35..6a40feb61 100644 --- a/test/val/Makefile +++ b/test/val/Makefile @@ -17,6 +17,8 @@ else RM := rm -f endif +WORKDIR := ./../../testwrk + .PHONY: all clean TESTS := $(patsubst %.c,%.prg,$(wildcard *.c))