On 25 Jan 2006 at 21:02, Adriaan van Os wrote:
Prof A Olowofoyeku (The African Chief) wrote:
On 25 Jan 2006 at 15:45, Adriaan van Os wrote:
Has somebody worked with gpc on MinGW passing both -mwindows and -mconsole to create both a console box and GUI stuff ?
It is superfluous to pass both, since if you don't pass '-mwindows', then it defaults to '-mconsole'. If you pass both, you still end up with '-mconsole'. In either case, you can still have a GUI; '-mconsole' doesn't stop you from having a GUI.
Well, at http://www.mingw.org/docs.shtml it reads:
"The -mwindows switch is needed to create Windows executables instead of console applications. It assures the appropriate Windows libraries are linked in for you. To get a console screen along with a standard windows application, add the -mconsole flag as well as -mwindows."
The GUI libraries can be linked in manually of course. So, there is no difference between passing nothing and passing both -mwindows and -mconsole, apart from those standard GUI DLLs ?
Seems so to me. Perhaps '-mwindows' causes certain libraries to be linked automatically. However, in my windows.pas, I have a number of {$l ...} directives for the main GUI libraries. Perhaps that is why passing both switches makes no difference to passing neither.
PS: if you pass only '-mwindows', then you don't get a console at all.
Best regards, The Chief -------- Prof. Abimbola A. Olowofoyeku (The African Chief) web: http://www.greatchief.plus.com/