--- a/src/fontdiff/diff_job.cc
+++ b/src/fontdiff/diff_job.cc
@@ -77,8 +77,10 @@ void DiffJob::WritePDF(const std::string& filepath) {
     creator.append(" ");
     creator.append(version);
   }
+  #if CAIRO_VERSION > 11499
   cairo_pdf_surface_set_metadata(pdf_surface, CAIRO_PDF_METADATA_CREATOR,
                                  creator.c_str());
+  #endif
 
   cairo_t* pdf = cairo_create(pdf_surface);
   for (const Page* page : pages_) {
