Tiny Core Linux
Tiny Core Extensions => TCE Talk => Topic started by: ferran on April 27, 2020, 03:07:32 PM
-
Oh, broh...
When i wanted to compile a C program like this:
tc@box:~/Code/C$ gcc accounts.c -o accounts
accounts.c:1:10: fatal error: stdio.h: No such file or directory
1 | #include <stdio.h>
| ^~~~~~~~~
compilation terminated.
tc@box:~/Code/C$ find / -type f -name "stdio.h"
find: /mnt/sda1/lost+found: Permission denied
/tmp/tcloop/gcc/usr/local/include/c++/9.2.0/tr1/stdio.h
/tmp/tcloop/gcc/usr/local/lib/gcc/i486-pc-linux-gnu/9.2.0/include/ssp/stdio.h
/tmp/tcloop/syslinux/usr/local/share/syslinux/com32/include/stdio.h
I've the idea of write into the program this:
#include </tmp/tcloop/gcc/usr/local/include/c++/9.2.0/tr1/stdio.h>
#include </tmp/tcloop/gcc/usr/local/include/c++/9.2.0/tr1/stdlib.h>
.
.
It doesn't seems something too orthodox.
What will happen if the .c executable runs on another machine (and on another distribution with its particular file tree)?.
Thus, How could I do for TC recognize this standand header of C without to have write all its path ?
Thank you in advance.
-
False alarm!
I looked up libc-dev.tcz but it didn't exist.
Then I've noticed that in TC there are glibc and I found the glibc_base-dev.tcz where all the header's files appear in it.
It's Solved !!
-
Hi ferran
Did you first install the compiletc.tcz extension so you have a proper tool chain installed?
-
Hi ferran
Did you first install the compiletc.tcz extension so you have a proper tool chain installed?
So don't... currently I've the usual install of TC and never more. Should I do it now?
-
Hi ferran
If you are looking to compile existing programs or a program you are trying to write, you should install compiletc.tcz.
-
Oh yeah ! It contents the glib_base-dev.tcz too :D
I say again: thank you very much.
It's SOLVED.