LSX-blog

Feed Rss

【原创】打包内核为RPM包

05.31.2015, Linux, by .

下载内核包

1
https://www.kernel.org/pub/linux/kernel/v3.x/linux-3.16.7.tar.gz

安装依赖包

1
yum install gcc rpm-build redhat-rpm-config ncurses-devel patchutils bc xmlto asciidoc elfutils-libelf-devel zlib-devel binutils-devel newt-devel python-devel perl-ExtUtils-Embed hmaccalc kernel-firmware -y

解压内核压缩包

1
tar zxvf linux-3.16.7.tar.gz

复制本机内核配置到新内核目录

1
2
cd linux-3.16.7
cp /boot/config-2.6.32-504.8.1.el6.x86_64 .config

增加内核安装后默认启动

1
2
cd linux-3.16.7
vim scripts/package/mkspec

在%post最后面增加如下行

1
echo "/sbin/grubby --set-default 0"

在%post段后面添加%preun段

1
2
3
echo "%preun"
echo "new-kernel-pkg --rminitrd --rmmoddep --remove $KERNELRELEASE"
echo ""

简单设置config

1
make menuconfig

General setup —> Local version – append to kernel release
输入
.el6.x86_64
保存
创建RPM包
make rpm-pkg

等待完成
~/rpmbuild/RPMS/x86_64 即可看到。

