Wine makes TC x32_x64 installer abort on Ubuntu 12.04x64

English support forum

Moderators: white, Hacker, petermad, Stefan2

User avatar
karlchen
Power Member
Power Member
Posts: 4603
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Wine makes TC x32_x64 installer abort on Ubuntu 12.04x64

Post by *karlchen »

Hello, folks.

Preface:
I know that Total Commander is a Windows software. Therefore problems when executing the combined x32/x64 installer of Total Commander 8.0x, experienced on Ubuntu 12.0x64 and Wine 1.4 x86_x64, will only be relevant to a small minority of T.C. users.
Nonetheless, I thought it may worth reporting, hoping someone might be around who has got an idea on how to diagnose and solve the Wine problem.


Prerequisites:
  • Ubuntu 12.04 x64 "Precise Pangolin", available updates installed
  • Wine 1.4 x86_x64 installed
  • Total Commander 8.0 combined setup programme for x32/x64, e.g. tcm801x32_64_rc2.exe
How to reproduce:
  1. Launch tcm801x32_64_rc2.exe
  2. Select "Install normally"
  3. Almost immediately afterwards a small dialogue box will be displayed. Title "Wine programme crash". Diagnostic message: "Internal error - invalid parameter received"
  4. The only choise is to confirm the message. The installation has been aborted.
If you perform the same installation attempt on the commandline the scenario will look like this:
karl@Pangolin:~/Downloads/TotalCommander$ wine tc801x32_64_rc2.exe
fixme:heap:HeapSetInformation 0x240000 0 0x23fcd0 4
fixme:wtsapi:WTSEnumerateProcessesA Stub (nil) 0x00000000 0x00000001 0x23f768 0x23f74c
wine: Unhandled page fault on read access to 0x40019678 at address 0x7f1b2960db91 (thread 0035), starting debugger...
Can't attach process 0034: error 5
karl@Pangolin:~/Downloads/TotalCommander$
Note:
This is a Wine problem. Wine is to blame, not the T.C. installer.
Using the 32-bit installer tc801x32_rc2.exe in the same environment will work as expected.

Workaround:
Install T.C. 8.0x 64-bit manually.

Q: Why was this posted here and not in a Wine forum?
A: Because sometimes I am being an optimist hoping there will be some simple solution like in the other Wine/T.C. thread a week ago. :wink: :oops:

Kind regards,
Karl
Last edited by karlchen on 2012-07-14, 12:43 UTC, edited 1 time in total.
MX Linux 21.3 64-bit xfce, Total Commander 10.52 64-bit
The people of Alderaan keep on bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine.
The Prophet's Song
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48113
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

WTSEnumerateProcessesA is called by both the 32-bit install.exe and the 64-bit install.exe/install64.exe to determine the logged on user name for the last page of the installer, where the user can choose for which use the shortcuts should be created. However, the same 64-bit installer is used both in the combined and the 64-bit only installer.

Can you try whether you get this crash with the 32-bit only installer? This would mean that the combined installer would be launching the 32-bit install.exe instead of the 64-bit install64.exe in the combined installer.
Author of Total Commander
https://www.ghisler.com
User avatar
karlchen
Power Member
Power Member
Posts: 4603
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, Christian.

Thank your for your reply.

About your question
Can you try whether you get this crash with the 32-bit only installer?
As was stated in my post in green letters
Using the 32-bit installer tc801x32_rc2.exe in the same environment will work as expected.
I.e. installing the 32-bit editions works fine using the 32-bit installer.

The problems affecting the combined 32-bit/64-bit installer run on wine 1.4 may really be that Wine can handle 32-bit executables and that Wine 1.4 can handle 64-bit executables, but that Wine cannot really handle executables holding both kind of executables. Maybe, too, Wine does not give the appropriate answer when asked about 32-bit or 64-bit.

Anyway, it is really just a minor issue affecting the installation procedure, and it can be worked around.

Kind regards,
Karl
MX Linux 21.3 64-bit xfce, Total Commander 10.52 64-bit
The people of Alderaan keep on bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine.
The Prophet's Song
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48113
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

I have installed Ubuntu 64-bit in a virtual machine now, and can confirm that the function WTSEnumerateProcessesA is present but crashes. Unfortunately evewn surrounding it with a __try ... __except block cannot avoid the crash. I found a function to detect Wine and skipped the function, but the installer keeps crashing in other functions too. Finally, since the CAB unpack dll isn't ported to 64-bit either, the installer couldn't work anyway.

The only way to install it was like this:
1. Install the 32-bit version
2. Run it
3. Open the 64-bit installer with Ctrl+PageDown
4. Extract the files from the CAB file which aren't already in the TC dir
5. Create a link for totalcmd64.exe

I could find a solution for the cursor problem in the 64-bit version, though (by setting the cursor position to 0 before reading the new directory), so the 64-bit version works fine except for the missing CAB unpacker.
Author of Total Commander
https://www.ghisler.com
User avatar
karlchen
Power Member
Power Member
Posts: 4603
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, Christian.

Thanks you very much for taking the time to investigate the Wine related issues affecting Total Commander 8.0 x64 and its (combined) installer. :)

About the steps to install T.C. 8.0 x64:
Yes, these are the steps that will work and which I have followed, too. :)

About extracting CAB files:
Workaround/solution reported => here :wink:

About the cursor position in T.C. 8.0 x64 on Ubuntu x64:
Great. :) - Though one gets used to the visual glitch after a while. (Linux users have got to learn to live with compromises.)

