Ns3 Projects for B.E/B.Tech M.E/M.Tech PhD Scholars.  Phone-Number:9790238391   E-mail: ns3simulation@gmail.com

NS3 BAKE INSTALLATION STEPS

Our developers here have shared a brief explanation about the Bake is a build automation tool designed to simplify and streamline the process of building and managing software projects. It offers a flexible and easy-to-use framework for defining and executing build tasks, automating various aspects of the software build process such as compilation, testing, and deployment. bake supports defining build tasks using a simple and readable configuration language, which can help reduce the complexity of managing build dependencies and processes. This tool is especially beneficial for projects that necessitate tailored build processes or must be compatible with various tools and environments. Through the utilization of bake, developers have the ability to establish consistent and efficient build systems, guaranteeing uniformity and dependability throughout the software development lifecycle.

Some of the exciting and exclusive article that is just popped out for you to notify the steps that are required for the installation of Bake.

PRE-REQUISITES:

  1. Fresh installation of Ubuntu 22.04 LTS:

Screenshot:

Fresh installation of Ubuntu 22_04 LTS

INSTALL DEPENDENCIES OF BAKE:

  1. Open a terminal, Copy and Paste the commands to install required package:

Screenshot:

2.System File Update Command:

First of all, we need to updates the list of available packages and their versions stored in the system’s package index. Use below command to update the system package.

Command:      “sudo apt-get update”

Screenshot

System File Update Command

3.Python Installation:

Next, we need to install Python package in the ubuntu system. Use below command to install the Python package.

Command:      “sudo apt-get install python3”

Screenshot:

Python Installation

4.Git Installation:

Next, we need to install Git package in the ubuntu system. Use below command to install the Git package.

Command:      “sudo apt-get install git”

Screenshot:

Git Installation

5.GCC & G++ Installation:

Next, we need to install the both GCC and G++ package in the ubuntu system. Use below command to install the both GCC and G++ package.

Command:      “sudo apt-get install gcc g++”

Screenshot:

GCC & G++ Installation

Click Y to install these additional Packages.

Screenshot:

GCC & G++ Installation

6.Make & Cmake Installation:

Next, we need to install the both make and cmake package in the ubuntu system. Use below command to install the both make and cmake package.

Command:      “sudo apt-get install make cmake”

Screenshot:

Click Y to install these additional Packages. Screenshot:

7.Pygraphviz Installation:

Next, we need to install the pygraphviz package in the ubuntu system. Use below command to install the pygraphviz package.

Command:      “sudo apt-get install python3-pygraphviz”

Screenshot:

Make & Cmake Installation

Click Y to install these additional Packages.

Screenshot:

Make & Cmake Installation

8.Python3-dev Installation:

Next, we need to install the python3-dev package in the ubuntu system. Use below command to install the python3-dev package.

Command:      “sudo apt-get install python3-dev”

Screenshot:

Pygraphviz Installation

Click Y to install these additional Packages.

Screenshot:

Pygraphviz Installation

9.QT Packages Installation:

Next, we need to install the qt packages in the ubuntu system. Use below command to install the qt packages.

Command:      “sudo apt install qtbase5-dev qtchooser qt5-qmake qtbase5-dev-tools”

Screenshot:

Python3-dev Installation

Click Y to install these additional Packages.

Screenshot:

Python3-dev Installation

10.Python Setup Tools Package Installation:

Next, we need to install the python setup tools packages in the ubuntu system. Use below command to install the python setup tools packages.

Command:      “sudo apt install python3-setuptools”

Screenshot:

Python3-dev Installation

Click Y to install these additional Packages.

Screenshot:

QT Packages Installation

11.Pyvisualizer and pybindings Installation:

Next, we need to install the Pyvisualizer and pybindings in the ubuntu system. Use below command to install these packages.

Command:     

“sudo apt install gir1.2-goocanvas-2.0 python3-gi python3-gi-cairo python3-pygraphviz gir1.2-gtk-3.0 ipython3 python3-pip pkg-config sqlite3 libc6-dev libc6-dev-i386 libclang-dev llvm-dev automake

