Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Dave Yeo

Pages: [1] 2 3 ... 325
I tried various combinations of dllexport (which seems to be mandatory to export the symbol) and stdcall cdecl... But I ever end up with exporting _NdpTypes instead NdpTypes. I was under the impression that c++ don't add the _ but obviously I misinterpreted some stuff.

Another idea, is there any emx tool which can modify the exported symbols? Or add a new symbol to a dll which references to the orignal?

Btw. this all started cause I didn't manage to convince c++/linker to work with a .def file as it was used with icc or watcom. You know I'm not experienced with all this stuff so there is much guessing on my side.

You only need dllexport if you don't have the symbols in the def file. Traditionally, before we got dllexport, you hand wrote a DEF file including the exports, either by name or ordinal or you ran emxexp on the
object files and piped the results to the def file. Run emxexp with no parameters to see usage..
I've only done it the other way, pulling in symbols from a GCC DLL to a OW binary.
Note that with OW, you have to be careful to use the right calling convention to begin with, it defaults to its own calling convention which is incompatible with GCC DLLs, it uses registers instead of the stack.
See "Open Watcom 2.0 C/C++ Programmers Guide under Commonly Asked Questions, Converting to OpenWatcom C/C++, Conversion from IBM-compatible PC compilers.
In the case of porting from icc or OW, I simply edit the DEF, adding the underscores

Edit: You might also need the extern keyword

Isn't it _System to use non-underscored variable names?

Might be.

After unpacking, preferably a copy of the DLL, you can run strings on it, piping the results through less,
Code: [Select]
strings WPCONFIG.DLL | less
And see all text in the DLL. Strings is not perfect so you do get some garbage mixed in. There's a lot of strings in this DLL.
Or if you know what you are looking for, use grep,
Code: [Select]
H:\tmp>strings WPCONFIG.DLL  | grep "POINTERS"


Applications / Re: Experiment: Moving OS/2 Graphic/MM Resources
« on: July 14, 2024, 07:25:12 pm »
I think "lxlite /x file"

It's one of the things that I find irritating about the various Linux desktop environments, this forcing everything to open in the centre of the desktop. In theory you could pass -geometry x y IIRC to force where to open but wouldn't be surprised geometry is ignored.
Another irritation is associating an icon with a program, which seems non-trivial.

Hi JTA, earlier versions of Hobbes existed, some were distributed in CD form by Walnut Creek such as, there's a couple of other ones floating around.
Most of this software will run on AOS, sometimes needing a simple recompile.

Applications / Re: ArcaOS v5.1 and VirtualBox OS/2 Version
« on: July 05, 2024, 02:22:37 am »
Was wondering if you were finally able to download the VBOX source?

I was having profile problems the last few days, which was locking me out of my account here. But two days ago, I noted an email was sent to Adrian @ Netlabs that timeline was not working as expected, and downloads were really slow.



Hi Mark, I ended up downloading in Linux, where it only timed out once. Building, I ran into a problem with OpenSSL where the API has changed and it seems non-trivial to figure it out, at least for me. Guess I should download the official source and see how they fixed it.
Meanwhile after a normal wet cold spring, something that hasn't been happening here for some years, we're back to the heat, only low 30's unlike the other year where it was mid 40's. At least no fires or flooding, at that the Fraser barely rose at all at the Mission train bridge.
Hopefully you will have an uneventful year.

It's the calling convention, cdecl vs stdcall. I think you need __attribute__ ((__cdecl)), might be ((__stdlib)) and __declspec instead of __attribute__
Code: [Select]
__attribute__ ((dllexport)) __attribute__((__stdcall)) extern const char *NdpTypes[];
or __cdecl
Been a while since I thought about this so sorry for being unclear, needed it in the past for linking OW and GCC.
gcc vs g++ shouldn't matter

