[racket] Access c based dll through ffi
Hello Friends,
I have make a little dll in visual studio :
[CODE_BEGIN]
#include <stdio.h>
extern "C"
{
__declspec(dllexport) void DisplayHelloFromDLL()
{
printf ("Hello from DLL !\n");
}
}
[CODE_END]
After I try to access it through ffi like this:
[CODE_BEGIN]
#lang racket
(require ffi/com
ffi/unsafe
ffi/unsafe/define
ffi/winapi
racket/string
racket/format)
(define-ffi-definer define-dreamlog (ffi-lib "DreamLogging"))
[CODE_END]
But I get an
ffi-lib: couldn't open "DreamLogging.dll" (Unknown error; errno=193)
So my question is: What should be the right structure for ffi for accepting it?
Yours,