📄 group__g__install.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"><title>OCILIB (C Driver for Oracle): Installing OCILIB</title><link href="doxygen.css" rel="stylesheet" type="text/css"><link href="tabs.css" rel="stylesheet" type="text/css"></head><body><!-- Generated by Doxygen 1.5.4 --><div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="modules.html"><span>Modules</span></a></li> <li><a href="annotated.html"><span>Data Structures</span></a></li> <li><a href="files.html"><span>Files</span></a></li> </ul></div><h1>Installing OCILIB</h1><dl class="user" compact><dt><b>Compatibilities</b></dt><dd></dd></dl>Actual version of OCILIB has been validated on :<p><ul><li>Platforms: Windows, HP/UX, Linux, Mac OS, Solaris, AIX, OpenVMS</li><li>Architectures: 32/64bits</li><li>Compilers: GCC / MinGW, MS Compilers, IBM XLC, CCs, LabView</li><li>Oracle versions: 8i, 9i, 10g, 11g</li></ul><p>Please, contact the author if you have validated OCILIB on platforms or compilers not listed here.<p><dl class="user" compact><dt><b>Global build options</b></dt><dd></dd></dl>OCILIB supports the following global build options:<p>=> Oracle import:<p><ul><li>OCI_IMPORT_LINKAGE for linkage at compile time <b>(default on unixes)</b></li><li>OCI_IMPORT_RUNTIME for runtime loading <b>(default with prebuilt OCILIB libraries on MS Windows)</b></li></ul><p>=> Oracle charset<p><ul><li>OCI_CHARSET_ANSI for ANSI <b>(default)</b></li><li>OCI_CHARSET_UNICODE for Unicode</li><li>OCI_CHARSET_MIXED (ANSI for metadata, Unicode for user data)</li></ul><p>=> Calling convention (WINDOWS ONLY)<p><ul><li>OCI_API = __cdecl or blank for C/C++ only ! <b>(default)</b></li><li>OCI_API = __stdcall to link OCILIB shared library with language independence <b>(default with prebuilt OCILIB libraries on MS Windows)</b></li></ul><p><dl class="note" compact><dt><b>Note:</b></dt><dd>On Windows, OCI_API MUST be set to use prebuilt libraries</dd></dl><dl class="user" compact><dt><b>Installing OCIB on UNIX like systems</b></dt><dd></dd></dl>OCILIB uses GNU tools for deployment and installation on UNIX like platforms<p>Uncompress the archive (ocilib-x.y.z-gnu.tar.gz)<ul><li>$ cd ocilib-x.y.z</li><li>$ ./configure</li><li>$ ./make</li><li>$ ./make install (this step might require admin rights)</li></ul><p>Check the shared library path environment variable (LD_LIBRARY_PATH, LD_PATH, ...):<ul><li>it must include $ORACLE_HOME</li><li>it must include the path where OCILIB has been installed (by example, typically /usr/local/lib under Linux)</li></ul><p>In order to get theses values loaded at logon time, export theses values in your .profile configuration file :<ul><li>> export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$ORACLE_HOME/lib:/usr/local/lib</li></ul><p><b>GNU Installation options </b>:<p>OCILIB supports some options that are not needed for most common configurations.<p>List of available options:<p><ul><li>--with-oracle-import=(linkage|runtime)</li><li>--with-oracle-charset=(ansi|unicode|mixed)</li><li>--with-oracle-home=(custom oracle regular client directory)</li><li>--with-oracle-lib64=(yes|no - check out folders on mixed 32/64bits platforms)</li><li>--with-oracle-headers-path=(oracle header files directory)</li><li>--with-oracle-lib-path=(oracle shared lib directory)</li><li>--with-oracle-lib-name=(oracle shared lib name)</li><li>--with-custom-loader=(linker flag telling the linker which loader to use when loading dynamically at runtime Oracle shared libs. This option must be provide if the platform does not use the default loader flag "-ldl") and the --with-oracle-import is set to 'runtime'</li></ul><p><dl class="note" compact><dt><b>Note:</b></dt><dd>--with-oracle-headers-path and --with-oracle-lib-path are meant to be used with Instant client only but can used for regular client of libs and headers are not located in usual folders</dd></dl><dl class="user" compact><dt><b>Installing OCILIB on Microsoft Windows</b></dt><dd></dd></dl>32bits and 64bits DLLs are provided. Visual .NET (2005/2008) solutions are also provided to recompile the Dlls and the demo.<p><ul><li>Uncompress the archive (ocilib-x.y.z-windows.zip)</li><li>Copy <a class="el" href="ocilib_8h-source.html">ocilib\include\ocilib.h</a> to a folder listed in the compiler headers folders</li><li>Copy ocilib[32|64][x].lib to a folder listed in the linker libraries folders</li><li>Copy ocilib[32|64][x].dll to a folder included in the PATH environment variable</li></ul><p>[x] is the compiled version of OCILIB ("a" -> ANSI, "w" -> Unicode, "m" -> Mixed)<p><dl class="user" compact><dt><b>Oracle Instant Client Support</b></dt><dd></dd></dl>OCILIB supports Oracle Instant Client.<p>On Microsoft Windows, there is no difference between using a regular Oracle client and an Instant Client with OCILIB<p>On Unix-like systems, the Instant Client is divided in different packages.<p>Public headers and shared libs are not part of the same package.<p>So, you must provide the following options to the configure command:<p><ul><li>with-oracle-headers-path: location the public header files</li><li>with-oracle-lib-path: location the oracle shared lib</li></ul><p>If your instant client package containing the shared libs does not have a symbolic link 'libclntsh.[shared lib extension]' to the fully qualified shared lib real name, you must create it:<p>Example on Linux:<p><ul><li>$ ln -s $ORALIBPATH/libclntsh.so.10.1 $ORALIBPATH/libclntsh.so </li></ul><p><table border="0" cellpadding="0" cellspacing="0"><tr><td></td></tr></table><hr size="1"><address style="text-align: right;"><small>Generated on Sat Apr 18 01:13:12 2009 for OCILIB (C Driver for Oracle) by <a href="http://www.doxygen.org/index.html"><img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.4 </small></address></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -