Quote Originally Posted by Stoney
After testing BESEN a bit, I'm still impressed with your work. Thanks for adding support for FPC 2.4.0.
But support for 2.4.0 is only inoffically For example the 64-bit x64/AMD64 codegenerator of FPC 2.4.0 was/is very buggy, so BESEN compiles there only with -O1 or without any code optimizations.

Quote Originally Posted by Stoney
It works without any problems on my Windows machine, but unfortunately I'm having some issues getting it to work on a Mac.
First off, you something like this
[pascal]
{$ifdef fpc}
{$ifdef darwin}
{$pic off}
{$endif}
...
[/pascal]
since -fPic switch is set by default when compiling on a Mac.

BESEN loads dynamically from libc.so. Well, libc.so doesn't exist on Mac, it's called libc.dylib. So around line 41287 please change it to following:
[pascal]
{$ifdef darwin}
fpmprotect:=dlsym(dlopen('libc.dylib',RTLD_NOW),'m protect');
{$else}
fpmprotect:=dlsym(dlopen('libc.so',RTLD_NOW),'mpro tect');
{$endif}
[/pascal]
Fixed

Quote Originally Posted by Stoney
With those two changes it compile and BESENTest will at least start when being executed, but as soon as I load any script into the sample, I get this error:
Code:
Exception object An unhandled exception occurred at $00043114 :
Illegal instruction
Try the new BESEN.pas from the Sourceforge SVN with -dDisableJIT to disable the JIT testwise, and say me then, if it had work or not. The JIT stuff works at least under Windows and LInux with FPC 2.5.1 and Delphi 7 + Kylix.

Quote Originally Posted by Stoney
I would love to see some more examples especially in regards on how to integrate BESEN into existing applications, like how to access certain aspects of the application from the script and vice versa.
Yeah, this example stuff comes later.