diff options
| author | Mark Hatle <mark.hatle@windriver.com> | 2013-08-12 19:45:48 -0500 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2013-08-22 18:30:00 +0100 |
| commit | 33a3eac5a05443451fef8b6cfecabf773bdedbb8 (patch) | |
| tree | 5fc85c39c33437fed2b4555d3238faa73fd39b96 | |
| parent | 479fc7c2265ec38277d1c623a201a0f2ec7acda8 (diff) | |
| download | poky-33a3eac5a05443451fef8b6cfecabf773bdedbb8.tar.gz | |
python-smartpm: Add support to disable installing recommends
In order to attempt to reduce image sizes by skipping recommended packages,
a new mode was added to smart that only evaluates required packaged.
(From OE-Core rev: 6fd8141bbdcd84c591149d84ad84effc2357de72)
Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | meta/recipes-devtools/python/python-smartpm/smart-config-ignore-all-recommends.patch | 24 | ||||
| -rw-r--r-- | meta/recipes-devtools/python/python-smartpm_1.4.1.bb | 1 |
2 files changed, 25 insertions, 0 deletions
diff --git a/meta/recipes-devtools/python/python-smartpm/smart-config-ignore-all-recommends.patch b/meta/recipes-devtools/python/python-smartpm/smart-config-ignore-all-recommends.patch new file mode 100644 index 0000000000..df9d7799e8 --- /dev/null +++ b/meta/recipes-devtools/python/python-smartpm/smart-config-ignore-all-recommends.patch | |||
| @@ -0,0 +1,24 @@ | |||
| 1 | Add a simple method to disable the install of recommended packages | ||
| 2 | |||
| 3 | Upstream-Status: Pending | ||
| 4 | |||
| 5 | Usage: | ||
| 6 | smart config --set ignore-all-recommends=1 | ||
| 7 | |||
| 8 | Signed-off-by: Mark Hatle <mark.hatle@windriver.com> | ||
| 9 | |||
| 10 | Index: smart-1.4.1/smart/transaction.py | ||
| 11 | =================================================================== | ||
| 12 | --- smart-1.4.1.orig/smart/transaction.py | ||
| 13 | +++ smart-1.4.1/smart/transaction.py | ||
| 14 | @@ -611,7 +611,9 @@ class Transaction(object): | ||
| 15 | for prv in req.providedby: | ||
| 16 | for prvpkg in prv.packages: | ||
| 17 | if not reqrequired: | ||
| 18 | - if pkgconf.testFlag("ignore-recommends", prvpkg): | ||
| 19 | + if sysconf.get("ignore-all-recommends", 0) == 1: | ||
| 20 | + continue | ||
| 21 | + elif pkgconf.testFlag("ignore-recommends", prvpkg): | ||
| 22 | continue | ||
| 23 | if isinst(prvpkg): | ||
| 24 | found = True | ||
diff --git a/meta/recipes-devtools/python/python-smartpm_1.4.1.bb b/meta/recipes-devtools/python/python-smartpm_1.4.1.bb index b3b471a8b1..5d673b9902 100644 --- a/meta/recipes-devtools/python/python-smartpm_1.4.1.bb +++ b/meta/recipes-devtools/python/python-smartpm_1.4.1.bb | |||
| @@ -29,6 +29,7 @@ SRC_URI = "\ | |||
| 29 | file://smart-conflict-provider.patch \ | 29 | file://smart-conflict-provider.patch \ |
| 30 | file://smart-flag-ignore-recommends.patch \ | 30 | file://smart-flag-ignore-recommends.patch \ |
| 31 | file://smart-flag-exclude-packages.patch \ | 31 | file://smart-flag-exclude-packages.patch \ |
| 32 | file://smart-config-ignore-all-recommends.patch \ | ||
| 32 | " | 33 | " |
| 33 | 34 | ||
| 34 | SRC_URI[md5sum] = "573ef32ba177a6b3c4bf7ef04873fcb6" | 35 | SRC_URI[md5sum] = "573ef32ba177a6b3c4bf7ef04873fcb6" |
