Setup Development Environment

Setup Development Environment

  • 設定 IP
    auto eth0
    iface eth0 inet static
    address 10.129.6.243
    netmask 255.255.255.0
    gateway 10.129.6.254若是 dhcp
    auth eth0
    iface eth0 inet dhcp 

 

  • 設定 DNS
    nameserver 168.95.1.1
    nameserver 168.95.192.1 

 

  • 重啟網路服務

> /etc/init.d/networking restart

 

  • 安裝 c runtime library


ubuntu8.04 預設沒安裝 glic,所以編譯 c 程式時找不到標準 c 的 include file
> sudo  apt-get install libc6-dev

 

  • 安裝 g++

> sudo apt-get install build-essential

 

  • 安裝 samba
    > sudo /etc/init.d/samba stop 
    > sudo vim /etc/samba/smb.conf 
    [share] 
    path=/home/gary/umpc 
    browseable = yes 
    read only = no 
    create mask = 0644 
    directory mask = 0755 
    > sudo /etc/init.d/samba start 
    > sudo smbpasswd -a 帳號 
    > sudo smbpasswd –e 

 

  • 安裝 alsa-lib
    > tar jxvf alsa-lib-1.0.14.tar.bz2 
    > ./configure 
    > make 
    > sudo make install 
    或是直接下命令 
    > sudo apt-get install libasound2-dev 

 

  • 安裝 sshd
  • 編輯 /etc/apt/sources.list,加入台大站台
    
    deb http://ubuntu.csie.ntu.edu.tw/ubuntu/ dapper main restricted universe multiverse
    deb-src http://ubuntu.csie.ntu.edu.tw/ubuntu/ dapper main restricted universe multiverse
    deb http://ubuntu.csie.ntu.edu.tw/ubuntu/ dapper-updates main restricted universe multiverse
    deb-src http://ubuntu.csie.ntu.edu.tw/ubuntu/ dapper-updates main restricted universe multiverse
    deb http://ubuntu.csie.ntu.edu.tw/ubuntu/ dapper-backports main restricted universe multiverse
    deb-src http://ubuntu.csie.ntu.edu.tw/ubuntu/ dapper-backports main restricted universe multiverse
    deb http://ubuntu.csie.ntu.edu.tw/ubuntu/ dapper-security main restricted universe multiverse
    deb-src http://ubuntu.csie.ntu.edu.tw/ubuntu/ dapper-security main restricted universe multiverse
    
    執行
    
    apt-get update
    安裝 sshd
    apt-get install openssh-server
    會出現所依賴的 openssh-client 版本不符合,先移除它,再安裝
    apt-get remove openssh-client
    apt-get install openssh-client
    apt-get install openssh-server

 

  • 安裝 gtk 開發環境
    > sudo apt-get install glade-3 
    > sudo apt-get install libglade2-dev 
    > sudo apt-get install libglade2-0