LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 1515|回复: 4

Debian 2.6.15 内核 安装bootsplash

[复制链接]
发表于 2006-7-17 21:35:23 | 显示全部楼层 |阅读模式
1.安装内核编译环境:   
关心一下有关 kernel-package、gcc、binutils 和 modutils 的错误报告。在需要时使用较新的版本。
在 Debian 系统中用源码编译自定义内核要特别小心。用 make-kpkg 的 --append_to_version 选项来创建多重内核镜像比较安全。

# apt-get install debhelper modutils kernel-package libncurses5-dev

2.编译内核。
下载内核及其bootsplash内核补丁:
内核源代码包:http://www.kernel.org/pub/linux/kernel/v2.6/
bootsplash补丁下载地址:http://www.bootsplash.de
下载合适的内核补丁: 2.6.15内核下载bootsplash-3.1.6-2.6.15.diff  (2.6.17内核也可使用此补丁)

3.解开内核源码包,进入源码包目录,加上补丁。

#cd linux-2.6.15
#patch -p1 -i /tmp/bootsplash-3.1.6-2.6.15.diff (假定 bootsplash 的补丁放了在 /tmp 之中)


4.打补丁成功,内核设定文件(.config)

#cp /boot/config-2.6.15 .config
#make old config
#make menu config

Device Drivers ---> Block devices --->
<*> RAM disk support
  • Initial RAM disk (initrd) support

    Device Drivers ---> Graphics support --->
    <*> Support for frame buffer devices
  • VESA VGA graphics support

    Device Drivers ---> Graphics support ---> Console display driver support --->
    --- VGA text console
  • Video mode selection support
    <*> Framebuffer Console support

    Device Drivers ---> Graphics support ---> Bootsplash configuration --->
  • Bootup splash screen

    5.编译内核,并且打包

    #make-kpkg --revision 20060717 --initrd binary

    上层目录生5个 .deb文件
    linux-doc-2.6.15_20060616_all.deb
    linux-headers-2.6.15_20060616_i386.deb
    linux-image-2.6.15_20060616_i386.deb
    linux-manual-2.6.15_20060616_all.deb
    linux-source-2.6.15_20060616_all.deb


    6.安装新内核

    dpkg -i linux-image-2.6.15_20060616_i386.deb

    这个内核已经有bootsplash支持了,不过还需要合适的 initrd.img。

    7.安装bootsplash

    #vim /etc/apt/source.lst 加入
    deb http://debian.bootsplash.de unstable main
    deb-src http://debian.bootsplash.de unstable main

    #apt-get update
    #apt-get install bootsplash
    #apt-get install bootsplash-theme-newlinux

    # apt-get install sysv-rc-bootsplash (安装进度条)
    Reading package lists... Done
    Building dependency tree... Done
    sysv-rc-bootsplash is already the newest version.
    0 upgraded, 1 newly installed, 0 to remove and 34 not upgraded.
    Need to get 6106B/6106B of archives
    After unpacking 0B of additional disk space will be used.
    Do you want to continue [Y/n]? y

    .....
    Testing if patches apply cleanly...
    4 out of 5 hunks FAILED -- saving rejects to file /etc/init.d/rcS.rej
    Patches would not apply cleanly.
    dpkg: Fehler beim Bearbeiten von sysv-rc-bootsplash (--configure):
    Subprocess post-installation script returned error code 1
    Fehler traten auf beim Bearbeiten von:
    sysv-rc-bootsplash
    E: Sub-process /usr/bin/dpkg returned an error code (1)


    安装sysv-rc-bootsplash 出错,解决方法:
    # cd /tmp/
    # mkdir patch
    # wget http://ftp.de.debian.org/debian/pool/main/...6.ds1-1_all.deb
    # dpkg --extract sysv-rc_2.86.ds1-1_all.deb /tmp/patch

    # cp /etc/init.d/rc /etc/init.d/rc.orig
    # cp /etc/init.d/rcS /etc/init.d/rcS.orig
    # cp /tmp/patch/etc/init.d/rc /etc/init.d/rc
    # cp /tmp/patch/etc/init.d/rcS /etc/init.d/rcS
    # apt-get install sysv-rc-bootsplash

    # dpkg-reconfigure bootsplash

    选择合适的主题。

    8.执行 mkinitrd 程序制作一个“清洁”的initrd.img

    mkinitrd -o /boot/initrd.img-2.6.15 2.6.15

    9.设定启动选项:

    debian:~# update-grub

    grub:
    debian:~# vim /boot/grub/menu.lst

    title           Debian GNU/Linux, kernel 2.6.15(silent)
    root            (hd0,1)
    kernel          /boot/vmlinuz-2.6.15 root=/dev/hdc2 ro vga=791 splash=silent
    initrd          /boot/initrd.img-2.6.15
    savedefault
    boot


    title           Debian GNU/Linux, kernel 2.6.15(bootsplash)
    root            (hd0,1)
    kernel          /boot/vmlinuz-2.6.15 root=/dev/hdc2 ro vga=791
    initrd          /boot/initrd.img-2.6.15
    savedefault
    boot

    vga=791 是1024*768分辨率  可根据dpkg-reconfigure bootsplash设置自行更改。

    Debian GNU/Linux, kernel 2.6.15 (silent) ,将进入带进度条动画的启动画面
    Debian GNU/Linux, kernel 2.6.15 (bootsplash),将进入是背景加启动文字的启动画面了。


    lilo: (未测试)
    image=/boot/bzImage-2.6.15
    label=2.6.15
    read-only
    initrd=/boot/initrd.splash
    append="splash=silent"
    vga=791


    官方网站信息:
    Now Available for Linux Kernel 2.6.15!
    There's a Bootsplash Mailinglist now. Go to the subscription page to join the discussion, get help or just for the latest news.
    Verbose Mode - boot messages are shown, as normal.

    Silent Mode - boot messages are hidden and, in this example, a gradient filled progress bar is shown as well as TrueType text. Pressing F2 changes to Verbose mode.
  • 发表于 2006-7-17 21:50:31 | 显示全部楼层
    太累了
    bootlplash 最难伺候
    回复 支持 反对

    使用道具 举报

    发表于 2006-7-17 22:14:32 | 显示全部楼层
    写的很详细,顶一下。
    上次就在 sysv-rc 这里卡住,觉得要改文件,不放心就放弃了。

    现在编译最新内核太勤,装 bootsplash是有点累人,以后再试吧!还有 bootsplash 更新慢了点,感觉。
    回复 支持 反对

    使用道具 举报

    发表于 2006-7-17 22:19:49 | 显示全部楼层
    我宽屏分辨率是1280X800 vga=? vga设置多少?
    回复 支持 反对

    使用道具 举报

     楼主| 发表于 2006-7-17 23:25:06 | 显示全部楼层
    vga=? 具体可参考
    http://cha.homeip.net/blog/archives/2006/06/_bootsplash_lin.html
    另外可参考
    http://www.coolcode.cn/?p=63

    你的vga=791 应该可以 dpkg-reconfigure bootsplash 中要选上1024×768
    回复 支持 反对

    使用道具 举报

    您需要登录后才可以回帖 登录 | 注册

    本版积分规则

    快速回复 返回顶部 返回列表