-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
46 lines (35 loc) · 1.55 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# easy MQTT handler Makefile - Copyright (C) 2023 A. Zeil
NAME=easy_mqtt_handler
# Target to activate venv and install required python libs
activate-venv:
python3 -m venv .venv; \
. .venv/bin/activate; \
./.venv/bin/pip install -r requirements.txt
# Target for housekeeping
clean:
rm -rf build/ dist/ logs/ .venv/ src/$(NAME).dist-info/ src/$(NAME)/__pycache__ src/$(NAME)/locale/templates
find -depth -type d -name "__pycache__" -exec rm -rf {} \;
find -type f -name "*.mo" -exec rm {} \;
# Translation related targets
translation-templates:
mkdir -p ./src/easy_mqtt_handler/locale/templates/
./src/scripts/translation-generate-pots.sh
compile-translations:
./src/scripts/translation-compile-mos.sh
# Target to regenerate icons - only needed if application icon was changed
regenerate-icons:
./src/scripts/regenerate_icon_files.sh
# Target to create a Linux package for the distribution running on the current machine
package: activate-venv
.venv/bin/briefcase package
# Target to build packages for a lot of different Linux distributions
build-all-linux: regenerate-icons compile-translations activate-venv
./src/scripts/build_linux_all.sh
# Target to create an AppImage for Linux
build-linux-appimage: regenerate-icons compile-translations activate-venv
.venv/bin/briefcase build linux appimage
build-linux-flatpak: regenerate-icons compile-translations activate-venv
.venv/bin/briefcase package linux flatpak
# Target to build the MacOS app
build-macos-app: regenerate-icons compile-translations activate-venv
.venv/bin/briefcase build macos app