2021-08-02 17:27:27 -07:00
|
|
|
VERSION_STR := $(shell python -c 'import comictaggerlib._version; print( comictaggerlib._version.version)')
|
2018-01-17 13:35:10 -08:00
|
|
|
|
|
|
|
ifeq ($(OS),Windows_NT)
|
|
|
|
APP_NAME=comictagger.exe
|
2020-08-14 22:15:52 -07:00
|
|
|
FINAL_NAME=ComicTagger-$(VERSION_STR).exe
|
2021-08-02 17:27:27 -07:00
|
|
|
ICON_PATH="windows/app.ico"
|
2018-01-17 13:35:10 -08:00
|
|
|
else ifeq ($(shell uname -s),Darwin)
|
|
|
|
APP_NAME=ComicTagger.app
|
2020-08-14 22:15:52 -07:00
|
|
|
FINAL_NAME=ComicTagger-$(VERSION_STR).app
|
2021-08-02 17:27:27 -07:00
|
|
|
ICON_PATH="mac/app.icns"
|
2018-01-17 13:35:10 -08:00
|
|
|
else
|
|
|
|
APP_NAME=comictagger
|
|
|
|
FINAL_NAME=ComicTagger-$(VERSION_STR)
|
2021-08-02 17:27:27 -07:00
|
|
|
ICON_PATH="windows/app.ico"
|
2018-01-17 13:35:10 -08:00
|
|
|
endif
|
|
|
|
|
2021-08-02 17:27:27 -07:00
|
|
|
.PHONY: all clean pydist upload dist
|
2018-01-17 13:35:10 -08:00
|
|
|
|
|
|
|
all: clean dist
|
2012-11-29 21:30:37 -08:00
|
|
|
|
|
|
|
clean:
|
2013-02-06 23:04:23 -08:00
|
|
|
rm -rf *~ *.pyc *.pyo
|
2013-02-14 17:05:35 -08:00
|
|
|
rm -rf scripts/*.pyc
|
2013-02-07 21:38:14 -08:00
|
|
|
cd comictaggerlib; rm -f *~ *.pyc *.pyo
|
|
|
|
rm -rf dist MANIFEST
|
2013-02-07 13:34:00 -08:00
|
|
|
rm -rf *.deb
|
2013-02-06 23:04:23 -08:00
|
|
|
rm -rf logdict*.log
|
2018-01-14 07:41:27 -08:00
|
|
|
$(MAKE) -C mac clean
|
2013-02-07 21:38:14 -08:00
|
|
|
rm -rf build
|
2018-09-19 13:05:39 -07:00
|
|
|
rm -rf comictaggerlib/ui/__pycache__
|
2013-01-24 22:13:33 -08:00
|
|
|
|
2013-02-06 21:21:07 -08:00
|
|
|
pydist:
|
2018-09-19 13:05:39 -07:00
|
|
|
make clean
|
|
|
|
mkdir -p piprelease
|
|
|
|
rm -f comictagger-$(VERSION_STR).zip
|
2013-02-07 17:14:04 -08:00
|
|
|
python setup.py sdist --formats=zip #,gztar
|
2018-09-19 13:05:39 -07:00
|
|
|
mv dist/comictagger-$(VERSION_STR).zip piprelease
|
|
|
|
rm -rf comictagger.egg-info dist
|
2013-02-07 21:38:14 -08:00
|
|
|
|
2013-02-07 17:14:04 -08:00
|
|
|
upload:
|
2014-04-18 08:42:05 -07:00
|
|
|
python setup.py register
|
2014-03-23 15:28:03 -07:00
|
|
|
python setup.py sdist --formats=zip upload
|
2013-02-06 11:13:07 -08:00
|
|
|
|
2021-08-02 17:27:27 -07:00
|
|
|
dist:
|
|
|
|
pyinstaller.exe --name="comictagger" --windowed --add-data 'comictaggerlib/ui/*.ui;ui' --add-data 'comictaggerlib/graphics;graphics' -i windows/app.ico --version-file file_version_info.py comictagger.py
|
2020-08-14 22:15:52 -07:00
|
|
|
mv dist/$(APP_NAME) dist/$(FINAL_NAME)
|