SkPDF: milestone in metadata, also SkMilestone.h

TBR=reed@google.com

GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1823753002

Review URL: https://codereview.chromium.org/1823753002
diff --git a/src/pdf/SkPDFMetadata.cpp b/src/pdf/SkPDFMetadata.cpp
index 118cda3..addec4f 100644
--- a/src/pdf/SkPDFMetadata.cpp
+++ b/src/pdf/SkPDFMetadata.cpp
@@ -5,6 +5,7 @@
  * found in the LICENSE file.
  */
 
+#include "SkMilestone.h"
 #include "SkPDFMetadata.h"
 #include "SkPDFTypes.h"
 #include <utility>
@@ -27,6 +28,9 @@
             timeZoneMinutes);
 }
 
+#define SKPDF_STRING(X) SKPDF_STRING_IMPL(X)
+#define SKPDF_STRING_IMPL(X) #X
+
 SkPDFObject* SkPDFMetadata::createDocumentInformationDict() const {
     auto dict = sk_make_sp<SkPDFDict>();
     static const char* keys[] = {
@@ -38,7 +42,7 @@
             }
         }
     }
-    dict->insertString("Producer", "Skia/PDF");
+    dict->insertString("Producer", "Skia/PDF m" SKPDF_STRING(SK_MILESTONE));
     if (fCreation) {
         dict->insertString("CreationDate", pdf_date(*fCreation.get()));
     }
@@ -48,6 +52,9 @@
     return dict.release();
 }
 
+#undef SKPDF_STRING
+#undef SKPDF_STRING_IMPL
+
 #ifdef SK_PDF_GENERATE_PDFA
 SkPDFMetadata::UUID SkPDFMetadata::uuid() const {
     // The main requirement is for the UUID to be unique; the exact