Commit Graph

31 Commits

Author SHA1 Message Date
Richard Purdie bfd0a39bdf classes: Drop now unneeded update_data calls
Now that the datastore works dynamically we don't need the update_data calls
so we can just remove them. They're not actually done anything at all for
a while.

(From OE-Core rev: 8de0c5d3bd01919e2bf0394f9c485936d6098cec)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-02-15 09:29:55 -08:00
Joshua Lock 3c59b1bf93 meta: remove True option to getVarFlag calls
getVarFlag() now defaults to expanding by default, thus remove the
True option from getVarFlag() calls with a regex search and
replace.

Search made with the following regex:
getVarFlag ?\(( ?[^,()]*, ?[^,()]*), True\)

(From OE-Core rev: 2dea9e490a98377010b3d4118d054814c317a735)

Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-12-16 10:23:23 +00:00
Joshua Lock c4e2c59088 meta: remove True option to getVar calls
getVar() now defaults to expanding by default, thus remove the True
option from getVar() calls with a regex search and replace.

Search made with the following regex: getVar ?\(( ?[^,()]*), True\)

(From OE-Core rev: 7c552996597faaee2fbee185b250c0ee30ea3b5f)

Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-12-16 10:23:23 +00:00
Robert Yang 49d189e241 package_tar: avoid chdir warnings and restore cwd after packaging
Fixed:
WARNING: attr-2.4.47-r0 do_package_write_tar: Task do_package_tar changed cwd to /path/to/attr/2.4.47-r0/packages-split/attr-locale-sv

(From OE-Core rev: 3753d07c9ff33b9a97aca61ad312b0e283c4c68d)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-15 10:01:43 +01:00
Richard Purdie 7fa6eeba1c classes/lib: Add expand parameter to getVarFlag
This sets the scene for removing the default False for expansion
from getVarFlag. This would later allow True to become the default.

On the most part this is an automatic translation with:

sed -e 's:\(\.getVarFlag([^,()]*, [^,()]*\)):\1, True):g'  -i `grep -ril getVar *`

In this case, the default was False, but True was used since in most
cases here expansion would be expected.

(From OE-Core rev: 42a10788e89b07b14a150ced07113566cf99fcdd)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-04 23:39:00 +00:00
Richard Purdie 86d30d756a meta: Add explict getVar param for (non) expansion
Rather than just use d.getVar(X), use the more explict d.getVar(X, False)
since at some point in the future, having the default of expansion would
be nice. This is the first step towards that.

This patch was mostly made using the command:

sed -e 's:\(getVar([^,()]*\)\s*):\1, False):g' -i `grep -ril getVar *`

(From OE-Core rev: ab7c1d239b122c8e549e8112c88fd46c9e2b061b)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-06-23 11:57:25 +01:00
Paul Eggleton ae12658095 classes/package_tar: fix conflicts with package_deb / package_ipk
Avoid tar noticing that the directory is changing when
do_package_write_deb or do_package_write_ipk are running at the same
time as do_package_write_tar (because DEBIAN and CONTROL are being added
and removed while tar is running so the directory changes).

