diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2015-01-01 07:49:13 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2015-01-01 07:49:13 -0800 |
commit | 5094b36f533907335a301877254a01beeab668f0 (patch) | |
tree | 597b7cf07b6287a8cca2749969a3d2cfce227e78 /Makefile | |
parent | 99c41ec1654df41ab027c18559227254d976e59a (diff) | |
download | txr-5094b36f533907335a301877254a01beeab668f0.tar.gz txr-5094b36f533907335a301877254a01beeab668f0.tar.bz2 txr-5094b36f533907335a301877254a01beeab668f0.zip |
* Makefile (rebuild, clean, repatch): Fail these targets if
the program is not configured.
(distclean): Providing alternative implementation when the
program is not configured.
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 17 |
1 files changed, 13 insertions, 4 deletions
@@ -185,23 +185,32 @@ $(call EACH_CONF,txr.o): CFLAGS += -DTXR_VER=\"$(txr_ver)\" $(call EACH_CONF,$(MPI_OBJS)): CFLAGS += -DXMALLOC=chk_malloc -DXREALLOC=chk_realloc $(call EACH_CONF,$$(MPI_OBJS)): CFLAGS += -DXCALLOC=chk_calloc -DXFREE=free -.PHONY: rebuild +.PHONY: rebuild clean repatch distclean + +ifeq ($(PROG),) +rebuild clean repatch: notconfigured + +distclean: + $(V)echo "executing generic cleanup for non-configured directory" + rm -f txr txr.exe txr-dbg txr-dbg.exe y.tab.c lex.yy.c y.tab.h y.output + rm -rf config + rm -rf config.* + rm -rf mpi-1.?.? +else rebuild: clean repatch $(PROG) -.PHONY: clean clean: conftest.clean tests.clean rm -f $(PROG)$(EXE) $(PROG)-dbg$(EXE) y.tab.c lex.yy.c y.tab.h y.output rm -rf opt dbg -.PHONY: repatch repatch: cd mpi-$(mpi_version); quilt pop -af cd mpi-$(mpi_version); quilt push -a -.PHONY: distclean distclean: clean rm -rf $(conf_dir) rm -rf mpi-$(mpi_version) +endif TESTS_TMP := txr.test.out TESTS_OUT := $(addprefix tst/,\ |