aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile20
1 files changed, 16 insertions, 4 deletions
diff --git a/Makefile b/Makefile
index 3d930f97..7aa69aac 100644
--- a/Makefile
+++ b/Makefile
@@ -25,10 +25,14 @@ ifdef DOC
$(MAKE) -C doc
endif
-uninstall: uninstall-bin uninstall-doc
+ifdef DEVEL
+INSTALL_DEV = install-dev
+UNINSTALL_DEV = uninstall-dev
+endif
+uninstall: uninstall-bin uninstall-doc $(UNINSTALL_DEV)
@echo -e '\nmake uninstall does not remove files in '$(DESTDIR)$(ETCDIR)', you can use make uninstall-etc to do that.\n'
-install: install-bin install-doc install-plugins
+install: install-bin install-doc install-plugins install-etc $(INSTALL_DEV)
@echo
@echo Installed successfully
@echo
@@ -111,12 +115,20 @@ uninstall-dev:
install-etc:
mkdir -p $(DESTDIR)$(ETCDIR)
- $(INSTALL) -m 0644 $(_SRCDIR_)motd.txt $(DESTDIR)$(ETCDIR)/motd.txt
- $(INSTALL) -m 0644 $(_SRCDIR_)bitlbee.conf $(DESTDIR)$(ETCDIR)/bitlbee.conf
+ $(INSTALL) -m 0644 $(_SRCDIR_)motd.txt $(DESTDIR)$(ETCDIR)/motd.txt.sample
+ $(INSTALL) -m 0644 $(_SRCDIR_)bitlbee.conf $(DESTDIR)$(ETCDIR)/bitlbee.conf.sample
+ @if ! [ -e $(DESTDIR)$(ETCDIR)/motd.txt ]; then \
+ $(INSTALL) -m 0644 $(_SRCDIR_)motd.txt $(DESTDIR)$(ETCDIR)/motd.txt; \
+ fi
+ @if ! [ -e $(DESTDIR)$(ETCDIR)/bitlbee.conf ]; then \
+ $(INSTALL) -m 0644 $(_SRCDIR_)bitlbee.conf $(DESTDIR)$(ETCDIR)/bitlbee.conf; \
+ fi
uninstall-etc:
rm -f $(DESTDIR)$(ETCDIR)/motd.txt
+ rm -f $(DESTDIR)$(ETCDIR)/motd.txt.sample
rm -f $(DESTDIR)$(ETCDIR)/bitlbee.conf
+ rm -f $(DESTDIR)$(ETCDIR)/bitlbee.conf.sample
-rmdir $(DESTDIR)$(ETCDIR)
install-plugins: install-plugin-otr install-plugin-skype