Skip to contentSkip to conversation

debian.bbclass: call auto_libname in reverse sorted AUTO_LIBNAME_PKGS

PATCH In review Martin Jansa 2 participants 2 messages Mar 3, 2011

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 debian.bbclass: call auto_libname in reverse sorted AUTO_LIBNAME_PKGS

* see comment for reason why we need this
* more info:
http://lists.linuxtogo.org/pipermail/openembedded-devel/2011-February/029877.html

---
 meta/classes/debian.bbclass |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)
meta/classes/debian.bbclass +7 -1
index d35882f..46a9d08 100644
@@ -107,7 +107,13 @@ python debian_package_name_hook () {
 					if newpkg != pkg:
 						bb.data.setVar('PKG_' + pkg, newpkg, d)
 
-	for pkg in (bb.data.getVar('AUTO_LIBNAME_PKGS', d, 1) or "").split():
+	# reversed sort is needed when some package is substring of another
+	# ie in ncurses we get without reverse sort: 
+	# DEBUG: LIBNAMES: pkgname libtic5 devname libtic pkg ncurses-libtic orig_pkg ncurses-libtic debian_pn None newpkg libtic5
+	# and later
+	# DEBUG: LIBNAMES: pkgname libtic5 devname libtic pkg ncurses-libticw orig_pkg ncurses-libtic debian_pn None newpkg libticw
+	# so we need to handle ncurses-libticw->libticw5 before ncurses-libtic->libtic5
+	for pkg in sorted((bb.data.getVar('AUTO_LIBNAME_PKGS', d, 1) or "").split(), reverse=True):
 		auto_libname(packages, pkg)
 }
 
Signature · 1 line
1.7.4.1
Acked-by on v1 1/1
#1 lore raw

Op 3 mrt 2011, om 15:46 heeft Martin Jansa het volgende geschreven:

Quoted 5 lines

* see comment for reason why we need this
* more info:
http://lists.linuxtogo.org/pipermail/openembedded-devel/2011-February/029877.html

Quoted 31 lines

---
meta/classes/debian.bbclass | 8 +++++++-

1 files changed, 7 insertions(+), 1 deletions(-)
meta/classes/debian.bbclass +7 -1
index d35882f..46a9d08 100644
@@ -107,7 +107,13 @@ python debian_package_name_hook () {
 					if newpkg != pkg:
 						bb.data.setVar('PKG_' + pkg, newpkg, d)
 
-	for pkg in (bb.data.getVar('AUTO_LIBNAME_PKGS', d, 1) or "").split():
+	# reversed sort is needed when some package is substring of another
+	# ie in ncurses we get without reverse sort: 
+	# DEBUG: LIBNAMES: pkgname libtic5 devname libtic pkg ncurses-libtic orig_pkg ncurses-libtic debian_pn None newpkg libtic5
+	# and later
+	# DEBUG: LIBNAMES: pkgname libtic5 devname libtic pkg ncurses-libticw orig_pkg ncurses-libtic debian_pn None newpkg libticw
+	# so we need to handle ncurses-libticw->libticw5 before ncurses-libtic->libtic5
+	for pkg in sorted((bb.data.getVar('AUTO_LIBNAME_PKGS', d, 1) or "").split(), reverse=True):
 		auto_libname(packages, pkg)
 }
 
Signature · 7 lines
1.7.4.1


_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core