Program Launchers on desktop not working after updates

Message
Author
FX-Tech
Posts: 19
Joined: Thu Sep 17, 2020 11:30 pm

Re: Program Launchers on desktop not working after updates

#21 Post by FX-Tech »

Hey Guys,

So, this machine is a member of a Windows AD Domain. That's a normal home folder location for a user on a domain. There is usually a folder under home indicating the name of the domain and that users in that folder are members of the domain. The same launcher works from the side bar AND the main wine menu. Wine is not hanging.

You probably can't reproduce the issue if it is an issue with being a member of a domain. It's only not working if the launcher is on the desktop. Probably not a lot of MX users are using machines that are members of a domain. Is there any way to turn off this new "Feature"?

Thanks,
Trevor

FX-Tech
Posts: 19
Joined: Thu Sep 17, 2020 11:30 pm

Re: Program Launchers on desktop not working after updates

#22 Post by FX-Tech »

Thought I'd change the launcher to open in a terminal to see if there was any useful output:
Terminal View.jpg
You do not have the required permissions to view the files attached to this post.

User avatar
fehlix
Developer
Posts: 12732
Joined: Wed Apr 11, 2018 5:09 pm

Re: Program Launchers on desktop not working after updates

#23 Post by fehlix »

FX-Tech wrote: Thu Jan 19, 2023 1:49 pm Here is the command in the launcher that is on the Desktop:

Code: Select all

env WINEPREFIX="/home/BPLSV/trevorj/.wine" wine C:\\\\ProgramData\\\\Microsoft\\\\Windows\\\\Start\\ Menu\\\\Programs\\\\IntelEvent\\ Express.lnk
That's the same command as the launcher in the main menu under the wine folder. To put it on the Desktop I just did a right click ans selected "Add to Desktop".
Would this wine command shown in the launcher run within terminal opened within the desktop directory:
Here with replaced double backslash "\\" by singel backslash "\"

Code: Select all

env WINEPREFIX="/home/BPLSV/trevorj/.wine" wine C:\\ProgramData\\Microsoft\\Windows\\Start\ Menu\\Programs\\IntelEvent\ Express.lnk

FX-Tech
Posts: 19
Joined: Thu Sep 17, 2020 11:30 pm

Re: Program Launchers on desktop not working after updates

#24 Post by FX-Tech »

Hi Fehlix,

Yes, I saw that too, but this launch command was generated directly by wine when the program was installed and has worked flawlessly for several years, until now. I did try changing the line and it made no difference. Thanks.

User avatar
fehlix
Developer
Posts: 12732
Joined: Wed Apr 11, 2018 5:09 pm

Re: Program Launchers on desktop not working after updates

#25 Post by fehlix »

FX-Tech wrote: Thu Jan 19, 2023 6:24 pm Hi Fehlix,

Yes, I saw that too, but this launch command was generated directly by wine when the program was installed and has worked flawlessly for several years, until now. I did try changing the line and it made no difference. Thanks.
That was meant as a question whether the env -line runs or not, from terminal opened in Desktop directory?

FX-Tech
Posts: 19
Joined: Thu Sep 17, 2020 11:30 pm

Re: Program Launchers on desktop not working after updates

#26 Post by FX-Tech »

Just realized I attached the wrong screen shot of the terminal. The previous one is when I had modified the command line to remove spaces. This is what the terminal output looks like with the command line that wine generated and has always worked:
terminal output.jpg
You do not have the required permissions to view the files attached to this post.

User avatar
fehlix
Developer
Posts: 12732
Joined: Wed Apr 11, 2018 5:09 pm

Re: Program Launchers on desktop not working after updates

#27 Post by fehlix »

FX-Tech wrote: Thu Jan 19, 2023 6:39 pm Just realized I attached the wrong screen shot of the terminal. The previous one is when I had modified the command line to remove spaces. This is what the terminal output looks like with the command line that wine generated and has always worked:
terminal output.jpg
I hate terminal text posted as screenshot images!
OK, can you run the same command I posted from Terminal
but this time change first directory to $HOME:
Open Terminal:

Code: Select all

cd $HOME
env WINEPREFIX="/home/BPLSV/trevorj/.wine" wine C:\\ProgramData\\Microsoft\\Windows\\Start\ Menu\\Programs\\IntelEvent\ Express.lnk

User avatar
fehlix
Developer
Posts: 12732
Joined: Wed Apr 11, 2018 5:09 pm

Re: Program Launchers on desktop not working after updates

#28 Post by fehlix »

OK, seems I can reproduce, something with the quotings within the launcher on the desktop:

This type Exec line of launcher worked for me from with the launcher but als from the terminal CLI :

Code: Select all

Exec=env WINEPREFIX="/home/BPLSV/trevorj/.wine" wine "C:/ProgramData/Microsoft/Windows/Start Menu/Programs/IntelEvent Express.lnk"
So right click on the Launcher on the Desktop and replace the command with

