From d118d3b584ee427acc05ae7ee5b062995c0bddb7 Mon Sep 17 00:00:00 2001 From: konrad Date: Fri, 4 Jun 2010 20:48:45 +0000 Subject: [PATCH] add scripting external add scripting to default makefiles git-svn-id: https://silmor.de/svn/softmagic/smoke/trunk@492 6e3c4bff-ac9f-4ac1-96c5-d2ea494d3e33 --- Makefile.mingw | 14 +++++++++++++- Makefile.unix | 16 ++++++++++++++-- 2 files changed, 27 insertions(+), 3 deletions(-) diff --git a/Makefile.mingw b/Makefile.mingw index c22c85e..ae0ef46 100644 --- a/Makefile.mingw +++ b/Makefile.mingw @@ -31,6 +31,9 @@ NOPT = # No editable content below this line ########################################################### +QTDIR=$(shell $(QMAKE) -query QT_INSTALL_PREFIX) +QTBIN=$(shell $(QMAKE) -query QT_INSTALL_BINS) + all: dist wob: woc @@ -54,7 +57,16 @@ qwbase: cd pack/qtbase && $(QMAKE) $(QOPT) cd pack/qtbase && $(MAKE) -dist: client +#script stuff: depends on generated CPP files +script: qtscript/generated_cpp + cd qtscript/qtbindings && $(QMAKE) && $(MAKE) release + +#generated script plugins: depend on Qt version +qtscript/generated_cpp: $(QTBIN)/qmake.exe + cd qtscript/generator && $(QMAKE) && $(MAKE) + cd qtscript/generator && set QTDIR=$(QTDIR) && ./generator + +dist: script client echo !define QTDIR \ >qtpath.nsh $(QMAKE) -query QT_INSTALL_PREFIX >>qtpath.nsh $(NSIS) $(NOPT) smoke.nsi diff --git a/Makefile.unix b/Makefile.unix index cb7157e..fdb9d0e 100644 --- a/Makefile.unix +++ b/Makefile.unix @@ -21,7 +21,10 @@ DOXYGEN = doxygen # No editable content below this line ########################################################### -all: server client +QTDIR=$(shell $(QMAKE) -query QT_INSTALL_PREFIX) +QTBIN=$(shell $(QMAKE) -query QT_INSTALL_BINS) + +all: script server client wob: woc cd wob ; ../pack/woc/woc magicsmoke.wolf @@ -40,6 +43,15 @@ client: wob zip wbase zip: cd zip ; $(QMAKE) && $(MAKE) +#script stuff: depends on generated CPP files +script: qtscript/generated_cpp + cd qtscript/qtbindings && $(QMAKE) && $(MAKE) + +#generated script plugins: depend on Qt version +qtscript/generated_cpp: $(QTBIN)/qmake + cd qtscript/generator && $(QMAKE) && $(MAKE) + cd qtscript/generator && QTDIR=$(QTDIR) ./generator + dist: @echo Distribution not implemented yet @@ -58,4 +70,4 @@ clean: distclean: clean #tell Make that the rules above are symbolic: -.PHONY: woc wob server client sdoc zip wbase clean distclean +.PHONY: script woc wob server client sdoc zip wbase clean distclean -- 1.7.2.5