In this section, you will create a simple C program on Ubuntu OS using a pre-installed text editor. You have to repeat the steps mentioned in the above section to install the build-essential package / Development Tools again, and then you are good to go.Ĭreating a Simple C Program in Ubuntu Using Text Editor Note: If the Output looks like the below Output, there was some discrepancy during the installation process. If you see Output like the above-displayed Output on your screen, you have successfully installed the GCC compiler`. Note: -version flag under the GCC command is compatible with almost all the terminal development software in Linux. First, update the packages list using the below command as the root user: So, if you are using a Red Hat Linux / Fedora / CentOS-based Linux operating system, then you have to install the Development Tools package to get the GCC compiler in your system.ġ. In Red Hat Linux Fedora or CentOS operating systems, there is no build-essentials package present, but we can install a similar package in these operating systems that are required for software development. This version of Ubuntu comes with a pre-installed version of the GCC compiler, so you can first check the installed compiler version using the command mentioned in the below section. Note: We are using Ubuntu 20.04 LTS version in this tutorial. Now we can know how to compile the C program in Linux. This process will install the GCC Compiler on your Linux Operating System so that you can use this compiler to learn how to compile C Programs in Linux.Ĭongratulations! Now, you have successfully completed the installation of the build-essential package and the GCC Compiler. It will take up to 3-5 minutes to completely install the build-essential meta-package in your system. Press the Y key and then the Enter key once you get the same output above on your screen to continue the installation process. If required, enter your system password to proceed. To begin, update the packages list using the below command: You can use the shortcut key Ctrl + Alt + T, or manually open up the terminal by searching it in the menu option ( ⋮⋮⋮ icon).ġ. Let's see the steps involved in installing the build-essential package:įirst, you have to open up the terminal. Let's start the tutorial by installing the essential package, the build-essential package, in our Linux operating system. This tool will come in handy if you wish to package your program for a Debian-based system.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |