6
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

ns-3構築を爆速で終わらせるためのシェルスクリプト

Last updated at Posted at 2018-07-29

ns-3.28をUbuntuに一気に入れてしまいたいのでシェルスクリプトを書いてみた。
動作環境 Ubuntu 16.04 or Ubuntu 17.10

ns3.sh
# !/bin/sh

sudo apt install gcc g++
sudo apt install python python-dev
sudo apt install mercurial python-setuptools git
sudo apt install qt4-dev-tools libqt4-dev
sudo apt install cmake libc6-dev libc6-dev-i386 g++-multilib
sudo apt install gdb valgrind
sudo apt install gsl-bin libgsl2 libgsl-dev
sudo apt install flex bison libfl-dev
sudo apt install tcpdump
sudo apt install sqlite sqlite3 libsqlite3-dev
sudo apt install libxml2 libxml2-dev
sudo apt install libgtk2.0-0 libgtk2.0-dev
sudo apt install vtun lxc
sudo apt install uncrustify
sudo apt install doxygen graphviz imagemagick
sudo apt install texlive texlive-extra-utils texlive-latex-extra texlive-font-utils texlive-lang-portuguese dvipng
sudo apt install python-sphinx dia
sudo apt install python-pygraphviz python-kiwi python-pygoocanvas libgoocanvas-dev ipython
sudo apt install libboost-signals-dev libboost-filesystem-dev
sudo apt install openmpi-bin openmpi-common openmpi-doc libopenmpi-dev
cd ~
wget http://www.nsnam.org/release/ns-allinone-3.28.tar.bz2
tar xjf ns-allinone-3.28.tar.bz2
cd ns-allinone-3.28/ns-3.28
./waf distclean
./waf configure --enable-sudo -d optimized
# enable-sudoはビルドしたものに管理者権限を与えるようにするオプション
# -d optimizedはそのマシン用に最適化するオプション
# サンプルコードもビルドしたければ--enable-exmamples
# テストコードもビルドしたければ--enable-tests
./waf

適宜編集して使ってください。
ちなみにUbuntu18.04ではpython-pygoocanvasを入れることが出来ないので、--vizオプションでPyVizが使えません。トポロジを可視化出来なくても良いならUbuntu18.04でも動かせると思います。

6
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
6
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?