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:
- Fresh installation of Ubuntu 22.04 LTS:
Screenshot:
INSTALL DEPENDENCIES OF BAKE:
- 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
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:
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:
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:
Click Y to install these additional Packages.
Screenshot:
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:
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:
Click Y to install these additional Packages.
Screenshot:
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:
Click Y to install these additional Packages.
Screenshot:
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:
Click Y to install these additional Packages.
Screenshot:
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:
Click Y to install these additional Packages.
Screenshot:
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:
Click Y to install these additional Packages.
Screenshot:
Next, We use the 2nd command to install these pybindings Package.
Screenshot:
Next, We use the 3rd command to install these pybindings Package.
Screenshot:
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:
Here we shown the downloaded Bake files in the home Directory.
Screenshot:
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:
Here we shown the path given to the bake by using “echo $PATH” command.
Screenshot:
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:
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:
Here we shown that bake downloaded the ns 3 configuration files.
Screenshot:
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:
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:
Screenshot:
Note: This Error will occur due to pybindgen configuration so follow the Python bindings Enabling Procedure as Below.
- 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:
Screenshot:
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:
Here we installed the python bindings required packages successfully.
- 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:
Screenshot: