aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorBerke Kocaoğlu <berke.kocaoglu@metu.edu.tr>2021-09-25 07:00:21 +0200
committerGitHub <noreply@github.com>2021-09-25 07:00:21 +0200
commit696f68753f1b85299f64592f9cc57c2e77d914f1 (patch)
tree3c9ab74822ce2918d5a80a6f51fb1d47351e1432 /Makefile
parent4ec8fd5377bb05ef5646ab461e3957e201c1b9fb (diff)
downloadnsxiv-696f68753f1b85299f64592f9cc57c2e77d914f1.tar.zst
Rename icon & desktop and add install-all in Makefile (#96)
* Rename in Makefile Renamed {icon,desktop} => install-{icon,desktop} * Add install-all in Makefile * Added .PHONY targets and renamed icon_cleanup Added .PHONY targets and renamed icon_cleanup to uninstall_icon * Update README.md Co-authored-by: TAAPArthur <taaparthur@gmail.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile12
1 files changed, 7 insertions, 5 deletions
diff --git a/Makefile b/Makefile
index 1bae33b..e126211 100644
--- a/Makefile
+++ b/Makefile
@@ -46,7 +46,7 @@ LDLIBS = -lImlib2 -lX11 -lXft -lfontconfig $(OPTIONAL_LIBS)
OBJS = autoreload_$(AUTORELOAD).o commands.o image.o main.o options.o \
thumbs.o util.o window.o
-.PHONY: all clean install uninstall icon
+.PHONY: all clean install uninstall install-all install-icon uninstall-icon install-desktop
.SUFFIXES:
.SUFFIXES: .c .o
@@ -87,12 +87,14 @@ version.h: Makefile .git/index
clean:
$(RM) *.o nsxiv
-desktop:
+install-all: install install-desktop install-icon
+
+install-desktop:
@echo "INSTALL nsxiv.desktop"
mkdir -p $(DESTDIR)$(PREFIX)/share/applications
cp nsxiv.desktop $(DESTDIR)$(PREFIX)/share/applications
-icon:
+install-icon:
@echo "INSTALL icon"
for f in $(ICONS); do \
dir="$(DESTDIR)$(PREFIX)/share/icons/hicolor/$${f%.png}/apps"; \
@@ -101,7 +103,7 @@ icon:
chmod 644 "$$dir/nsxiv.png"; \
done
-icon_cleanup:
+uninstall-icon:
@echo "REMOVE icon"
for f in $(ICONS); do \
dir="$(DESTDIR)$(PREFIX)/share/icons/hicolor/$${f%.png}/apps"; \
@@ -119,7 +121,7 @@ install: all
@echo "INSTALL share/nsxiv/"
install -Dt $(DESTDIR)$(DOCPREFIX)/examples examples/*
-uninstall: icon_cleanup
+uninstall: uninstall-icon
@echo "REMOVE bin/nsxiv"
rm -f $(DESTDIR)$(PREFIX)/bin/nsxiv
@echo "REMOVE nsxiv.1"