¶LFS系统构建03-安装基础系统软件
¶准备虚拟内核文件系统
1 | mkdir -pv $LFS/{dev,proc,sys,run} |
¶开始进入构建的lfs环境
1 | chroot "$LFS" /tools/bin/env -i \ |
¶创建主要目录
1 | mkdir -pv /{bin,boot,etc/{opt,sysconfig},home,lib/firmware,mnt,opt} |
¶创建重要文件和符号连接
1 | ln -sv /tools/bin/{bash,cat,chmod,dd,echo,ln,mkdir,pwd,rm,stty,touch} /bin |
¶linux api 头文件
1 | cd $LFS/sources/ |
¶man-pages
1 | tar xvf man-pages-4.16.tar.xz |
¶glibc
1 | cd $LFS/sources/ |
¶gawk
1 | tar xvf gawk-4.2.1.tar.xz |
¶适应工具链
1 | mv -v /tools/bin/{ld,ld-old} |
¶zlib
1 | tar xvf zlib-1.2.11.tar.xz |
¶file
1 | cd $LFS/sources |
¶readline
1 | cd $LFS/sources |
¶m4
1 | cd $LFS/sources |
¶bc
1 | cd $LFS/sources |
¶texinfo
1 | sed -i '5481,5485 s/({/(\\{/' tp/Texinfo/Parser.pm |
¶binutils
1 | tar xvf binutils-2.32.tar.xz |
¶gmp
1 | cd $LFS/sources |
¶mpfr
1 | cd $LFS/sources |
¶mpc
1 | cd $LFS/sources |
¶shadow
1 | cd $LFS/sources |
¶gcc(第三次安装)
1 | cd $LFS/sources |
¶bzip
1 | cd $LFS/sources |
¶pkg-config
1 | cd $LFS/sources |
¶ncurses
1 | cd $LFS/sources |
¶attr
1 | cd $LFS/sources |
¶acl
1 | cd $LFS/sources |
¶libcap
1 | cd $LFS/sources |
¶sed
1 | cd $LFS/sources |
¶psmisc
1 | cd $LFS/sources |
¶lana-etc
1 | cd $LFS/sources |
¶bison
1 | cd $LFS/sources |
¶flex
1 | cd $LFS/sources |
¶grep
1 | cd $LFS/sources |
¶bash
1 | cd $LFS/sources |
¶libtool
1 | cd $LFS/sources |
¶gdbm
1 | cd $LFS/sources |
¶gperf
1 | cd $LFS/sources |
¶expat
1 | cd $LFS/sources |
¶inetutils
1 | cd $LFS/sources |
¶perl
1 | cd $LFS/sources |
¶XML-Parser
1 | cd $LFS/sources |
¶intltool
1 | cd $LFS/sources |
¶autoconf
1 | cd $LFS/sources |
¶automake
1 | cd $LFS/sources |
¶xz
1 | cd $LFS/sources |
¶kmod
1 | cd $LFS/sources |
¶gettext
1 | cd $LFS/sources |
¶elfutils
1 | cd $LFS/sources |
¶libffi
1 | cd $LFS/sources |
¶openssl
1 | cd $LFS/sources |
¶Python
1 | cd $LFS/sources |
¶ninja
1 | cd $LFS/sources |
¶meson
1 | cd $LFS/sources |
¶coreutils
1 | cd $LFS/sources |
¶check
1 | cd $LFS/sources |
¶diffutils
1 | cd $LFS/sources |
¶gawk
1 | cd $LFS/sources |
¶findutils
1 | cd $LFS/sources |
¶groff
1 | cd $LFS/sources |
¶grub
1 | cd $LFS/sources |
¶less
1 | cd $LFS/sources |
¶gzip
1 | cd $LFS/sources |
¶iproute
1 | cd $LFS/sources |
¶kbd
1 | cd $LFS/sources |
¶libpipeline
1 | cd $LFS/sources |
¶make
1 | cd $LFS/sources |
¶man-db
1 | cd $LFS/sources |
¶patch
1 | cd $LFS/sources |
¶tar
1 | cd $LFS/sources |
¶vim
1 | cd $LFS/sources |
¶procps
1 | cd $LFS/sources |
¶utils-linux
1 | cd $LFS/sources |
¶e2fsprogs
1 | cd $LFS/sources |
¶sysklogd
1 | cd $LFS/sources |
¶sysvinit
1 | cd $LFS/sources |
¶eudev
1 | cd $LFS/sources |
¶再次剥离(可选)
1 | 在blfs中u用valgrind 或 gdb运行测试时需要这些调试信息 |
¶清理
1 | rm -rf /tmp/* |