Skip to content
This repository has been archived by the owner on Jan 21, 2024. It is now read-only.

A collection of scripts to prepare a Gentoo tarball for the pinebook pro

Notifications You must be signed in to change notification settings

Jannik2099/gentoo-pinebookpro

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

79 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gentoo-pinebookpro

A collection of scripts to prepare a Gentoo tarball for the pinebook pro

Disclaimer:

I do not recommend Gentoo for people new to Linux.

How to use

READ THE GENTOO HANDBOOK!!! https://wiki.gentoo.org/wiki/Handbook:AMD64

./prepare.sh -h to display usage, this is safe to run in any environment and will not read or write anything.

tarball preparation instructions

Do this on your pbp or another aarch 64 environment, qemu works aswell.

  • Download a Stage 3 arm64 tarball - usually from https://www.gentoo.org/downloads/#arm64
  • Extract the tarball as root, otherwise you'll mess up file permissions!
  • Put the files of this repository into the tarball - preferably into /var/tmp/gentoo-pinebookpro.
    • You can do this with, e.g. git clone https://github.com/Jannik2099/gentoo-pinebookpro /var/tmp/gentoo-pinebookpro (or wget https://github.com/Jannik2099/gentoo-pinebookpro/archive/master.zip -O /tmp/master.zip; unzip /tmp/master.zip -d /var/tmp/gentoo-pinebookpro; rm /tmp/master.zip, if you don't have git but do have wget.)
  • Chroot into the tarball as explained in the Handbook - https://wiki.gentoo.org/wiki/Handbook:AMD64/Installation/Base#Copy_DNS_info
  • Edit your /etc/portage/make.conf to use the desired amount of threads and simultaneous jobs - I recommend MAKEOPTS="-j6 -l8" and EMERGE_DEFAULT_OPTS="--jobs 6 --load-average 8" (each as seperate lines in the file)
  • Execute the script prepare.sh - it is recommended to not change the default options unless you really know what this will do, and what will break if you do.
  • Should the script fail you can run it again without having to unpack a new tarball.

From there on, do the usual tarball installation following the Gentoo Handbook.

Linux Kernel

  • Use sys-kernel/pinebookpro-manjaro-sources as the kernel

To install / update a kernel:

  • Mount /boot. Select it with eselect kernel set.
  • Emerge sys-boot/extlinux and sys-boot/u-boot.
  • Install u-boot to the target block device as instructed.
  • Call genkernel all to compile and install the Kernel.
  • Go to the kernel directory (/usr/src/linux) and do make dtbs && make dtbs_install.
  • Lastly, run u-boot-update.
  • Check /boot/extlinux/extlinux.conf for any obvious mistakes.

It's heavily recommended to run the latest mesa, to do so add media-libs/mesa ~arm64 to your /etc/portage/package.accept_keywords . Similarly, running the latest versions of your DE and the underlying Qt / GTK libs is often a good idea.

Changes to the Gentoo repository

I have changed or added some ebuilds via my overlay pinebookpro-overlay . It is installed by the prepare script via eselect-repository.

  • The Kernel ebuild sys-kernel/pinebookpro-manjaro-sources has been added.
  • virtual/linux-sources has been adapted accordingly.
  • The wifi firmware is packaged as sys-firmware/pinebookpro-firmware, from sys-kernel/linux-firmware only rockchip/dptx.bin is needed, the configuration is done by the script (see /etc/portage/savedconfig/sys-kernel/linux-firmware-yyyymmdd)
  • An ebuild for miscellaneous fixes sys-firmware/pinebookpro-misc has been added. Please emerge this after having booted into Gentoo, it will most likely fail in a chroot. It is required for full functionality.
  • An ebuild that applies profile overrides app-portage/pinebookpro-profile-overrides has been added, this is auto-installed and you really really shouldn't uninstall it.

Useful stuff for people new to Gentoo

Ebuilds (the scripts that configure, compile and install a package) are sometimes not released as stable or not released at all for all architectures. This is called keywording: for example, KEYWORDS="amd64 ~arm64" indicates the ebuild is marked stable for amd64, testing for arm64 and masked for all other architectures. You can and will override this a lot by editing /etc/portage/package.accept_keywords . Adding category/package keyword to this file will emerge the latest version that uses the respective keyword. For example, firefox has all LTS releases marked stable and all others marked testing. www-client/firefox ~arm64 would always select the latest release. Dependencies that require keyword changes can be automatically unmasked and the changes merged with dispatch-conf

Known issues

General:

Issue:	The keyboard / touchpad is unresponsive sometimes
Fix:	Make sure you have updated the keyboard / touchpad firmware, see https://github.com/ayufan-rock64/pinebook-pro-keyboard-updater

Issue:	The PBP charges a lot slower after a while, the charging LED starts blinking
Fix	This is a weird safety feature of the battery controller. It usually goes away after charging to full or restarting

Issue:	Wifi bad
Fix:	The wifi powersave seems to be broken, disable it with `iwconfig wlan0 power off` - what an unfortunate naming

About

A collection of scripts to prepare a Gentoo tarball for the pinebook pro

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages