diff --git a/plugins/Makefile b/plugins/Makefile index 8521dd445..6cd8d09fe 100644 --- a/plugins/Makefile +++ b/plugins/Makefile @@ -1,14 +1,28 @@ -all: hud irc +all: ezscript hud irc -.PHONY: all hud irc +clean: ezscript-clean hud-clean irc-clean + +.PHONY: all ezscript hud irc help: @-echo make a subdirectory +ezscript: + $(MAKE) -C ezscript + +ezscript-clean: + $(MAKE) clean -C ezscript + hud: $(MAKE) -C hud +hud-clean: + $(MAKE) clean -C hud + irc: $(MAKE) -C irc +irc-clean: + $(MAKE) clean -C irc + diff --git a/plugins/ezscript/Makefile b/plugins/ezscript/Makefile index ef2fd2484..6f99df7bb 100644 --- a/plugins/ezscript/Makefile +++ b/plugins/ezscript/Makefile @@ -1,8 +1,12 @@ DO_CC=$(CC) -ggdb -fPIC -Wall $(CFLAGS) -o $@ -c $< OBJECTS=ezscript.o plugin.o qvm_api.o HEADERS=../plugin.h +OUTFILE=../ezscriptx86.so all: $(OBJECTS) - $(CC) -ggdb -fPIC -shared $(OBJECTS) -o ../ezscriptx86.so + $(CC) -ggdb -fPIC -shared $(OBJECTS) -o $(OUTFILE) + +clean: + rm -rf $(OBJECTS) $(OUTFILE) ezscript.o: ezscript.c $(HEADERS) $(DO_CC) diff --git a/plugins/hud/Makefile b/plugins/hud/Makefile index 917bc5096..b017b9950 100644 --- a/plugins/hud/Makefile +++ b/plugins/hud/Makefile @@ -1,9 +1,12 @@ - DO_CC=$(CC) -ggdb -fPIC -Wall $(CFLAGS) -o $@ -c $< OBJECTS=ui_sbar.o plugin.o qvm_api.o HEADERS=../plugin.h +OUTFILE=../hudx86.so all: $(OBJECTS) - $(CC) -ggdb -fPIC -shared $(OBJECTS) -o ../hudx86.so + $(CC) -ggdb -fPIC -shared $(OBJECTS) -o $(OUTFILE) + +clean: + rm -rf $(OBJECTS) $(OUTFILE) ui_sbar.o: ui_sbar.c $(HEADERS) $(DO_CC) diff --git a/plugins/irc/Makefile b/plugins/irc/Makefile index 3967ecb4c..57f52d41d 100644 --- a/plugins/irc/Makefile +++ b/plugins/irc/Makefile @@ -1,9 +1,12 @@ - DO_CC=$(CC) -fPIC $(CFLAGS) -o $@ -c $< OBJECTS=ircclient.o plugin.o qvm_api.o HEADERS=../plugin.h +OUTFILE=../ircx86.so all: $(OBJECTS) - gcc --shared -ldl $(OBJECTS) -o ../ircx86.so + gcc --shared -ldl $(OBJECTS) -o $(OUTFILE) + +clean: + rm -rf $(OBJECTS) $(OUTFILE) ircclient.o: ircclient.c $(HEADERS) $(DO_CC)