【原创】打包内核为RPM包 有 3,041 条回应

  1. wod [url=https://freecasinoww.com/#]big fish casino[/url]

    回复
  2. oxb [url=https://onlinecasinoww.com/#]no deposit casino[/url] vxn [url=https://onlinecasinoww.com/#]free casino games[/url]
    nwn [url=https://onlinecasinoww.com/#]play online casino[/url]

    回复
  3. ekl [url=https://casinolucky.us.org/#]slots games free[/url]
    yvo [url=https://casinolucky.us.org/#]free slots online no download[/url]

    回复
  4. uqq [url=https://casinolucky.us.org/#]totally free casino games[/url]

    回复
  5. mtl [url=https://onlinecasinoww.com/#]casino online[/url] bmd [url=https://onlinecasinoww.com/#]casino slots[/url]
    bvb [url=https://onlinecasinoww.com/#]online casino[/url]

    回复
  6. cqk [url=https://buycbdoil40.com/#]cbd oil dosage[/url]
    lza [url=https://buycbdoil40.com/#]where to buy cbd oil[/url]

    回复
  7. avr [url=https://casino-games.us.org/#]caesars free slots online[/url]
    mln [url=https://casino-games.us.org/#]free blackjack vegas world[/url]

    回复
  8. ifm [url=https://onlinecasinoww.com/#]online casino games[/url] ior [url=https://onlinecasinoww.com/#]casino bonus codes[/url]

    回复
  9. jeb [url=https://onlinecasinoww.com/#]online casino games[/url]

    回复
  10. cfv [url=https://casinogameww.com/#]online casino games[/url]
    plo [url=https://casinogameww.com/#]free casino games online[/url]

    回复
  11. aww [url=https://buycbdoil40.com/#]zilis cbd oil[/url]
    zqt [url=https://buycbdoil40.com/#]cbd oil at walmart[/url]

    回复
  12. xvf [url=https://casino-game.us.org/#]best casino slot games[/url]

    回复
  13. umb [url=https://casinolucky.us.org/#]royal river casino[/url]

    回复
  14. jij [url=https://onlinecasinoww.com/#]best online casinos[/url]

    回复
  15. hox [url=https://onlinecasinoww.com/#]free casino[/url] jdd [url=https://onlinecasinoww.com/#]best online casinos[/url]

    回复
  16. pij [url=https://casino-game.us.org/#]online gambling[/url]
    bom [url=https://casino-game.us.org/#]vegas free slots online[/url]

    回复
  17. fhj [url=https://buycbdoil50.com/#]benefits of hemp oil[/url]
    lku [url=https://buycbdoil50.com/#]cbd hemp oil walmart[/url]

    回复
  18. vjb [url=https://buycbdoil40.com/#]what is cbd oil[/url]

    回复
  19. rjn [url=https://casinogameww.com/#]big fish casino[/url]

    回复
  20. xzl [url=https://casinolucky.us.org/#]all slots casino[/url]
    xka [url=https://casinolucky.us.org/#]casino bonus[/url]

    回复
  21. pau [url=https://buycbdoil50.com/#]buy cbd online[/url]
    mpr [url=https://buycbdoil50.com/#]cbd oil canada online[/url]

    回复
  22. vgs [url=https://casinolucky.us.org/#]free slot games online[/url]
    tju [url=https://casinolucky.us.org/#]zone online casino games[/url]

    回复
  23. vkd [url=https://casino-game.us.org/#]free casino slots with bonus[/url]

    回复
  24. yga [url=https://freecasinoww.com/#]casino games[/url] vzt [url=https://freecasinoww.com/#]free casino games online[/url]
    hcm [url=https://freecasinoww.com/#]casino real money[/url]

    回复
  25. xuv [url=https://casino-game.us.org/#]cafe casino online[/url]
    vfl [url=https://casino-game.us.org/#]las vegas free slots[/url]

    回复
  26. bqi [url=https://casino-games.us.org/#]world class casino slots[/url]

    回复
  27. cpt [url=https://casinolucky.us.org/#]free slots no registration no download[/url]

    回复
  28. jom [url=https://casino-games.us.org/#]atari vegas world free slots[/url]
    aht [url=https://casino-games.us.org/#]high 5 casino[/url]

    回复
  29. rlg [url=https://freecasinoww.com/#]casino game[/url]

    回复
  30. bzt [url=https://onlinecasinoww.com/#]free casino games online[/url]

    回复
  31. lke [url=https://buycbdoil50.com/#]green roads cbd oil[/url]

    回复
  32. jyp [url=https://freecasinoww.com/#]casino slots[/url] dwo [url=https://freecasinoww.com/#]casino slots[/url]
    pvv [url=https://freecasinoww.com/#]play online casino[/url]

    回复
  33. kfs [url=https://casino-games.us.org/#]vegas casino free slot games[/url]

    回复
  34. squ [url=https://freecasinoww.com/#]casino games[/url]

    回复
  35. njo [url=https://onlinecasinoww.com/#]online casino games[/url] ftq [url=https://onlinecasinoww.com/#]free casino[/url]
    cpi [url=https://onlinecasinoww.com/#]play online casino[/url]

    回复
  36. kuh [url=https://casinogameww.com/#]casino online slots[/url] vgd [url=https://casinogameww.com/#]online casino games[/url]
    ove [url=https://casinogameww.com/#]casino online[/url]

    回复
  37. aie [url=https://onlinecasinoww.com/#]best online casinos[/url] gwl [url=https://onlinecasinoww.com/#]casino games[/url]
    hia [url=https://onlinecasinoww.com/#]casino online[/url]

    回复
  38. xxe [url=https://casinogameww.com/#]online casinos[/url]

    回复
  39. ezf [url=https://casinolucky.us.org/#]scatter slots[/url]

    回复
  40. les [url=https://onlinecasinoww.com/#]casino real money[/url]

    回复
  41. hgj [url=https://casinolucky.us.org/#]las vegas free penny slots[/url]
    act [url=https://casinolucky.us.org/#]slot machines free games[/url]

    回复
  42. lxp [url=https://casino-game.us.org/#]goldfish slots[/url]

    回复
  43. whf [url=https://onlinecasinoww.com/#]casino game[/url] dhj [url=https://onlinecasinoww.com/#]casino slots[/url]

    回复
  44. umt [url=https://casino-games.us.org/#]vegas casino free slot games[/url]
    kug [url=https://casino-games.us.org/#]turning stone online slots[/url]

    回复
  45. zuo [url=https://casino-game.us.org/#]doubledown casino[/url]
    oar [url=https://casino-game.us.org/#]free online slots vegas world[/url]

    回复
  46. faa [url=https://casinolucky.us.org/#]100 best usa casinos with best codes[/url]
    vwf [url=https://casinolucky.us.org/#]play free blackjack against computer[/url]

    回复
  47. ebh [url=https://buycbdoil40.com/#]what is hemp oil good for[/url]
    lte [url=https://buycbdoil40.com/#]hemp oil vs cbd oil[/url]

    回复
  48. rue [url=https://onlinecasinoww.com/#]casino online[/url] gsm [url=https://onlinecasinoww.com/#]casino games[/url]

    回复
  49. juy [url=https://casinogameww.com/#]casino play[/url]
    rjy [url=https://casinogameww.com/#]online casino games[/url]

    回复
  50. gnb [url=https://buycbdoil40.com/#]cbd oil dosage[/url]
    zhe [url=https://buycbdoil40.com/#]pure cbd oil[/url]

    回复

发表评论

电子邮件地址不会被公开。 必填项已用*标注