You are viewing our Forum Archives. To view or take place in current topics click here.
GCC says file doesn't exist.
Posted:
GCC says file doesn't exist.Posted:
Status: Offline
Joined: Oct 03, 201311Year Member
Posts: 1,409
Reputation Power: 64
So, I'm trying to convert my kernel.c file into a object file (.o), but when I try using this command line (gcc -c kernel.c -o kernel.o) it says that the file (kernel.c, duh.) doesn't exist. It's in the same directory and it is indeed spelled right and it is also a .c file. Any help?
#2. Posted:
Status: Offline
Joined: Oct 03, 201311Year Member
Posts: 1,409
Reputation Power: 64
I fixed it by using a different compiler. Weird. O_o
- 0useful
- 0not useful
#3. Posted:
Status: Offline
Joined: Aug 14, 200915Year Member
Posts: 1,291
Reputation Power: 65
Status: Offline
Joined: Aug 14, 200915Year Member
Posts: 1,291
Reputation Power: 65
Could you give the EXACT output that gcc returns? And are you sure that it says that kernel.c doesn't exist and not kernel.o? You could also try doing this:
According to gnu.org, that will create a .o file in the current directory. I would test it, but I'm on Windows right now.
gcc -c kernel.c
According to gnu.org, that will create a .o file in the current directory. I would test it, but I'm on Windows right now.
- 0useful
- 0not useful
#4. Posted:
Status: Offline
Joined: Oct 03, 201311Year Member
Posts: 1,409
Reputation Power: 64
Experiment5X wrote Could you give the EXACT output that gcc returns? And are you sure that it says that kernel.c doesn't exist and not kernel.o? You could also try doing this:
gcc -c kernel.c
According to gnu.org, that will create a .o file in the current directory. I would test it, but I'm on Windows right now.
I'm using a GCC Windows alternative. It worked, and all I had to do was use a different GCC program. I'm just having problems linking these files with ld now.
- 0useful
- 0not useful
You are viewing our Forum Archives. To view or take place in current topics click here.