$sudo apt-get install build-essential
$sudo apt-get install tcl8.4 tcl8.4-dev tk8.4 tk8.4-dev
$sudo apt-get install libxmu-dev
2. 從 http://www.isi.edu/nsnam/ns/ 下載 NS2 All in One 套件
$tar xvfz ns-allinone-2.31.tar.gz
$cd ns-allinone-2.31
$./install
3. 等一段時間後,在 .bashrc 裡加入 path 設定 (以下請自行改成ns2所在的目錄位置)
export PATH=$PATH:/home/username/ns-allinone-2.31/bin:/home/username/ns-allinone-2.31/tcl8.4.14/unix:/home/username/ns-allinone-2.31/tk8.4.14/unix
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/username/ns-allinone-2.31/otcl-1.13:/home/username/ns-allinone-2.31/lib
export TCL_LIBRARY=$TCL_LIBRARY:/home/username/ns-allinone-2.31/tcl8.4.14/library
4. 執行 ./validate 驗證安裝
沒有留言:
張貼留言