删除自己编译的软件

编译安装

1
2
3
4
5
wget url
cd dirname
./configure 
make
make install

估计编译的时候很少有人去看屏幕上让人眼花的log输出,下面是install不同选项做的事摘自stackoverflow

the install target install : altinstall bininstall manisntall It does everything altinstall does, along with bininstall and maninstal

Here’s bininstall, it just creates the python and other symbolic links.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
# Install the interpreter by creating a symlink chain:
#  $(PYTHON) -> python2 -> python$(VERSION))
# Also create equivalent chains for other installed files
bininstall:     altbininstall
        -if test -f $(DESTDIR)$(BINDIR)/$(PYTHON) -o -h $(DESTDIR)$(BINDIR)/$(PYTHON); \
        then rm -f $(DESTDIR)$(BINDIR)/$(PYTHON); \
        else true; \
        fi
        (cd $(DESTDIR)$(BINDIR); $(LN) -s python2$(EXE) $(PYTHON))
        -rm -f $(DESTDIR)$(BINDIR)/python2$(EXE)
        (cd $(DESTDIR)$(BINDIR); $(LN) -s python$(VERSION)$(EXE) python2$(EXE))
        ... (More links created)

And here’s maninstall, it just creates “unversioned” links to the python manual pages.

1
2
3
4
5
6
# Install the unversioned manual pages
maninstall:     altmaninstall
        -rm -f $(DESTDIR)$(MANDIR)/man1/python2.1
        (cd $(DESTDIR)$(MANDIR)/man1; $(LN) -s python$(VERSION).1 python2.1)
        -rm -f $(DESTDIR)$(MANDIR)/man1/python.1
        (cd $(DESTDIR)$(MANDIR)/man1; $(LN) -s python2.1 python.1)

altinstall skips creating the python link and the manual pages links, install will hide the system binaries and manual pages.

删除编译的软件

方法一:查看日志,看看都干了什么,反着来就行了 方法二:

1
make uninstall

但是并不是所有的源码都支持 方法三:安装的时候换为下面命令 makeinstall,checkinstall 即使两个都运行也没事,checkinstall 会覆盖makeinstall 如果想删除使用命令

1
dpkg -P packagename