1、添加軟件源 su到root用戶
vi /etc/apt/sources.list 也可用gedit /etc/apt/sources.list (gnome下用,如果kde下則用 kdesudo kate /etc/apt/sources.list 在非root用戶下用才能打開。)
#阿里雲源(debian 8.x (jessie))
deb http://mirrors.aliyun.com/debian/ jessie main non-free contrib deb http://mirrors.aliyun.com/debian/ jessie-proposed-updates main non-free contrib deb-src http://mirrors.aliyun.com/debian/ jessie main non-free contrib deb-src http://mirrors.aliyun.com/debian/ jessie-proposed-updates main non-free contrib
#中科大源(debian 8.x (jessie))
deb http://mirrors.ustc.edu.cn/debian jessie main contrib non-free
deb-src http://mirrors.ustc.edu.cn/debian jessie main contrib non-free
deb http://mirrors.ustc.edu.cn/debian jessie-proposed-updates main contrib non-free
deb-src http://mirrors.ustc.edu.cn/debian jessie-proposed-updates main contrib non-free
deb http://mirrors.ustc.edu.cn/debian jessie-updates main contrib non-free
deb-src http://mirrors.ustc.edu.cn/debian jessie-updates main contrib non-free
2、更新系統
$ sudo aptitude update
$ sudo aptitude upgrade
$ sudo aptitude dist-upgrade
會提示沒有安裝sudo,那就不用sudo,直接在root#下輸入sudo后面的就行了。
3、安裝sudo 使普通用戶有系統管理的權利
root# aptitude install sudo
root# chmod +w /etc/sudoers 授予sudoers 寫的權限,否則為只讀。
Root# vi etc/sudoers 或者gedit /etc/sudoers 編輯 etc/sudoers
找到root 行並在下行輸入你的賬戶,在賬戶后面把root后面的復制下來就行了。然后保存。vi編譯器輸入:wq
root# chmod 0440 /etc/sudoers 去掉sudoers 寫的權限改為只讀。
root# exit 退到普通賬戶。
4、安裝編譯環境 apt-get install build-essential 即可解決make問題