ยง2023-09-06
Using crossdev may unintentionally "pollute" ebuild repositories if proper care is not taken. Follow this section to assure that crossdev places files in a reasonable location, and does not create other disturbances.
- crossdev will place the ebuilds/categories it generates into one of four places, in this order:
- An ebuild repository specified on the command-line with the --ov-output (-oO) option
- An ebuild repository named 'cross-${CTARGET}'
- An ebuild repository named 'crossdev'
- It then falls back on the ebuild repository having the lowest priority value in /etc/portage/repos.conf/
- If it falls back on ebuild repositories that have the same priority, it will use the first ebuild repository alphabetically
- Most users will want to prevent crossdev from disturbing configured ebuild repositories. One solution is to create an ebuild repository for crossdev, in
- order to avoid it from choosing a seemingly random repository to store packages in:
(chroot) h2Jammy / # ls /var/db/repos/
gentoo
(chroot) h2Jammy / # mkdir -p /var/db/repos/crossdev/{profiles,metadata}
(chroot) h2Jammy / # echo 'crossdev' > /var/db/repos/crossdev/profiles/repo_name
(chroot) h2Jammy / # echo 'masters = gentoo' > /var/db/repos/crossdev/metadata/layout.conf
(chroot) h2Jammy / # chown -R portage:portage /var/db/repos/crossdev
If the Gentoo ebuild repository is synchronized using Git, or any other method with Manifest files that do not include checksums for ebuilds, prevent "masked by: corruption" errors with:
- FILE /var/db/repos/crossdev/metadata/layout.conf
masters = gentoo
thin-manifests = true
- Then instruct Portage and crossdev to use this ebuild repository:
- FILE /etc/portage/repos.conf/crossdev.conf
(chroot) h2Jammy / # ls /etc/portage/repos.conf/crossdev.conf
ls: cannot access '/etc/portage/repos.conf/crossdev.conf': No such file or directory
(chroot) h2Jammy / # nano /etc/portage/repos.conf/crossdev.conf # as follows
[crossdev]
location = /var/db/repos/crossdev
priority = 10
masters = gentoo
auto-sync = no