2014-08-30 14 views
2

我在Ubuntu上安裝了「apt-get install」的python3.4。從源代碼手動安裝python 3.4.1是否正確覆蓋了python 3.3的apt-get安裝?從python 3.4.1源手動安裝是否能正確覆蓋Ubuntu的現有python 3.4安裝?

例如,Ubuntu安裝在/usr/lib/python3.4中有文件,而在https://www.python.org/ftp/python/3.4.1/Python-3.4.1.tar.xz中的安裝程序在其他幾個位置存放文件。

如何正確刪除apt-get install?或者,源代碼是否會正確地覆蓋舊的目錄?

回答

0

apt-get remove (package)刪除。與hello例如:

# sudo apt-get remove hello 

Reading package lists... Done 
Building dependency tree  
Reading state information... Done 
The following packages will be REMOVED: 
    hello 
0 upgraded, 0 newly installed, 1 to remove and 245 not upgraded. 
After this operation, 111 kB disk space will be freed. 
Do you want to continue [Y/n]? 
(Reading database ... 211551 files and directories currently installed.) 
Removing hello ... 
Processing triggers for man-db ... 
Processing triggers for install-info ... 

獲取來源,有了正確的路徑 - 它被Debian化(Ubuntu的也可以)

$ apt-get source hello 

走進源,並建立一個二進制軟件包它

$ cd hello* 
$ fakeroot debian/rules binary 

然後安裝新鮮的二進制包:

$ sudo dpkg -i ../hello*deb 

Selecting previously unselected package hello. 
(Reading database ... 211546 files and directories currently installed.) 
Unpacking hello (from ../hello_2.8-4_amd64.deb) ... 
Setting up hello (2.8-4) ... 
Processing triggers for install-info ... 
Processing triggers for man-db ... 

或者,從這裏安裝Ubuntu(Debian)Python 3.4.1二進制包:https://packages.debian.org/search?keywords=python3