sudo python3 -m pip install –user cppyy

sudo python3 -m pip install –user cxxfilt”

Screenshot:

Python Setup Tools Package Installation

Click Y to install these additional Packages.

Screenshot:

Python Setup Tools Package Installation

Next, We use the 2nd command to install these pybindings Package.

Screenshot:

Pyvisualizer and pybindings Installation

Next, We use the 3rd command to install these pybindings Package.

Screenshot:

Pyvisualizer and pybindings Installation

12.Bake Download:

First of all, we need to download Bake using Git. Use the below command in the terminal to download the bake files.

Command:      “git clone https://gitlab.com/nsnam/bake

Screenshot:

Pyvisualizer and pybindings Installation

Here we shown the downloaded Bake files in the home Directory.

Screenshot:

Pyvisualizer and pybindings Installation
Bake Download
Bake Download

13.Add to path to the bake file:

Next, we need to set path for Bake files. Use the below command in the terminal to set path to the bake files.

Command:     

“export BAKE_HOME=`pwd`/bake

 export PATH=$PATH:$BAKE_HOME

 export PYTHONPATH=$PYTHONPATH:$BAKE_HOME”

Screenshot:

Add to path to the bake file

Here we shown the path given to the bake by using “echo $PATH” command.

Screenshot:

Add to path to the bake file

14.Checking bake Requirements:

Next, we need to check the bake requirements to install Bake. Use the below command in the terminal to check the bake requirements.

Command:     

“bake.py check”

Screenshot:

Checking bake Requirements

15.Downloading Ns3 and Configuring with bake:

Next, we need to download the ns 3 and configure the ns 3 using bake tool. Use the below command in the terminal to perform download and configure process.

Command:     

“bake.py configure -e ns-3.35”

Screenshot:

Downloading Ns3 and Configuring with bake

Here we shown that bake downloaded the ns 3 configuration files.

Screenshot:

Downloading Ns3 and Configuring with bake

16.Show the Configuration of ns 3.35 using Bake:

Next, we will show the configuration of the ns 3 using bake tool. Use the below command in the terminal to show the configuration of ns 3.35 using bake tool and by giving this command you need to get output like below image, If not then follow all previous steps.

Command:     

“bake.py show”

Screenshot:

Show the Configuration of ns 3.35 using Bake

17.Deployment of ns 3.35 using Bake:

Next, we will deploy the Bake to download the two directories, build and source should have been created. Source will have one directory for each module downloaded and the build will contain the installed object files for all the built modules.

Command:     

“bake.py deploy”

Screenshot:

Deployment of ns 3.35 using Bake

Screenshot:

Deployment of ns 3.35 using Bake

Note: This Error will occur due to pybindgen configuration so follow the Python bindings Enabling Procedure as Below.

  1. Enable Python Bindings:

The Python bindings for NS-3 are a set of Python modules that allow you to use the Network Simulator 3 (NS-3) library from within Python. With the Python bindings, you can leverage the power of NS-3 to simulate and analyse network behaviour without needing to write code in C++.

Next, we will locate the cppclass.py file in /home/<your-user-name>/source/pybindgen/pybindgen/cppclass.py

Screenshot:

Enable Python Bindings

Screenshot:

Enable Python Bindings

Next, we need to open cppclass.py file in the text Editor by right clicking the file and Edit the following file code with below screenshot.

Screenshot:

Enable Python Bindings

Here we installed the python bindings required packages successfully.

  1. Re-Deployment of ns 3.35 using Bake:

Next, we will deploy the Bake to download the two directories, build and source should have been created. Source will have one directory for each module downloaded and the build will contain the installed object files for all the built modules.

Command:     

“bake.py deploy -vvv”

Screenshot:

Re-Deployment of ns 3.35 using Bake

Screenshot:

Re-Deployment of ns 3.35 using Bake