simple-apt-update/Makefile

55 lines
1.4 KiB
Makefile
Raw Normal View History

2023-07-18 15:17:23 +02:00
NAME=simple-apt-update
PREFIX=/usr
DESTDIR=
BINDIR=$(PREFIX)/bin
POLDIR=/usr/share/polkit-1/actions
ICONSDIR=/usr/share/icons
APPDIR=/usr/share/applications
all: \
res/desktop/$(NAME).desktop \
res/polkit/org.freedesktop.policykit.$(NAME).policy
2023-07-18 16:53:25 +02:00
clean:
rm -f res/desktop/$(NAME).desktop
rm -f res/polkit/org.freedesktop.policykit.$(NAME).policy
2023-07-18 15:17:23 +02:00
install: \
bin/$(NAME) \
res/desktop/$(NAME).desktop \
res/icons/$(NAME).svg \
res/polkit/org.freedesktop.policykit.$(NAME).policy
install -d -m 755 \
$(DESTDIR)$(BINDIR)
2023-07-18 15:17:23 +02:00
install -m 755 \
bin/$(NAME) \
$(DESTDIR)$(BINDIR)/$(NAME)
install -d -m 755 \
$(DESTDIR)$(POLDIR)
2023-07-18 15:17:23 +02:00
install -m 644 \
res/polkit/org.freedesktop.policykit.$(NAME).policy \
$(DESTDIR)$(POLDIR)/org.freedesktop.policykit.$(NAME).policy
install -d -m 755 \
$(DESTDIR)$(ICONSDIR)
2023-07-18 15:17:23 +02:00
install -m 644 \
res/icons/$(NAME).svg \
$(DESTDIR)$(ICONSDIR)/$(NAME).svg
install -d -m 755 \
$(DESTDIR)$(APPDIR)
2023-07-18 15:17:23 +02:00
install -m 644 \
res/desktop/$(NAME).desktop \
$(DESTDIR)$(APPDIR)/$(NAME).desktop
2023-07-18 16:53:25 +02:00
res/desktop/$(NAME).desktop: \
res/desktop/$(NAME).desktop.in
sed -e 's|{BINDIR}|$(BINDIR)|' \
< res/desktop/$(NAME).desktop.in \
> res/desktop/$(NAME).desktop
res/polkit/org.freedesktop.policykit.$(NAME).policy: \
res/polkit/org.freedesktop.policykit.$(NAME).policy.in
sed -e 's|{BINDIR}|$(BINDIR)|' \
< res/polkit/org.freedesktop.policykit.$(NAME).policy.in \
> res/polkit/org.freedesktop.policykit.$(NAME).policy