How To Install cairo on Rocky Linux 8

In this tutorial we learn how to install cairo on Rocky Linux 8. cairo is A 2D graphics library

Introduction

In this tutorial we learn how to install cairo on Rocky Linux 8.

What is cairo

Cairo is a 2D graphics library designed to provide high-quality display and print output. Currently supported output targets include the X Window System, in-memory image buffers, and image files (PDF, PostScript, and SVG). Cairo is designed to produce consistent output on all output media while taking advantage of display hardware acceleration when available.

We can use yum or dnf to install cairo on Rocky Linux 8. In this tutorial we discuss both methods but you only need to choose one of method to install cairo.

Install cairo on Rocky Linux 8 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install cairo using dnf by running the following command:

sudo dnf -y install cairo

Install cairo on Rocky Linux 8 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install cairo using yum by running the following command:

sudo yum -y install cairo

How To Uninstall cairo on Rocky Linux 8

To uninstall only the cairo package we can use the following command:

sudo dnf remove cairo

cairo Package Contents on Rocky Linux 8

/usr/bin/cairo-sphinx
/usr/lib/.build-id
/usr/lib/.build-id/26
/usr/lib/.build-id/26/191f0c090709755335468266f87765d4163d51
/usr/lib/.build-id/27
/usr/lib/.build-id/27/309db60ae584df16f4d877bfa1d42cc887ebb9
/usr/lib/.build-id/87
/usr/lib/.build-id/87/fd22280d25cac00555b3f1fd1674e57c10d466
/usr/lib64/libcairo-script-interpreter.so.2
/usr/lib64/libcairo-script-interpreter.so.2.11512.0
/usr/lib64/libcairo.so.2
/usr/lib64/libcairo.so.2.11512.0
/usr/share/doc/cairo
/usr/share/doc/cairo/AUTHORS
/usr/share/doc/cairo/BIBLIOGRAPHY
/usr/share/doc/cairo/BUGS
/usr/share/doc/cairo/NEWS
/usr/share/doc/cairo/README
/usr/share/licenses/cairo
/usr/share/licenses/cairo/COPYING
/usr/share/licenses/cairo/COPYING-LGPL-2.1
/usr/share/licenses/cairo/COPYING-MPL-1.1
/usr/bin/cairo-sphinx
/usr/lib/.build-id
/usr/lib/.build-id/3e
/usr/lib/.build-id/3e/cb17dd647aa76b0d6bba8849ad76e89bd424f9
/usr/lib/.build-id/5b
/usr/lib/.build-id/5b/8c2ade8689096114bb11d56588b9b3b157251f
/usr/lib/.build-id/8f
/usr/lib/.build-id/8f/dc68478c85e4f8f07f0d6c856743b9e601b4c0
/usr/lib/libcairo-script-interpreter.so.2
/usr/lib/libcairo-script-interpreter.so.2.11512.0
/usr/lib/libcairo.so.2
/usr/lib/libcairo.so.2.11512.0
/usr/share/doc/cairo
/usr/share/doc/cairo/AUTHORS
/usr/share/doc/cairo/BIBLIOGRAPHY
/usr/share/doc/cairo/BUGS
/usr/share/doc/cairo/NEWS
/usr/share/doc/cairo/README
/usr/share/licenses/cairo
/usr/share/licenses/cairo/COPYING
/usr/share/licenses/cairo/COPYING-LGPL-2.1
/usr/share/licenses/cairo/COPYING-MPL-1.1

References

Summary

In this tutorial we learn how to install cairo on Rocky Linux 8 using yum and dnf.