Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: Bundling Sybase dll using perl2exe

by jfroebe (Parson)
on Dec 09, 2013 at 19:08 UTC ( #1066320=note: print w/replies, xml ) Need Help??


in reply to Bundling Sybase dll using perl2exe

You basically need to include a large chunk of the $SYBASE directory. You're better off simply making the installation of Sybase (now SAP) Open Client a requirement.

Please note, that while DBD::Sybase is pretty forgiving on the *nixes for binding against different Openclient releases, it is a real bugger in the Windows world. If your environment is Windows, use ODBC.

HOWTO: BUILDING PERL MODULE DBD::SYBASE 1.15 FOR ACTIVESTATE PERL (WINDOWS 32BIT) 5.16.3 USING THE MINGW COMPILER if you need to

Jason L. Froebe

Blog, Tech Blog

Replies are listed 'Best First'.
Re^2: Bundling Sybase dll using perl2exe
by Anonymous Monk on Dec 10, 2013 at 05:14 UTC
    Dear Monks, Thanks for your reply, I really don't want to make the Sybase Open Client as a requirement and if possible bundle the required dll/obj files with my appplication. The error which I get when I bundle most of the dll's is The context allocation routine failed when it tried to load localization files!! One or more following problems may caused the failure Your sybase home directory is c:\sql10. Your sybase home directory is c:\sql10. Check the environment variable SYBASE if it is not the one you want! Check the environment variable SYBASE if it is not the one you want! Cannot access file c:\sql10\ini\objectid.dat I have bundled the objectid.dat file also in my application exe, I still get this error as well DBD_alloc method fails. Thanks, Mansi

      The official method is to install OpenClient. If you want a self contained binary, you're basically out of luck.

      Another option is to use Sybase's JDBC driver (jConnect) with DBD::JDBC. However, using DBD::JDBC will require you to have Java installed somewhere... then it comes down to, if you require Java, why are you using Perl? Catch-22

      Jason L. Froebe

      Blog, Tech Blog

      Just an update, the exact error for alloc method is: DBD::Sybase initialize :cx_ctx_alloc(112) failed at PERL2EXE/STORAGE/Dynaloader.pm line 214.
        As jfroebe says - a Sybase client app requires a whole slew of files, locale files, charset files, you name it. There's no way to run a C-based client without them.

        Michael

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1066320]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (5)
As of 2021-10-15 21:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My first memorable Perl project was:







    Results (68 votes). Check out past polls.

    Notices?