diff options
Diffstat (limited to 'meta/recipes-core/util-linux/util-linux_2.17.2.bb')
-rw-r--r-- | meta/recipes-core/util-linux/util-linux_2.17.2.bb | 31 |
1 files changed, 30 insertions, 1 deletions
diff --git a/meta/recipes-core/util-linux/util-linux_2.17.2.bb b/meta/recipes-core/util-linux/util-linux_2.17.2.bb index 190a9e3784..f6bdfd4988 100644 --- a/meta/recipes-core/util-linux/util-linux_2.17.2.bb +++ b/meta/recipes-core/util-linux/util-linux_2.17.2.bb | |||
@@ -1,6 +1,9 @@ | |||
1 | MAJOR_VERSION = "2.17" | 1 | MAJOR_VERSION = "2.17" |
2 | PR = "r7" | ||
2 | require util-linux.inc | 3 | require util-linux.inc |
3 | PR = "r6" | 4 | |
5 | # note that `lscpu' is under GPLv3+ | ||
6 | LICENSE_util-linux-lscpu = "GPLv3+" | ||
4 | 7 | ||
5 | SRC_URI += "file://uclibc-compile.patch \ | 8 | SRC_URI += "file://uclibc-compile.patch \ |
6 | file://util-linux-ng-replace-siginterrupt.patch \ | 9 | file://util-linux-ng-replace-siginterrupt.patch \ |
@@ -9,6 +12,32 @@ SRC_URI += "file://uclibc-compile.patch \ | |||
9 | SRC_URI[md5sum] = "4635725a3eef1c57090bac8ea5e082e6" | 12 | SRC_URI[md5sum] = "4635725a3eef1c57090bac8ea5e082e6" |
10 | SRC_URI[sha256sum] = "c9ae801b6a5ab20b7749a278a8bf6830ef53adc5e8b7eb0ac1a9f410c774118f" | 13 | SRC_URI[sha256sum] = "c9ae801b6a5ab20b7749a278a8bf6830ef53adc5e8b7eb0ac1a9f410c774118f" |
11 | 14 | ||
15 | # Only lscpu part is gplv3; rest of the code is not, | ||
16 | # so take out the lscpu parts while running non-gplv3 build. | ||
17 | python () { | ||
18 | d.setVar("REMOVELSCPU", "no") | ||
19 | if (d.getVar("INCOMPATIBLE_LICENSE", True) or "").find("GPLv3") != -1: | ||
20 | # avoid GPLv3 | ||
21 | d.setVar("REMOVELSCPU", "yes") | ||
22 | packages = (d.getVar("PACKAGES", False) or "").split() | ||
23 | if "util-linux-lscpu" in packages: | ||
24 | packages.remove("util-linux-lscpu") | ||
25 | d.setVar("PACKAGES", " ".join(packages)) | ||
26 | |||
27 | src_uri = (d.getVar("SRC_URI", False) or "").split() | ||
28 | src_uri.append("file://remove-lscpu.patch") | ||
29 | d.setVar("SRC_URI", " ".join(src_uri)) | ||
30 | } | ||
31 | |||
32 | do_remove_lscpu() { | ||
33 | if [ "x${REMOVELSCPU}" = "xyes" ]; then | ||
34 | rm -f sys-utils/lscpu.c sys-utils/lscpu.1 | ||
35 | rm -rf tests/ts/lscpu tests/expected/lscpu | ||
36 | fi | ||
37 | } | ||
38 | |||
39 | addtask remove_lscpu before do_configure after do_patch | ||
40 | |||
12 | # fallocate is glibc 2.10, fallocate64 is glibc 2.11 | 41 | # fallocate is glibc 2.10, fallocate64 is glibc 2.11 |
13 | # we need to disable it for older versions | 42 | # we need to disable it for older versions |
14 | EXTRA_OECONF += "ac_cv_func_fallocate=no" | 43 | EXTRA_OECONF += "ac_cv_func_fallocate=no" |