-
Notifications
You must be signed in to change notification settings - Fork 3
/
README
80 lines (55 loc) · 2.13 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
OCILIB - D bindings
--------------------------------
DESCRIPTION
===========
OCILIB is an open source and cross platform Oracle Driver that
delivers efficient access to Oracle databases. It offers a full
featured, easy and productive API. Written in ISO C on top of
OCI, OCILIB runs on all Oracle platforms.
D BINDINGS
==========
Version 1.3, based on OCILIB v3.12.0 (2013-02-07)
C headers available in the c/ directory.
LICENSE
=======
It's licensed under GNU LESSER GENERAL PUBLIC LICENSE (LGPL).
SETUP
=====
Windows
Download OCILIB version v3.12.0 (ocilib-3.12.0-windows.zip) from http://www.ocilib.net/
$ unzip ocilib-3.12.0-windows.zip
$ cd ocilib\lib32
Copy the folder 'deimos' and the file 'myapp.d' from this repository to ocilib\lib32
Create the import library - ANSI version*
if the implib utility is not installed in your system, download it from
http://ftp.digitalmars.com/bup.zip
$ implib ociliba-dmd.lib ociliba.dll
Build the app - ANSI - version*
$ dmd myapp.d ociliba-dmd.lib
Run the app
$ SET ORACLE_HOME=C:\oraclexe\app\oracle\product\10.2.0\server
$ SET PATH=%PATH%;C:\oraclexe\app\oracle\product\10.2.0\server\bin
$ myapp
* OCILIB comes in 3 versions. ANSI, Unicode and Mixed.
To use the Unicode version:
- create the import library from ocilibw.dll
- add -version=Unicode to dmd
To use the Mixed version:
- create the import library from ocilibm.dll
- add -version=Mixed to dmd.
For details, please see http://orclib.sourceforge.net/doc/html/group__g__charset.html
Linux
Download and install OCILIB as described in
http://orclib.sourceforge.net/doc/html/group__g__install.html
Copy the folder 'deimos' and the file 'myapp.d' from this repository to a folder of your choice.
Set the environment variables
$ export ORACLE_HOME=/usr/lib/oracle/xe/app/oracle/product/10.2.0/server
$ export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/usr/local/lib
Compile and run the app
$ dmd myapp.d -L-locilib
$ ./myapp
LINKS
=====
Official website: http://www.ocilib.net/
Sourceforge.net project: http://sourceforge.net/projects/orclib/
Article on Wikipedia: http://en.wikipedia.org/wiki/OCILIB