Estimated build time: 0.5 SBU Estimated required disk space: 15 MB |
The Coreutils package contains a whole series of basic shell utilities.
Coreutils installs the following:
basename, cat, chgrp, chmod, chown, chroot, cksum, comm, cp, csplit, cut, date, dd, df, dir, dircolors, dirname, du, echo, env, expand, expr, factor, false, fmt, fold, groups, head, hostid, hostname, id, install, join, kill, link, ln, logname, ls, md5sum, mkdir, mkfifo, mknod, mv, nice, nl, nohup, od, paste, pathchk, pinky, pr, printenv, printf, ptx, pwd, readlink, rm, rmdir, seq, sha1sum, shred, sleep, sort, split, stat, stty, su, sum, sync, tac, tail, tee, test, touch, tr, true, tsort, tty, uname, unexpand, uniq, unlink, uptime, users, vdir, wc, who, whoami, yes
Not yet checked but probably something like this:
Bash: sh
Binutils: ar, as, ld, ranlib
Coreutils: basename, cat, chmod, chown, echo, expr, hostname,
install, ls, mv, rm, sleep, tr, uname
Diffutils: cmp
Gawk: gawk
GCC: cc, cc1, collect2, cpp0, gcc
Gettext: msgfmt, xgettext
Glibc: getconf
Grep: egrep, fgrep, grep
Make: make
Perl: perl
Sed: sed
Tar: tar
Texinfo: install-info, makeinfo
Normally the functionality of uname is somewhat broken, in that the -p switch always returns "unknown". The following patch fixes this behaviour for Intel architectures:
patch -Np1 -i ../coreutils-5.0-uname.patch |
We do not want Coreutils to install its version of the hostname program, because it is inferior to the version provided by Net-tools. Prevent its installation by applying a patch:
patch -Np1 -i ../coreutils-5.0-hostname-2.patch |
Now prepare Coreutils for compilation:
./configure --prefix=/usr |
Compile the package:
make |
This package has a testsuite available which can perform a number of checks to ensure it built correctly. Should you choose to run it, the following commands will do so:
make check-root make RUN_EXPENSIVE_TESTS=yes check |
Install the package:
make install |
And move some programs to their proper locations:
mv /usr/bin/{basename,cat,chgrp,chmod,chown,cp,dd,df} /bin mv /usr/bin/{dir,dircolors,du,date,echo,false,head} /bin mv /usr/bin/{install,ln,ls,mkdir,mkfifo,mknod,mv,pwd} /bin mv /usr/bin/{rm,rmdir,shred,sync,sleep,stty,su,test} /bin mv /usr/bin/{touch,true,uname,vdir} /bin mv /usr/bin/chroot /usr/sbin |
Finally, create a few necessary symlinks:
ln -s test /bin/[ ln -s ../../bin/install /usr/bin |