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包 有 69,762 条回应

  1. Hello There. I found your blog using msn. This is a very well written article.
    I’ll make sure to bookmark it and come back to read more of your useful information. Thanks for the post.
    I’ll certainly return.

    回复
  2. Fantastic site you have here but I was curious if
    you knew of any message boards that cover the same topics discussed
    in this article? I’d really love to be a part of group where I can get opinions from other knowledgeable individuals that share the same interest.
    If you have any recommendations, please let me know.
    Thanks a lot!

    回复
  3. Excellent post. I was checking constantly this
    blog and I’m impressed! Very useful info particularly the last part :
    ) I care for such info a lot. I was looking for this certain info for a long time.
    Thank you and good luck.

    回复
  4. With thanks! Plenty of postings.
    [url=http://advair-coupons.com/]advair diskus 250/50[/url]

    回复
  5. Great goods from you, man. I’ve understand your stuff previous to and you’re just too magnificent.
    I really like what you’ve acquired here, really like what you are stating
    and the way in which you say it. You make it enjoyable and you still care for to keep it smart.
    I cant wait to read far more from you. This is actually a wonderful site.

    回复
  6. Just want to say your article is as astonishing. The clearness in your publish is
    just excellent and that i can suppose you are an expert on this subject.
    Fine with your permission let me to snatch your RSS feed to keep up
    to date with drawing close post. Thanks one million and please carry on the gratifying work.

    回复
  7. [url=https://onlineloan.us.com/]online loan[/url]

    回复
  8. I’m amazed, I must say. Rarely do I come across a
    blog that’s both equally educative and entertaining, and without a doubt,
    you’ve hit the nail on the head. The problem is something that not enough men and women are speaking intelligently
    about. Now i’m very happy that I stumbled across this during my hunt for something regarding this.

    回复
  9. I got this website from my pal who shared with me regarding this site and now
    this time I am browsing this web page and reading very informative articles or reviews at this time.

    回复
  10. I visited multiple web pages but the audio quality for audio
    songs current at this web page is genuinely marvelous.

    回复
  11. I was able to find good advice from your blog articles.

    回复
  12. Have you ever considered publishing an e-book or guest authoring on other websites?

    I have a blog based on the same subjects you discuss and would really like to have
    you share some stories/information. I know my viewers would enjoy your work.
    If you’re even remotely interested, feel free to shoot me an e-mail.

    回复
  13. Superb postings. Thanks a lot! [url=http://cephalexinmsnrxmsnrx.best/]antibiotics cephalexin[/url]

    回复
  14. Wow that was odd. I just wrote an really long comment but after I clicked submit my comment didn’t appear.
    Grrrr… well I’m not writing all that over again. Anyways, just wanted to
    say excellent blog!

    回复
  15. Reliable knowledge. Cheers. [url=http://viagrapython.com/]generic viagra online[/url]

    回复
  16. What’s Happening i am new to this, I stumbled upon this I have found It positively helpful and it has helped me
    out loads. I’m hoping to give a contribution & assist other users
    like its helped me. Great job.

    回复
  17. Heya i am for the first time here. I found this board and I find
    It really helpful & it helped me out a lot. I am hoping to present something back and aid others like you helped me.

    回复
  18. You suggested it effectively! [url=http://buymodafinilntx.com/]Provigil Rezeptfrei[/url]

    回复
  19. Greetings I am so grateful I found your blog page, I
    really found you by accident, while I was researching on Yahoo for something else, Regardless
    I am here now and would just like to say cheers for a tremendous post and a all round exciting blog (I also love the theme/design), I don’t have time to read it all
    at the minute but I have bookmarked it and also added your
    RSS feeds, so when I have time I will be back to read more, Please do keep up the excellent b.

    回复
  20. Highly descriptive post, I enjoyed that a lot. Will there be a part 2?

    回复
  21. It’s not my first time to visit this web site, i am browsing this web page dailly and take good information from here daily.

    回复
  22. What a stuff of un-ambiguity and preserveness of valuable know-how about unpredicted emotions.

    回复
  23. Welcome to Israel. In this escort directory section, you will find Israel escorts.
    Euro Girls Escort is the absolute most trusted escort directory and among the biggest 21girlz directory.
    All content and photos are regularly checked and updated
    with real photos. This makes sure, that all escort Ads are
    usually up to date and brings you the most effective experience.

    This portion of the catalogue features luxury companions providing escort services.
    Israel escorts works in elite escort agencies, as an unbiased escorts or in local strip clubs, dancing
    clubs, brothels, lap-dance bars and cabarets. The majority of the high class ladies do travel worldwide.
    You may even want to utilize call girl services – these escort girls can either
    work incall or outcall. Such elite escorts may be invited to a hotel room or you are
    able to visit them within their place.

    回复
  24. Thank you for the good writeup. It in fact was a amusement account it.
    Look advanced to more added agreeable from you! By the way, how can we communicate?

    回复
  25. What’s up to every body, it’s my first go to see of this website; this
    blog includes awesome and really fine material
    designed for readers.

    回复
  26. Hello, i think that i saw you visited my website thus i got
    here to go back the choose?.I’m attempting to find issues to improve my site!I
    suppose its adequate to make use of a few of your ideas!!

    回复
  27. Hi, i think that i saw you visited my weblog thus i came to “return the favor”.I’m trying to find
    things to improve my site!I suppose its ok to use some of your ideas!!

    回复
  28. If you would like to grow your know-how just keep visiting this web site and be updated with the most up-to-date information posted here.

    回复
  29. Hi, Neat post. There is a problem together with your site in internet explorer, might test this?
    IE nonetheless is the marketplace leader and a large
    element of other people will omit your wonderful
    writing due to this problem.

    回复
  30. Hello There. I found your blog using msn. This is an extremely well written article.
    I’ll be sure to bookmark it and return to read
    more of your useful info. Thanks for the post. I will certainly return.

    回复
  31. Great goods from you, man. I have understand your stuff previous to and you are just extremely wonderful.
    I actually like what you’ve acquired here, certainly like what
    you’re saying and the way in which you say it. You make
    it entertaining and you still take care of to keep it sensible.
    I can not wait to read far more from you. This is really
    a wonderful website.

    回复
  32. Admiring the dedicaztion you put into your blog and in depth information you present.
    It’sawesome to cme across a blog every once in a while that isn’t the same old
    rehashed material. Fantastic read! I’ve bookmarked you site and I’m adding ypur RSS feeds to my Google account.

    回复
  33. I am really thankful to the owner of this web site who has shared this
    impressive piece of writing at here.

    回复
  34. What’s up it’s me, I am also visiting this web site on a regular basis,
    this web site is really nice and the users are truly sharing fastidious thoughts.

    回复
  35. [url=https://loansonlinenb.com/]loans online no credit check[/url]

    回复
  36. I am really enjoying the theme/design of
    your weblog. Do you ever run into any internet browser compatibility issues?
    A few of my blog audience have complained about
    my blog not operating correctly in Explorer but looks
    great in Safari. Do you have any ideas to help fix this issue?

    回复
  37. Howdy would you mind letting me know which hosting company you’re
    using? I’ve loaded your blog in 3 different web
    browsers and I must say this blog loads a lot faster
    then most. Can you suggest a good hosting provider at a reasonable price?

    Many thanks, I appreciate it!

    回复
  38. Hmm is anyone else having problems with the pictures on this blog loading?
    I’m trying to figure out if its a problem on my end or if it’s the blog.
    Any feedback would be greatly appreciated.

    回复
  39. Seriously plenty of very good data!
    [url=http://augmentin4u.com/]Can I Take Augmentin With Acidophilus[/url] [url=http://canadianonlinepharmacytrust.com/]mexican pharmacies shipping to usa[/url] [url=http://viagradocker.com/]viagra coupon[/url]

    回复
  40. Its like you read my mind! You seem to know a lot about this, like you wrote the book in it or something. I think that you can do with a few pics to drive the message home a bit, but other than that, this is great blog. A great read. I will certainly be back.| а

    回复
  41. It is safe to say that you are apprehensive off
    asking you attractive ladies what she needs in bed? Generally,
    it is perfectly safe for you to engage and enjoy 3d virtual dating.
    Searching for dating young ladies? More seasoned ladies looking for more youthful men for one night
    remain on your bed. This is your time to begin dating in a way that brings you the excitement and happiness that you have been looking for.

    Some minxes leaving free sex ads are looking for a no-strings-attached date, some
    might be interested in a serious long-term mating. Genuine connect applications to get sex and singles.
    More seasoned singles searching for a nsa sexy local person who have lovely body need prevailing
    man to utilize her body and appreciate sex hookup.
    When the person hasn’t money, but he wants sex, the best way to use free gay
    web services. Browse thousands of attractive personals
    of would-be dating partners, and if a person appeals to you, just wink at them or
    send them a flirty message!

    回复
  42. I always spent my half an hour to read this blog’s content all the time along with a cup of coffee.| а

    回复
  43. Incredible quest there. What occurred after? Thanks!

    回复
  44. Hello! I just wanted to ask if you ever have any issues with hackers?
    My last blog (wordpress) was hacked and I ended up losing months of hard work due to no backup.
    Do you have any methods to stop hackers?

    回复
  45. Howdy! I know this is kinda off topic however I’d figured I’d ask.
    Would you be interested in trading links or maybe guest writing a blog post or vice-versa?
    My blog addresses a lot of the same subjects as yours and I
    feel we could greatly benefit from each other.
    If you might be interested feel free to shoot me an email.
    I look forward to hearing from you! Wonderful blog by the way!

    回复
  46. cheers considerably this fabulous website is definitely
    formal and relaxed

    回复
  47. [url=https://prozacfluo.com/]buy prozac[/url] [url=https://anafranil24.com/]clomipramine anafranil[/url] [url=https://hydroxychloroquine4.com/]buy hydroxychloroquine online[/url] [url=https://amoxicillinrem.com/]price of amoxicillin 30 capsules[/url] [url=https://bupropion911.com/]bupropion 75 mg in india[/url]

    回复
  48. [url=http://prednisolone360.com/]prednisolone buy[/url]

    回复
  49. [url=http://lisinoprilht.com/]buy lisinopril uk[/url] [url=http://citalopram24.com/]citalopram 5 mg uk[/url] [url=http://buspar365.com/]buy buspar[/url] [url=http://amoxicillin05.com/]amoxicillin online canada[/url] [url=http://tetracycline911.com/]where to get tetracycline[/url]

    回复

发表评论

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