What are files with the "*.c" extension? Whatever it is, is it like perl? Can I run the script on a Windows machine? Help me peez!
Printable View
What are files with the "*.c" extension? Whatever it is, is it like perl? Can I run the script on a Windows machine? Help me peez!
sounds like they are likely to be something to do with c programming language, it could be an uncompiled file (dont quote me on this but c++ uses *.cpp for uncompiled files and im pretty sure c uses *.c for its uncompiled stuff)
if anyone else thinks this isn't right, let me know so i can sort it out too
All i know is uncompiled C is .c i think
files with the extension .c are usually either c or c++. You can download a free compiler at Cygwin. This is the windows version of the GCC compiler found on many *nix boxes.
You might also want to book the File Extension Source, which lists all the extensions and what they generally stand for.
Hope this helps.
and , you can't run it as a script, but it must be compiled
with a c compiler into an exe file, as has been mentioned.
You might want to find out which compiler the author
intended the files to be compiled on, and what type of machine
and OS was intended, because even though c is supposed to
be portable between systems, it's never 100% portable
in practice.
:cool:
the file that you have aka *.c is most likely a C/C++ written in Nix (guessing). If it was done in Visual C++ you'd have a whole bunch of files such as .cpp and .c so open up nix and use gcc to look at the code if you can.
you can get the gnu C compiler for any platform, also for the windows platform ;)
so go to http://www.gnu.org/software/gcc/gcc.html
and start learning the wonderfull language of the C
Simply put, and .c file is a C program file. It contains the actual source code of whatever program you're trying to write. Like rcgreen said, it's not run as a script, but actually, you'll need to compile it using a C Compiler. I use the one from Borland on my Windows box. And if you're talking about *nix systems, then you always have 'gcc'.
As a result of compilation, you'll end up with a .exe with the same name as the file ( in windows ), or a.out ( in *nix ) unless specified otherwise. It's this file that you will be looking to run.
There we go. :)
Definatly make sure you know what OS it was ment for coz it's very likely you'll run into problems if you try compile a *nix program on windows or vice versa.
also check that you have any nessesary header files (e.g foobar.h) they will be writen in at the top of the c file.
other than that i cant think of any other problems so have fun compliing :)
Definatly make sure you know what OS it was ment for coz it's very likely you'll run into problems if you try compile a *nix program on windows or vice versa.
also check that you have any nessesary header files (e.g foobar.h) they will be writen in at the top of the c file.
other than that i cant think of any other problems so have fun compliing :)