Status
Not open for further replies.

Vivek788

In the zone
I get error file or folder not found with any library file i include in my C program.
I am using feisty fawn.
 

mehulved

18 Till I Die............
Can you give more details. Sounds a bit unclear to me on what exactly are you trying to say. Maybe give an example error message.
 

mehulved

18 Till I Die............
Sometimes some libraries need to be linked while compiling. Maybe that's his problem. I had faced it with the math library.
 
OP
Vivek788

Vivek788

In the zone
vivek@vivek-desktop:~/programs$ gcc 1.c
1.c:1:18: error: stdio.h: No such file or directory
1.c: In function ‘main’:
1.c:6: warning: incompatible implicit declaration of built-in function ‘printf’
1.c:7: warning: incompatible implicit declaration of built-in function ‘scanf’
1.c:10:2: warning: no newline at end of file
vivek@vivek-desktop:~/programs$ cat 1.c
#include<stdio.h>
main()
{
int i,y;
char *names[]={"PACIFIC","ATLANTIC"};
printf("Enter number:");
scanf("%d",&i);
printf("%o %x %d",i,i,i);
printf("%c %s",names[1],names[1]);
}vivek@vivek-desktop:~/programs$
 

[xubz]

"The Cake is a Lie!!"
Well, Just installing GCC won't do any good. You need to install the Libraries too!

I'd suggest you to install the build-essential Package.

sudo apt-get install build-essential


Edit: On the Lighter note, For a good editor, Try Geany. It kinda supports compile and run by just pressing F5 :)
 

mehulved

18 Till I Die............
well vi and kate support that too :p
BTW, build-essential package is available in feisty CD. No need to go online to download it.
 

mehulved

18 Till I Die............
That's good but still you will be missing a few things specially a C++ compiler and stuff. It would be good to install the full build-essential package.
 
Status
Not open for further replies.
Top Bottom