Jon West | 7d88140 | 2021-04-15 08:42:42 -0400 | [diff] [blame] | 1 | DESTDIR?=/ |
| 2 | |
| 3 | purge_pycache: |
| 4 | @find -name '__pycache__' | xargs rm -rf |
| 5 | |
| 6 | install: purge_pycache |
| 7 | python3 setup.py install --prefix=/usr --root=$(DESTDIR) |
| 8 | |
| 9 | ubuntu_install: purge_pycache |
| 10 | python3 setup.py install --prefix=/usr --root=$(DESTDIR) --no-compile |
| 11 | |
| 12 | uninstall: |
| 13 | $(eval DAEMONPATH := $(shell find $(DESTDIR)/usr/lib/python3* -maxdepth 2 -name "razer")) |
| 14 | $(eval EGGPATH := $(shell readlink -f $(DAEMONPATH)-*.egg-info/)) # shows an error when it's not already installed (maybe use some if condition) |
| 15 | @rm -v -rf $(DAEMONPATH) |
| 16 | @rm -v -rf $(EGGPATH) |