2012-11-14 17:25:01 -08:00
|
|
|
# This Makefile expects that certain GNU utils are available:
|
|
|
|
# rm, cp, grep, cut, cat
|
|
|
|
|
2013-02-07 21:38:14 -08:00
|
|
|
HOMEPATH ?= $(HOME)
|
|
|
|
TAGGER_BASE:= $(HOMEPATH)/Dropbox/tagger/comictagger
|
|
|
|
TAGGER_SRC := $(TAGGER_BASE)/comictaggerlib
|
2012-11-12 22:04:57 -08:00
|
|
|
DIST_DIR := $(TAGGER_BASE)\windows\dist
|
|
|
|
NSIS_CMD := "C:\Program Files (x86)\NSIS\makensis.exe"
|
2013-02-07 21:38:14 -08:00
|
|
|
VERSION := $(shell grep version "$(TAGGER_SRC)/ctversion.py" | cut -d= -f2)
|
2012-11-12 22:04:57 -08:00
|
|
|
|
2012-11-14 17:25:01 -08:00
|
|
|
all: clean dist package
|
2012-11-12 22:04:57 -08:00
|
|
|
|
2012-11-14 17:25:01 -08:00
|
|
|
dist:
|
2012-11-12 22:04:57 -08:00
|
|
|
cd "$(TAGGER_BASE)" &
|
2013-02-06 20:50:10 -08:00
|
|
|
"C:\Python27\Scripts\cxfreeze.bat" $(TAGGER_BASE)\comictagger.py --icon nsis\app.ico
|
2012-11-19 11:57:49 -08:00
|
|
|
#--base-name=Win32GUI
|
2012-11-12 22:04:57 -08:00
|
|
|
cp -R C:\Python27\Lib\site-packages\PyQt4\plugins\imageformats $(DIST_DIR)
|
2013-02-06 20:50:10 -08:00
|
|
|
cp "$(TAGGER_SRC)\UnRAR2\UnRARDLL\unrar.dll" $(DIST_DIR)
|
|
|
|
cp -r "$(TAGGER_SRC)\ui" $(DIST_DIR)
|
|
|
|
cp -r "$(TAGGER_SRC)\graphics" $(DIST_DIR)
|
2012-11-12 22:04:57 -08:00
|
|
|
|
|
|
|
rm "$(DIST_DIR)\QtWebKit4.dll"
|
|
|
|
rm "$(DIST_DIR)\PyQt4.QtWebKit.pyd"
|
|
|
|
|
2012-11-14 17:25:01 -08:00
|
|
|
package:
|
|
|
|
echo !define RELEASE_STR $(VERSION) > $(TAGGER_BASE)\windows\nsis\release.nsh
|
2012-11-12 22:04:57 -08:00
|
|
|
$(NSIS_CMD) "$(TAGGER_BASE)\windows\nsis\comictagger.nsi"
|
2013-02-08 14:14:18 -08:00
|
|
|
mkdir -p "$(TAGGER_BASE)\release"
|
2012-11-29 21:30:03 -08:00
|
|
|
mv "$(TAGGER_BASE)\windows\nsis\ComicTagger*.exe" "$(TAGGER_BASE)\release"
|
2012-11-12 22:04:57 -08:00
|
|
|
|
|
|
|
clean:
|
2012-11-14 17:25:01 -08:00
|
|
|
-rm -rf dist
|
2013-02-08 14:07:38 -08:00
|
|
|
-rm -rf nsis/release.nsh
|