Tag Archives: how to compile C program in Redhat linux server

How to Write and compile C Programs in RedHat Linux Server

Hello guys in this tutorial we are going to learn how to write and Compile C program in RedHat Linux Server.Its a very simple process you just need to following Simple Steps. At Fast we will Install C Compiler in Linux Server. we will install C Compiler through Yum Server. If you don’t have any idea about YUM server so please click and look how to install yum server in Redhat LInux Serverc labguage Step 1 Here i accept you configure YUM server in redhat linux, then we will install C -Compiler t through below Commands

[root@localhost ~]# yum install gcc* -y 

Step 2 then we will write C Program like this

[root@localhost ~]# vim vishnu.c
void main()
printf("hello this is my linux server c programming demo');

Step 3 then we will compile Program below Commands

[root@localhost ~]# gcc vishnu.c -o cprogram

Step 4 now if we don’t found any error in this  program then we will run below commands 

[root@localhost ~]# ./cprogram
hello this is my linux server c programming demo

if you have any Problem in this process please comments here i will solve your problem

Thank you

Vishnu Sharma