Code: Select all

env WINEPREFIX="/home/BPLSV/trevorj/.wine" wine "C:/ProgramData/Microsoft/Windows/Start Menu/Programs/IntelEvent Express.lnk"
or alternatively open in Text editor and replace the Exec= line
+++EDIT+++
Opps corrected ... again: mainly repalce all "\\" with "/" and "\ " with just " ",
and put all int double quotes

++EDIT 2 +++
Here the way to reproduce the issue:
I've installed within wine, Total Commander,
which created this Launcher on the Desktop:

Code: Select all

[Desktop Entry]
Name=Total Commander
Exec=env WINEPREFIX="/home/demo/.wine" wine C:\\\\Program\\ Files\\\\totalcmd\\\\totalcmd.exe 
Type=Application
StartupNotify=false
Comment=C:\\Program Files Totalcmd
Icon=B838_totalcmd.0
StartupWMClass=totalcmd.exe
Path=
Terminal=false
and gave the same error of not starting:
now I replaced the Exec line with

Code: Select all

Exec=env WINEPREFIX="/home/demo/.wine" wine "C:/Program Files/totalcmd/totalcmd.exe"
so the Desktop-launcher looks like this:

Code: Select all

[Desktop Entry]
Name=Total Commander
Exec=env WINEPREFIX="/home/demo/.wine" wine "C:/Program Files/totalcmd/totalcmd.exe"
Type=Application
StartupNotify=false
Comment=C:\\Program Files Totalcmd
Icon=B838_totalcmd.0
StartupWMClass=totalcmd.exe
Path=
Terminal=false
which worked, /after marke as trusted.
So the whole issue seems related to the handling of those quadro "\\\\" backslashes with the Desktop launcher, created by wine-installer, which appears to be now an issue within Xfce 4.18. ... Ufff.. :turtle:

+++ EDIT 3 +++
Or alternatively:
* Replace all "\\\\"-quadro backslashes with one "/"-forward slash.
* Replace "\\ " double-backslash+ space with "\ " one backslash and space

Or this one liner running with terminal in the Desktop directory, which would fix all wine launchers on the Desktop in one go:

Code: Select all

perl -i -pe 's/\\{4}/\//g; s/\\{2} /\\ /g;'  *.desktop
:happybday:

+++ EDIT 4 +++
This is the "final" solution use only forward-slashes and quotes . Replace all "\\\\"-quadro back-slashes with a single "/" forward-slash
and replace all "\\ " double-slash + space with a double-quoted space " ":
As one liner:

Code: Select all

perl -pe 's/\\{4}/\//g;s/\\{2} /" "/g;' *.desktop
This makes sure, any future Xfce-fix of desktop launcher, which may properly handle "\\\\" and "\\ " bask-slashes, by using only a "forward"-slashes and quote spaces.

FX-Tech
Posts: 19
Joined: Thu Sep 17, 2020 11:30 pm

Re: Program Launchers on desktop not working after updates

#29 Post by FX-Tech »

Hey Fehlix,

Thought I posted a reply a few minutes ago, but I must have not. Anyway, I solved it by making a new launcher and using this command line:

Code: Select all

env WINEPREFIX="/home/BPLSV/trevorj/.wine" wine C:\\ProgramData\\Microsoft\\Windows\\Start\ Menu\\Programs\\IntelEvent\ Express.lnk
It works in a newly created launcher. It seems that wine uses a single "\" to indicate a space and "\\" to indicate a folder branch. Not sure why there were 3 of them in places, but obviously there is an issue with the new security and wine. Maybe the new launcher automatically marks it as trusted? Just guessing here as I have no idea how the new security feature works.

Thanks for your help guys!
Cheers,
Trevor

User avatar
fehlix
Developer
Posts: 12732
Joined: Wed Apr 11, 2018 5:09 pm

Re: Program Launchers on desktop not working after updates

#30 Post by fehlix »

FX-Tech wrote: Thu Jan 19, 2023 7:31 pm Not sure why there were 3 of them in places, but obviously there is an issue with the new security and wine.
Nope, that's a strong indication of a regression ( a bug), nothing todo with security. The old quador- "\\\\" backslashes
where needed, b/c desktop files when "started" would first replace "\\\\" with "\\".
Next step would be to pass this argument to wine, which would then replace "\\" with "\"
As it works from the menu, that#s an clear indication the new Desktop-launcher handling introduced
this issue. Not an issue with the new trusted feature, but an regression withn the new code for handling launchers.
So suggest, to use my adjusted fix "with "forward slashes, b/c they may fix the issue,
to work properly with quadro- "\\\\" backslashes again, which would than make you "\\"-double backslash solution not work. (see "EDIT 4" with my last post above...)

Post Reply

Return to “General”