一个奇怪的问题--关于声卡独占
删除Alt+F2运行的历史命令

一步一步打造自己的Linux--LFS6.3安装过程(七)

獨立的圓 posted @ 2008年3月19日 01:54 in Linux with tags LFS , 7578 阅读

 本站文章已轉移,敬請移步:http://www.xxb.me/ ,謝謝!

Bzip2-1.0.4
Diffutils-2.8.1
File-4.21
Findutils-4.2.31
Flex-2.5.33
GRUB-0.97
Gawk-3.1.5
Gettext-0.16.1
Grep-2.5.1a
Groff-1.18.1.4
Gzip-1.3.12
Inetutils-1.5
IPRoute2-2.6.20-070313
Kbd-1.12
Less-406
Make-3.81
Man-DB-2.4.4

Bzip2   (5分钟)

  1. $ tar xvf $LFS/bzip2-1.0.4.tar.gz
  2. $ cd bzip2-1.0.4
  3. $ patch -Np1 -i $LFS/bzip2-1.0.4-install_docs-1.patch
  4. $ make -f Makefile-libbz2_so
  5. $ make clean
  6. $ make
  7. $ make PREFIX=/usr install
  8. $ cp -v bzip2-shared /bin/bzip2
  9. $ cp -av libbz2.so* /lib
  10. $ ln -sv ../../lib/libbz2.so.1.0 /usr/lib/libbz2.so
  11. $ rm -v /usr/bin/{bunzip2,bzcat,bzip2}
  12. $ ln -sv bzip2 /bin/bunzip2
  13. $ ln -sv bzip2 /bin/bzcat
  14. $ cd ..
  15. $ rm -rf bzip2-1.0.4

Diffutils   (5分钟)

  1. $ tar xvf $LFS/diffutils-2.8.1.tar.gz
  2. $ cd diffutils-2.8.1
  3. $ patch -Np1 -i $LFS/diffutils-2.8.1-i18n-1.patch
  4. $ touch man/diff.1
  5. $ ./configure --prefix=/usr
  6. $ make
  7. $ make install
  8. $ cd ..
  9. $ rm -rf diffutils-2.8.1

File   (5分钟)

  1. $ tar xvf $LFS/file-4.21.tar.gz
  2. $ cd file-4.21
  3. $ ./configure --prefix=/usr
  4. $ make
  5. $ make install
  6. $ cd ..
  7. $ rm -rf file-4.21

Findutils   (5分钟)

  1. $ tar xvf $LFS/findutils-4.2.31.tar.gz
  2. $ cd findutils-4.2.31
  3. $ ./configure --prefix=/usr --libexecdir=/usr/lib/findutils \
        --localstatedir=/var/lib/locate
  4. $ make
  5. $ make install
  6. $ mv -v /usr/bin/find /bin
  7. $ sed -i -e 's/find:=${BINDIR}/find:=\/bin/' /usr/bin/updatedb
  8. $ cd ..
  9. $ rm -rf findutils-4.2.31

Flex   (5分钟)

  1. $ tar xvf $LFS/flex-2.5.33.tar.bz2
  2. $ cd flex-2.5.33
  3. $ ./configure --prefix=/usr
  4. $ make
  5. $ make install
  6. $ ln -sv libfl.a /usr/lib/libl.a
  7. $ cat > /usr/bin/lex << "EOF"
    #!/bin/sh
    # Begin /usr/bin/lex

    exec /usr/bin/flex -l "$@"

    # End /usr/bin/lex
    EOF
  8. $ chmod -v 755 /usr/bin/lex
  9. $ cd ..
  10. $ rm -rf flex-2.5.33

GRUB   (5分钟)

  1. $ tar xvf $LFS/grub-0.97.tar.gz
  2. $ cd grub-0.97
  3. $ patch -Np1 -i $LFS/grub-0.97-disk_geometry-1.patch
  4. $ ./configure --prefix=/usr
  5. $ make
  6. $ make install
  7. $ mkdir -v /boot/grub
  8. $ cp -v /usr/lib/grub/i386-pc/stage{1,2} /boot/grub
  9. $ cd ..
  10. $ rm -rf grub-0.97

Gawk   (5分钟)

  1. $ tar xvf $LFS/gawk-3.1.5.tar.bz2
  2. $ cd gawk-3.1.5
  3. $ patch -Np1 -i $LFS/gawk-3.1.5-segfault_fix-1.patch
  4. $ ./configure --prefix=/usr --libexecdir=/usr/lib
  5. $ cat >> config.h << "EOF"
  6. #define HAVE_LANGINFO_CODESET 1
  7. #define HAVE_LC_MESSAGES 1
  8. EOF
  9. $ make
  10. $ make install
  11. $ cd ..
  12. $ rm -rf gawk-3.1.5

Gettext   (10分钟)

  1. $ tar xvf $LFS/gettext-0.16.1.tar.gz
  2. $ cd gettext-0.16.1
  3. $ ./configure --prefix=/usr
  4. $ make
  5. $ make install
  6. $ cd ..
  7. $ rm -rf gettext-0.16.1

Grep   (5分钟)

  1. $ tar xvf $LFS/grep-2.5.1a.tar.bz2
  2. $ cd grep-2.5.1a
  3. $ patch -Np1 -i $LFS/grep-2.5.1a-redhat_fixes-2.patch
  4. $ chmod +x tests/fmbtest.sh
  5. $ ./configure --prefix=/usr --bindir=/bin
  6. $ make
  7. $ make install
  8. $ cd ..
  9. $ rm -rf grep-2.5.1a