Fixes [YOCTO #5652]

(From OE-Core rev: d000761acdb2645ac879d8d9d6b022770545f644)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-02-25 08:01:09 +00:00
Paul Eggleton 8e8de62a2d classes/package_tar: fix file ownership within tarballs
The fakeroot flag wasn't correctly set leading to files within the
output tarballs having uid/gid values from the build host instead of the
desired target permissions.

(From OE-Core rev: a31c7ec56568e5dafc2f45ba5675367ddceb0e3e)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-06-19 18:03:35 +01:00
Richard Purdie e13755a542 package_tar: Fix so it actually works
This tells us how long the code hasn't been used for :/

(From OE-Core rev: cd503c7f7fec6d177209832f73cec9c5d490be6b)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-17 22:32:04 +00:00
Richard Purdie 8fb417a67c package_tar: Remove completely pointless code
Remove/simply overcomplicated code. No functionality change.

(From OE-Core rev: e3b21455e4ecc5b4961cf52e035a2d6d541faf69)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-17 22:32:04 +00:00
Richard Purdie 7e629a36c9 package_tar: bb.mkdirhier -> bb.utils.mkdirhier
Fix deprecated function reference.

(From OE-Core rev: 9e7a6492010aa2de65310d6fa13290068e7cadb1)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-17 22:32:04 +00:00
Richard Purdie 398a6dcc84 package_tar: Fix whitespace
(From OE-Core rev: fead6005b56f53535967476cc752691316e02183)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-17 22:32:03 +00:00
Richard Purdie ba110d3b69 package_rpm/dev/ipk/tar: Drop unused functions
The package_xxx_install functions date from a different era and are not used by
anything. In the rpm case, they're simply unimplemented, in the tar case they're
using broken whitespace and deprecated functions. We might as well clean
out the old broken unused code.

(From OE-Core rev: 3684036213c9b1c27389260b7a1e3441c6bd659d)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-17 22:32:03 +00:00
Richard Purdie 3247292683 Split do_packagedata task from do_package
Currently, do_rootfs has a dependency on all the do_package output being present
due to its usage of the pkgdata directories. This means that if you run:

bitbake xxxx-image -c rootfs

you end up having to fetch and unpack all the do_package data which is usually
large and inefficient. It also means rm_work has to leave all the do_package
data lying around so rootfs works.

This patch splits the actual creation of the pkgdata directory off into a separate
task, "packagedata" which happens immediately after do_package. We can then remap
the dependencies so this task is depended upon, not do_package. Sstate can then be
programmed not to require do_package at the appropriate times.

Whilst this patch doesn't do so, it opens the possibility of rm_work wiping
out the do_package output from WORKDIR as long as it also removed the do_package
stamp (both normal and setscene variants) and allowing more space savings
with rm_work which has been regularly requested.

(From OE-Core rev: 6107ee294afde395e39d084c33e8e94013c625a9)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-01-25 12:42:47 +00:00
Robert Yang e40995e569 meta: replace os.system with subprocess.call
Replace os.system with subprocess.call since the older function would
fail (more or less) silently if the executed program cannot be found

More info:
http://docs.python.org/library/subprocess.html#subprocess-replacements

[YOCTO #2454]

(From OE-Core rev: a07d03cc6f67c88feb9813ae7deb6e4a93552dfe)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-05-30 12:04:45 +01:00
Richard Purdie b1aeaa8b0d meta: Replace bb.data.expand(xxx, d) -> d.expand(xxx)
sed \
 -e 's:bb.data.\(expand([^,()]*\), *\([^) ]*\) *):\2.\1):g' \
 -i `grep -ril bb.data.expand *`

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-05 10:23:53 -08:00
Richard Purdie 06f2f8ce0a meta: Convert getVar/getVarFlag(xxx, 1) -> (xxx, True)
Using "1" with getVar is bad coding style and "True" is preferred.
This patch is a sed over the meta directory of the form:

sed \
 -e 's:\(\.getVar([^,()]*, \)1 *):\1True):g' \
 -e 's:\(\.getVarFlag([^,()]*, [^,()]*, \)1 *):\1True):g' \
 -i `grep -ril getVar *`

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-05 10:22:56 -08:00
Richard Purdie 0a434ac101 getVar/setVar cleanups
Complete the bb.data.getVar/setVar replacements with accesses
directly to the data store object.

(From OE-Core rev: 2864ff6a4b3c3f9b3bbb6d2597243cc5d3715939)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-11-27 10:25:34 +00:00
Richard Purdie c8dee9b92d Convert to use direct access to the data store (instead of bb.data.*Var*())
This is the result of running the following over the metadata:

sed \
-e 's:bb.data.\(setVar([^,()]*,[^,()]*\), *\([^ )]*\) *):\2.\1):g' \
-e 's:bb.data.\(setVarFlag([^,()]*,[^,()]*,[^,()]*\), *\([^) ]*\) *):\2.\1):g' \
-e 's:bb.data.\(getVar([^,()]*\), *\([^(), ]*\) *,\([^)]*\)):\2.\1,\3):g' \
-e 's:bb.data.\(getVarFlag([^,()]*,[^,()]*\), *\([^(), ]*\) *,\([^)]*\)):\2.\1,\3):g' \
-e 's:bb.data.\(getVarFlag([^,()]*,[^,()]*\), *\([^() ]*\) *):\2.\1):g' \
-e 's:bb.data.\(getVar([^,()]*\), *\([^) ]*\) *):\2.\1):g' \
-i `grep -ril bb.data *`

(From OE-Core rev: b22831fd63164c4db9c0b72934d7d734a6585251)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-11-10 11:51:19 +00:00
Lianhao Lu 16f06f7135 classes/package_xxx.class: Use PKGE/PKGV/PKGR.
Use PKGE/PKGV/PKGR to build various package feed in tasks of pacakge_write_xxx.

(From OE-Core rev: c2872315905fcdf6e4bf11fe96e5ca62af3475f8)

Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-05-27 17:55:49 +01:00
Richard Purdie 3c539be84c package_*.bbclass: Always run these tasks under fakeroot
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-08-19 22:36:26 +01:00
Joshua Lock 29d5edffb0 Use pseudo rather than fakeroot for fake root privileges
Make use of the ability to configure the fake root provider and use Wind
River's pseudo utility.

Signed-off-by: Joshua Lock <josh@linux.intel.com>
2010-07-16 15:40:32 +01:00
Richard Purdie b772c8cde5 bitbake.conf/base.bbclass: Rename the staging directory to sysroots and the populate_staging task to populate_sysroot
This change makes the purpose of the staging directory more obvious and
the taskname more true to what it now actually does.

The layout version number is increased due to the change in layout
but code to convert existing directories and insert a symlink for
backwards compatibility is included.

Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2009-11-13 12:15:42 +00:00
Richard Purdie c54117458a classes: Remove and sanitise import statements
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2009-11-13 12:15:28 +00:00
Richard Purdie c47528db49 package_tar.bbclass: Make the output slightly less verbose
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@3773 311d38ba-8fff-0310-9ca6-ca027cbcb966
2008-02-11 22:54:02 +00:00
Marcin Juszkiewicz d862b5758c package_{ipk|deb|tar|rpm): append depend-tasks instead of overwriting
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@3265 311d38ba-8fff-0310-9ca6-ca027cbcb966
2007-11-28 20:01:41 +00:00
Richard Purdie 48fd37f5f9 packaging: Split deb and ipk creation into separate tasks so changing the packaging type means the new type of packages are automatically generated.
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@2526 311d38ba-8fff-0310-9ca6-ca027cbcb966
2007-08-21 09:37:30 +00:00
Richard Purdie 409335beae classes: Rework core dependencies to work properly at the task level
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@1427 311d38ba-8fff-0310-9ca6-ca027cbcb966
2007-04-03 11:31:02 +00:00
Richard Purdie e2b821a834 package.bbclass: Split into two tasks, one which prepares the packages and then package_write which actually generates the packages. The two stage approach allows us to avoid circular dependency issues from classes like debian.bbclass. As the data being emitted into pkgdata/ changed, you need to either wipe tmp or rerun the do_install/do_package tasks (wipe the do_xyz stamps from the stamps dir). Everything will repackage anyway due to the new task.
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@807 311d38ba-8fff-0310-9ca6-ca027cbcb966
2006-10-20 16:09:05 +00:00
Chris Larson 4fa2d11bb1 Sync up.. all the deb/dpkg changes which I have locally are now in svn.
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@728 311d38ba-8fff-0310-9ca6-ca027cbcb966
2006-09-19 09:04:09 +00:00
Richard Purdie b2f192faab Rename /openembedded/ -> /meta/
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@530 311d38ba-8fff-0310-9ca6-ca027cbcb966
2006-07-21 10:10:31 +00:00