diff options
Diffstat (limited to 'classes')
-rw-r--r-- | classes/package_deb.bbclass | 6 | ||||
-rw-r--r-- | classes/package_ipk.bbclass | 6 |
2 files changed, 10 insertions, 2 deletions
diff --git a/classes/package_deb.bbclass b/classes/package_deb.bbclass index 9697426d5d..388f9819bd 100644 --- a/classes/package_deb.bbclass +++ b/classes/package_deb.bbclass @@ -138,7 +138,11 @@ python do_package_deb () { raise bb.build.FuncFailed("unable to open control file for writing.") fields = [] - fields.append(["Version: %s-%s\n", ['PV', 'PR']]) + pe = bb.data.getVar('PE', d, 1) + if pe and int(pe) > 0: + fields.append(["Version: %s:%s-%s\n", ['PE', 'PV', 'PR']]) + else: + fields.append(["Version: %s-%s\n", ['PV', 'PR']]) fields.append(["Description: %s\n", ['DESCRIPTION']]) fields.append(["Section: %s\n", ['SECTION']]) fields.append(["Priority: %s\n", ['PRIORITY']]) diff --git a/classes/package_ipk.bbclass b/classes/package_ipk.bbclass index 70bcdf6b7f..19c082d978 100644 --- a/classes/package_ipk.bbclass +++ b/classes/package_ipk.bbclass @@ -142,7 +142,11 @@ python do_package_ipk () { raise bb.build.FuncFailed("unable to open control file for writing.") fields = [] - fields.append(["Version: %s-%s\n", ['PV', 'PR']]) + pe = bb.data.getVar('PE', d, 1) + if pe and int(pe) > 0: + fields.append(["Version: %s:%s-%s\n", ['PE', 'PV', 'PR']]) + else: + fields.append(["Version: %s-%s\n", ['PV', 'PR']]) fields.append(["Description: %s\n", ['DESCRIPTION']]) fields.append(["Section: %s\n", ['SECTION']]) fields.append(["Priority: %s\n", ['PRIORITY']]) |