Fix shared library not being linked with ROOT libs