diff options
Diffstat (limited to 'meta/recipes-core/coreutils/coreutils_8.29.bb')
-rw-r--r-- | meta/recipes-core/coreutils/coreutils_8.29.bb | 131 |
1 files changed, 131 insertions, 0 deletions
diff --git a/meta/recipes-core/coreutils/coreutils_8.29.bb b/meta/recipes-core/coreutils/coreutils_8.29.bb new file mode 100644 index 0000000000..8df88020e3 --- /dev/null +++ b/meta/recipes-core/coreutils/coreutils_8.29.bb | |||
@@ -0,0 +1,131 @@ | |||
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=d32239bcb673463ab874e80d47fae504\ | ||
9 | file://src/ls.c;beginline=1;endline=15;md5=1c3f9411e1842a062ce5ce9210beee0e" | ||
10 | DEPENDS = "gmp libcap" | ||
11 | DEPENDS_class-native = "" | ||
12 | |||
13 | inherit autotools gettext texinfo | ||
14 | |||
15 | SRC_URI = "${GNU_MIRROR}/coreutils/${BP}.tar.xz \ | ||
16 | file://remove-usr-local-lib-from-m4.patch \ | ||
17 | file://fix-selinux-flask.patch \ | ||
18 | file://0001-Unset-need_charset_alias-when-building-for-musl.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 | " | ||
23 | |||
24 | SRC_URI[md5sum] = "960cfe75a42c9907c71439f8eb436303" | ||
25 | SRC_URI[sha256sum] = "92d0fa1c311cacefa89853bdb53c62f4110cdfda3820346b59cbd098f40f955e" | ||
26 | |||
27 | EXTRA_OECONF_class-native = "--without-gmp" | ||
28 | EXTRA_OECONF_class-target = "--enable-install-program=arch,hostname --libexecdir=${libdir}" | ||
29 | EXTRA_OECONF_class-nativesdk = "--enable-install-program=arch" | ||
30 | |||
31 | # acl and xattr are not default features | ||
32 | # | ||
33 | PACKAGECONFIG_class-target ??= "\ | ||
34 | ${@bb.utils.filter('DISTRO_FEATURES', 'acl xattr', d)} \ | ||
35 | " | ||
36 | |||
37 | # The lib/oe/path.py requires xattr | ||
38 | PACKAGECONFIG_class-native ??= "xattr" | ||
39 | |||
40 | # with, without, depends, rdepends | ||
41 | # | ||
42 | PACKAGECONFIG[acl] = "--enable-acl,--disable-acl,acl," | ||
43 | PACKAGECONFIG[xattr] = "--enable-xattr,--disable-xattr,attr," | ||
44 | PACKAGECONFIG[single-binary] = "--enable-single-binary,--disable-single-binary,," | ||
45 | |||
46 | # [ df mktemp base64 gets a special treatment and is not included in this | ||
47 | bindir_progs = "arch basename chcon cksum comm csplit cut dir dircolors dirname du \ | ||
48 | env expand expr factor fmt fold groups head hostid id install \ | ||
49 | join link logname md5sum mkfifo nice nl nohup nproc od paste pathchk \ | ||
50 | pinky pr printenv printf ptx readlink realpath runcon seq sha1sum sha224sum sha256sum \ | ||
51 | sha384sum sha512sum shred shuf sort split stdbuf sum tac tail tee test timeout\ | ||
52 | tr truncate tsort tty unexpand uniq unlink uptime users vdir wc who whoami yes" | ||
53 | |||
54 | # hostname gets a special treatment and is not included in this | ||
55 | base_bindir_progs = "cat chgrp chmod chown cp date dd echo false kill ln ls mkdir \ | ||
56 | mknod mv pwd rm rmdir sleep stty sync touch true uname stat" | ||
57 | |||
58 | sbindir_progs= "chroot" | ||
59 | |||
60 | # Let aclocal use the relative path for the m4 file rather than the | ||
61 | # absolute since coreutils has a lot of m4 files, otherwise there might | ||
62 | # be an "Argument list too long" error when it is built in a long/deep | ||
63 | # directory. | ||
64 | acpaths = "-I ./m4" | ||
65 | |||
66 | # Deal with a separate builddir failure if src doesn't exist when creating version.c/version.h | ||
67 | do_compile_prepend () { | ||
68 | mkdir -p ${B}/src | ||
69 | } | ||
70 | |||
71 | do_install_class-native() { | ||
72 | autotools_do_install | ||
73 | # remove groups to fix conflict with shadow-native | ||
74 | rm -f ${D}${STAGING_BINDIR_NATIVE}/groups | ||
75 | # The return is a must since native doesn't need the | ||
76 | # do_install_append() in the below. | ||
77 | return | ||
78 | } | ||
79 | |||
80 | do_install_append() { | ||
81 | for i in df mktemp base64; do mv ${D}${bindir}/$i ${D}${bindir}/$i.${BPN}; done | ||
82 | |||
83 | install -d ${D}${base_bindir} | ||
84 | [ "${base_bindir}" != "${bindir}" ] && for i in ${base_bindir_progs}; do mv ${D}${bindir}/$i ${D}${base_bindir}/$i.${BPN}; done | ||
85 | |||
86 | install -d ${D}${sbindir} | ||
87 | [ "${sbindir}" != "${bindir}" ] && for i in ${sbindir_progs}; do mv ${D}${bindir}/$i ${D}${sbindir}/$i.${BPN}; done | ||
88 | |||
89 | # [ requires special handling because [.coreutils will cause the sed stuff | ||
90 | # in update-alternatives to fail, therefore use lbracket - the name used | ||
91 | # for the actual source file. | ||
92 | mv ${D}${bindir}/[ ${D}${bindir}/lbracket.${BPN} | ||
93 | } | ||
94 | |||
95 | inherit update-alternatives | ||
96 | |||
97 | ALTERNATIVE_PRIORITY = "100" | ||
98 | ALTERNATIVE_${PN} = "lbracket ${bindir_progs} ${base_bindir_progs} ${sbindir_progs} base64 mktemp df" | ||
99 | ALTERNATIVE_${PN}-doc = "base64.1 mktemp.1 df.1 groups.1 kill.1 uptime.1 stat.1 hostname.1" | ||
100 | |||
101 | ALTERNATIVE_LINK_NAME[hostname.1] = "${mandir}/man1/hostname.1" | ||
102 | |||
103 | ALTERNATIVE_LINK_NAME[base64] = "${base_bindir}/base64" | ||
104 | ALTERNATIVE_TARGET[base64] = "${bindir}/base64.${BPN}" | ||
105 | ALTERNATIVE_LINK_NAME[base64.1] = "${mandir}/man1/base64.1" | ||
106 | |||
107 | ALTERNATIVE_LINK_NAME[mktemp] = "${base_bindir}/mktemp" | ||
108 | ALTERNATIVE_TARGET[mktemp] = "${bindir}/mktemp.${BPN}" | ||
109 | ALTERNATIVE_LINK_NAME[mktemp.1] = "${mandir}/man1/mktemp.1" | ||
110 | |||
111 | ALTERNATIVE_LINK_NAME[df] = "${base_bindir}/df" | ||
112 | ALTERNATIVE_TARGET[df] = "${bindir}/df.${BPN}" | ||
113 | ALTERNATIVE_LINK_NAME[df.1] = "${mandir}/man1/df.1" | ||
114 | |||
115 | ALTERNATIVE_LINK_NAME[lbracket] = "${bindir}/[" | ||
116 | ALTERNATIVE_TARGET[lbracket] = "${bindir}/lbracket.${BPN}" | ||
117 | |||
118 | ALTERNATIVE_LINK_NAME[groups.1] = "${mandir}/man1/groups.1" | ||
119 | ALTERNATIVE_LINK_NAME[uptime.1] = "${mandir}/man1/uptime.1" | ||
120 | ALTERNATIVE_LINK_NAME[kill.1] = "${mandir}/man1/kill.1" | ||
121 | ALTERNATIVE_LINK_NAME[stat.1] = "${mandir}/man1/stat.1" | ||
122 | |||
123 | python __anonymous() { | ||
124 | for prog in d.getVar('base_bindir_progs').split(): | ||
125 | d.setVarFlag('ALTERNATIVE_LINK_NAME', prog, '%s/%s' % (d.getVar('base_bindir'), prog)) | ||
126 | |||
127 | for prog in d.getVar('sbindir_progs').split(): | ||
128 | d.setVarFlag('ALTERNATIVE_LINK_NAME', prog, '%s/%s' % (d.getVar('sbindir'), prog)) | ||
129 | } | ||
130 | |||
131 | BBCLASSEXTEND = "native nativesdk" | ||