http://bugs.winehq.org/show_bug.cgi?id=13545
Summary: doubleclick on .exe starts all programs in wrong directory Product: Wine Version: unspecified Platform: All OS/Version: Linux Status: UNCONFIRMED Severity: major Priority: P2 Component: -unknown AssignedTo: wine-bugs@winehq.org ReportedBy: kazmirzak@web.de
It might be a problem of some distributions they are not able to cope with but still: if I doubleclick an .exe file for example in Ubuntu 8.04 dolphin, they don't find their daughter files and crash. This problem is NOT LIMITED to Ubuntu. Reason: the default directory is "/home/user" and not the directory we are in.
I know that you can't solve the problems of distributions but you can introduce an idiot-save and absolute usable workaround:
wine --grab-default-directory /media/disk/test/test.exe
This command line could be included in the application runner of the distribution, but not only that - it is even great for command-line-gurus. It simply tells wine to automatically cd to the directory of the .exe-file before starting it.
Possible for 1.0 ?
http://bugs.winehq.org/show_bug.cgi?id=13545
--- Comment #1 from Lei Zhang thestig@google.com 2008-05-30 12:18:18 --- You can just write a wrapper script to handle this. No need for new wine options.
exe=/media/disk/test/test.exe cd "$(dirname "$exe")"; wine "$(basename "$exe")"
or
exe=/media/disk/test/test.exe wine "$(winepath -w "$exe")"
http://bugs.winehq.org/show_bug.cgi?id=13545
Vitaliy Margolen vitaliy@kievinfo.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution| |INVALID
--- Comment #2 from Vitaliy Margolen vitaliy@kievinfo.com 2008-05-30 21:42:31 --- First of all "wine.desktop" that comes with Wine has this line: Exec=wine start /unix %f
If yours has something wrong or you are not using this command to run files on double click this bug is invalid.
http://bugs.winehq.org/show_bug.cgi?id=13545
James Hawkins truiken@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #3 from James Hawkins truiken@gmail.com 2008-05-31 02:13:00 --- Closing.
http://bugs.winehq.org/show_bug.cgi?id=13545
kazmirzak@web.de changed:
What |Removed |Added ---------------------------------------------------------------------------- Resolution|INVALID |WONTFIX
--- Comment #4 from kazmirzak@web.de 2008-06-01 06:32:51 --- First: for some reason "wine.desktop" did NOT include start /unix %f
Second: a wrapper script seems not appropriate for the normal user
Third: start is a really BAD workaround: see this console output:
$ start [anything]
start: Need to be root
So even a patched wine.desktop doesn't work.
http://bugs.winehq.org/show_bug.cgi?id=13545
Vincent Povirk madewokherd@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |madewokherd@gmail.com
--- Comment #5 from Vincent Povirk madewokherd@gmail.com 2008-06-01 11:37:43 --- The wine.desktop file included in versions of Wine from 0.9.60 on does say Exec=wine start /unix %f. Do you have an older version installed?
If your version is recent, do you have a wine.desktop file in ~/.local?
http://bugs.winehq.org/show_bug.cgi?id=13545
--- Comment #6 from kazmirzak@web.de 2008-06-02 05:37:07 --- Hi,
I have the latest ubuntu repository installed, that is version 0.9.59-0-ubuntu5. Obviously wine has made a great step since then, but there is still mystic in it:
There is a wine.desktop in "~/.local/share/applications". I patched the Exec line and it now looks like this: ---------------------------------- [Desktop Entry] Comment[de]= Comment= Exec=wine start /unix %f GenericName[de]= GenericName= MimeType=application/x-ms-dos-executable;application/x-executable; Name[de]=Wine Windows-Emulator Name=Wine Windows-Emulator StartupNotify=true Terminal=false TerminalOptions= Type=Application X-DBUS-StartupType= X-KDE-SubstituteUID=false X-KDE-Username= ------------------------------------------
There is still the problem that start needs to be root and consequently the files above disabled wine to open anything. Is there something wrong with "start"?
I think, despite the little start thing, a tiny additional command line parameter needs 10 minutes to be coded and won't disturb anyone who doesn't need it. It's just a "nice-to-have".
http://bugs.winehq.org/show_bug.cgi?id=13545
--- Comment #7 from Vincent Povirk madewokherd@gmail.com 2008-06-02 06:54:34 --- The /unix switch was added to wine start in 0.9.60. You'll either need to upgrade wine (see http://winehq.org/site/download-deb) or use a shell script.
If you have to run Wine as root, that is likely because you ran it first with sudo: http://wiki.winehq.org/FAQ#head-96bebfa287b4288974de0df23351f278b0d41014
http://bugs.winehq.org/show_bug.cgi?id=13545
--- Comment #8 from kazmirzak@web.de 2008-06-03 09:57:27 --- Hi,
no, Vincent, that is not true. Wine does start as normal user if I type "wine abc.exe" - it only can't get the directory right. It is START that doesn't work as a normal user.
Please, could you try on your machine to cd to a given directory, decide for a file (abc.bmp) and try "start abc.bmp" - what do you get?
Apart from hoping for your particular answer, I will wait till 0.9.60 is in the official repositories, which can't take too long I suppose.
http://bugs.winehq.org/show_bug.cgi?id=13545
--- Comment #9 from Vincent Povirk madewokherd@gmail.com 2008-06-03 10:09:29 --- That probably will take until the next major Ubuntu release, which will probably be around October.
I do get the "need to be root" message. Apparently, there is a start command in Linux that has nothing at all to do with Wine and does require root. You should run your file as: wine start filename
http://bugs.winehq.org/show_bug.cgi?id=13545
kazmirzak@web.de changed:
What |Removed |Added ---------------------------------------------------------------------------- Resolution|WONTFIX |LATER
--- Comment #10 from kazmirzak@web.de 2008-06-05 01:51:19 --- Hi, Vincent,
obviously you are right! There is a start.exe that is executed when running "wine start abc". Unfortunately, start.exe doesn't change anything in the behaviour I get, so it doesn't change the default directory to the executed file's. I conclude start.exe has been patched in Version 0.9.60, so I'm not going to rise more questions.
The second good news is that, in the biggest emergency, I could patch this .exe on my own ;-)
Thanks for your help and see you again in 0.9.60, which won't last till October - in October, I expect version 1.0 to be shipped with Ubuntu!!
http://bugs.winehq.org/show_bug.cgi?id=13545
Dmitry Timoshkov dmitry@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Severity|major |normal Resolution|LATER |ABANDONED
--- Comment #11 from Dmitry Timoshkov dmitry@codeweavers.com 2008-06-09 01:58:21 --- Changing the resolution to abandoned. If the problem persists please open a separate bug report.
http://bugs.winehq.org/show_bug.cgi?id=13545
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Platform|All |Other
--- Comment #12 from Austin English austinenglish@gmail.com 2012-02-23 15:24:33 CST --- Removing deprecated 'All' Platform.