If I'm reading the error message correctly, you don't need to build a Perl with useithreads in order to fix your compile problem. Assuming I found the right one, the error message your referring to is:

print "WARNING: Oracle is built with multi-threading libra +ries\n" . " You will most likely need to rebuild perl +from sources\n" . " with the following libraries: -lcl -lpthre +ad\n" ;

Adding those options won't build a threaded Perl, it just builds it with threadsafe C runtime libraries and the pthread libraries. The resulting Perl will still be non-threaded, and not suffer the performance hit that imposes.

In any case, if you chose to build a threaded Perl, if DBD::Oracle uses (p)threads under the covers, there is no conflict between that can ithreads. The cloning of Perl data done for spawned iThreads , is a purely Perl affair and will not happen if non-perl library spawns threads--even if that library is dynalinked to a threaded perl.

Finally, going purely on what I see in the XS and C files for DBD::Oracle, it appears to be iThreads-aware, even if it's not warrented as iThreads-safe.

In summary, just add the options above to the link command and (re)build your Perl as you would normally and your problems will (or should) just "go away", with no other risks or special considerations.


Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
Lingua non convalesco, consenesco et abolesco. -- Rule 1 has a caveat! -- Who broke the cabal?
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.

In reply to Re: DBD::Oracle and threading on a web server by BrowserUk
in thread DBD::Oracle and threading on a web server by graff

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.