diff options
| author | klaar36 <klas.arvidsson@liu.se> | 2015-03-20 17:30:24 +0100 |
|---|---|---|
| committer | klaar36 <klas.arvidsson@liu.se> | 2015-03-20 17:30:24 +0100 |
| commit | e7bc50ca8ffcaa6ed68ebd2315f78b0f5a7d10ad (patch) | |
| tree | 4de97af7207676b69cb6a9aba8cb443cc134855d /src/Makefile | |
| parent | b0418a24e709f0632d2ede5b0f327c422931939b (diff) | |
| download | pintos-rs-e7bc50ca8ffcaa6ed68ebd2315f78b0f5a7d10ad.tar.gz | |
Initial Pintos
Diffstat (limited to 'src/Makefile')
| -rw-r--r-- | src/Makefile | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/src/Makefile b/src/Makefile new file mode 100644 index 0000000..551f654 --- /dev/null +++ b/src/Makefile @@ -0,0 +1,47 @@ +BUILD_SUBDIRS = threads userprog vm filesys + +all:: + @echo "Run 'make' in subdirectories: $(BUILD_SUBDIRS)." + @echo "This top-level make has only 'clean' targets." + +CLEAN_SUBDIRS = $(BUILD_SUBDIRS) examples utils + +clean:: + for d in $(CLEAN_SUBDIRS); do $(MAKE) -C $$d $@; done + rm -f TAGS tags + +distclean:: clean + find . -name '*~' -exec rm '{}' \; + find . -name 'fs.dsk' -exec rm '{}' \; + +TAGS_SUBDIRS = $(BUILD_SUBDIRS) devices lib +TAGS_SOURCES = find $(TAGS_SUBDIRS) -name \*.[chS] -print + +TAGS:: + etags --members `$(TAGS_SOURCES)` + +tags:: + ctags -T --no-warn `$(TAGS_SOURCES)` + +cscope.files:: + $(TAGS_SOURCES) > cscope.files + +cscope:: cscope.files + cscope -b -q -k + +SKEL_SRC = $(shell find . -name '*.[ch]' -exec /usr/xpg4/bin/egrep -q '//--*\[ .*\]--*//' {} \; -print) + +skel:: TAGS + @for i in $(SKEL_SRC); do \ + echo "Processing $$i"; \ + mv $$i $$i~~; \ + /home/klaar/bin/strip $$i~~ $$i; \ + done + +REVERT = $(subst ~~,,$(shell find . -name '*~~')) + +revert:: + @for i in $(REVERT); do \ + echo "Processing $$i"; \ + mv $$i~~ $$i; \ + done |
