Merge branch 'master' of ssh://git.uucp.hu/git/sysop/tools
[hband-tools.git] / xgui-tools / Makefile
blob1ff85e57ccc1349bd8f69b09124f2e61ce84b5db
2 PREFIX = /usr/tool
4 default:
5 @echo may be interested in: install-all
6 false
8 TOOLS = gexifcomment gtail xgcal xstopper perspect
10 TARGET_FILES = $(foreach tool,$(TOOLS),$(PREFIX)/$(tool))
11 UNINSTALL_TARGETS = $(foreach tool,$(TOOLS),UNINSTALL/$(tool))
12 SHELL = bash -e
14 define rid
15 @[ ! -e $(1) ] || rm -v $(1)
16 endef
19 install-all: $(TARGET_FILES)
20 .PHONY: install-all
22 uninstall-all: $(UNINSTALL_TARGETS)
23 .PHONY: uninstall-all
25 $(UNINSTALL_TARGETS):
26 $(call rid,$(PREFIX)/$(notdir $@))
27 .PHONY: $(UNINSTALL_TOOLS)
29 UNINSTALL/xgcal:
30 $(call rid,/usr/share/xgcal/timezones.png)
31 $(call rid,/usr/share/xgcal)
32 $(call rid,$(PREFIX)/xgcal)
34 $(PREFIX)/xgcal: DEPENDENCY/sunclock DEPENDENCY/gcal DEPENDENCY/solartime /usr/share/xgcal/timezones.png
36 DEPENDENCY/sunclock DEPENDENCY/gcal DEPENDENCY/solartime:
37 type $(notdir $@)
38 .PHONY: DEPENDENCY/sunclock DEPENDENCY/gcal DEPENDENCY/solartime
40 /usr/share/xgcal/timezones.png: timezones.png | /usr/share/xgcal
41 install $< $@
43 /usr/share/xgcal:
44 mkdir -p $@
46 $(TARGET_FILES): $(PREFIX)/%: %
47 install $< $@