User Tools

Site Tools


libdbi

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
libdbi [2007/03/02 22:03] – Typo (libdb -> libdbi) dbslibdbi [2007/07/03 00:03] – Note that libdbi is now linked with -rpath dbs
Line 1: Line 1:
 +^ Version ^ Description of change ^
 +| 1.2.x | Compile options now use ''-rpath'' to hard-code location of libdbi and avoid environment setup hassles |
  
 +Libdbi is a "database-independent abstraction layer in C, similar to the DBI/DBD layer in Perl" Currently we use it for cstore, which is a C based interface to the database, and for reporter-store, the reporting system's backend service.
 +
 +  * Get libdbi sources [[http://sourceforge.net/project/showfiles.php?group_id=23824|here]]
 +  * Get the libdbi-drivers sources [[https://sourceforge.net/project/showfiles.php?group_id=65979|here]]
 +  * Build libdbi
 +    <code>./configure --disable-docs && make all install</code>
 +
 +  * Build libdbi-drivers.  
 +    <code> 
 +    # note: you may not need or may need to change --with-pgsql-dir=/opt/
 +    ./configure --with-pgsql-dir=/opt/ --disable-docs --with-pgsql --enable-libdbi && make all install  
 +    </code>
 +
 +  * **[Note - only for versions prior to Evergreen 1.2.x]**: When all of this is done, you **must** ensure that ''/usr/local/lib'' and ''/usr/local/lib/dbd'' are added to your ld path. If you encounter an error in ''osrfsys.log'' similar to ''WARN: Failed to dlopen library file oils_cstore.so: libdbdpgsql.so: cannot open shared object file: No such file or directory'', you probably have not set this part of your environment correctly. On most systems, you can use one of the following approaches:
 +    * Modify the ''LD_LIBRARY_PATH'' environment variable for the ''opensrf'' user:
 +      - In your favorite text editor, open ''/home/opensrf/.bashrc'' (assuming you're running the bash shell)
 +      - Add the following line to the bottom of the file:<code>
 +export LD_LIBRARY_PATH=/usr/local/lib:/usr/local/lib/dbd:$LD_LIBRARY_PATH
 +</code>
 +      - Run ''. /home/opensrf/.bashrc'' to set your environment immediately. Any subsequent times that you log in as ''opensrf'' the environment will be set automatically for you.
 +    * **OR** Modify the ld path for the entire system. (//Note//: This does not work on Gentoo; see the [[installing_prerequisites_on_gentoo|Gentoo install]] documentation for an alternative approach.)
 +      - As the root user, open ''/etc/ld.so.conf'' in a text editor
 +      - Add the following lines to the bottom of the file:<code>
 +/usr/local/lib
 +/usr/local/lib/dbd
 +</code>
 +      - Run ''ldconfig'' to reload the system path.

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki

© 2008-2022 GPLS and others. Evergreen is open source software, freely licensed under GNU GPLv2 or later.
The Evergreen Project is a U.S. 501(c)3 non-profit organization.