realbasic-plugins
[Top] [All Lists]

Re: try/catch in a static lib

To: REALbasic Plugins <realbasic-plugins at lists dot realsoftware dot com>
Subject: Re: try/catch in a static lib
From: Ruslan Zasukhin <sunshine at public dot kherson dot ua>
Date: Sun, 24 Jul 2005 23:37:38 +0300
Delivered-to: realbasic-plugins at lists dot realsoftware dot com
On 7/24/05 11:27 PM, "Alfred Van Hoek" <vanhoek at mac dot com> wrote:

>> Or do I misunderstand what your problem is? (I must admit that I don't
>> know why you specifically point out "static lib")
>> 
> 
> You do not misunderstand. I was just thinking if a static lib might
> behave differently, but I might be wrong.
> 
> A static lib, that internally raises exceptions and transmits  an error
> as a function result to an api call the lib defines like:
> 
> OSErr err = LibFunction1(void* libref, long value);
> 
> then if it is true what you say, the err will most likely be noErr,
> because the try/catch within the lib is not called appropriately,
> because the plugin SDK does wrong initialization?
> 
> If your starter kit provides proper initialization, will this also work
> in Xcode?
> 
> And please RS, could you also comment on it, and if the plugin SDK does
> lack proper initialization, how would the plugin then be able to
> appropriately use a third-party lib?
> 
> We need not only Thomas' criticisms and solutions, but also need your
> input, because the plugin does not function appropriately because of
> what is described in this thread.
> 
> And Thomas, would these initializations also work in Xcode?
> 
> Heck, this is a critical issue...

Hi Alfred,

* what Thomas points is SIMPLY that you need add
    __initialize
    __terminate

    in the linker panel of your plugin project

    as only you add this 2 words, exceptions in plugin start work.
    So this is very simple issue, and you do not need help from REAL.


* in the xCode this works automatically probably. Do not know exactly.
    I have not see such linker settings in the xCode.


* it sounds like you have have on hands some static library,
    that AS YOU KNOW raises internally C++ exceptions and self catch them.
    but this not works. Right ?

    then point 1 should fix your problem I think.


OR you need self develop new static library and you ask how to do that ?


-- 
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina - Joining Worlds of Information
http://www.paradigmasoft.com

[I feel the need: the need for speed]


_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

<Prev in Thread] Current Thread [Next in Thread>