summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
Diffstat (limited to 'meta')
-rw-r--r--meta/classes/distrodata.bbclass56
1 files changed, 14 insertions, 42 deletions
diff --git a/meta/classes/distrodata.bbclass b/meta/classes/distrodata.bbclass
index df6d300666..90ee7ae492 100644
--- a/meta/classes/distrodata.bbclass
+++ b/meta/classes/distrodata.bbclass
@@ -1,4 +1,3 @@
1require conf/distro/include/distro_tracking_fields.inc
2 1
3addhandler distro_eventhandler 2addhandler distro_eventhandler
4python distro_eventhandler() { 3python distro_eventhandler() {
@@ -8,7 +7,7 @@ python distro_eventhandler() {
8 logfile = dc.create_log_file(e.data, "distrodata.csv") 7 logfile = dc.create_log_file(e.data, "distrodata.csv")
9 lf = bb.utils.lockfile("%s.lock" % logfile) 8 lf = bb.utils.lockfile("%s.lock" % logfile)
10 f = open(logfile, "a") 9 f = open(logfile, "a")
11 f.write("Package,Description,Owner,License,ChkSum,Status,VerMatch,Version,Upsteam,Non-Update,Reason,Recipe Status,Distro 1,Distro 2,Distro 3\n") 10 f.write("Package,Description,Owner,License,VerMatch,Version,Upsteam,Reason,Recipe Status,Distro 1,Distro 2,Distro 3\n")
12 f.close() 11 f.close()
13 bb.utils.unlockfile(lf) 12 bb.utils.unlockfile(lf)
14 13
@@ -68,21 +67,12 @@ python do_distrodata_np() {
68 67
69 pgrp = localdata.getVar('SECTION', True) 68 pgrp = localdata.getVar('SECTION', True)
70 plicense = localdata.getVar('LICENSE', True).replace(',','_') 69 plicense = localdata.getVar('LICENSE', True).replace(',','_')
71 if localdata.getVar('LIC_FILES_CHKSUM', True):
72 pchksum="1"
73 else:
74 pchksum="0"
75
76 if localdata.getVar('RECIPE_STATUS', True):
77 hasrstatus="1"
78 else:
79 hasrstatus="0"
80 70
81 rstatus = localdata.getVar('RECIPE_STATUS', True) 71 rstatus = localdata.getVar('RECIPE_COLOR', True)
82 if rstatus is not None: 72 if rstatus is not None:
83 rstatus = rstatus.replace(',','') 73 rstatus = rstatus.replace(',','')
84 74
85 pupver = localdata.getVar('RECIPE_LATEST_VERSION', True) 75 pupver = localdata.getVar('RECIPE_UPSTREAM_VERSION', True)
86 if pcurver == pupver: 76 if pcurver == pupver:
87 vermatch="1" 77 vermatch="1"
88 else: 78 else:
@@ -94,16 +84,12 @@ python do_distrodata_np() {
94 noupdate="1" 84 noupdate="1"
95 noupdate_reason = noupdate_reason.replace(',','') 85 noupdate_reason = noupdate_reason.replace(',','')
96 86
97 ris = localdata.getVar('RECIPE_INTEL_SECTION', True)
98 maintainer = localdata.getVar('RECIPE_MAINTAINER', True) 87 maintainer = localdata.getVar('RECIPE_MAINTAINER', True)
99 rttr = localdata.getVar('RECIPE_TIME_BETWEEN_LAST_TWO_RELEASES', True) 88 rlrd = localdata.getVar('RECIPE_UPSTREAM_DATE', True)
100 rlrd = localdata.getVar('RECIPE_LATEST_RELEASE_DATE', True)
101 dc = localdata.getVar('DEPENDENCY_CHECK', True)
102 rc = localdata.getVar('RECIPE_COMMENTS', True)
103 result = dist_check.compare_in_distro_packages_list(distro_check_dir, localdata) 89 result = dist_check.compare_in_distro_packages_list(distro_check_dir, localdata)
104 90
105 bb.note("DISTRO: %s,%s,%s,%s,%s,%s,%s,%s,%s, %s, %s, %s\n" % \ 91 bb.note("DISTRO: %s,%s,%s,%s,%s,%s,%s,%s,%s\n" % \
106 (pname, pdesc, maintainer, plicense, pchksum, hasrstatus, vermatch, pcurver, pupver, noupdate, noupdate_reason, rstatus)) 92 (pname, pdesc, maintainer, plicense, vermatch, pcurver, pupver, noupdate_reason, rstatus))
107 line = pn 93 line = pn
108 for i in result: 94 for i in result:
109 line = line + "," + i 95 line = line + "," + i
@@ -155,21 +141,12 @@ python do_distrodata() {
155 141
156 pgrp = localdata.getVar('SECTION', True) 142 pgrp = localdata.getVar('SECTION', True)
157 plicense = localdata.getVar('LICENSE', True).replace(',','_') 143 plicense = localdata.getVar('LICENSE', True).replace(',','_')
158 if localdata.getVar('LIC_FILES_CHKSUM', True):
159 pchksum="1"
160 else:
161 pchksum="0"
162
163 if localdata.getVar('RECIPE_STATUS', True):
164 hasrstatus="1"
165 else:
166 hasrstatus="0"
167 144
168 rstatus = localdata.getVar('RECIPE_STATUS', True) 145 rstatus = localdata.getVar('RECIPE_COLOR', True)
169 if rstatus is not None: 146 if rstatus is not None:
170 rstatus = rstatus.replace(',','') 147 rstatus = rstatus.replace(',','')
171 148
172 pupver = localdata.getVar('RECIPE_LATEST_VERSION', True) 149 pupver = localdata.getVar('RECIPE_UPSTREAM_VERSION', True)
173 if pcurver == pupver: 150 if pcurver == pupver:
174 vermatch="1" 151 vermatch="1"
175 else: 152 else:
@@ -182,19 +159,15 @@ python do_distrodata() {
182 noupdate="1" 159 noupdate="1"
183 noupdate_reason = noupdate_reason.replace(',','') 160 noupdate_reason = noupdate_reason.replace(',','')
184 161
185 ris = localdata.getVar('RECIPE_INTEL_SECTION', True)
186 maintainer = localdata.getVar('RECIPE_MAINTAINER', True) 162 maintainer = localdata.getVar('RECIPE_MAINTAINER', True)
187 rttr = localdata.getVar('RECIPE_TIME_BETWEEN_LAST_TWO_RELEASES', True) 163 rlrd = localdata.getVar('RECIPE_UPSTREAM_DATE', True)
188 rlrd = localdata.getVar('RECIPE_LATEST_RELEASE_DATE', True)
189 dc = localdata.getVar('DEPENDENCY_CHECK', True)
190 rc = localdata.getVar('RECIPE_COMMENTS', True)
191 # do the comparison 164 # do the comparison
192 result = dist_check.compare_in_distro_packages_list(distro_check_dir, localdata) 165 result = dist_check.compare_in_distro_packages_list(distro_check_dir, localdata)
193 166
194 lf = bb.utils.lockfile("%s.lock" % logfile) 167 lf = bb.utils.lockfile("%s.lock" % logfile)
195 f = open(logfile, "a") 168 f = open(logfile, "a")
196 f.write("%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s" % \ 169 f.write("%s,%s,%s,%s,%s,%s,%s,%s,%s" % \
197 (pname, pdesc, maintainer, plicense, pchksum, hasrstatus, vermatch, pcurver, pupver, noupdate, noupdate_reason, rstatus)) 170 (pname, pdesc, maintainer, plicense, vermatch, pcurver, pupver, noupdate_reason, rstatus))
198 line = "" 171 line = ""
199 for i in result: 172 for i in result:
200 line = line + "," + i 173 line = line + "," + i
@@ -218,7 +191,7 @@ python checkpkg_eventhandler() {
218 191
219 lf = bb.utils.lockfile("%s.lock" % logfile) 192 lf = bb.utils.lockfile("%s.lock" % logfile)
220 f = open(logfile, "a") 193 f = open(logfile, "a")
221 f.write("Package\tVersion\tUpver\tLicense\tSection\tHome\tRelease\tPriority\tDepends\tBugTracker\tPE\tDescription\tStatus\tTracking\tURI\tMAINTAINER\n") 194 f.write("Package\tVersion\tUpver\tLicense\tSection\tHome\tRelease\tDepends\tBugTracker\tPE\tDescription\tStatus\tTracking\tURI\tMAINTAINER\n")
222 f.close() 195 f.close()
223 bb.utils.unlockfile(lf) 196 bb.utils.unlockfile(lf)
224 return 197 return
@@ -475,7 +448,6 @@ python do_checkpkg() {
475 psection = localdata.getVar('SECTION', True) 448 psection = localdata.getVar('SECTION', True)
476 phome = localdata.getVar('HOMEPAGE', True) 449 phome = localdata.getVar('HOMEPAGE', True)
477 prelease = localdata.getVar('PR', True) 450 prelease = localdata.getVar('PR', True)
478 ppriority = localdata.getVar('PRIORITY', True)
479 pdepends = localdata.getVar('DEPENDS', True) 451 pdepends = localdata.getVar('DEPENDS', True)
480 pbugtracker = localdata.getVar('BUGTRACKER', True) 452 pbugtracker = localdata.getVar('BUGTRACKER', True)
481 ppe = localdata.getVar('PE', True) 453 ppe = localdata.getVar('PE', True)
@@ -655,8 +627,8 @@ python do_checkpkg() {
655 pdesc = "".join(pdesc.split("\t")) 627 pdesc = "".join(pdesc.split("\t"))
656 lf = bb.utils.lockfile("%s.lock" % logfile) 628 lf = bb.utils.lockfile("%s.lock" % logfile)
657 f = open(logfile, "a") 629 f = open(logfile, "a")
658 f.write("%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\n" % \ 630 f.write("%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\t%s\n" % \
659 (pname,pversion,pupver,plicense,psection, phome,prelease, ppriority,pdepends,pbugtracker,ppe,pdesc,pstatus,pmver,psrcuri,maintainer)) 631 (pname,pversion,pupver,plicense,psection, phome,prelease, pdepends,pbugtracker,ppe,pdesc,pstatus,pmver,psrcuri,maintainer))
660 f.close() 632 f.close()
661 bb.utils.unlockfile(lf) 633 bb.utils.unlockfile(lf)
662} 634}