diff options
author | Alexander Kanavin <alex.kanavin@gmail.com> | 2020-05-02 21:53:52 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2020-05-03 15:41:40 +0100 |
commit | f372ddb776265c7e8c6e134763f6d9fd81b5a756 (patch) | |
tree | 9242a20bc1166711b19b129ce5f188943ff0726b /meta/recipes-core/coreutils/coreutils_8.32.bb | |
parent | 97216d023f496c831898620bf953a21a3a9d42be (diff) | |
download | poky-f372ddb776265c7e8c6e134763f6d9fd81b5a756.tar.gz |
coreutils: update to 8.32
License-Update: copyright years, http changed to https
(From OE-Core rev: 6e1052d401da5a9fa7f535786d76e033a39bc30a)
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/coreutils/coreutils_8.32.bb')
-rw-r--r-- | meta/recipes-core/coreutils/coreutils_8.32.bb | 190 |
1 files changed, 190 insertions, 0 deletions
diff --git a/meta/recipes-core/coreutils/coreutils_8.32.bb b/meta/recipes-core/coreutils/coreutils_8.32.bb new file mode 100644 index 0000000000..2422f8634e --- /dev/null +++ b/meta/recipes-core/coreutils/coreutils_8.32.bb | |||
@@ -0,0 +1,190 @@ | |||
1 | SUMMARY = "The basic file, shell and text manipulation utilities" | ||
2 | DESCRIPTION = "The GNU Core Utilities provide the basic file, shell and text \ | ||
3 | manipulation utilities. These are the core utilities which are expected to exist on \ | ||
4 | every system." | ||
5 | HOMEPAGE = "http://www.gnu.org/software/coreutils/" | ||
6 | BUGTRACKER = "http://debbugs.gnu.org/coreutils" | ||
7 | LICENSE = "GPLv3+" | ||
8 | LIC_FILES_CHKSUM = "file://COPYING;md5=1ebbd3e34237af26da5dc08a4e440464 \ | ||
9 | file://src/ls.c;beginline=1;endline=15;md5=b7d80abf5b279320fb0e4b1007ed108b \ | ||
10 | " | ||
11 | DEPENDS = "gmp libcap" | ||
12 | DEPENDS_class-native = "" | ||
13 | |||
14 | inherit autotools gettext texinfo | ||
15 | |||
16 | SRC_URI = "${GNU_MIRROR}/coreutils/${BP}.tar.xz \ | ||
17 | file://remove-usr-local-lib-from-m4.patch \ | ||
18 | file://fix-selinux-flask.patch \ | ||
19 | file://0001-uname-report-processor-and-hardware-correctly.patch \ | ||
20 | file://disable-ls-output-quoting.patch \ | ||
21 | file://0001-local.mk-fix-cross-compiling-problem.patch \ | ||
22 | file://run-ptest \ | ||
23 | file://0001-ls-restore-8.31-behavior-on-removed-directories.patch \ | ||
24 | " | ||
25 | |||
26 | SRC_URI[md5sum] = "022042695b7d5bcf1a93559a9735e668" | ||
27 | SRC_URI[sha256sum] = "4458d8de7849df44ccab15e16b1548b285224dbba5f08fac070c1c0e0bcc4cfa" | ||
28 | |||
29 | EXTRA_OECONF_class-native = "--without-gmp" | ||
30 | EXTRA_OECONF_class-target = "--enable-install-program=arch,hostname --libexecdir=${libdir}" | ||
31 | EXTRA_OECONF_class-nativesdk = "--enable-install-program=arch,hostname" | ||
32 | |||
33 | # acl and xattr are not default features | ||
34 | # | ||
35 | PACKAGECONFIG_class-target ??= "\ | ||
36 | ${@bb.utils.filter('DISTRO_FEATURES', 'acl xattr', d)} \ | ||
37 | " | ||
38 | |||
39 | # The lib/oe/path.py requires xattr | ||
40 | PACKAGECONFIG_class-native ??= "xattr" | ||
41 | |||
42 | # with, without, depends, rdepends | ||
43 | # | ||
44 | PACKAGECONFIG[acl] = "--enable-acl,--disable-acl,acl," | ||
45 | PACKAGECONFIG[xattr] = "--enable-xattr,--disable-xattr,attr," | ||
46 | PACKAGECONFIG[single-binary] = "--enable-single-binary,--disable-single-binary,," | ||
47 | |||
48 | # [ df mktemp nice printenv base64 gets a special treatment and is not included in this | ||
49 | bindir_progs = "arch basename chcon cksum comm csplit cut dir dircolors dirname du \ | ||
50 | env expand expr factor fmt fold groups head hostid id install \ | ||
51 | join link logname md5sum mkfifo nl nohup nproc od paste pathchk \ | ||
52 | pinky pr printf ptx readlink realpath runcon seq sha1sum sha224sum sha256sum \ | ||
53 | sha384sum sha512sum shred shuf sort split sum tac tail tee test timeout \ | ||
54 | tr truncate tsort tty unexpand uniq unlink uptime users vdir wc who whoami yes" | ||
55 | |||
56 | # hostname gets a special treatment and is not included in this | ||
57 | base_bindir_progs = "cat chgrp chmod chown cp date dd echo false hostname kill ln ls mkdir \ | ||
58 | mknod mv pwd rm rmdir sleep stty sync touch true uname stat" | ||
59 | |||
60 | sbindir_progs= "chroot" | ||
61 | |||
62 | PACKAGE_BEFORE_PN_class-target += "coreutils-stdbuf" | ||
63 | FILES_coreutils-stdbuf = "${bindir}/stdbuf ${libdir}/coreutils/libstdbuf.so" | ||
64 | RDEPENDS_coreutils_class-target += "coreutils-stdbuf" | ||
65 | |||
66 | # Let aclocal use the relative path for the m4 file rather than the | ||
67 | # absolute since coreutils has a lot of m4 files, otherwise there might | ||
68 | # be an "Argument list too long" error when it is built in a long/deep | ||
69 | # directory. | ||
70 | acpaths = "-I ./m4" | ||
71 | |||
72 | # Deal with a separate builddir failure if src doesn't exist when creating version.c/version.h | ||
73 | do_compile_prepend () { | ||
74 | mkdir -p ${B}/src | ||
75 | } | ||
76 | |||
77 | do_install_class-native() { | ||
78 | autotools_do_install | ||
79 | # remove groups to fix conflict with shadow-native | ||
80 | rm -f ${D}${STAGING_BINDIR_NATIVE}/groups | ||
81 | # The return is a must since native doesn't need the | ||
82 | # do_install_append() in the below. | ||
83 | return | ||
84 | } | ||
85 | |||
86 | do_install_append() { | ||
87 | for i in df mktemp nice printenv base64; do mv ${D}${bindir}/$i ${D}${bindir}/$i.${BPN}; done | ||
88 | |||
89 | install -d ${D}${base_bindir} | ||
90 | [ "${base_bindir}" != "${bindir}" ] && for i in ${base_bindir_progs}; do mv ${D}${bindir}/$i ${D}${base_bindir}/$i.${BPN}; done | ||
91 | |||
92 | install -d ${D}${sbindir} | ||
93 | [ "${sbindir}" != "${bindir}" ] && for i in ${sbindir_progs}; do mv ${D}${bindir}/$i ${D}${sbindir}/$i.${BPN}; done | ||
94 | |||
95 | # [ requires special handling because [.coreutils will cause the sed stuff | ||
96 | # in update-alternatives to fail, therefore use lbracket - the name used | ||
97 | # for the actual source file. | ||
98 | mv ${D}${bindir}/[ ${D}${bindir}/lbracket.${BPN} | ||
99 | } | ||
100 | |||
101 | inherit update-alternatives | ||
102 | |||
103 | ALTERNATIVE_PRIORITY = "100" | ||
104 | # Make hostname's priority higher than busybox but lower than net-tools | ||
105 | ALTERNATIVE_PRIORITY[hostname] = "90" | ||
106 | ALTERNATIVE_${PN} = "lbracket ${bindir_progs} ${base_bindir_progs} ${sbindir_progs} base64 nice printenv mktemp df" | ||
107 | ALTERNATIVE_${PN}-doc = "base64.1 nice.1 mktemp.1 df.1 groups.1 kill.1 uptime.1 stat.1 hostname.1" | ||
108 | |||
109 | ALTERNATIVE_LINK_NAME[hostname.1] = "${mandir}/man1/hostname.1" | ||
110 | |||
111 | ALTERNATIVE_LINK_NAME[base64] = "${base_bindir}/base64" | ||
112 | ALTERNATIVE_TARGET[base64] = "${bindir}/base64.${BPN}" | ||
113 | ALTERNATIVE_LINK_NAME[base64.1] = "${mandir}/man1/base64.1" | ||
114 | |||
115 | ALTERNATIVE_LINK_NAME[mktemp] = "${base_bindir}/mktemp" | ||
116 | ALTERNATIVE_TARGET[mktemp] = "${bindir}/mktemp.${BPN}" | ||
117 | ALTERNATIVE_LINK_NAME[mktemp.1] = "${mandir}/man1/mktemp.1" | ||
118 | |||
119 | ALTERNATIVE_LINK_NAME[df] = "${base_bindir}/df" | ||
120 | ALTERNATIVE_TARGET[df] = "${bindir}/df.${BPN}" | ||
121 | ALTERNATIVE_LINK_NAME[df.1] = "${mandir}/man1/df.1" | ||
122 | |||
123 | ALTERNATIVE_LINK_NAME[nice] = "${base_bindir}/nice" | ||
124 | ALTERNATIVE_TARGET[nice] = "${bindir}/nice.${BPN}" | ||
125 | ALTERNATIVE_LINK_NAME[nice.1] = "${mandir}/man1/nice.1" | ||
126 | |||
127 | ALTERNATIVE_LINK_NAME[printenv] = "${base_bindir}/printenv" | ||
128 | ALTERNATIVE_TARGET[printenv] = "${bindir}/printenv.${BPN}" | ||
129 | |||
130 | ALTERNATIVE_LINK_NAME[lbracket] = "${bindir}/[" | ||
131 | ALTERNATIVE_TARGET[lbracket] = "${bindir}/lbracket.${BPN}" | ||
132 | |||
133 | ALTERNATIVE_LINK_NAME[groups.1] = "${mandir}/man1/groups.1" | ||
134 | ALTERNATIVE_LINK_NAME[uptime.1] = "${mandir}/man1/uptime.1" | ||
135 | ALTERNATIVE_LINK_NAME[kill.1] = "${mandir}/man1/kill.1" | ||
136 | ALTERNATIVE_LINK_NAME[stat.1] = "${mandir}/man1/stat.1" | ||
137 | |||
138 | python __anonymous() { | ||
139 | for prog in d.getVar('base_bindir_progs').split(): | ||
140 | d.setVarFlag('ALTERNATIVE_LINK_NAME', prog, '%s/%s' % (d.getVar('base_bindir'), prog)) | ||
141 | |||
142 | for prog in d.getVar('sbindir_progs').split(): | ||
143 | d.setVarFlag('ALTERNATIVE_LINK_NAME', prog, '%s/%s' % (d.getVar('sbindir'), prog)) | ||
144 | } | ||
145 | |||
146 | BBCLASSEXTEND = "native nativesdk" | ||
147 | |||
148 | inherit ptest | ||
149 | |||
150 | RDEPENDS_${PN}-ptest += "bash findutils gawk liberror-perl libmodule-build-perl make perl perl-module-file-stat python3-core sed shadow" | ||
151 | |||
152 | # -dev automatic dependencies fails as we don't want libmodule-build-perl-dev, its too heavy | ||
153 | # may need tweaking if DEPENDS changes | ||
154 | RRECOMMENDS_coreutils-dev[nodeprrecs] = "1" | ||
155 | RRECOMMENDS_coreutils-dev = "acl-dev attr-dev gmp-dev libcap-dev bash-dev findutils-dev gawk-dev shadow-dev" | ||
156 | |||
157 | do_install_ptest () { | ||
158 | install -d ${D}${PTEST_PATH}/tests | ||
159 | cp -r ${S}/tests/* ${D}${PTEST_PATH}/tests | ||
160 | sed -i 's/ginstall/install/g' `grep -R ginstall ${D}${PTEST_PATH}/tests | awk -F: '{print $1}' | uniq` | ||
161 | install -d ${D}${PTEST_PATH}/build-aux | ||
162 | install ${S}/build-aux/test-driver ${D}${PTEST_PATH}/build-aux/ | ||
163 | cp ${B}/Makefile ${D}${PTEST_PATH}/ | ||
164 | cp ${S}/init.cfg ${D}${PTEST_PATH}/ | ||
165 | cp -r ${B}/src ${D}${PTEST_PATH}/ | ||
166 | cp -r ${S}/src/*.c ${D}${PTEST_PATH}/src | ||
167 | sed -i '/^VPATH/s/= .*$/= ./g' ${D}${PTEST_PATH}/Makefile | ||
168 | sed -i '/^PROGRAMS/s/^/#/g' ${D}${PTEST_PATH}/Makefile | ||
169 | sed -i '/^Makefile: /s/^.*$/Makefile:/g' ${D}${PTEST_PATH}/Makefile | ||
170 | sed -i '/^abs_srcdir/s/= .*$/= \$\{PWD\}/g' ${D}${PTEST_PATH}/Makefile | ||
171 | sed -i '/^abs_top_builddir/s/= .*$/= \$\{PWD\}/g' ${D}${PTEST_PATH}/Makefile | ||
172 | sed -i '/^abs_top_srcdir/s/= .*$/= \$\{PWD\}/g' ${D}${PTEST_PATH}/Makefile | ||
173 | sed -i '/^built_programs/s/ginstall/install/g' ${D}${PTEST_PATH}/Makefile | ||
174 | chmod -R 777 ${D}${PTEST_PATH} | ||
175 | |||
176 | # Disable subcase stty-pairs.sh, it will cause test framework hang | ||
177 | sed -i '/stty-pairs.sh/d' ${D}${PTEST_PATH}/Makefile | ||
178 | |||
179 | # Disable subcase tail-2/assert.sh as it has issues on 32-bit systems | ||
180 | sed -i '/assert.sh/d' ${D}${PTEST_PATH}/Makefile | ||
181 | |||
182 | # Tweak test d_type-check to use python3 instead of python | ||
183 | sed -i "1s@.*@#!/usr/bin/python3@" ${D}${PTEST_PATH}/tests/d_type-check | ||
184 | install ${B}/src/getlimits ${D}/${bindir} | ||
185 | |||
186 | # handle multilib | ||
187 | sed -i s:@libdir@:${libdir}:g ${D}${PTEST_PATH}/run-ptest | ||
188 | } | ||
189 | |||
190 | FILES_${PN}-ptest += "${bindir}/getlimits" | ||