Krolyxon
Commit 696f687

Branches

Refs →

nsxiv696f687

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
Author
Berke Kocaoğlu
Date
2021-09-25 08:00 +0300
Committer
GitHub · 2021-09-25 05:00 +0000
Parent
4ec8fd5
Commit
696f68753f1b85299f64592f9cc57c2e77d914f1

+13 −7

2 files changed

  1. M Makefile +7 −5
  2. M README.md +6 −2
M Makefile View
@@ -46,7 +46,7 @@ LDLIBS = -lImlib2 -lX11 -lXft -lfontconfig $(OPTIONAL_LIBS)
4646 OBJS = autoreload_$(AUTORELOAD).o commands.o image.o main.o options.o \
4747 thumbs.o util.o window.o
4848
49−.PHONY: all clean install uninstall icon
49+.PHONY: all clean install uninstall install-all install-icon uninstall-icon install-desktop
5050 .SUFFIXES:
5151 .SUFFIXES: .c .o
5252
@@ -87,12 +87,14 @@ version.h: Makefile .git/index
8787 clean:
8888 $(RM) *.o nsxiv
8989
90−desktop:
90+install-all: install install-desktop install-icon
91+
92+install-desktop:
9193 @echo "INSTALL nsxiv.desktop"
9294 mkdir -p $(DESTDIR)$(PREFIX)/share/applications
9395 cp nsxiv.desktop $(DESTDIR)$(PREFIX)/share/applications
9496
95−icon:
97+install-icon:
9698 @echo "INSTALL icon"
9799 for f in $(ICONS); do \
98100 dir="$(DESTDIR)$(PREFIX)/share/icons/hicolor/$${f%.png}/apps"; \
@@ -101,7 +103,7 @@ icon:
101103 chmod 644 "$$dir/nsxiv.png"; \
102104 done
103105
104−icon_cleanup:
106+uninstall-icon:
105107 @echo "REMOVE icon"
106108 for f in $(ICONS); do \
107109 dir="$(DESTDIR)$(PREFIX)/share/icons/hicolor/$${f%.png}/apps"; \
@@ -119,7 +121,7 @@ install: all
119121 @echo "INSTALL share/nsxiv/"
120122 install -Dt $(DESTDIR)$(DOCPREFIX)/examples examples/*
121123
122−uninstall: icon_cleanup
124+uninstall: uninstall-icon
123125 @echo "REMOVE bin/nsxiv"
124126 rm -f $(DESTDIR)$(PREFIX)/bin/nsxiv
125127 @echo "REMOVE nsxiv.1"
M README.md View
@@ -82,11 +82,15 @@ Installing nsxiv:
8282
8383 Installing desktop entry:
8484
85− # make desktop
85+ # make install-desktop
8686
8787 Installing icons:
8888
89− # make icon
89+ # make install-icon
90+
91+Installing all of the above:
92+
93+ # make install-all
9094
9195 Please note, that these requires root privileges.
9296 By default, nsxiv is installed using the prefix `/usr/local`, so the full path