summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/util-linux/util-linux_2.21.2.bb
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-core/util-linux/util-linux_2.21.2.bb')
-rw-r--r--meta/recipes-core/util-linux/util-linux_2.21.2.bb45
1 files changed, 45 insertions, 0 deletions
diff --git a/meta/recipes-core/util-linux/util-linux_2.21.2.bb b/meta/recipes-core/util-linux/util-linux_2.21.2.bb
new file mode 100644
index 0000000000..7f2c2a915f
--- /dev/null
+++ b/meta/recipes-core/util-linux/util-linux_2.21.2.bb
@@ -0,0 +1,45 @@
1MAJOR_VERSION = "2.21"
2PR = "r0"
3require util-linux.inc
4
5# note that `lscpu' is under GPLv3+
6LICENSE_${PN}-lscpu = "GPLv3+"
7
8SRC_URI += "file://util-linux-ng-replace-siginterrupt.patch \
9 file://util-linux-ng-2.16-mount_lock_path.patch \
10 file://uclibc-__progname-conflict.patch \
11"
12
13SRC_URI[md5sum] = "b75b3cfecb943f74338382fde693c2c3"
14SRC_URI[sha256sum] = "066f9d8e51bfabd809d266edcd54eefba1cdca57725b95c074fd47fe6fba3d30"
15
16# Only lscpu part is gplv3; rest of the code is not,
17# so take out the lscpu parts while running non-gplv3 build.
18# The removal of the package should now occur during
19# the build if INCOMPATIBLE_LICENSE is set to GPLv3
20
21python () {
22 d.setVar("REMOVELSCPU", "no")
23 if (d.getVar("INCOMPATIBLE_LICENSE", True) or "").find("GPLv3") != -1:
24 # avoid GPLv3
25 d.setVar("REMOVELSCPU", "yes")
26 src_uri = (d.getVar("SRC_URI", False) or "").split()
27 src_uri.append("file://remove-lscpu.patch")
28 d.setVar("SRC_URI", " ".join(src_uri))
29}
30
31do_remove_lscpu() {
32 if [ "x${REMOVELSCPU}" = "xyes" ]; then
33 rm -f sys-utils/lscpu.c sys-utils/lscpu.1
34 rm -rf tests/ts/lscpu tests/expected/lscpu
35 fi
36}
37
38addtask remove_lscpu before do_configure after do_patch
39
40CACHED_CONFIGUREVARS += "scanf_cv_alloc_modifier=as"
41EXTRA_OECONF_virtclass-native += "--disable-fallocate --disable-use-tty-group"
42
43do_install_append () {
44 sed -i -e '1s,.*,#!${bindir}/env perl,' ${D}${bindir}/chkdupexe
45}