Disabling Console Screen

Ask for help with ScummVM problems

Moderator: ScummVM Team

Post Reply
e_orz
Posts: 6
Joined: Thu Nov 09, 2006 8:36 pm

Disabling Console Screen

Post by e_orz »

Is there a way to disable the console screen that starts with scummVM?
clem
Posts: 2159
Joined: Mon Oct 31, 2005 11:14 am

Post by clem »

http://sourceforge.net/tracker/index.ph ... tid=418823

I managed to work around it by running ScummVM as a hidden window from a NSIS installation script, though
ExultDominus
Posts: 12
Joined: Mon Mar 03, 2008 5:22 pm

Post by ExultDominus »

sorry for the necrophilia.
I was searching the documentation and the FAQ but couldn't find any mention of whether you can hide the console window nowadays, so then I searched the forum and found only this small thread.
So is it possible nowadays or still not possible? (I assume you can still compile it with the No_Console switch, though)
Lostech
Posts: 157
Joined: Fri May 04, 2007 8:42 am
Contact:

Post by Lostech »

I think this depends on with which compiler or project file ScummVM for Windows was build.
IMHO it seems that this console window does only show up if ScummVM has been compiled with MSVC.
If ScummVM has been compiled with MinGW (GNU style in MSYS bash) there is no console window shown when it starts.
So perhaps the Windows MSVC maintainer should have an eye on the project file. Perhaps there is also in release configuration something enabled in the SDL part which was meant for debug config.
BTW: actually the actual SVN does also not compile with MSVC8.
ExultDominus
Posts: 12
Joined: Mon Mar 03, 2008 5:22 pm

Post by ExultDominus »

If ScummVM has been compiled with MinGW (GNU style in MSYS bash) there is no console window shown when it starts.
Ah, thanks. I'll try the snapshot then. If that is still done by Kirben, it'll be compiled with Mingw...

Edit: grrr, snapshot also opens a console :(
Oh, well, let's get the SVN and see how far I'll get in compiling it myself :)
User avatar
md5
ScummVM Developer
Posts: 2250
Joined: Thu Nov 03, 2005 9:31 pm
Location: Athens, Greece

Post by md5 »

Lostech wrote:I think this depends on with which compiler or project file ScummVM for Windows was build.
IMHO it seems that this console window does only show up if ScummVM has been compiled with MSVC.
If ScummVM has been compiled with MinGW (GNU style in MSYS bash) there is no console window shown when it starts.
So perhaps the Windows MSVC maintainer should have an eye on the project file. Perhaps there is also in release configuration something enabled in the SDL part which was meant for debug config.
BTW: actually the actual SVN does also not compile with MSVC8.
That's not true, you can disable the console in both MSVC and MinGW. It's enabled by default in ScummVM's MSVC project options, and to disable it in GCC you need to supply the "-mwindows" switch, which builds a windows application (without the console). If you do wish to disable the console under MSVC, you can always check the compilation instructions we got, it's right there:
http://wiki.scummvm.org/index.php/Compi ... he_console
(follow the reverse procedure)

Also, both the stable 0.11.1 source and the SVN version compile fine under MSVC7.1, MSVC8 and MSVC9, so I'm not sure why you're saying that you can't compile it. Have you included all the required libraries? What sort of error are you getting?

Step-by-step instructions for compiling the source for a variety of compilers and platforms can be found in the project's wiki:
http://wiki.scummvm.org/index.php/Compiling_ScummVM
Lostech
Posts: 157
Joined: Fri May 04, 2007 8:42 am
Contact:

Post by Lostech »

The MSVC compiling problem is solved.
It seems that I checked out this morning a SVN revision which was finally not fully updated (pretty much changes today).
So I copied the working SVN source files from the MinGW folder where a older SVN checkout from yesterday has been to the MSVC folder and compiling worked then. Now I have only a small linking problem because I´ve copied the MinGW libs... But this is easy to solve.

But why is the console enabled by default within the MSVC project and not in the normal GCC makefile?
ExultDominus
Posts: 12
Joined: Mon Mar 03, 2008 5:22 pm

Post by ExultDominus »

compiling with mingw indeed has the -mwindow set by default. Thanks. The initial compile went well, now I only need to put all the libs there, so everything get enabled :)
User avatar
MusicallyInspired
Posts: 1136
Joined: Fri Mar 02, 2007 8:03 am
Location: Manitoba, Canada
Contact:

Post by MusicallyInspired »

md5 wrote:That's not true, you can disable the console in both MSVC and MinGW. It's enabled by default in ScummVM's MSVC project options, and to disable it in GCC you need to supply the "-mwindows" switch, which builds a windows application (without the console).
Sorry for the necromancy. What exactly do you type in MSYS to do this? Eveything I try is unrecognized. Or do you edit the makefile to include it or something?
KuroShiro
Posts: 473
Joined: Thu May 15, 2008 7:42 am
Location: Somewhere Out There

Post by KuroShiro »

MusicallyInspired wrote:
md5 wrote:That's not true, you can disable the console in both MSVC and MinGW. It's enabled by default in ScummVM's MSVC project options, and to disable it in GCC you need to supply the "-mwindows" switch, which builds a windows application (without the console).
Sorry for the necromancy. What exactly do you type in MSYS to do this? Eveything I try is unrecognized. Or do you edit the makefile to include it or something?
You don't do anything in msys. Find the sdl-config file (it should be in your MinGW /bin directory) and edit it with some sort of notepad program. Scroll down a bit, and you should see the various flags. By default, under --libs and --static-libs, there should be a -mwindows flag. If you want the console to appear, you have to delete it (doing so shouldn't affect anything else). Alternatively, if you don't want it to appear, you have to add the flag along with the others.
User avatar
MusicallyInspired
Posts: 1136
Joined: Fri Mar 02, 2007 8:03 am
Location: Manitoba, Canada
Contact:

Post by MusicallyInspired »

I see. Where do I add it then? It's already there. I assume I have to add it somewhere else? Thanks for the response.
KuroShiro
Posts: 473
Joined: Thu May 15, 2008 7:42 am
Location: Somewhere Out There

Post by KuroShiro »

MusicallyInspired wrote:I see. Where do I add it then? It's already there. I assume I have to add it somewhere else? Thanks for the response.
If it's already there twice then the console should be disabled by default (you'll have to run configure again for it to change I think). If it's not you could try downloading a new copy of the sdl stuff from their website. If you're trying to reactivate the console then just delete -mwindows wherever it appears.
Kirben
Posts: 421
Joined: Wed Sep 21, 2005 12:15 pm
Location: Melbourne, Victoria, Australia

Post by Kirben »

The console window can no longer be disabled during compilation.

Use the --no-console command line option, to disable the console window under Windows.
User avatar
MusicallyInspired
Posts: 1136
Joined: Fri Mar 02, 2007 8:03 am
Location: Manitoba, Canada
Contact:

Post by MusicallyInspired »

Oh nice! I was waiting for it to be a command line parameter option. Didn't see it in the command line info page.
Post Reply