summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorSean Cross <sean@xobs.io>2019-10-19 12:36:14 +0800
committerEddie Hung <eddie@fpgeh.com>2020-05-01 08:25:53 -0700
commit11c4f998b25b6c07f4081cea10e2532ebcb7f4d4 (patch)
treed211e5ba2a5190d70a9f042499d5f28040b42cf5 /Makefile
parent54763e6882fc88d12fadfcd7df1b40d52b8f9beb (diff)
downloadabc-11c4f998b25b6c07f4081cea10e2532ebcb7f4d4.tar.gz
abc-11c4f998b25b6c07f4081cea10e2532ebcb7f4d4.tar.bz2
abc-11c4f998b25b6c07f4081cea10e2532ebcb7f4d4.zip
Makefile: break apart steps in `make clean`
The `make clean` target consists of a single `rm` call that passes every generated file, object file, and dependency directory. This results in a command line that's around 53,800 characters long. On Linux, the maximum length of a command line is 131,072 or 262,144 characters, however on Windows the limit is 32,768. The 53,800 character command simply fails to run on Windows, which is a problem when the first command that gets run is `make clean`. Break this target into steps, first removing the output files, then the object files, then any generated garbage, and then the object depedency directories. This fixes `make clean` (and as a result yosys) on Windows. Signed-off-by: Sean Cross <sean@xobs.io>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile5
1 files changed, 4 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 583bc25b..641cd6ac 100644
--- a/Makefile
+++ b/Makefile
@@ -206,7 +206,10 @@ depend: $(DEP)
clean:
@echo "$(MSG_PREFIX)\`\` Cleaning up..."
- $(VERBOSE)rm -rvf $(PROG) lib$(PROG).a $(OBJ) $(GARBAGE) $(OBJ:.o=.d)
+ $(VERBOSE)rm -rvf $(PROG) lib$(PROG).a
+ $(VERBOSE)rm -rvf $(OBJ)
+ $(VERBOSE)rm -rvf $(GARBAGE)
+ $(VERBOSE)rm -rvf $(OBJ:.o=.d)
tags:
etags `find . -type f -regex '.*\.\(c\|h\)'`