If the following error occurs even though libc6-dev is installed,
Do you install glibc-devel(redhat) or libc6-dev(debian)?
You need /usr/include/sys/types.h to compile ruby-oci8.
You need to use ruby-oci8 2.1.0 or upper. Otherwise, run the following command and re-install ruby-oci8.
$ sudo ln -s /usr/include/linux/ /usr/include/sys