diff options
author | Matt O'Gorman <mogorman@digium.com> | 2006-02-01 18:39:41 +0000 |
---|---|---|
committer | Matt O'Gorman <mogorman@digium.com> | 2006-02-01 18:39:41 +0000 |
commit | 7d03c33e0a63d431b6551cbe2ef13f9fb2aaa636 (patch) | |
tree | 6a2ab56c89ec254ff4692703dd51d495c9d7186f /Makefile | |
parent | 286a521e1135aaa655577646bfcfd7a98f2fb2dc (diff) |
Allows for user to uninstall asterisk binaries
bug 6177
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@9052 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 34 |
1 files changed, 34 insertions, 0 deletions
@@ -912,3 +912,37 @@ cleantest: if cmp -s .cleancount .lastclean ; then echo ; else \ $(MAKE) clean; cp -f .cleancount .lastclean;\ fi + +_uninstall: + rm -f $(DESTDIR)$(MODULES_DIR)/* + rm -f $(DESTDIR)$(ASTSBINDIR)/*asterisk* + rm -f $(DESTDIR)$(ASTSBINDIR)/astgenkey + rm -f $(DESTDIR)$(ASTSBINDIR)/autosupport + rm -rf $(DESTDIR)$(ASTHEADERDIR) + rm -rf $(DESTDIR)$(ASTVARLIBDIR)/sounds + rm -rf $(DESTDIR)$(ASTVARLIBDIR)/firmware + rm -rf $(DESTDIR)$(ASTMANDIR)/man8 + for x in $(SUBDIRS); do $(MAKE) -C $$x uninstall || exit 1 ; done + +uninstall: _uninstall + @echo " +--------- Asterisk Uninstall Complete -----+" + @echo " + Asterisk binaries, sounds, man pages, +" + @echo " + headers, modules, and firmware builds, +" + @echo " + have all been uninstalled. +" + @echo " + +" + @echo " + To remove ALL traces of Asterisk, +" + @echo " + including configuration, spool +" + @echo " + directories, and logs, run the following +" + @echo " + command: +" + @echo " + +" + @echo " + $(MAKE) uninstall-all +" + @echo " +-------------------------------------------+" + + +uninstall-all: _uninstall + rm -rf $(DESTDIR)$(ASTLIBDIR) + rm -rf $(DESTDIR)$(ASTVARLIBDIR) + rm -rf $(DESTDIR)$(ASTSPOOLDIR) + rm -rf $(DESTDIR)$(ASTETCDIR) + rm -rf $(DESTDIR)$(ASTLOGDIR) + |