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包 有 103,581 条回应

  1. Pretty! This was ann extremely wonderfyl article. Thank you for supplying this information.

    回复
  2. What’s Going down i am new to this, I stumbled upon this I have discovered It absolutely useful and it has helped me out loads.

    I’m hoping to give a contribution & help different users like its aided me.

    Great job.

    回复
  3. Hi there, I check your blogs daily. Your writing style is awesome, keep doing
    what you’re doing!

    回复
  4. Hello it’s me, I am also visiting this site daily, this site
    is genuinely good and the viewers are genuinely sharing pleasant thoughts.

    回复
  5. [url=https://robaxin24.com/]robaxin without rx[/url]

    回复
  6. fantastic submit, very informative. I ponder why the other experts of this
    sector do not understand this. You should proceed your writing.

    I’m sure, you’ve a great readers’ base already!

    回复
  7. An outstanding share! I’ve just forwarded this
    onto a colleague who had been conducting a little homework on this.
    And he actually bought me dinner because I stumbled upon it
    for him… lol. So let me reword this…. Thank YOU for the
    meal!! But yeah, thanx for spending time to discuss this matter here on your blog.

    回复
  8. Great beat ! I would like to apprentice even as you amend your website,
    how could i subscribe for a blog website? The account aided me
    a applicable deal. I were tiny bit familiar of
    this your broadcast provided vivid clear idea

    回复
  9. [url=https://chloroquineav.com/]where can i buy aralen[/url] [url=https://avodart24.com/]avodart soft capsules 0.5 mg[/url] [url=https://dapoxetine911.com/]dapoxetine medicine price in india[/url] [url=https://anafranilmed.com/]anafranil prices[/url] [url=https://ivermectin3.com/]ivermectin 200[/url] [url=https://robaxin24.com/]robaxin 500 mg tablet price[/url] [url=https://dipyridamol.com/]dipyridamole capsules[/url] [url=https://indocinrx.com/]medicine indocin 50 mg[/url] [url=https://lopressormetoprolol.com/]lopressor 12.5 mg[/url] [url=https://cleocing.com/]cleocin hcl 150 mg[/url] [url=https://cephalexin911.com/]cephalexin 50 mg capsules[/url] [url=https://fluoxetinetb.com/]fluoxetine tablets india[/url] [url=https://prednisolone911.com/]canadian prednisolone 5mg[/url] [url=https://viagrasoftab.com/]buy generic viagra soft tabs[/url] [url=https://vardenafilxr.com/]vardenafil 20mg canadian pharmacy[/url] [url=https://ampicillin24.com/]ampicillin 150mg[/url] [url=https://zithromax360.com/]buy zithromax without prescription online[/url] [url=https://ivaltrex.com/]buy generic valtrex online cheap[/url] [url=https://levitratab.com/]levitra daily use[/url] [url=https://prozacflx.com/]price of prozac in india[/url]

    回复
  10. [url=https://albendazoleotc.com/]is albenza over the counter[/url] [url=https://silagratab.com/]silagra 50 mg india[/url] [url=https://plavix.us.com/]medication plavix 75mg[/url] [url=https://prednisonesr.com/]prednisone 2 mg daily[/url] [url=https://ivermectin3.com/]stromectol cream[/url] [url=https://vardenafilxr.com/]vardenafil 5mg[/url] [url=https://sumycin365.com/]sumycin over the counter[/url] [url=https://stratterra.com/]strattera price south africa[/url] [url=https://accutanisotretinoin.com/]accutane online no rx[/url] [url=https://tetracyclinecaps.com/]tetracycline medicine price[/url] [url=https://finasteridealop.com/]minoxidil finasteride[/url] [url=https://indocinrx.com/]indocin 500mg[/url] [url=https://seroquel50.com/]seroquel sleep walking[/url] [url=https://ventolin24.com/]cost of ventolin[/url] [url=https://clonidinenorx.com/]clonidine 0.03mg[/url] [url=https://robaxin24.com/]robaxin 750 750 mg[/url] [url=https://tadalafillil.com/]generic tadalafil 20mg canada[/url] [url=https://lopressormetoprolol.com/]lopressor 100 mg price[/url] [url=https://inderal.us.com/]inderal 10 mg cost[/url] [url=https://dipyridamol.com/]dipyridamole brand name uk[/url]

    回复
  11. I visited multiple blogs however the audio feature for audio songs present at this website is actually wonderful.

    回复
  12. [url=https://sildenafilv.com/]sildenafil online buy india[/url] [url=https://viagrasoftab.com/]viagra soft tabs 100mg pills[/url]

    回复
  13. Hello, this weekend is nice for me, since this point in time i
    am reading this great educational piece of writing here at my house.

    回复
  14. [url=http://hydroxychloroquinecv.com/]generic hydroxychloroquine[/url] [url=http://albendazoleotc.com/]where to buy albendazole uk[/url] [url=http://zofranondansetron.com/]cost of zofran 4 mg[/url] [url=http://avodart24.com/]avodart soft capsules[/url] [url=http://advair250.com/]buy advair singapore[/url]

    回复
  15. Excellent way of explaining, and pleasant post to obtain information about my presentation subject, which
    i am going to deliver in university.

    回复
  16. [url=https://indocinrx.com/]indocin 100mg[/url] [url=https://prozacflx.com/]prozac 50 mg tablets[/url] [url=https://glucophagge.com/]glucophage mastercard[/url] [url=https://hydroxychloroquinecv.com/]buy plaquenil online uk[/url] [url=https://dipyridamol.com/]dipyridamole 75 mg tablet[/url] [url=https://cleocing.com/]cleocin pill[/url]

    回复
  17. This design is spectacular! You most certainly know how to keep a
    reader amused. Between your wit and your videos, I was almost moved to start my own blog (well, almost…HaHa!) Wonderful job.
    I really loved what you had to say, and more than that, how you presented
    it. Too cool!

    回复
  18. [url=http://flagyl24.com/]metronidazole 250mg shipped w/o rx[/url] [url=http://albendazoleotc.com/]albendazole price in us[/url] [url=http://hydroxychloroquinecv.com/]generic plaquenil price[/url] [url=http://clomid150.com/]order clomid from canada[/url] [url=http://seroquel50.com/]can you order seroquel online[/url] [url=http://zithromax360.com/]zithromax 500 mg lowest price drugstore online[/url] [url=http://lexaporo.com/]lexapro cost canada[/url]

    回复
  19. I will immediately clutch your rss feed as I can’t to find your e-mail subscription hyperlink or e-newsletter service.
    Do you’ve any? Please let me recognize so that I may just subscribe.
    Thanks.

    回复
  20. [url=http://elimitepermethrin.com/]buy elimite otc[/url] [url=http://finpecia911.com/]finpecia 1 mg[/url] [url=http://prazosin.us.com/]1mg prazosin[/url]

    回复
  21. [url=http://arimidex365.com/]arimidex cost generic[/url] [url=http://hydroxychloroquinecv.com/]hydroxychloroquine 100 mg[/url] [url=http://viagrasoftab.com/]viagra soft tabs 100mg 50mg[/url] [url=http://vermox100.com/]vermox nz[/url] [url=http://backtrim.com/]bactrim 960[/url] [url=http://albendazoleotc.com/]albendazole 400 mg tab[/url] [url=http://azithromycinp.com/]azithromycin in singapore[/url]

    回复
  22. Burning hot online girls from your area to meet is no more a problem with
    our sex chat! Observe private rooms and enjoy live cam girls as if you
    were there with them. Threesome, foursome or more person in private video chat rooms.
    Watch deleted, private & flagged amateur sex videos from social networks!

    It’s no wonder, then, that porn stars have enormous followings
    on social media. With the demand for social media at
    an all-time high, more and more porn sites are embracing the communal.
    Do you want a soft sex video or a harcore porn? There’s
    no free chat option, but you get unlimited free previews of their live streaming video as a way to preview the site before joining.
    Here you can use our free java adult chat rooms (all text),
    or check out free video chat with featured live cam girls and guys.
    With such a bountiful supply of nubile cam girls pulsing in and out of Chaturbate every day, it’s no wonder that they are the most popular adult webcam site on Earth.

    回复
  23. Today, I went to the beach with my kids. I found a sea shell and gave it to my 4 year old
    daughter and said “You can hear the ocean if you put this to your ear.” She put
    the shell to her ear and screamed. There was a hermit crab inside and it
    pinched her ear. She never wants to go back! LoL I know this is completely
    off topic but I had to tell someone!

    回复
  24. [url=https://advair250.com/]advair diskus price canada[/url]

    回复
  25. Good post! We will be linking to this particularly great post on our
    website. Keep up the great writing.

    回复
  26. doxycycline dosage [url=http://doxycyclinetab.com/]doxycycline use[/url] doxycycline side effects in dogs

    回复
  27. [url=http://tretinoin365.com/]tretinoin india pharmacy[/url] [url=http://triamterenebenzathiazide.com/]triamterene medication[/url]

    回复

AaronEmber进行回复 取消回复

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