Commit Graph

10 Commits

Author SHA1 Message Date
Richard Purdie 480bf037ae sstate: Get rid of crazy name mapping
When originally developed, it was thought a task may have more than one associated
sstate archive. The way the code has grown that idea is now not possible or needed.
We can therefore assume one sstate archive per task and drop the crazy name
mapping code. Simpler is better in this case.

The downside is that various sstate archives will change name so this forces a cache
rebuild. Given the other sstate changes going in at this time, this isn't really
a bad thing as things would rebuild anyway.

(From OE-Core rev: 5afe86a6854b21692fd97c5fc7fab50dbc068acb)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-12-18 17:08:05 +00:00
Laurentiu Palcu 3438927b30 archive-*-source.bbclass: handle dependency in anonymous function
Using "before do_rootfs" would have this task added to do_rootfs
dependencies regardless of the filtering options. Instead, add this
dependency in the anonymous python function.

(From OE-Core rev: 2400a74923e51e17ecfa94c2d63908b0b2aac76a)

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-05-07 13:58:26 +01:00
Laurentiu Palcu a8eca39001 archive-*-source.bbclass: have do_dumpdata_create_diff_gz task run before do_rootfs
do_rootfs[cleandirs] contains ${S} and, if do_rootfs task starts before
the do_dumpdata_create_diff_gz is finished, an error will occur in the
process because the directory will be removed while still needed by the
create_diff_gz() function.

This patch will force the do_dumpdata_create_diff_gz task to run before
do_rootfs when the final image is created.

[YOCTO #4310]

(From OE-Core rev: cd90be31571178d6822dba5a94a2795209a3576c)

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-05-03 16:19:20 +01:00
Kevin Strasser 3e4655d951 archiver: fix srpm archiving build errors
srpm archiving doesn't need to be handled as a different case
when deciding what archive tasks to add.

When srpm is selected as the archiving type, the scripts and logs
archive staging directory ${WORKDIR}/script-logs is cleaned, and
its contents moved out to ${WORKDIR}.

Now that we are including ${WORKDIR}/script-logs in sstate-inputdirs,
the directory must be preserved.

[YOCTO #4032]

(From OE-Core rev: 0c80286a3383b436a0a63a0b00eb357dd9dea4fb)

Signed-off-by: Kevin Strasser <kevin.strasser@linux.intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-04-03 17:01:13 +01:00
Kevin Strasser 52026492c6 archiver: fix archive filtering behavior
With the addition of sstate, ensure that archiving tasks are only
added to the build if they produce output in the directory specified
by the 'sstate-inputdirs' flag.

Move calls to 'tar_filter' and 'not_tarball' out to
archive-*-source.bbclass in order to filter out packages before their
archiving tasks are added to the build.

Additionally, negate the return value of copyleft_should_include in
tar_filter, so that packages that do not pass are in turn filtered out.

(From OE-Core rev: 392562a21d9f2deb6fe6f8bb5378b09f4c5918d4)

Signed-off-by: Kevin Strasser <kevin.strasser@linux.intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-18 13:18:21 +00:00
Kevin Strasser 6b8ed0660f archive-*-source.bbclass: fix scripts_with_logs build error
Log and script archives are only generated when explicitly enabled by
setting the environment variable SOURCE_ARCHIVE_LOG_WITH_SCRIPTS to
'logs_with_scripts'. When left disabled, the path specified to be
handled by sstate is never created, resulting in a build error.

Only attempt to archive scripts and logs when explicitly enabled.

(From OE-Core rev: 7f1f3e6b6db9a50f5e68bc8dff95549e692153b1)

Signed-off-by: Kevin Strasser <kevin.strasser@linux.intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-18 13:18:21 +00:00
Muhammad Shakeel 98d82a5dcb archive-*-source.bbclass: Handle all package classes
* Add archiver tasks correctly for any 'IMAGE_PKGTYPE'.

[YOCTO #3449]

(From OE-Core rev: 0783686c4dc837674a2bcf3ca1f3f4858e256195)

Signed-off-by: Muhammad Shakeel <muhammad_shakeel@mentor.com>
Signed-off-by: Noor Ahsan <noor_ahsan@mentor.com>
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-28 23:15:45 +00:00
Muhammad Shakeel 2b1afa10bc archiver class: Use tasks with sstate instead of pre/post funcs
* Add tasks to move sources, script/logs and diff/env files in
  deploy directory.
* Enable SSTATE for 'do_archive_scripts_logs' task
* Enable SSTATE for 'do_dumpdata_create_diff_gz' task
* SSTATE is not used for sources/patches archiver task because source
  archive package can result into a very large file. It will be an
  unnecessary overhead to keep sources in DL_DIR and cached-binaries.
* If 'SOURCE_ARCHIVE_PACKAGE_TYPE' is 'srpm' then use pre/post functions
  because in this case we do not want to use tasks to move sources/logs
  in DEPLOY_DIR. 'do_package_write_rpm' is responsible for handling
  archiver packages.

[YOCTO #3449]

(From OE-Core rev: 959e2ae23ccbc6955a28996d4538e457cd8cfa5e)

Signed-off-by: Muhammad Shakeel <muhammad_shakeel@mentor.com>
Signed-off-by: Noor Ahsan <noor_ahsan@mentor.com>
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-28 23:15:45 +00:00
Robert Yang 2ba95cc79e archiver.bbclass: fix the coding style
* Make the comment line under 80 characters.
* Use the triple double quotes for the docstring.
* Add a whitespace behind the comma (,).
* Other minor fixes.

[YOCTO #2619]

(From OE-Core rev: 885a95992abe11ebef7a8e4363e6002ee80403bf)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-08-29 16:02:07 -07:00
Xiaofeng Yan c87b50ea9d archive-patched-source.bbclass: Archive patched source
This bbclass inherits archiver.bbclass to archive patched source

[YOCTO #1977]

(From OE-Core rev: 8f25bf3881ee568bbe03132d2205da5382fa7dd6)

Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-04-04 17:17:54 +01:00