Groff   (5分钟)

  1. $ tar xvf $LFS/groff-1.18.1.4.tar.gz
  2. $ cd groff-1.18.1.4
  3. $ patch -Np1 -i $LFS/groff-1.18.1.4-debian_fixes-1.patch
  4. $ sed -i -e 's/2010/002D/' -e 's/2212/002D/' \
        -e 's/2018/0060/' -e 's/2019/0027/' font/devutf8/R.proto
  5. $ PAGE=A4 ./configure --prefix=/usr --enable-multibyte
  6. $ make
  7. $ make install
  8. $ ln -sv eqn /usr/bin/geqn
  9. $ ln -sv tbl /usr/bin/gtbl
  10. $ cd ..
  11. $ rm -rf groff-1.18.1.4

Gzip   (5分钟)

  1. $ tar xvf $LFS/gzip-1.3.12.tar.gz
  2. $ cd gzip-1.3.12
  3. $ ./configure --prefix=/usr --bindir=/bin
  4. $ make
  5. $ make install
  6. $ mv -v /bin/{gzexe,uncompress,zcmp,zdiff,zegrep} /usr/bin
  7. $ mv -v /bin/{zfgrep,zforce,zgrep,zless,zmore,znew} /usr/bin
  8. $ cd ..
  9. $ rm -rf gzip-1.3.12

Inetutils   (5分钟)

  1. $ tar xvf $LFS/inetutils-1.5.tar.gz
  2. $ cd inetutils-1.5
  3. $ patch -Np1 -i $LFS/inetutils-1.5-no_server_man_pages-2.patch
  4. $ ./configure --prefix=/usr --libexecdir=/usr/sbin \
        --sysconfdir=/etc --localstatedir=/var \
        --disable-ifconfig --disable-logger --disable-syslogd \
        --disable-whois --disable-servers
  5. $ make
  6. $ make install
  7. $ mv -v /usr/bin/ping /bin
  8. $ cd ..
  9. $ rm -rf inetutils-1.5

IPRoute2   (5分钟)

  1. $ tar xvf $LFS/iproute2-2.6.20-070313.tar.gz
  2. $ cd iproute-2.6.20-070313
  3. $ sed -i -e '/tc-bfifo.8/d' -e '/tc-pfifo.8/s/pbfifo/bfifo/' Makefile
  4. $ make SBINDIR=/sbin
  5. $ make SBINDIR=/sbin install
  6. $ mv -v /sbin/arpd /usr/sbin
  7. $ cd ..
  8. $ rm -rf iproute-2.6.20-070313

Kbd   (5分钟)

  1. $ tar xvf $LFS/kbd-1.12.tar.bz2
  2. $ cd kbd-1.12
  3. $ patch -Np1 -i $LFS/kbd-1.12-backspace-1.patch
  4. $ patch -Np1 -i $LFS/kbd-1.12-gcc4_fixes-1.patch
  5. $ ./configure --datadir=/lib/kbd
  6. $ make
  7. $ make install
  8. $ mv -v /usr/bin/{kbd_mode,openvt,setfont} /bin
  9. $ cd ..
  10. $ rm -rf kbd-1.12

Less   (5分钟)

  1. $ tar xvf $LFS/less-406.tar.gz
  2. $ cd less-406
  3. $ ./configure --prefix=/usr --sysconfdir=/etc
  4. $ make
  5. $ make install
  6. $ cd ..
  7. $ rm -rf less-406

Make   (5分钟)

  1. $ tar xvf $LFS/make-3.81.tar.bz2
  2. $ cd make-3.81
  3. $ ./configure --prefix=/usr
  4. $ make
  5. $ make install
  6. $ cd ..
  7. $ rm -rf make-3.81

Man-DB   (5分钟)

  1. $ tar xvf $LFS/man-db-2.4.4.tar.gz
  2. $ cd man-db-2.4.4
  3. $ mv man/de{_DE.88591,}
  4. $ mv man/es{_ES.88591,}
  5. $ mv man/it{_IT.88591,}
  6. $ mv man/ja{_JP.eucJP,}
  7. $ sed -i 's,\*_\*,??,' man/Makefile.in
  8. $ sed -i -e '\%\t/usr/man%d' -e '\%\t/usr/local/man%d' src/man_db.conf.in
  9. $ cat >> include/manconfig.h.in << "EOF"
    #define WEB_BROWSER "exec /usr/bin/lynx"
    #define COL "/usr/bin/col"
    #define VGRIND "/usr/bin/vgrind"
    #define GRAP "/usr/bin/grap"
    EOF
  10. $ patch -Np1 -i ../man-db-2.4.4-fixes-1.patch
  11. $ ./configure --prefix=/usr --enable-mb-groff --disable-setuid
  12. $ make
  13. $ make install
  14. $ cat >> convert-mans << "EOF"
    #!/bin/sh -e
    FROM="$1"
    TO="$2"
    shift ; shift
    while [ $# -gt 0 ]
    do
            FILE="$1"
            shift
            iconv -f "$FROM" -t "$TO" "$FILE" >.tmp.iconv
            mv .tmp.iconv "$FILE"
    done
    EOF
  15. $ install -m755 convert-mans  /usr/bin
  16. $ cd ..
  17. $ rm -rf man-db-2.4.4

登录 *


loading captcha image...
(输入验证码)
or Ctrl+Enter