I have the Live Cd Distro of Damn Small Linux.Its really cool.I am able to learn a lot of unix commands from the xterm.But alas,i aint able to compile any of the programs that i type in vi editor
(eg: i created a sample file a.c
in the $ prompt i gave :$cc a.c
cc : command not found.... was the reply.)
now is it possible to compile c progams in DSL?
pls tell me!
Thanks
i dont think gcc is there on DSL any way i am sure it can be loaded.
$gcc a.c
DSL contains a tiny ANSI C compiler named tcc
Use $ tcc filename.c to compile your c programs
Thanks a ton guys!i'll try it out and tell u!
Dear pradeep,
gcc does not work. it says the same thing...
gcc:command not found.
Dear Gnurag,
tcc does work but i get an error saying "stdio.h" not found.so i just copied stdio.h file in the same folder as a.c
Still it gives the same error.
How do i make the compiler work??
its a tiny c compiler, so many things wont work out of the box.
if you copy stdio.h file in the same folder as a.c then you have to declare the include statement like this:
#include "stdio.h"
i'm skeptical if this works.. you may need to copy more header files, or install proper compiler like gcc
how abt using tc from windows after installing wine / crossover office
Hey guys.
Thanks a ton for the replies.
i found out how to make the compiler work
i just need to type the program as follows...
void main()
{printf("HI");}//without including stdio.h
$tcc a.c //to compile using Tiny C Compiler
$./a.out //to get the o/p
Just another question. How does DSL get installed. It says that it can install only on hda5!!