Question:
How to compile and run C++ programs without using any IDE .........?
2015-03-05 10:41:52 UTC
Although I started learning C++ before I started learning Java. However I prefer C++ is better than Java. But we can install java and we can run Java Programs in cmd. But to do the same thing in C++.......
Plz do not give answers like "IDE is better".
Three answers:
Robert J
2015-03-05 10:47:37 UTC
There are quite a few command-line compilers.



The best standardised one is probably GCC - as used in Linux etc.



You can run that in Windows using MinGW or Cygwin.



See below for an example:

http://mingw-w64.sourceforge.net/
mmarrero
2015-03-05 15:08:20 UTC
You simply don't know anything about C/C++, it's not that simple. Start with an IDE, then graduate to command-line. All C++ compilers invoke a bunch of command-line software, you can see all the switches on the project properties.



Anyway, you need how to deal with makefiles, invoking the compiler and linker directly only works for trivial things like "Hello world".



In Windows, under Visual Studio tools, you'll see a "VSxxx xXX Native Tools command line", then run NMAKE. In Linux, you need to learn how to create a makefile. In Linux/Unix, you need to learn how to create a makefile and run make.
?
2015-03-05 11:12:44 UTC
First of all, use correct spelling: it's a good habit, and we are training

professionals, not fools. Second, don't tell us what sort of answers you will

accept. Third, try to use correct grammar. Now: you need not use an IDE

for any language. You do need a text editor, such as notepad or (better)

notepad++ (since you are confined to Windows).

>

> John (gnujohn)


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...