qutebrowser/misc/Makefile

36 lines
1.4 KiB
Makefile
Raw Normal View History

2017-11-21 10:35:11 +01:00
PYTHON = python3
PREFIX ?= /usr/local
2017-11-21 10:35:11 +01:00
ICONSIZES = 16 24 32 48 64 128 256 512
DATAROOTDIR = $(PREFIX)/share
DATADIR ?= $(DATAROOTDIR)
MANDIR ?= $(DATAROOTDIR)/man
2017-11-21 10:35:11 +01:00
2018-04-16 13:44:22 +02:00
SETUPTOOLSOPTIONS =
ifdef DESTDIR
SETUPTOOLSOPTS = --root="$(DESTDIR)"
endif
2017-11-21 10:35:11 +01:00
.PHONY: install
doc/qutebrowser.1.html:
a2x -f manpage doc/qutebrowser.1.asciidoc
install: doc/qutebrowser.1.html
2018-04-16 13:44:22 +02:00
$(PYTHON) setup.py install --prefix="$(PREFIX)" --optimize=1 $(SETUPTOOLSOPTS)
install -Dm644 misc/org.qutebrowser.qutebrowser.appdata.xml \
"$(DESTDIR)$(DATADIR)/metainfo/org.qutebrowser.qutebrowser.appdata.xml"
2017-11-21 10:35:11 +01:00
install -Dm644 doc/qutebrowser.1 \
"$(DESTDIR)$(MANDIR)/man1/qutebrowser.1"
2019-02-26 09:55:29 +01:00
install -Dm644 misc/org.qutebrowser.qutebrowser.desktop \
"$(DESTDIR)$(DATADIR)/applications/org.qutebrowser.qutebrowser.desktop"
2017-11-21 10:35:11 +01:00
$(foreach i,$(ICONSIZES),install -Dm644 "icons/qutebrowser-$(i)x$(i).png" \
"$(DESTDIR)$(DATADIR)/icons/hicolor/$(i)x$(i)/apps/qutebrowser.png";)
2017-11-21 10:35:11 +01:00
install -Dm644 icons/qutebrowser.svg \
"$(DESTDIR)$(DATADIR)/icons/hicolor/scalable/apps/qutebrowser.svg"
install -Dm755 -t "$(DESTDIR)$(DATADIR)/qutebrowser/userscripts/" \
2017-11-21 10:35:11 +01:00
$(wildcard misc/userscripts/*)
install -Dm755 -t "$(DESTDIR)$(DATADIR)/qutebrowser/scripts/" \
2017-11-21 10:35:11 +01:00
$(filter-out scripts/__init__.py scripts/__pycache__ scripts/dev \
scripts/testbrowser scripts/asciidoc2html.py scripts/setupcommon.py \
2017-11-21 10:35:11 +01:00
scripts/link_pyqt.py,$(wildcard scripts/*))