Create FWPPC DLL?

Create FWPPC DLL?

Postby Bill Simmeth » Mon Nov 13, 2006 8:44 pm

Is it possible to create a DLL with FWPPC? I would like to build a DLL from which I can call functions using RAPI on the desktop.

Thanks,
Bill Simmeth
Merchant Software Corp
Marshall, Virginia USA
Bill Simmeth
 
Posts: 42
Joined: Wed Oct 26, 2005 1:20 pm
Location: Marshall, Virginia, USA

Postby Antonio Linares » Tue Nov 14, 2006 12:38 am

Bill,

I assume that you want to have PRG code into the DLL, and build a self contained DLL, right ?

We can do that with FWH, and it should be quite similar for FWPPC, though we have not tested it yet. We are going to do some tests and we will let you know our results.
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42097
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Bill Simmeth » Tue Nov 14, 2006 2:08 am

Hi Antonio,

Thanks for the reply. Yes, you are correct -- I would like to have a free-standing DLL built with .prg code. I appreciate your tests and await the results!

Thanks again,
Bill Simmeth
Merchant Software Corp
Marshall, Virginia USA
Bill Simmeth
 
Posts: 42
Joined: Wed Oct 26, 2005 1:20 pm
Location: Marshall, Virginia, USA

Postby Antonio Linares » Wed Nov 15, 2006 12:02 am

Bill,

We have been doing several tests and it looks as there are some troubles that we need to solve with the Harbour development team, so unfortunately we can not provide you a quick solution for this.

Basically this is what we have tested:

1. Copy buildce.bat to builddll.bat and modify it this way:
echo %1.obj %hdir%\obj\vc\maindll.obj > msvc.tmp
...
... link ... /DLL /ENTRY:DllEntryPoint

maindll.obj is not included in the Harbour for Pocket PC distribution, so we built it here. We may email it to you if you want to try it.

We are not exactly sure about link /ENTRY:DllEntryPoint flag behavior. Acording to Microsoft docs, it should not be needed as DllEntryPoint() may be called automatically, but that was not the case. So we need to force its call.

The DLL gets properly built and it loads fine, but the Harbour virtual machine is not properly initialized. So it seems there is a problem somewhere in the startup code of the DLL that we need to trace.
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42097
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Bill Simmeth » Wed Nov 15, 2006 12:15 am

Antonio,

Thank you for your efforts! I hope the problem can be tracked down without too much effort. If you don't mind emailing the maindll.obj file to me that would be appreciated.

Thanks,
Bill Simmeth
Merchant Software Corp
Marshall, Virginia USA
Bill Simmeth
 
Posts: 42
Joined: Wed Oct 26, 2005 1:20 pm
Location: Marshall, Virginia, USA

Postby Antonio Linares » Wed Nov 15, 2006 12:52 am

Bill,

We have solved it! :-)

/ENTRY:DllEntryPoint is NOT needed, but hb_vmInit() has to be called from HBDLLENTRY() as DllEntryPoint() is not automatically called by the DLL startup (this is just a reminder for me :-) ).

We email you a working sample and the required files,
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42097
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Bill Simmeth » Wed Nov 15, 2006 1:15 pm

Antonio,

Many, many thanks! I have received your email and will begin work on it this morning!!

Thanks again,
Bill Simmeth
Merchant Software Corp
Marshall, Virginia USA
Bill Simmeth
 
Posts: 42
Joined: Wed Oct 26, 2005 1:20 pm
Location: Marshall, Virginia, USA


Return to FiveWin for Pocket PC

Who is online

Users browsing this forum: No registered users and 10 guests