使用者工具

網站工具


使用manjaro-tools_buildiso_liveiso

https://wiki.manjaro.org/index.php/Build_Manjaro_ISOs_with_buildiso

Download the latest ISO profiles

git clone https://gitlab.manjaro.org/profiles-and-settings/iso-profiles.git ~/iso-profiles

修改要安裝的套件與 overlay 資料


mirror repo , put it in /srv/http/localhost/repository/localrep/

lr /srv/http/localhost/repository/localrep/stable/
total 16
drwxr-xr-x 3 feuer feuer 4096 Jun 13 15:10 multilib
drwxr-xr-x 3 feuer feuer 4096 Jun 13 15:50 core
drwxr-xr-x 3 feuer feuer 4096 Jun 13 19:01 community
drwxr-xr-x 3 feuer feuer 4096 Jun 15 00:00 extra

And active httpd service.


vi ~/.config/manjaro-tools/manjaro-tools.conf

chroots_dir=/mnt/N300_2/manjaro-tools-2
#build_mirror=file:///mnt/N300_2/Manjaro_repo/ ## 不可以用 file://,buildpkg 和 buildiso 無法在所有階段順利取得檔案。
build_mirror=http://localhost/repository/localrep
repo_tree=('core' 'extra' 'community' 'multilib')
host_tree=https://github.com/manjaro
host_tree_abs=git://projects.archlinux.org/svntogit
build_list_pkg=default
branch=v21.5
build_list_iso=default
kernel="linux510"

pacman.conf local repo (seems not necessary)

vi /etc/pacman.d/locallist

Server = http://localhost/repository/localrep/stable/$repo/$arch

vi /etc/pacman.conf

[core]
Include = /etc/pacman.d/locallist
Include = /etc/pacman.d/mirrorlist

[extra]
Include = /etc/pacman.d/locallist
Include = /etc/pacman.d/mirrorlist

[community]
Include = /etc/pacman.d/locallist
Include = /etc/pacman.d/mirrorlist

# If you want to run 32 bit applications on your x86_64 system,
# enable the multilib repositories as required here.

[multilib]
Include = /etc/pacman.d/locallist
Include = /etc/pacman.d/mirrorlist

Prepare packages from AUR

https://wiki.manjaro.org/index.php/Buildiso_with_AUR_packages:_Using_buildpkg

使用預設的 /etc/manjaro-tools/manjaro-tools.conf
使用一般帳號。

mkdir ~/pkgbuild
cd ~/pkgbuild
git clone https://aur.archlinux.org/google-chrome
buildpkg -p google-chrome

<buildpkg_google-chrome.log>

在下載編譯 google-chrome 之前,會先安裝一個 chroot 環境,/var/lib/manjaro-tools/buildpkg/stable/x86_64/root; 在其中安裝必要的套件然後編譯 google-chrome。

後記:安裝 iso 和製作 aur 套件最好同一個 chroot 環境,否則安裝套件可能出問題(檔案毀損)。

(su)

06-29 21:33 [root@92cafe pkgbuild]# cp /var/cache/manjaro-tools/pkg/stable/x86_64/google-chrome-91.0.4472.114-1-x86_64.pkg.tar.zst  /srv/http/localhost/repository/AUR/stable/online-repo/x86_64/
06-29 21:33 [root@92cafe x86_64]# repo-add online-repo.db.tar.gz *.pkg.tar.*
==> Extracting online-repo.db.tar.gz to a temporary location...
==> Extracting online-repo.files.tar.gz to a temporary location...
==> Adding package 'google-chrome-74.0.3729.131-1-x86_64.pkg.tar.xz'
==> WARNING: A newer version for 'google-chrome' is already present in database
  -> Computing checksums...
  -> Removing existing entry 'google-chrome-91.0.4472.114-1'...
  -> Creating 'desc' db entry...
  -> Creating 'files' db entry...
==> Adding package 'google-chrome-91.0.4472.114-1-x86_64.pkg.tar.zst'
  -> Computing checksums...
  -> Removing existing entry 'google-chrome-74.0.3729.131-1'...
  -> Creating 'desc' db entry...
  -> Creating 'files' db entry...
==> Creating updated database file 'online-repo.db.tar.gz'

製作 online_repo 參考檔案:

[feuer@92cafe iso-profiles]$ cat ~/iso-profiles/community/cinnamon/user-repos.conf 
[online-repo]
SigLevel = Never
Server = http://localhost/repository/AUR/$repo/$arch

把 /etc/manjaro-tools/manjaro-tools.conf 改回自訂 repo source:

chroots_dir=/mnt/N300_2/manjaro-tools-2
build_mirror=http://localhost/repository/localrep/

把 ~/iso-profiles/community/cinnamon/Packages-Desktop 加入自訂增加套件。


buildiso

執行 buildiso -p cinnamon

使用manjaro-tools_buildiso_liveiso.txt · 上一次變更: 2021/06/29 16:13 由 fire