Banana Pi BPI-R2 new image:Gentoo image 2019-10-27

The „emerge frank-sources” command creates the source in the default directory (for 4.14 „emerge =sys-kernel/frank-sources-4.14”. Need one: USE = “$USE symlink” in front of emerge and there will be a symlink to the directory and now i play with USE="$USE build" to build the kernel with your build.sh file…

console messages:

>>> Emerging (5 of 5) sys-kernel/frank-sources-4.14::genbpi-overlay
>>> Preparing to unpack ...
>>> Unpacking source...
 * Repository id: frank-w_BPI-R2-4.14.git
 * To override fetched repository properties, use:
 *   EGIT_OVERRIDE_REPO_FRANK_W_BPI_R2_4_14
 *   EGIT_OVERRIDE_BRANCH_FRANK_W_BPI_R2_4_14
 *   EGIT_OVERRIDE_COMMIT_FRANK_W_BPI_R2_4_14
 *   EGIT_OVERRIDE_COMMIT_DATE_FRANK_W_BPI_R2_4_14
 * 
 * Fetching https://github.com/frank-w/BPI-R2-4.14.git ...
git fetch https://github.com/frank-w/BPI-R2-4.14.git +HEAD:refs/git-r3/HEAD
git symbolic-ref refs/git-r3/sys-kernel/frank-sources/0/__main__ refs/git-r3/HEAD
 * Checking out https://github.com/frank-w/BPI-R2-4.14.git to /var/tmp/portage/sys-kernel/frank-sources-4.14/work/linux-4.14-frank ...
git checkout --quiet refs/git-r3/HEAD
GIT update -->
   repository:               https://github.com/frank-w/BPI-R2-4.14.git
   at the commit:            aec90cd8bf6767fee9bd2f46d38dac045ebb1b50
>>> Source unpacked in /var/tmp/portage/sys-kernel/frank-sources-4.14/work
>>> Preparing source in /var/tmp/portage/sys-kernel/frank-sources-4.14/work/linux-4.14-frank ...
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/sys-kernel/frank-sources-4.14/work/linux-4.14-frank ...
>>> Source configured.
>>> Compiling source in /var/tmp/portage/sys-kernel/frank-sources-4.14/work/linux-4.14-frank ...
>>> Source compiled.
>>> Test phase [not enabled]: sys-kernel/frank-sources-4.14

>>> Install sys-kernel/frank-sources-4.14 into /var/tmp/portage/sys-kernel/frank-sources-4.14/image/
>>> Copying sources ...
>>> Completed installing sys-kernel/frank-sources-4.14 into /var/tmp/portage/sys-kernel/frank-sources-4.14/image/

 * Final size of build directory:      4 KiB
 * Final size of installed tree:  934752 KiB (912.8 MiB)

....
>>> Installing (5 of 5) sys-kernel/frank-sources-4.14::genbpi-overlay
 * checking 61839 files for package collisions
 16% done,  51375 files remaining ...
 33% done,  41217 files remaining ...
 50% done,  30629 files remaining ...
 67% done,  19894 files remaining ...
 79% done,  12971 files remaining ...
 94% done,   3519 files remaining ...
100% done
>>> Merging sys-kernel/frank-sources-4.14 to /
--- /usr/
--- /usr/src/
>>> /usr/src/linux-4.14-frank/
....
>>> /usr/src/linux-4.14-frank/.git/objects/info/alternates
>>> /usr/src/linux-4.14-frank/.git/objects/pack/
>>> /usr/src/linux-4.14-frank/Makefile
>>> /usr/src/linux-4.14-frank/README
>>> /usr/src/linux-4.14-frank/CREDITS
>>> /usr/src/linux-4.14-frank/include/dt-bindings/input/linux-event-codes.h -> ../../uapi/linux/input-event-codes.h
>>> /usr/src/linux-4.14-frank/drivers/net/wireless/mediatek/mt76/firmware/mt7662.bin -> mt7662_firmware_e3_v1.9.bin
>>> /usr/src/linux-4.14-frank/arch/arm/boot/dts/sun8i-a23-ippo-q8h-v1.2.dts -> sun8i-a23-q8-tablet.dts
>>> /usr/src/linux-4.14-frank/arch/arm/boot/dts/sun8i-a23-ippo-q8h-v5.dts -> sun8i-a23-q8-tablet.dts
>>> /usr/src/linux-4.14-frank/arch/arm/boot/dts/sun8i-a33-ippo-q8h-v1.2.dts -> sun8i-a33-q8-tablet.dts

 * If you are upgrading from a previous kernel, you may be interested
 * in the following document:
 *   - General upgrade guide: https://wiki.gentoo.org/wiki/Kernel/Upgrade

 * frank-sources is UNSUPPORTED by Gentoo Security.
 * This means that it is likely to be vulnerable to recent security issues.

 * Upstream kernel developers recommend always running the latest 
 * release of any current long term supported Linux kernel version.
 * To see a list of these versions, their most current release and 
 * long term support status, please go to https://www.kernel.org .

 * For specific information on why this kernel is unsupported, please read:
 * https://wiki.gentoo.org/wiki/Project:Kernel_Security
>>> sys-kernel/frank-sources-4.14 merged.
>>> Regenerating /etc/ld.so.cache...

>>> Recording sys-kernel/frank-sources in "world" favorites file...

 * Messages for package sys-kernel/frank-sources-4.14:

 * If you are upgrading from a previous kernel, you may be interested
 * in the following document:
 *   - General upgrade guide: https://wiki.gentoo.org/wiki/Kernel/Upgrade
 * frank-sources is UNSUPPORTED by Gentoo Security.
 * This means that it is likely to be vulnerable to recent security issues.
 * Upstream kernel developers recommend always running the latest 
 * release of any current long term supported Linux kernel version.
 * To see a list of these versions, their most current release and 
 * long term support status, please go to https://www.kernel.org .
 * For specific information on why this kernel is unsupported, please read:
 * https://wiki.gentoo.org/wiki/Project:Kernel_Security
>>> Auto-cleaning packages...

At least you should select specific branch before building instead of HEAD (which is currently 4.14-main but may change in future).

What does not work?

This is the HEAD you see in the gentoo ebuild feature and I can now distinguish between the two branches. Later, if the name changes, I’ll change it too. What’s not working right now? Emerge runs only with root privileges, so I have to remove this check and a lot of sudo from the script, but without damaging the system.

The kernel and modules I have created are different from the gentoo ebuild system, I can’t make binary out of it yet. By the way, the system compiled by @mt_werty is bleeding from many wounds, not entirely based on gentoo standards, and the 32G SD does not fit the system as it does not fit in mmc. It is okay for development, but not for release. I make a image of a gentoo standard and upload it and continue there. The binary repo is ready and up to date. I’m still testing your build.sh :slight_smile:

I see you have a repo, is it avaliable anywhere? I work on mesa ebuild for lima support, so I can merge it to your repo, whe it’s done. If it available of course :slight_smile:

This is a local repo, heavily in the test phase at the moment. it’s just about the kernel, later I will combine it with my previous repo (for bpi-pro and pbi-zero) and publish it. That repo already has everything :wink: