configure: error: xml2-config not found. Please check your libxml2 installation.

If you get the error

configure: error: xml2-config not found. Please check your libxml2 installation.

try installing libxml2-devel by running something like

sudo yum install libxml2-devel