You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+21-4Lines changed: 21 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,12 +16,16 @@ The API consists of two classes:
16
16
`Mysql2::Result` - returned from issuing a #query on the connection. It includes Enumerable.
17
17
18
18
## Installing
19
-
### OSX / Linux
19
+
### General Instructions
20
20
```sh
21
21
gem install mysql2
22
22
```
23
23
24
-
This gem links against MySQL's `libmysqlclient` C shared library. You may need to install a package such as `libmysqlclient-dev`, `mysql-devel`, or other appropriate package for your system.
24
+
This gem links against MySQL's `libmysqlclient` library or `Connector/C`
25
+
library, and compatible alternatives such as MariaDB.
26
+
You may need to install a package such as `libmysqlclient-dev`, `mysql-devel`,
27
+
or other appropriate package for your system. See below for system-specific
28
+
instructions.
25
29
26
30
By default, the mysql2 gem will try to find a copy of MySQL in this order:
27
31
@@ -52,6 +56,19 @@ This may be needed if you deploy to a system where these libraries
52
56
are located somewhere different than on your build system.
53
57
This overrides any rpath calculated by default or by the options above.
54
58
59
+
### Linux and other Unixes
60
+
61
+
You may need to install a package such as `libmysqlclient-dev` or `mysql-devel`;
62
+
refer to your distribution's package guide to find the particular package.
63
+
The most common issue we see is a user who has the library file `libmysqlclient.so` but is
64
+
missing the header file `mysql.h` -- double check that you have the _-dev_ packages installed.
65
+
66
+
### Mac OS X
67
+
68
+
You may use MacPorts, Homebrew, or a native MySQL installer package. The most
69
+
common paths will be automatically searched. If you want to select a specific
70
+
MySQL directory, use the `--with-mysql-dir` or `--with-mysql-config` options above.
71
+
55
72
### Windows
56
73
Make sure that you have Ruby and the DevKit compilers installed. We recommend
57
74
the [Ruby Installer](http://rubyinstaller.org) distribution.
@@ -420,13 +437,13 @@ As for field values themselves, I'm workin on it - but expect that soon.
420
437
421
438
This gem is tested with the following Ruby versions on Linux and Mac OS X:
0 commit comments