1. define_c_var for Win32??? - Rob

Hi,

(This question is mainly directed to Rob)

Will "define_c_var" be supported in Windows one day?

For me it would be a huge help with euAllegro as this is the main
reason I created an extra DLL (which is a huge amount of extra work).

Thanks,

Ray Smith
http;//www.geocities.com/ray_223

new topic     » topic index » view message » categorize

2. Re: define_c_var for Win32??? - Rob

--- Ray Smith <smithr at ix.net.au> wrote:
> 
> Hi,
> 
> (This question is mainly directed to Rob)
> 
> Will "define_c_var" be supported in Windows one day?
> 
> For me it would be a huge help with euAllegro as
> this is the main
> reason I created an extra DLL (which is a huge
> amount of extra work).
> 
> Thanks,
> 
> Ray Smith
> http;//www.geocities.com/ray_223

And call_back() for DOS32 too.
It allows us to call our Euphoria routines from ASM
and C.

Mike The Spike
> 
>

new topic     » goto parent     » topic index » view message » categorize

3. Re: define_c_var for Win32??? - Rob

Ray wrote...

> (This question is mainly directed to Rob)
> 
> Will "define_c_var" be supported in Windows one day?
> 
> For me it would be a huge help with euAllegro as this is the main
> reason I created an extra DLL (which is a huge amount of extra work).

"define_c_var"? Is there a "define_c_var" that I missed? 

Is your need for this to avoid all the peeking / poking, type conversion
stuff when calling dll functions? If it is then I would also like this.

Mark

new topic     » goto parent     » topic index » view message » categorize

4. Re: define_c_var for Win32??? - Rob

Ray Smith writes:
> Will "define_c_var" be supported in Windows one day?

If someone can tell me how to get the address of a
variable in a Windows .dll, i.e. a .dll that I've loaded 
dynamically using LoadLibrary(), I can probably add this 
feature very easily.

Currently you can run define_c_var() with Euphoria
for Windows, but it just tries to find the symbol as
if it were an exported function - I thought there was a chance
this would work, but I didn't know whether you were
supposed to look up "x", "_x" or something else.

Regards,
   Rob Craig
   Rapid Deployment Software
   http://www.RapidEuphoria.com

new topic     » goto parent     » topic index » view message » categorize

5. Re: define_c_var for Win32??? - Rob

Ray Smith writes:

> It works perfectly.

OK, I'll change the docs to say it works in WIN32 as well as Linux.

I implemented it for Windows just before the 2.2 release, and
I doubted it would work since the WIN32 function I'm calling
is called GetProcAddress(), and the Windows API docs
only describe linking C routines with it. I got the idea from 
somewhere that it might work with exported variables too, 
but a quick test I tried failed, so I took it out of the docs.
I probably didn't do the test correctly.

Thanks,
   Rob Craig
   Rapid Deployment Software
   http://www.RapidEuphoria.com

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu