A single command to open Portal 2 in a debug console.

Questions about Wine on Linux
Locked
Comokanu
Newbie
Newbie
Posts: 1
Joined: Wed Jun 06, 2012 3:16 pm

A single command to open Portal 2 in a debug console.

Post by Comokanu »

Due to some unknown problem I can only run Portal 2 by going to Winetricks --> Select 'steam' prefix --> Run a command line shell --> # wine PATH_TO_PORTAL2.EXE

This works perfectly fine, but it is kind of tedious. I know of the WINEDEBUG command but I do not understand the syntax. I would like to know a way to do all of the steps at once with a single command. I can either make a .desktop file with a command that opens portal2.exe from within the debug shell, or create a .sh file with multiple commands.

I am running Ubuntu Linux 12.04 64 bit and my Steam prefix is a 32 bit prefix.

Thank you in advance.
User avatar
SpawnHappyJake
Level 5
Level 5
Posts: 272
Joined: Sun Feb 06, 2011 5:57 am

Post by SpawnHappyJake »

I don't think I can help much in that department, but I see that you ran Wine as root ("#" means root). That's a no-no and breaks stuff. There is a way to fix what it breaks, however. I wonder if that could be part of the issue (guessing not, I just couldn't let you go running Wine as root - or else the Wine police might get you :P)

The one "trick" with .sh files I know of is to mark them as executable, or else it prompts you whether you want to view the file itself or execute it when you click it. Just right-click it, go into the properties and check off "allow to be executed as a program" or whatever. I think it's under "Permissions".

Jake
User avatar
dimesio
Moderator
Moderator
Posts: 13207
Joined: Tue Mar 25, 2008 10:30 pm

Post by dimesio »

As SpawnHappyJake says, first fix the problems you've created by running as root. http://wiki.winehq.org/FAQ#run_as_root

The command to start your game would be:

Code: Select all

WINEPREFIX=/path/to/prefix wine start /Unix /path/to/program.exe
(substitute the actual paths)
Locked