Cheers,
Karl
MX Linux 21.3 64-bit xfce, Total Commander 10.52 64-bit
The people of Alderaan keep on bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine.
The Prophet's Song
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48113
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Please try it with RC4. Unfortunately I cannot make the installer work, only the Wine developers can. But the cursor problem should be gone now.
Author of Total Commander
https://www.ghisler.com
User avatar
karlchen
Power Member
Power Member
Posts: 4603
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Wine makes TC x32_x64 installer abort on Ubuntu 12.04x64

Post by *karlchen »

Hello, Christian.

Having installed and tested Total Commander 8.01 RC4 x64/x32 on Ubuntu 12.04 x64 and Wine 1.4 I can confirm
  • the combined installer triggers the known Wine problem. -> Will report so to the Wine makers.
    Modified the thread title to read "Wine makes TC x32_x64 installer abort on Ubuntu 12.04x64", original "TC x32_x64 installer makes Wine abort on Ubuntu 12.04x64", to suggest clearly that the bottom of the problem is on the Wine side, which in fact it is.
  • the 32-bit installer still works fine.
  • the double cursor issue affecting T.C. 8.0(1) x64 has disappeared. :) The original thread about it, [Solved] TC 8.0x64 cursor display problem on Ubuntu 12.04x64, has been marked [solved].
Thanks a lot for taking the time to investigate and implement the workaround fix.

Cheers,
Karl
MX Linux 21.3 64-bit xfce, Total Commander 10.52 64-bit
The people of Alderaan keep on bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine.
The Prophet's Song
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48113
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Thanks! Unfortunately there will probably not be a fast solution because of the missing CAB unpacker...
Author of Total Commander
https://www.ghisler.com
User avatar
karlchen
Power Member
Power Member
Posts: 4603
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, Christian.

About the CABview problem:

I am not quite sure whether my report on how to solve the CAB unpacker problem inside Wine was not too clear: It is pretty trivial for any Wine user to fix the problem affecting the Wine internal (64-bit) cabview.dll problem themselves: TC8.0x64 Access Violation on CAB Files under Ubuntu 12.04x64

About the 64-bit installer problem:

Someone was a lot faster than me and reported the problem with the T.C. 64-bit installer on the Wine Bugzilla site: Total Commander 8.0 64-bit installer crashes due to pointer truncation (image base address > 4 GiB)].
This bug report suggests that indeed Wine behaves properly, but that it seems as if the 64-bit T.C. installer may hold a 32-bit cast operation which should not be present in the 64-bit installer.
(This may or may not be correct. At least this is what the bug reporter assumes.)

In case the left over cast operation is not just a hypothesis, could the same apply to the cabview calls as well? (casting some numbers not to exceed 32-bit size which is no longer required on 64-bit?)

Kind regards,
Karl
--
Ref.:
+ Wine Forum: Wine makes TC x32_x64 installer abort on Ubuntu 12.04x64
+ Wine Bugzilla: Total Commander 8.0 64-bit installer crashes due to pointer truncation (image base address > 4 GiB)
MX Linux 21.3 64-bit xfce, Total Commander 10.52 64-bit
The people of Alderaan keep on bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine.
The Prophet's Song
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48113
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

I will check it.
Author of Total Commander
https://www.ghisler.com
User avatar
karlchen
Power Member
Power Member
Posts: 4603
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Good evening, Christian.

Great. Thanks a lot.

Karl
MX Linux 21.3 64-bit xfce, Total Commander 10.52 64-bit
The people of Alderaan keep on bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine.
The Prophet's Song
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48113
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

I can confirm that there are some typecasts from HANDLE to int - but HANDLE is now 64-bit, but int is only 32-bit...

Now the installer works when skipping the call to WTSEnumerateProcessesA, but I cannot get the cab dll to work.

I copied the 32-bit dll to the 32-bit system32 dir, and the 64-bit dll to the 64-bit system32 dir and restarted TC, but it still crashes. How to you tell Wine to use these dlls?
Author of Total Commander
https://www.ghisler.com
User avatar
karlchen
Power Member
Power Member
Posts: 4603
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Good evening, Christian.
I copied the 32-bit dll to the 32-bit system32 dir, and the 64-bit dll to the 64-bit system32 dir
Exactly. 32-bit DLL to SysWow64 and 64-bit to System32, just as on Windows 64-bit.
How to you tell Wine to use these dlls?
With the help of winecfg.
Launch winecfg
Go to the the tab "Libraries" ("Bibilotheken")
Scroll down the drop down list to "cabinet".
Select "cabinet" and click on "Festlegen" (hm, what does the English version tell?)
Anyway, this will add the entry "Cabinet (Native, builtin)" to the lower part of the dialog box.
Click Apply.
That's it.

Native=genuine Windows DLL
Builtin=Wine DLL
So "Cabinet (Native, builtin)" means: if present prefer the genuine Windows cabinet.dll over the Wine DLL.

Cheers,
Karl
MX Linux 21.3 64-bit xfce, Total Commander 10.52 64-bit
The people of Alderaan keep on bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine.
The Prophet's Song
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48113
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

That worked, thanks! Please try this new 64-bit installer:
https://plugins.ghisler.com/beta/install64.zip
Author of Total Commander
https://www.ghisler.com
User avatar
karlchen
Power Member
Power Member
Posts: 4603
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

ghisler(Author) wrote:Please try this new 64-bit installer:
https://plugins.ghisler.com/beta/install64.zip
I sure will :) ... post back the result ...

Karl
MX Linux 21.3 64-bit xfce, Total Commander 10.52 64-bit
The people of Alderaan keep on bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine.
The Prophet's Song
Post Reply