mirror of
https://github.com/mattwind/alfs.git
synced 2025-07-28 06:39:15 +00:00
39 lines
1.1 KiB
Bash
Executable File
39 lines
1.1 KiB
Bash
Executable File
#!/bin/bash
|
|
|
|
if [ "$(whoami)" != "lfs" ]; then
|
|
echo "Script must be run as user: lfs"
|
|
exit 255
|
|
fi
|
|
|
|
cd $LFS/sources
|
|
|
|
tar xvf coreutils-8.32.tar.xz
|
|
|
|
cd coreutils-8.32
|
|
|
|
./configure --prefix=/usr \
|
|
--host=$LFS_TGT \
|
|
--build=$(build-aux/config.guess) \
|
|
--enable-install-program=hostname \
|
|
--enable-no-install-program=kill,uptime
|
|
|
|
make
|
|
|
|
make DESTDIR=$LFS install
|
|
|
|
mv -v $LFS/usr/bin/{cat,chgrp,chmod,chown,cp,date,dd,df,echo} $LFS/bin
|
|
mv -v $LFS/usr/bin/{false,ln,ls,mkdir,mknod,mv,pwd,rm} $LFS/bin
|
|
mv -v $LFS/usr/bin/{rmdir,stty,sync,true,uname} $LFS/bin
|
|
mv -v $LFS/usr/bin/{head,nice,sleep,touch} $LFS/bin
|
|
mv -v $LFS/usr/bin/chroot $LFS/usr/sbin
|
|
mkdir -pv $LFS/usr/share/man/man8
|
|
mv -v $LFS/usr/share/man/man1/chroot.1 $LFS/usr/share/man/man8/chroot.8
|
|
sed -i 's/"1"/"8"/' $LFS/usr/share/man/man8/chroot.8
|
|
|
|
cd $LFS/sources
|
|
|
|
rm -rf coreutils-8.32
|
|
|
|
echo "Done"
|
|
|