Can someone point me to something simple like this?
Thank you.
Notepad works for an editor on windows. You can use vi or whatever
you like on POSIX systems.
Just about every C compiler has a command line interface.
We do not know what compiler you are using (or want to use).
If you already have a compiler installed, then go to a newsgroup
dedicated to that compiler and ask how to use it from the command line
in that news group.
If you have an extra PC around, I'd just turn it into a Linux box (for
example, http://fedora.redhat.com). Then you can use "gcc".
I'm not sure if there is a pure port of gcc for Windows, but you can always
try cygwin (http://www.cygwin.com/).
You can use Emacs or vi.
There are a fair number of advantages to setting up a Linux box. You can,
for example, teach yourself Linux, Apache, PHP, Perl, Python, MySQL, and C++
as well. And Unix internals.
Furthermore, if you have a network in your home or apartment, you can quite
comfortably use a product like Putty along with Emacs or vi remotely from
Windows. In a typical home network, the network delay isn't even noticeable
(doesn't interfere with editing at all).
In fact, I have a box colocated in a data center about 100 miles from me,
and editing works fine. There _may_ have been some psychological adjustment
on my part to the fraction of a second delay, but I don't think so. It is
still "instant" and very usable.
The Lizard
If you want to use Windows, if i remember correctly MinGW and Visual C+
+ from Microsoft are the two major free compilers. Once you have them
installed you can compile sourcecode from the command line. As already
mentioned, choose the compiler you wish to use, then read its
documentation to learn how to compile with it.
Microsoft Visual C++ has been everything from $299 to $99 to free over the
years.
I'm too lazy to look up if the basic version is free these days.
But I forgot all about that.
And MinGW? Never heard of that in Lizardland.
The Lizard.
> There are a fair number of advantages to setting up a Linux box. You
> can, for example, teach yourself Linux, Apache, PHP, Perl, Python,
> MySQL, and C++ as well. And Unix internals.
>
Linux internals :)
--
Ian Collins
IDE - You can use GVIM for windows.
Get it from ftp://ftp.vim.org/pub/vim/pc/gvim72.exe
Compiler - You can use DJGPP (gcc compiler) for windows.
Get it from http://www.delorie.com/djgpp/zip-picker.html
-------------
~Santosh S Y
Visual C++ Express is free. Despite the name it's a perfectly good
C++ and C compiler.
> But I forgot all about that.
>
> And MinGW? Never heard of that in Lizardland.
I used to have trouble with the debugger.
"your code isn't compiled for debugging
would you like to recompile it for debugging now?"
<user clicks "yes">
"your code isn't compiled for debugging
would you like to recompile it for debugging now?"
<user clicks "yes">
...
sun goes out. last proton decays. C++ specification finalised.
--
Nick Keighley
When in doubt, consult a numerical analyst.
Windows: Notepad + MSYS\MinGW
Linux: KWrite (if you have KDE of course) + the toolchain on the
system
That's all.
there are other program editors around for windows
eg. ConTEXT, Crimson. Even Word is a better editor
than Notepad...
For Windows, I've used the following C compilers from the command line:
Mingw (gcc.exe)
Digital Mars (dmc.exe)
Lcc-win32 (lcc.exe)
Pelles C (pocc.exe)
The last two come with an IDE that you can safely ignore.
--
Bartc
notepad++ or code::blocks.
gcc is THE compiler :-)
--
Amarok 1.4.10 is airing: Metallica - Damage, Inc. [from: "Master Of
Puppets"]
I've written Notepad because that's already on the system when you istall
the OS, just like KWrite if you happen to install a Linux distribution who
uses KDE. Of course there are better ones...
I use gcc from "Equation Solution"
( http://www.equation.com/ )
with no need for Cygwin or MinGW or anything
... and I use one of many Notepad replacements
for the text editor :)
I'll save you the trouble. There is a version available free (IIRC you
cannot use it for commercial purposes) and has been for at least a few
versions and a number of years. The only reason I don't have the free
version is because I have an MSDN subscription on the company...
> But I forgot all about that.
>
> And MinGW? Never heard of that in Lizardland.
gcc (and other nix type tools) for Windows. It is (I think) short for
Minimalistic GNU for Windows. However, because it uses the Microsoft C
library and gcc has not been properly adapted for it there *are* areas
where it does not even conform to the old C90 standard. I believe (from
memory) that the printf/scanf families have problems with long double.
This is not an error by either Microsoft or the gcc team, rather it is a
problem in the way the MinGW team have glued the two things together.
--
Flash Gordon
If spamming me sent it to sm...@spam.causeway.com
If emailing me use my reply-to address
See the comp.lang.c Wiki hosted by me at http://clc-wiki.net/
I've never heard of a compiler with an IDE which doesn't also have a
fully functional command line interface. I don't use IDEs, and I've
never come across a compiler on any platform which requires me to. I
suggest looking at the documentation for the compilers you've tried;
Microsoft's compilers certainly have fully functional and documented CLIs.
For a text editor, I use Vim on all platforms.
So don't use the IDE.
> I believe in IDEs but I really just want to use a text
> editor and the command line (Windows).
So use a text editor and DOS window.
> Can someone point me to something simple like this?
http://www.google.com.au/search?q=c+compiler
--> http://www.thefreecountry.com/compilers/cpp.shtml
--> http://www.delorie.com/djgpp/
--
Peter
Try the DJGPP system, which includes a copy of gcc. I also
recommend getting the textpad editor. You can find these things
for free download at:
<http://delorie.com/djgpp/>
<http://textpad.com>
Then tell winders to bring up a console panel on bootup, and have
fun.
--
[mail]: Chuck F (cbfalconer at maineline dot net)
[page]: <http://cbfalconer.home.att.net>
Try the download section.
Oh yes, marvelous advice! Make sure you dress in a loincloth and woad
paint while you code to complete the stone-age experience.
Actually:
"#7: Can I use Express Editions for commercial use?
Yes, there are no licensing restrictions for applications built using
Visual Studio Express Editions."
That equation.com version of gcc really is a MinGW based compiler, nicely packaged.
C:\temp>gcc -v
Built by Equation Solution (http://www.Equation.com).
Using built-in specs.
Target: i386-pc-mingw32
Configured with: ../gcc-4.3.2-mingw/configure --host=i386-pc-mingw32
--build=x86_64-unknown-linux-gnu --target=i386-pc-mingw32
--prefix=/home/gfortran/gcc-home/binary/mingw32/native/x86_32/gcc/4.3.2
--with-gcc --with-gnu-ld --with-gnu-as --disable-shared --disable-nls
--disable-tls
--with-gmp=/home/gfortran/gcc-home/binary/mingw32/native/x86_32/gmp
--with-mpfr=/home/gfortran/gcc-home/binary/mingw32/native/x86_32/mpfr
--enable-languages=c,c++,fortran
--with-sysroot=/home/gfortran/gcc-home/binary/mingw32/cross/x86_32/gcc/4.3.2
--enable-libgomp --enable-threads=win32 --disable-win32-registry
Thread model: win32
gcc version 4.3.2 (GCC)
MinGW(gcc gdb gcov for windows) is perfect. The compiled binary
doesn't require a redistributable package to run on other machines,
while VC++ does.
If you want to write c programs in the way similar to the way fathers
of C work, you can give VIM a try. www.vim.org . Don't use the GUI,
start vim in the command prompt window.
The old Mac OSes had no 'command line' interface whatsoever.
Unless you used Apple's own Macintosh Programmer's Workshop,
you pretty much had no choice but to use an IDE.
[Implementations supplied their own console emulators for
console apps.]
--
Peter
> I've never heard of a compiler with an IDE which doesn't also have a
> fully functional command line interface. I don't use IDEs, and I've
> never come across a compiler on any platform which requires me to.
I've used older Macintosh stuff that had no command line interface.
But them the old Mac didn't *have* a command line.
--
Nick Keighley
I'm sure it never used to be allowed. However, I have other reasons to
have an MSDN sub.