Skip to content
Snippets Groups Projects
Commit 47c7d720 authored by Anders Blomdell's avatar Anders Blomdell
Browse files

Some Makefile cleanups.

parent 9ad4ef8a
Branches
Tags
No related merge requests found
......@@ -2,29 +2,30 @@ SUBDIRS=compiler lib test examples
export LABCOMM_JAR=$(shell pwd)/compiler/labcomm_compiler.jar
export LABCOMM=java -jar $(LABCOMM_JAR)
.PHONY: all
all: $(SUBDIRS:%=make-%)
.PHONY: make-%
make-%:
LD_LIBRARY_PATH=`pwd`/lib/c $(MAKE) -C $* -e
LD_LIBRARY_PATH=`pwd`/lib/c $(MAKE) -C $*
.PHONY: test
test: $(SUBDIRS:%=test-%)
.PHONY: test-%
test-%:
LD_LIBRARY_PATH=`pwd`/lib/c $(MAKE) -C $* -e test
LD_LIBRARY_PATH=`pwd`/lib/c $(MAKE) -C $* test
.PHONY: clean
clean: $(SUBDIRS:%=clean-%)
.PHONY: clean-%
clean-%:
$(MAKE) -C $* -e clean
$(MAKE) -C $* clean
.PHONY: distclean
distclean: clean $(SUBDIRS:%=distclean-%)
.PHONY: distclean-%
distclean-%:
$(MAKE) -C $* -e distclean
$(MAKE) -C $* distclean
SUBDIRS=c csharp java python
.PHONY: all
all:
cd c ; make
cd csharp ; make
cd java ; make
all: $(SUBDIRS:%=make-%)
.PHONY: make-%
make-%:
$(MAKE) -C $*
.PHONY: test
test:
$(MAKE) -C c test
test: $(SUBDIRS:%=test-%)
.PHONY: test-%
test-%:
$(MAKE) -C $* test
.PHONY: clean
clean:
$(MAKE) -C c clean
$(MAKE) -C csharp clean
$(MAKE) -C java clean
$(MAKE) -C python clean
clean: $(SUBDIRS:%=clean-%)
.PHONY: clean-%
clean-%:
$(MAKE) -C $* clean
.PHONY: distclean
distclean:
$(MAKE) -C c distclean
$(MAKE) -C csharp distclean
$(MAKE) -C java distclean
$(MAKE) -C python distclean
distclean: clean $(SUBDIRS:%=distclean-%)
.PHONY: distclean-%
distclean-%:
$(MAKE) -C $* distclean
......@@ -10,12 +10,18 @@ MODULES=Constant\
SampleHandler \
SampleType
.PHONY: all
all: labcomm.dll
labcomm.dll: $(MODULES:%=se/lth/control/labcomm/%.cs) Makefile
mcs -out:$@ -target:library $(filter %.cs, $^)
.PHONY: test
test:
.PHONY: clean
clean:
.PHONY: distclean
distclean:
rm -f labcomm.dll
......@@ -18,6 +18,7 @@ MODULES=Constant \
Writer \
WriterWrapper
.PHONY: all
all: labcomm.jar labcomm2014.jar labcomm2006.jar
labcomm.jar: gen/JAVAC
......@@ -45,6 +46,9 @@ gen/JAVAC: $(MODULES:%=se/lth/control/labcomm/%.java) \
touch $@
.PHONY: test
test:
.PHONY: clean
clean:
rm -rf gen
......
.PHONY: all
all:
.PHONY: test
test:
.PHONY: clean
clean:
find . -name '*.pyc' -exec rm {} \;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment