This topic was published by Hooman Aminvand and viewed 679 times since "". The last page revision was "".
- Topics - 11
In this session, we will familiarize ourselves with the installation requirements and see what tools are needed for programming in C.
Compiler: Tool or software that converts programming codes (C/C++, Java, etc.) to machine code (computers understanding machine code)
- Error Codes: If there is a mistake in your code, error codes will show your mistakes
- Precautions: In some cases, such as when the code contains a useless variable that is not used in the program, an alert is generated. Warnings, unlike errors, do not prevent the implementation of the program, and warnings are merely notifications to optimize the program.
- Executable File: A file that has the ability to execute.
For this tutorial, we will use Ubuntu. You will be able to work with Linux and learn basic information about commands. You will learn about C-programming and the GCC compiler.
First, you need a GNU/Linux operating-system with BASH, such as Ubuntu. We will see if the GCC compiler is installed using a terminal (Ctrl+Alt+T). Type "gcc" and then double-press Tab.
If it shows you that it is not installed on your system, you will enter
sudo apt-get install gcc.
GCC has C libraries, but to be able to compile C++, you will enter
sudo apt-get install build-essential.
Next, type "g++" and double-press Tab and you should see a list of "g++" commands.
Now, your compiler is ready!
- Writing Your First C Program in Linux - http://dcjtech.info/topic/writing-your-first-c-program-in-linux/
- A Newbie's Guide to the Linux System (Article Index) - http://dcjtech.info/topic/a-newbies-guide-to-the-linux-system/
- Programming and Development (Article Index) - http://dcjtech.info/topic/programming-and-development/
- Linux Compilers - http://dcjtech.info/topic/linux-compilers/