歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
Linux教程網 >> Linux基礎 >> Linux教程 >> 用gNewSense來創建自己的Linux發行版

用gNewSense來創建自己的Linux發行版

日期:2017/2/28 17:55:14   编辑:Linux教程
是否覺得在4,5百個Linux發行版中很難選擇?只是覺得某個版本的某些功能好,無法綜合,現在我們就來打造自己的發行版本,俺近期會發行一個linux版本代號為Xlib-Linux0.1,呵呵!
俺在沒有發現gNewSense之前想了很多辦法都沒有成功,最近看了她,但是似乎沒有中文資料,俺自己做了一下翻譯整理,希望對您有幫助,一步步來很簡單!
Step 1: 環境准備
需要一個debian環境,推薦ubunt和hiweed debian;
Step 2: GPG Key
很多APT都需要一個GPG Key來確認發行版,我們首先來創建一個自己的GPG Key:gpg –gen-key,注意要用空白密碼,後邊的配置需要這個,然後添加public Key到rootking;
Step 3: Packages
下邊這些文件是必須的:
apt-get install reprepro imagemagick debmirror build-essential apache2 subversion cdebootstrap
apt-get install squashfs-tools netpbm syslinux bittornado
apt-get build-dep linux-image-$(uname -r) ubiquity update-manager Ubuntu-artwork base-files ubuntu-meta
apt-get build-dep launchpad-integration grub system-tools-backends example-content gnome-panel
apt-get build-dep gnome-app-install
svn co http://svn.gnewsense.svnhopper.net/gnewsense/builder/trunk builder sudo ./fixup-kernel-wedge
Step 4:Debmirror (可選)
為了避免重復下載文件,俺建議創建一個自己的發行版的鏡像,可能需要27GB空間。
debmirror –nocleanup –verbose –progress –method=http –host=ie.archive.ubuntu.com –arch=i386 \
–source –dist=dapper,dapper-security,dapper-updates,dapper-backports –section=main,main/debian-installer,universe –ignore-release-gpg \
–root=ubuntu /the/target/directory
Step 5: Configuration(配置)
進入之前您創建的biulder文件夾,編輯config文件,這裡需要注意:MIRROR, RELEASE, DISTRONAME,DOMAIN, BASEDIR, 和 REPOAPT,這裡有個詳解文件:配置文件詳解,一定要仔細看這個很關鍵。
Step 6: Generate the repository
./gen-repo && ./do-update
這一步需要點時間,每次有更新的時候 re-run re-do(debmirror 如果有需要的話)
Step 7: Generate the LiveCD
sudo ./gen-livecd;生成的文件將放到 $LIVECDDIR/$DISTRONAME_L-livecd-$LIVECD_VERSION.iso
./gen-cdsource
./stage-cd
這一步會創建一個壓縮包,生成一個ISO文件在: $REPODST/cdimage
Step 7: Push your repository to a mirror and publicise
現在就可以發布了:
./push-repo
./push-cd
好了就這麼多,可以共享一下您的Linux麼?
Copyright © Linux教程網 All Rights Reserved