  An efficient integral library Libcint was designed to automatically implement
general integrals for Gaussian-type scalar and spinor basis functions. The
library can handle arbitrary integral expressions on top of $\mathbf{p}$,
$\mathbf{r}$ and $\sigma$ operators with one-electron overlap and nuclear
attraction, two-electron Coulomb and Gaunt operators. Using a symbolic algebra
tool, new integrals are derived and translated to C code programmatically. The
generated integrals can be used in various types of molecular properties. In
the present work, we computed the analytical gradients and NMR shielding
constants at both non-relativistic and four-component relativistic Hartree-Fock
level to demonstrate the capability of the integral library. Due to the use of
kinetically balanced basis and gauge including atomic orbitals, the
relativistic analytical gradients and shielding constants requires the integral
library to handle the fifth-order electron repulsion integral derivatives. The
generality of the integral library is achieved without losing efficiency. On
the modern multi-CPU platform, Libcint can easily reach the overall throughput
being many times of the I/O bandwidth. On a 20-core node, we are able to
achieve an average output 7.9 GB/s for C$_{60}$ molecule with cc-pVTZ basis.
