Skip to contentSkip to conversation

package.bbclass: call PACKAGESTRIPFUNCS before populate_packages

PATCH RESEND In review Andreas Oberritter 2 participants 4 messages Dec 8, 2010 – Dec 16, 2010

lore
Share & tools
lore
#0 lore raw

PATCH RESEND 1/1 package.bbclass: call PACKAGESTRIPFUNCS before populate_packages

Introduce run_strip_funcs() to call the functions in PACKAGESTRIPFUNCS and place it before populate_packages().

This allows users of do_split_packages() to package the .debug directories, which get created by do_runstrip().

do_split_packages() is usually prepended to populate_packages().

---
 classes/package.bbclass |   12 +++++++-----
 1 files changed, 7 insertions(+), 5 deletions(-)
classes/package.bbclass +7 -5
index 2769595..678ffa9 100644
@@ -367,6 +367,12 @@ python perform_packagecopy () {
 	os.system('cp -pPR %s/. %s/' % (installdest, pkgcopy))
 }
 
+python run_strip_funcs() {
+	if (bb.data.getVar('PACKAGE_STRIP', d, True) != 'no'):
+		for f in (bb.data.getVar('PACKAGESTRIPFUNCS', d, True) or '').split():
+			bb.build.exec_func(f, d)
+}
+
 python populate_packages () {
 	import glob, errno, re,os
 
@@ -391,11 +397,6 @@ python populate_packages () {
 		else:
 			package_list.append(pkg)
 
-
-	if (bb.data.getVar('PACKAGE_STRIP', d, True) != 'no'):
-		for f in (bb.data.getVar('PACKAGESTRIPFUNCS', d, True) or '').split():
-			bb.build.exec_func(f, d)
-
 	pkgdest = bb.data.getVar('PKGDEST', d, True)
 	os.system('rm -rf %s' % pkgdest)
 
@@ -1011,6 +1012,7 @@ PACKAGE_PREPROCESS_FUNCS ?= ""
 PACKAGEFUNCS ?= "perform_packagecopy \
                 ${PACKAGE_PREPROCESS_FUNCS} \
 		package_do_split_locales \
+		run_strip_funcs \
 		populate_packages \
 		package_do_shlibs \
 		package_do_pkgconfig \
Signature · 1 line
1.7.2.3
#1 lore raw

Ping

Quoted 50 lines · Andreas Oberritter

Introduce run_strip_funcs() to call the functions in PACKAGESTRIPFUNCS and place it before populate_packages().

This allows users of do_split_packages() to package the .debug directories, which get created by do_runstrip().

do_split_packages() is usually prepended to populate_packages().

---
 classes/package.bbclass |   12 +++++++-----
 1 files changed, 7 insertions(+), 5 deletions(-)
classes/package.bbclass +7 -5
index 2769595..678ffa9 100644
@@ -367,6 +367,12 @@ python perform_packagecopy () {
 	os.system('cp -pPR %s/. %s/' % (installdest, pkgcopy))
 }
 
+python run_strip_funcs() {
+	if (bb.data.getVar('PACKAGE_STRIP', d, True) != 'no'):
+		for f in (bb.data.getVar('PACKAGESTRIPFUNCS', d, True) or '').split():
+			bb.build.exec_func(f, d)
+}
+
 python populate_packages () {
 	import glob, errno, re,os
 
@@ -391,11 +397,6 @@ python populate_packages () {
 		else:
 			package_list.append(pkg)
 
-
-	if (bb.data.getVar('PACKAGE_STRIP', d, True) != 'no'):
-		for f in (bb.data.getVar('PACKAGESTRIPFUNCS', d, True) or '').split():
-			bb.build.exec_func(f, d)
-
 	pkgdest = bb.data.getVar('PKGDEST', d, True)
 	os.system('rm -rf %s' % pkgdest)
 
@@ -1011,6 +1012,7 @@ PACKAGE_PREPROCESS_FUNCS ?= ""
 PACKAGEFUNCS ?= "perform_packagecopy \
                 ${PACKAGE_PREPROCESS_FUNCS} \
 		package_do_split_locales \
+		run_strip_funcs \
 		populate_packages \
 		package_do_shlibs \
 		package_do_pkgconfig \
#2 lore raw
Quoted 12 lines · Andreas Oberritter

Ping

Quoted 9 lines · Andreas Oberritter

Introduce run_strip_funcs() to call the functions in PACKAGESTRIPFUNCS and place it before populate_packages().

This allows users of do_split_packages() to package the .debug directories, which get created by do_runstrip().

do_split_packages() is usually prepended to populate_packages().

looks ok to me. I thought .debug are automatically picked into -debug packages
In what cases will this help ?

Quoted 47 lines
Quoted 34 lines
---
 classes/package.bbclass |   12 +++++++-----
 1 files changed, 7 insertions(+), 5 deletions(-)
classes/package.bbclass +6 -5
index 2769595..678ffa9 100644
@@ -367,6 +367,12 @@ python perform_packagecopy () {
 	os.system('cp -pPR %s/. %s/' % (installdest, pkgcopy))
 }
 
+python run_strip_funcs() {
+	if (bb.data.getVar('PACKAGE_STRIP', d, True) != 'no'):
+		for f in (bb.data.getVar('PACKAGESTRIPFUNCS', d, True) or '').split():
+			bb.build.exec_func(f, d)
+}
+
 python populate_packages () {
 	import glob, errno, re,os
 
@@ -391,11 +397,6 @@ python populate_packages () {
 		else:
 			package_list.append(pkg)
 
-
-	if (bb.data.getVar('PACKAGE_STRIP', d, True) != 'no'):
-		for f in (bb.data.getVar('PACKAGESTRIPFUNCS', d, True) or '').split():
-			bb.build.exec_func(f, d)
-
 	pkgdest = bb.data.getVar('PKGDEST', d, True)
 	os.system('rm -rf %s' % pkgdest)
 

classes/package.bbclass PACKAGE_PREPROCESS_FUNCS ?= "" · line 1018

Quoted 7 lines
classes/package.bbclass +1 -0
@@ -1011,6 +1012,7 @@ PACKAGE_PREPROCESS_FUNCS ?= ""
 PACKAGEFUNCS ?= "perform_packagecopy \
                 ${PACKAGE_PREPROCESS_FUNCS} \
 		package_do_split_locales \
+		run_strip_funcs \
 		populate_packages \
 		package_do_shlibs \
 		package_do_pkgconfig \

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

#3 lore raw
Quoted 10 lines · Khem Raj
Quoted 9 lines · Andreas Oberritter

Ping

Quoted 6 lines · Andreas Oberritter

Introduce run_strip_funcs() to call the functions in PACKAGESTRIPFUNCS and place it before populate_packages().

This allows users of do_split_packages() to package the .debug directories, which get created by do_runstrip().

Quoted 7 lines
Quoted 3 lines
Quoted 3 lines

do_split_packages() is usually prepended to populate_packages().

looks ok to me. I thought .debug are automatically picked into -debug packages
In what cases will this help ?

We have a set of plugins split into one package each. With this patch, I can create "plugin-foo-dbg" packages, which seems to be much nicer than having one meta-dbg package containing all debug symbols, especially with a large amount of plugins.

Regards,
Andreas