Opened 7 years ago

Closed 7 years ago

#109 closed defect (fixed)

unable to run on windows xp

Reported by: bakhtiarhasmanan@… Owned by: jan vrany
Priority: major Milestone: 8.0.0
Component: default Keywords:
Cc: Also affects CVS HEAD (eXept version): no

Description

st/x: version 6.2.6 b2424
os: winxp sp3
step: invoke cmd, run stx.bat

VM [warning]: could not find/load classLib <libstx_libbasic> (error=0x7f / 127).

FATAL: Failed to load class library "libstx_libbasic"
new: e50020 .. e50020 .. 1050020 surv: 1060020 .. 1260020
old: 509c0000 .. 50a19160 .. 589c0000 cold: 0 .. 0

LIBSTX_LIBBASIC.DLL is calling RegDeleteKeyExW from advapi32.dll which XP only have RegDeleteKeyW.

Attachments (1)

libbasic_fix_1_of_1_rev_12176ee7234c_Issue__109__Call__RegDeleteKeyExW____indirectly_via_function_pointer.patch (4.5 KB ) - added by jan vrany 7 years ago.
Fix proposal (attempt 1)

Download all attachments as: .zip

Change History (9)

comment:1 by bakhtiarhasmanan@…, 7 years ago

note: that's only dll that have issue, once solved stx run happily, but strangely I only able use the native ui if stx run from console, double click from explorer will give old "non-native" ui.

comment:2 by jan vrany, 7 years ago

Milestone: 8.0.0
Owner: set to jan vrany
Status: newaccepted

comment:3 by jan vrany, 7 years ago

Right, RegDeleteKeyExW() is not available on 32bit Windows XP so linking the library naturally fails. The cuplrit is Win32OperatingSystem.st:15835

To make it working on such an ancient Windows, we have to link RegDeleteKeyExW() on demand manually using LoadLibary() and GetProcAddress()...

note: that's only dll that have issue, once solved stx run happily,

How did you "solve" it? Did you fix the code and recompiled on Windows XP or what?
If you are able to recompile, can you try attached patch and let me know if it works?

The thing is, I don't have any XP machine at hand any more, only Win 7 & Win 10...

comment:4 by bakhtiarhasmanan@…, 7 years ago

I don't know how to compile st/x (yet), this is my first time using st/x. I have shims dll (code borrowed from WINE project) that have some vista-compatible API so I just redirect LIBSTX_LIBBASIC.DLL's IAT to that shim dll.

I think the patch is justified for this case. Thank you.

comment:5 by jan vrany, 7 years ago

I see. I'll upload a custome test build somewhere for you to test before pushing the fix to. However I can't promise I can make it this week. Beginning of next week for sure.

comment:6 by jan vrany, 7 years ago

OK, could you please try this custom build

https://swing.fit.cvut.cz/download/smalltalkx/smalltalkx-jv-branch-6.2.6_20170102_i386-win32.zip

Maybe there are more problems like this one. Also, the problem with GUI look should be fixed in this build.

comment:7 by jan vrany, 7 years ago

A friend confirmed the above build works, so I'll polish the commit, add some tests and push soon.

comment:8 by bakhtiarhasmanan@…, 7 years ago

Resolution: fixed
Status: acceptedclosed

Sorry for very late response, it runs now and ui issue also fixed.

Note: See TracTickets for help on using tickets.