well it depends how you compile. i do g++ -std=c++11 [other options like -Wall and -Wextra when im working on releases] source_files.cpp -o elf_file_name* [any libraries to link to]
you probably want to do g++ yourfile.cpp -o whateveryouwanttocallthebinary
Hmm. I suppose what i'm asking is how do I get it to run? For instance n Code::Blocks, you press F9/Click the Green Arrow with the crank behind it and the program compiles(I think is the right term) and executes so if it was hello world, you'd get the black box appearing and saying "Hello World!".
With g++ main.cpp I can get it to compile(again not sure if the right term) but I can't get it to execute and say "Hello World" Instead, if I try something like run main.exe I get a white box that flashes quickly then Cygwin says "Aborted (core dumped). Or maybe that's what it was supposed to do? Maybe the white box said Hello World but it happens too fast for me to see it, should Hello World! appear in the Cygwin terminal though?