In this article, I am going to show you how to install Code-blocks on Ubuntu 20.04 Linux system using command line. The installation is very simple. I am using Ubuntu 20.04 operating system for installing Code-blocks. However, the steps mentioned would mostly work for all Debian based Linux distributions.
Let’s get started
Step 1. Open the Linux terminal
Open the Linux terminal, you can use the Ctrl+Alt+T keyboard shortcut or go to ‘Activities’ and find the ‘Terminal’ application. You must have a root user password or a sudo user account to update Linux repositories and install Code-blocks.
A sudo user is the user who has admin privileges to install and update software on Linux systems and do many more administration tasks.
Step 2. Update Linux repositories
To update Linux repositories, give the commands as shown below
By updating Linux repositories, it would ensure that you get the latest version of the software from Ubuntu.
$ sudo apt update -y
Step 3. Install build-essential tools
Below command will install GCC and G++ compiler with all the tools to compile and build a C/C++ program.
This step is optional, but I would recommand to run this command to get all the tools installed.
$ sudo apt install build-essential -y
Step 4. Install Code-blocks on Ubuntu 20.04 Linux
Once you have completed running all of the above commands successfully, now you can go for Code-blocks installation. Run the command as shown below
$ sudo apt install codeblocks -y
Ubuntu Linux will fetch all the required files and dependencies from its repositories.
Step 5. Open Code-blocks on Ubuntu 20.04 Linux
Here the installation process is complete, Code-blocks is ready for you to write C/C++ programs. You can see it in applications list now.
Conclusion
In this way we saw how to install Code-blocks on Ubuntu 20.04 Linux system using the command line.. This process will install the Code-blocks 20.03 version available in Ubuntu 20.04 Linux repositories.
You have seen the installation is quite simple, you just need to have a sudo or root user password and internet connection to your system.
There are also another methods of installing Code-blocks on Ubuntu 20.04. By using 'Ubuntu Software' or by downloading and installing Code-blocks from it's official website. But I find this method simple and fast.
Comments
Post a Comment