V4RB 3.0 and pre-emptive threads

Charles Yeomans charles at declareSub.com
Mon Jul 23 09:46:03 CDT 2007


If you want to try this approach, you might be better off getting the  
Objective-C library and declaring to that.


Charles Yeomans


On Jul 23, 2007, at 6:10 AM, Dave Addey wrote:

> Hi Ruslan,
>
> Thank you for all of the help with this.  I have one more  
> possibility to
> explore.  Would it be possible for me to declare directly against the
> Valentina Kernel dylib, and pass in a reference to the Valentina  
> objects I
> have already created?  Something like this in RB:
>
>
> Const kVKernelLib =
> "/usr/local/lib/vcomponents/libvkernel_fat_release.dylib"
>
> Declare Function ValentinaInit Lib kVKernelLib (inCacheSize as UInt32,
> inMacSNPtr as Ptr, inWinSNPtr as Ptr, inUnixSNPtr as Ptr) as UInt32
>
> Dim VCacheSize as integer
> VCacheSize = ValentinaInit(8*1024*1024, 0, 0, 0)
>
>
> Whenever I try this, my REALbasic application crashes with a  
> console error
> of:
>
>
> dyld: lazy symbol binding failed: Symbol not found: _ValentinaInit
>   Referenced from: /Documents/DJ-1800/svn_code_cvsdude/ 
> PreemptiveThread/Test
> project/PreemptiveThread.debug.app/Contents/MacOS/ 
> PreemptiveThread.debug
>   Expected in: /usr/local/lib/vcomponents/libvkernel_fat_release.dylib
>
>
> This does not involve passing references to existing REALbasic  
> objects, and
> I guess I would need to do this too.
>
> I am very aware that this is *not* the way this is meant to be  
> done!  But I
> have to find a way to call Valentina, on a true, preemptive background
> thread from within REALbasic, using my existing REALbasic valentina  
> objects,
> but without using the V4RB plugin.  My only alternative is to re- 
> write all
> of my database code in a plugin (and this is a lot of code).
>
> If you have any other ideas as to how I could do this, I would be very
> grateful, as I am hitting my head against a brick wall.
>



More information about the Valentina mailing list