Imported Upstream version 0.6.27
[platform/upstream/libsolv.git] / tools / common_write.c
index ba40f35..e20f64f 100644 (file)
@@ -6,8 +6,6 @@
  */
 
 #include <sys/types.h>
-#include <limits.h>
-#include <fcntl.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
 #include "repo.h"
 #include "repo_write.h"
 #include "common_write.h"
+#include "solvversion.h"
 
-#define LIBSOLV_TOOLVERSION "1.0"
+/* toolversion history
+ * 1.0: initial tool version
+ * 1.1: changed PRODUCT_ENDOFLIFE parsing
+*/
 
 static Id verticals[] = {
   SOLVABLE_AUTHORS,
@@ -27,6 +29,8 @@ static Id verticals[] = {
   SOLVABLE_EULA,
   SOLVABLE_DISKUSAGE,
   SOLVABLE_FILELIST,
+  SOLVABLE_CHANGELOG_AUTHOR,
+  SOLVABLE_CHANGELOG_TEXT,
   0
 };
 
@@ -193,7 +197,7 @@ write_info(Repo *repo, FILE *fp, int (*keyfilter)(Repo *repo, Repokey *key, void
   repodata_add_flexarray(info, SOLVID_META, REPOSITORY_EXTERNAL, h);
 }
 
-int
+void
 tool_write(Repo *repo, const char *basename, const char *attrname)
 {
   Repodata *data;
@@ -316,7 +320,6 @@ tool_write(Repo *repo, const char *basename, const char *attrname)
        free(languages[i]);
       solv_free(languages);
       repodata_free(info);
-      return 0;
     }
   if (attrname)
     {
@@ -334,5 +337,4 @@ tool_write(Repo *repo, const char *basename, const char *attrname)
       exit(1);
     }
   repodata_free(info);
-  return 0;
 }