How to identify WORKDIR?
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories. The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:
workdir = os.path.join(builddir, 'tmp/work')
Then validate the workdir exists or not. It works for me but hardcode here as Richard point out. So is there a better way to get the WORKDIR here? Thanks.
Regards,
Kai
Quoted 7 lines · Kang Kai
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories.
The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:
Quoted 5 lines
workdir =
os.path.join(builddir, 'tmp/work')Then validate the workdir exists or not. It works for me but hardcode here as Richard point out.
So is there a better way to get the WORKDIR here? Thanks.
I was thinking of something like:
bitbake -e | grep ^WORKDIR
since you already call into bitbake in the script in question.
Cheers,
Richard
Quoted 8 lines · Richard Purdie
Quoted 7 lines · Kang Kai
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories.
The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:
Quoted 8 lines
Quoted 5 lines
workdir =
os.path.join(builddir, 'tmp/work')Then validate the workdir exists or not. It works for me but hardcode here as Richard point out.
So is there a better way to get the WORKDIR here? Thanks.I was thinking of something like:
bitbake -e | grep ^WORKDIR
If get WORKDIR in this way, I'll update the script with no argument because the argument is useless to identify the WORKDIR.
Regards,
Kai
Quoted 8 lines
since you already call into bitbake in the script in question.
Cheers,
Richard
Quoted 9 lines · Kang Kai
Quoted 8 lines · Richard Purdie
Quoted 7 lines · Kang Kai
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories.
The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:
Quoted 8 lines
Quoted 8 lines
Quoted 5 lines
workdir =
os.path.join(builddir, 'tmp/work')Then validate the workdir exists or not. It works for me but hardcode here as Richard point out.
So is there a better way to get the WORKDIR here? Thanks.I was thinking of something like:
bitbake -e | grep ^WORKDIR
And the result is something like that:
WORKDIR="/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/x86_64-poky-linux/bblayers-1.0-r0"
Is it ok to remove 2 items seperated by slash at the end of string? Right now is:
"/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/"
Regards,
Kai
Quoted 19 lines
If get WORKDIR in this way, I'll update the script with no argument because the argument is useless to identify the WORKDIR.
Regards,
KaiQuoted 8 lines
since you already call into bitbake in the script in question.
Cheers,
Richard
_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel
Quoted 17 lines · Kang Kai
Quoted 16 lines · Kang Kai
Quoted 15 lines · Richard Purdie
Quoted 7 lines · Kang Kai
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories.
The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:Quoted 5 lines
workdir =
os.path.join(builddir, 'tmp/work')Then validate the workdir exists or not. It works for me but hardcode here as Richard point out.
So is there a better way to get the WORKDIR here? Thanks.I was thinking of something like:
Quoted 7 lines
Quoted 1 line
Quoted 1 line
bitbake -e | grep ^WORKDIR
And the result is something like that:
WORKDIR="/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/x86_64-poky-linux/bblayers-1.0-r0"Is it ok to remove 2 items seperated by slash at the end of string? Right now is:
"/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/"
Aren't you looking for ^TMPDIR ?
Quoted 30 lines
Regards,
KaiQuoted 16 lines
If get WORKDIR in this way, I'll update the script with no argument because the argument is useless to identify the WORKDIR.
Regards,
KaiQuoted 8 lines
since you already call into bitbake in the script in question.
Cheers,
Richard
Quoted 4 lines
_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel
Signature · 1 line
Martin 'JaMa' Jansa jabber: [email protected]
Quoted 18 lines · Martin Jansa
Quoted 17 lines · Kang Kai
Quoted 16 lines · Kang Kai
Quoted 15 lines · Richard Purdie
Quoted 7 lines · Kang Kai
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories.
The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:Quoted 5 lines
workdir =
os.path.join(builddir, 'tmp/work')Then validate the workdir exists or not. It works for me but hardcode here as Richard point out.
So is there a better way to get the WORKDIR here? Thanks.I was thinking of something like:
Quoted 8 lines
Quoted 7 lines
Quoted 1 line
Quoted 1 line
bitbake -e | grep ^WORKDIR
And the result is something like that:
WORKDIR="/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/x86_64-poky-linux/bblayers-1.0-r0"Is it ok to remove 2 items seperated by slash at the end of string? Right now is:
"/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/"Aren't you looking for ^TMPDIR ?
If use WORKDIR = TMPDIR/"work", it is still hard coding.
Quoted 25 lines
Quoted 25 lines
Regards,
KaiQuoted 9 lines
If get WORKDIR in this way, I'll update the script with no argument because the argument is useless to identify the WORKDIR.
Regards,
KaiQuoted 4 lines
since you already call into bitbake in the script in question.
Cheers,
Quoted 8 lines
Quoted 3 lines
Richard
_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel
Quoted 23 lines · Kang Kai
Quoted 22 lines · Martin Jansa
Quoted 21 lines · Kang Kai
Quoted 9 lines · Kang Kai
Quoted 8 lines · Richard Purdie
Quoted 7 lines · Kang Kai
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories.
The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:Quoted 8 lines
Quoted 8 lines
Quoted 5 lines
workdir =
os.path.join(builddir, 'tmp/work')Then validate the workdir exists or not. It works for me but hardcode here as Richard point out.
So is there a better way to get the WORKDIR here? Thanks.I was thinking of something like:
bitbake -e | grep ^WORKDIR
And the result is something like that:
WORKDIR="/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/x86_64-poky-linux/bblayers-1.0-r0"
Quoted 6 lines
Quoted 4 lines
Quoted 3 lines
Is it ok to remove 2 items seperated by slash at the end of string? Right now is:
"/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/"Aren't you looking for ^TMPDIR ?
If use WORKDIR = TMPDIR/"work", it is still hard coding.
Assuming 2 items at the end won't work for people using rm_old_work:
http://git.openembedded.org/meta-micro/commit/?id=fcf525654915edb9650f1a6c2852f336366f8b2f
or slightly different version:
http://git.shr-project.org/git/?p=meta-smartphone.git;a=blob;f=meta-shr/classes/rm_old_work.bbclass
And I think more people have different "tmp/" part e.g. default would be "tmp-eglibc/" (thanks to TCLIBCAPPEND meta/conf/distro/defaultsetup.conf:TMPDIR .= "${TCLIBCAPPEND}"), but "work" is quite common.
meta/conf/bitbake.conf:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PF}" meta-shr/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${PF}" meta-micro/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}"
Cheers,
Quoted 27 lines
Quoted 26 lines
Quoted 26 lines
Regards,
KaiQuoted 9 lines
If get WORKDIR in this way, I'll update the script with no argument because the argument is useless to identify the WORKDIR.
Regards,
KaiQuoted 4 lines
since you already call into bitbake in the script in question.
Cheers,
Quoted 8 lines
Quoted 3 lines
Richard
_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel
Signature · 1 line
Martin 'JaMa' Jansa jabber: [email protected]
Quoted 27 lines · Martin Jansa
Quoted 26 lines · Kang Kai
Quoted 25 lines · Martin Jansa
Quoted 24 lines · Kang Kai
Quoted 9 lines · Kang Kai
Quoted 8 lines · Richard Purdie
Quoted 7 lines · Kang Kai
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories.
The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:Quoted 8 lines
Quoted 8 lines
Quoted 5 lines
workdir =
os.path.join(builddir, 'tmp/work')Then validate the workdir exists or not. It works for me but hardcode here as Richard point out.
So is there a better way to get the WORKDIR here? Thanks.I was thinking of something like:
bitbake -e | grep ^WORKDIR
And the result is something like that:
WORKDIR="/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/x86_64-poky-linux/bblayers-1.0-r0"Is it ok to remove 2 items seperated by slash at the end of string? Right now is:
"/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/"
Quoted 6 lines
Quoted 2 lines
Quoted 1 line
Aren't you looking for ^TMPDIR ?
If use WORKDIR = TMPDIR/"work", it is still hard coding.
Assuming 2 items at the end won't work for people using
rm_old_work:
http://git.openembedded.org/meta-micro/commit/?id=fcf525654915edb9650f1a6c2852f336366f8b2f
or slightly different version:
http://git.shr-project.org/git/?p=meta-smartphone.git;a=blob;f=meta-shr/classes/rm_old_work.bbclass
Hi Martin,
Quoted 11 lines
And I think more people have different "tmp/" part e.g. default would be "tmp-eglibc/" (thanks to TCLIBCAPPEND meta/conf/distro/defaultsetup.conf:TMPDIR .= "${TCLIBCAPPEND}"), but "work" is quite common.
meta/conf/bitbake.conf:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PF}" meta-shr/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${PF}" meta-micro/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}"
OK. Thanks very much.
Regards,
Kai
Quoted 25 lines
Cheers,
Quoted 23 lines
Quoted 23 lines
Quoted 23 lines
Regards,
KaiQuoted 9 lines
If get WORKDIR in this way, I'll update the script with no argument because the argument is useless to identify the WORKDIR.
Regards,
KaiQuoted 4 lines
since you already call into bitbake in the script in question.
Cheers,
Quoted 7 lines
Quoted 3 lines
Richard
_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel
Quoted 27 lines · Martin Jansa
Quoted 26 lines · Kang Kai
Quoted 25 lines · Martin Jansa
Quoted 24 lines · Kang Kai
Quoted 9 lines · Kang Kai
Quoted 8 lines · Richard Purdie
Quoted 7 lines · Kang Kai
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories.
The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:Quoted 8 lines
Quoted 8 lines
Quoted 5 lines
workdir =
os.path.join(builddir, 'tmp/work')Then validate the workdir exists or not. It works for me but hardcode here as Richard point out.
So is there a better way to get the WORKDIR here? Thanks.I was thinking of something like:
bitbake -e | grep ^WORKDIR
And the result is something like that:
WORKDIR="/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/x86_64-poky-linux/bblayers-1.0-r0"Is it ok to remove 2 items seperated by slash at the end of string? Right now is:
"/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/"
Quoted 8 lines
Quoted 3 lines
Quoted 1 line
Aren't you looking for ^TMPDIR ?
If use WORKDIR = TMPDIR/"work", it is still hard coding.
Assuming 2 items at the end won't work for people using
rm_old_work:
http://git.openembedded.org/meta-micro/commit/?id=fcf525654915edb9650f1a6c2852f336366f8b2f
or slightly different version:
http://git.shr-project.org/git/?p=meta-smartphone.git;a=blob;f=meta-shr/classes/rm_old_work.bbclass
Martin,
Can you please point me to more details about this class - any background or discussions... Thanks.
Signature · 1 line
Denys
Quoted 51 lines
And I think more people have different "tmp/" part e.g. default would be "tmp-eglibc/" (thanks to TCLIBCAPPEND meta/conf/distro/defaultsetup.conf:TMPDIR .= "${TCLIBCAPPEND}"), but "work" is quite common.
meta/conf/bitbake.conf:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PF}" meta-shr/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${PF}" meta-micro/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}"Cheers,
Quoted 27 lines
Quoted 26 lines
Quoted 26 lines
Regards,
KaiQuoted 9 lines
If get WORKDIR in this way, I'll update the script with no argument because the argument is useless to identify the WORKDIR.
Regards,
KaiQuoted 4 lines
since you already call into bitbake in the script in question.
Cheers,
Quoted 8 lines
Quoted 3 lines
Richard
_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-develSignature · 8 lines
Martin 'JaMa' Jansa jabber: [email protected] _______________________________________________ bitbake-devel mailing list [email protected] http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel
Quoted 37 lines · Denys Dmytriyenko
Quoted 27 lines · Martin Jansa
Quoted 26 lines · Kang Kai
Quoted 25 lines · Martin Jansa
Quoted 24 lines · Kang Kai
Quoted 9 lines · Kang Kai
Quoted 8 lines · Richard Purdie
Quoted 7 lines · Kang Kai
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories.
The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:Quoted 8 lines
Quoted 8 lines
Quoted 5 lines
workdir =
os.path.join(builddir, 'tmp/work')Then validate the workdir exists or not. It works for me but hardcode here as Richard point out.
So is there a better way to get the WORKDIR here? Thanks.I was thinking of something like:
bitbake -e | grep ^WORKDIR
And the result is something like that:
WORKDIR="/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/x86_64-poky-linux/bblayers-1.0-r0"Is it ok to remove 2 items seperated by slash at the end of string? Right now is:
"/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/"Quoted 8 lines
Quoted 3 lines
Quoted 1 line
Aren't you looking for ^TMPDIR ?
If use WORKDIR = TMPDIR/"work", it is still hard coding.
Assuming 2 items at the end won't work for people using
rm_old_work:
http://git.openembedded.org/meta-micro/commit/?id=fcf525654915edb9650f1a6c2852f336366f8b2f
or slightly different version:
http://git.shr-project.org/git/?p=meta-smartphone.git;a=blob;f=meta-shr/classes/rm_old_work.bbclass
Quoted 4 lines
Martin,
Can you please point me to more details about this class - any background or discussions... Thanks.
Hi,
Well it works better then rm_work with sstate and the original class is from meta-micro (so maybe ask pb if you want more details, but the class is quite simple). I've just replaced last directory name because of this issue:
Cheers,
Quoted 57 lines
Signature · 2 lines
-- DenysQuoted 51 lines
And I think more people have different "tmp/" part e.g. default would be "tmp-eglibc/" (thanks to TCLIBCAPPEND meta/conf/distro/defaultsetup.conf:TMPDIR .= "${TCLIBCAPPEND}"), but "work" is quite common.
meta/conf/bitbake.conf:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PF}" meta-shr/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${PF}" meta-micro/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}"Cheers,
Quoted 27 lines
Quoted 26 lines
Quoted 26 lines
Regards,
KaiQuoted 9 lines
If get WORKDIR in this way, I'll update the script with no argument because the argument is useless to identify the WORKDIR.
Regards,
KaiQuoted 4 lines
since you already call into bitbake in the script in question.
Cheers,
Quoted 8 lines
Quoted 3 lines
Richard
_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-develSignature · 8 lines
Martin 'JaMa' Jansa jabber: [email protected] _______________________________________________ bitbake-devel mailing list [email protected] http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel
Signature · 1 line
Martin 'JaMa' Jansa jabber: [email protected]
Quoted 43 lines · Martin Jansa
Quoted 37 lines · Denys Dmytriyenko
Quoted 27 lines · Martin Jansa
Quoted 26 lines · Kang Kai
Quoted 25 lines · Martin Jansa
Quoted 24 lines · Kang Kai
Quoted 9 lines · Kang Kai
Quoted 8 lines · Richard Purdie
Quoted 7 lines · Kang Kai
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories.
The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:Quoted 8 lines
Quoted 8 lines
Quoted 5 lines
workdir =
os.path.join(builddir, 'tmp/work')Then validate the workdir exists or not. It works for me but hardcode here as Richard point out.
So is there a better way to get the WORKDIR here? Thanks.I was thinking of something like:
bitbake -e | grep ^WORKDIR
And the result is something like that:
WORKDIR="/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/x86_64-poky-linux/bblayers-1.0-r0"Is it ok to remove 2 items seperated by slash at the end of string? Right now is:
"/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/"Quoted 8 lines
Quoted 3 lines
Quoted 1 line
Aren't you looking for ^TMPDIR ?
If use WORKDIR = TMPDIR/"work", it is still hard coding.
Assuming 2 items at the end won't work for people using
rm_old_work:
http://git.openembedded.org/meta-micro/commit/?id=fcf525654915edb9650f1a6c2852f336366f8b2f
or slightly different version:
http://git.shr-project.org/git/?p=meta-smartphone.git;a=blob;f=meta-shr/classes/rm_old_work.bbclassQuoted 4 lines
Martin,
Can you please point me to more details about this class - any background or discussions... Thanks.
Quoted 8 lines
Hi,
Well it works better then
rm_workwith sstate and the original class is from meta-micro (so maybe ask pb if you want more details, but the class is quite simple). I've just replaced last directory name because of this issue:
Martin,
Hmm, my understanding those are slightly different classes - rm_work cleans WORKDIR after the build to save space, while this rm_old_work seems to clean up before the build. I tried searching for any previous discussions of this class or any other rationale, but even the commit itself doesn't provide much explanation for it...
Phil,
Do you mind giving a short description of this peculiar rm_old_work class? :) Thanks.
Signature · 1 line
Denys
Quoted 55 lines
Quoted 52 lines
Quoted 51 lines
And I think more people have different "tmp/" part e.g. default would be "tmp-eglibc/" (thanks to TCLIBCAPPEND meta/conf/distro/defaultsetup.conf:TMPDIR .= "${TCLIBCAPPEND}"), but "work" is quite common.
meta/conf/bitbake.conf:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PF}" meta-shr/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${PF}" meta-micro/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}"Cheers,
Quoted 27 lines
Quoted 26 lines
Quoted 26 lines
Regards,
KaiQuoted 9 lines
If get WORKDIR in this way, I'll update the script with no argument because the argument is useless to identify the WORKDIR.
Regards,
KaiQuoted 4 lines
since you already call into bitbake in the script in question.
Cheers,
Quoted 8 lines
Quoted 3 lines
Richard
_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel_______________________________________________
bitbake-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-develSignature · 8 lines
Martin 'JaMa' Jansa jabber: [email protected] _______________________________________________ bitbake-devel mailing list [email protected] http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-develSignature · 1 line
Martin 'JaMa' Jansa jabber: [email protected]
rm_old_work seems to do exactly what it sounds like. It removes *old* workdirs from previous versions of the recipe to keep it from bloating without bound if you retain the same tmpdir.
Signature · 1 line
Christopher Larson
Quoted 155 lines · Denys Dmytriyenko
Quoted 53 lines · Martin Jansa
Quoted 45 lines · Denys Dmytriyenko
Quoted 35 lines · Martin Jansa
Quoted 34 lines · Kang Kai
Quoted 31 lines · Martin Jansa
Quoted 19 lines · Kang Kai
Quoted 18 lines · Kang Kai
Quoted 17 lines · Richard Purdie
Quoted 7 lines · Kang Kai
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories.
The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:Quoted 6 lines
workdir =
os.path.join(builddir, 'tmp/work')Then validate the workdir exists or not. It works for me but hardcode here as Richard point out.
So is there a better way to get the WORKDIR here? Thanks.I was thinking of something like:
Quoted 8 lines
Quoted 1 line
Quoted 1 line
bitbake -e | grep ^WORKDIR
And the result is something like that:
WORKDIR="/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/x86_64-poky-linux/bblayers-1.0-r0"Is it ok to remove 2 items seperated by slash at the end of string? Right now is:
"/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/"Aren't you looking for ^TMPDIR ?
Quoted 7 lines
Quoted 1 line
If use WORKDIR = TMPDIR/"work", it is still hard coding.
Assuming 2 items at the end won't work for people using
rm_old_work:
http://git.openembedded.org/meta-micro/commit/?id=fcf525654915edb9650f1a6c2852f336366f8b2f
or slightly different version:
http://git.shr-project.org/git/?p=meta-smartphone.git;a=blob;f=meta-shr/classes/rm_old_work.bbclassQuoted 5 lines
Martin,
Can you please point me to more details about this class - any background or discussions... Thanks.
Quoted 8 lines
Hi,
Well it works better then
rm_workwith sstate and the original class is from meta-micro (so maybe ask pb if you want more details, but the class is quite simple). I've just replaced last directory name because of this issue:Martin,
Hmm, my understanding those are slightly different classes -
rm_workcleans WORKDIR after the build to save space, while thisrm_old_workseems to clean up before the build. I tried searching for any previous discussions of this class or any other rationale, but even the commit itself doesn't provide much explanation for it...Phil,
Do you mind giving a short description of this peculiar
rm_old_workclass? :) Thanks.Signature · 1 line
DenysQuoted 53 lines
Quoted 53 lines
Quoted 49 lines
And I think more people have different "tmp/" part e.g. default would be "tmp-eglibc/" (thanks to TCLIBCAPPEND meta/conf/distro/defaultsetup.conf:TMPDIR .= "${TCLIBCAPPEND}"), but "work" is quite common.
meta/conf/bitbake.conf:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PF}" meta-shr/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${PF}" meta-micro/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}"Cheers,
Quoted 30 lines
Quoted 28 lines
Quoted 27 lines
Regards,
KaiQuoted 7 lines
If get WORKDIR in this way, I'll update the script with no argument because the argument is useless to identify the WORKDIR.
Regards,
KaiQuoted 2 lines
since you already call into bitbake in the script in question.
Quoted 9 lines
Quoted 3 lines
Cheers,
Richard
_______________________________________________
bitbake-devel mailing list
[email protected] (mailto:[email protected])
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel_______________________________________________
bitbake-devel mailing list
[email protected] (mailto:[email protected])
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-develSignature · 1 line
Martin 'JaMa' Jansa jabber: [email protected] (mailto:[email protected])Quoted 12 lines
Quoted 7 lines
Quoted 5 lines
_______________________________________________
bitbake-devel mailing list
[email protected] (mailto:[email protected])
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-develSignature · 1 line
Martin 'JaMa' Jansa jabber: [email protected] (mailto:[email protected])_______________________________________________
bitbake-devel mailing list
[email protected] (mailto:[email protected])
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel
Quoted 3 lines · Christopher Larson
rm_old_workseems to do exactly what it sounds like. It removes *old* workdirs from previous versions of the recipe to keep it from bloating without bound if you retain the same tmpdir.
Correct, that's my understanding as well. But it's not meant to replace rm_work, as it can't save space the same way during the build - by the time your build is done, you are using 100% of what WORKDIR would have been w/o this class in the case of a clean build . It prevents the size to grow beyond that point though...
I was just trying to clarify this statement, suggesting they both serve the same purpose:
Quoted 1 line
Well it works better then
rm_workwith sstate
Signature · 1 line
Denys
Quoted 159 lines · Denys Dmytriyenko
Quoted 156 lines · Martin Jansa
Quoted 53 lines · Denys Dmytriyenko
Quoted 45 lines · Martin Jansa
Quoted 35 lines · Kang Kai
Quoted 34 lines · Martin Jansa
Quoted 31 lines · Kang Kai
Quoted 19 lines · Kang Kai
Quoted 18 lines · Richard Purdie
Quoted 17 lines · Kang Kai
Quoted 7 lines
Hi All,
I write a script to clean up WORKDIR that remove the obsoleted packages' build directories.
The script accept a argument as BUILDDIR and I use this clause to identify the WORKDIR:Quoted 6 lines
workdir =
os.path.join(builddir, 'tmp/work')Then validate the workdir exists or not. It works for me but hardcode here as Richard point out.
So is there a better way to get the WORKDIR here? Thanks.I was thinking of something like:
Quoted 8 lines
Quoted 1 line
Quoted 1 line
bitbake -e | grep ^WORKDIR
And the result is something like that:
WORKDIR="/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/x86_64-poky-linux/bblayers-1.0-r0"Is it ok to remove 2 items seperated by slash at the end of string? Right now is:
"/mnt/sda10/poky-all-platform/build-qemux86_64/tmp/work/"Aren't you looking for ^TMPDIR ?
Quoted 7 lines
Quoted 1 line
If use WORKDIR = TMPDIR/"work", it is still hard coding.
Assuming 2 items at the end won't work for people using
rm_old_work:
http://git.openembedded.org/meta-micro/commit/?id=fcf525654915edb9650f1a6c2852f336366f8b2f
or slightly different version:
http://git.shr-project.org/git/?p=meta-smartphone.git;a=blob;f=meta-shr/classes/rm_old_work.bbclassQuoted 5 lines
Martin,
Can you please point me to more details about this class - any background or discussions... Thanks.
Quoted 8 lines
Hi,
Well it works better then
rm_workwith sstate and the original class is from meta-micro (so maybe ask pb if you want more details, but the class is quite simple). I've just replaced last directory name because of this issue:Martin,
Hmm, my understanding those are slightly different classes -
rm_workcleans WORKDIR after the build to save space, while thisrm_old_workseems to clean up before the build. I tried searching for any previous discussions of this class or any other rationale, but even the commit itself doesn't provide much explanation for it...Phil,
Do you mind giving a short description of this peculiar
rm_old_workclass? :) Thanks.Signature · 1 line
DenysQuoted 53 lines
Quoted 53 lines
Quoted 49 lines
And I think more people have different "tmp/" part e.g. default would be "tmp-eglibc/" (thanks to TCLIBCAPPEND meta/conf/distro/defaultsetup.conf:TMPDIR .= "${TCLIBCAPPEND}"), but "work" is quite common.
meta/conf/bitbake.conf:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PF}" meta-shr/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${PF}" meta-micro/classes/rm_old_work.bbclass:
WORKDIR = "${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}"Cheers,
Quoted 30 lines
Quoted 28 lines
Quoted 27 lines
Regards,
KaiQuoted 7 lines
If get WORKDIR in this way, I'll update the script with no argument because the argument is useless to identify the WORKDIR.
Regards,
KaiQuoted 2 lines
since you already call into bitbake in the script in question.
Quoted 9 lines
Quoted 3 lines
Cheers,
Richard
_______________________________________________
bitbake-devel mailing list
[email protected] (mailto:[email protected])
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel_______________________________________________
bitbake-devel mailing list
[email protected] (mailto:[email protected])
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-develSignature · 1 line
Martin 'JaMa' Jansa jabber: [email protected] (mailto:[email protected])Quoted 12 lines
Quoted 7 lines
Quoted 5 lines
_______________________________________________
bitbake-devel mailing list
[email protected] (mailto:[email protected])
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-develSignature · 1 line
Martin 'JaMa' Jansa jabber: [email protected] (mailto:[email protected])_______________________________________________
bitbake-devel mailing list
[email protected] (mailto:[email protected])
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/bitbake-devel