Applications / Re: General Software Testing
« on: June 30, 2024, 08:50:34 am »
I did try that, along with a larger stack,
Code: [Select]
06-25-2024  22:00:48  SYS3175  PID 01d5  TID 0001  Slot 0082
P1=00000001  P2=0c685000  P3=XXXXXXXX  P4=XXXXXXXX
EAX=00001740  EBX=00001740  ECX=00000230  EDX=121ff344
ESI=0c685000  EDI=122001c4
DS=0053  DSACC=d0f3  DSLIM=bfffffff
ES=0053  ESACC=d0f3  ESLIM=bfffffff
FS=150b  FSACC=00f3  FSLIM=00000030
GS=0000  GSACC=****  GSLIM=********
CS:EIP=005b:1f9adf76  CSACC=d0df  CSLIM=bfffffff
SS:ESP=0053:0809278c  SSACC=d0f3  SSLIM=bfffffff
EBP=ffffe8c0  FLG=00010202

PMMERGE.DLL 0004:0001df76

I've since lost my work as it was on the ram disk

Applications / Re: ArcaOS v5.1 and VirtualBox OS/2 Version
« on: June 29, 2024, 07:27:51 am »
As a general comment, since this version of VirtualBox was compiled on 2018, I really hope/wish that someone can recompile it just point to our currents DLLs. (if it works). I guess the full source code is here:

Thought I'd give it a try, or at least see where newer GCC's have broken it. Unluckily I'm having a hell of a time downloading the source. I've downloaded about 1.5 GB's so far. It runs for a while updating the files, then stalls though I see I'm downloading at close to 500KB/s, eventually times out, have to do a "svn cleanup" and redo "svn up"
The correct command for the source is,
Code: [Select]
svn checkout vbox
Adjust the last argument to how you want the source labeled.
More later when I get the source downloaded.
BTW, IIRC, the workaround for that error was to wait a while and retry.

Applications / Re: General Software Testing
« on: June 28, 2024, 05:02:12 pm »
Ran fine here, besides the default scaling being too small. After adjusting the scale to 100% looks good.

Applications / Re: General Software Testing
« on: June 26, 2024, 02:11:07 am »

I'm not sure why your link attempt went wrong.  Probably the linker you attempted to use.  I can link here with either icc.exe or 3.0.8's ilink.

Yes, it was using ilink 5.0. My env cmd had %VACPP%\bin towards the end of PATH so it was picking up the wrong ilink.

Applications / Re: General Software Testing
« on: June 25, 2024, 06:26:30 am »
I tried building it with VisualAge 3.08 and os2tk45
Complex.h was missing, I got it from the Visualage includes, along with iostream.h. complexm.lib was missing, I edited it out of the makefile. Almost compiled, I don't know ibmcpp well enough, error was,
Code: [Select]
Object Modules [.obj]: /base:0x10000  /pmtype:pm  +
Object Modules [.obj]: "fractz.OBJ"
Run File [fractz.*]: "FRACTZ.EXE"
Map File []: ""
Libraries [.lib]:
Definitions File [nul.def]: "fractz.def"
ILink : fatal error LNK1082: lnkods50.exe : stub file not found
NMAKE : fatal error U1077: 'W:\OS2\CMD.EXE' : return code '12'

complex.h seems to be a bunch of math stuff in a class.

Applications / Re: General Software Testing
« on: June 25, 2024, 12:00:52 am »
I increased the stack, which stopped it crashing, still doesn't do much besides a dialog box with weird characters with an OK button that exits.
Code: [Select]
exehdr /stackos2:20000 FRACTZ.EXE

Marketplace / Re: ebay Stuff
« on: June 22, 2024, 03:09:27 am »

I have some questions about this one. "OS/2 2.1 Special Edition" (86G1442)
It says "For use with Windows 3.1", was the "Special Edition" after or before the "OS/2 2.1 for Windows" ?? or it is a different thing?


From, Michal says,
Code: [Select]
It’s difficult to tell from the screenshot whether it is showing OS/2 2.0 or 2.1. It’s also impossible to tell from the above screenshot that it’s actually OS/2 2.1 Special Edition, better known as OS/2 for Windows, released in October 1993.

So it seems that it is just how it was first named.

Pages: [1] 2 3 ... 325