Firefox installed from packages on my RaspBerry Pi Zero crashes every time I launch it...

Exactly bro. I'm trying to see if I can compile it on the RockPro RK3399 because it is more powerful than the Radxa 3W,but it seems worst. I already know that I should learn how to cross compile chromium for arm64 on my FreeBSD x64 bit. But since it is not a trivial task for me,I want to check if I can do it directly on the Arm board,to save me "some" time.
 
The RockPro has 4 Gb of RAM,so we should double the hours.

Do you have a nice tutorial to share where I can learn how to cross compile chromium for arm64 on X64 bit ?

If I find a nice tutorial I will change tecnique for sure ;)
 
the easiest but not the fastest is to run a freebsd arm64 image in qemu on a powerfull x86 box
you can get many cores, lots of ram and fast disk. emulated cpu is not that fast but you may achive 1:1 with a rk3999 if you have a fast enough x86 box
 
the easiest but not the fastest is to run a freebsd arm64 image in qemu on a powerfull x86 box
you can get many cores, lots of ram and fast disk. emulated cpu is not that fast but you may achive 1:1 with a rk3999 if you have a fast enough x86 box

What about to find the package already precompiled somewhere ? Maybe we can do : pkg add chromium.pkg and it's done.
 
It's compiling. I see that as new option Chromium comes with the panfrost driver (its the same for Firefox ?)....it will run with some sort of hardware acceleration ?
 
/usr/local/bin/python3.11: can't open file '/usr/ports/www/chromium/work/chromium-136.0.7103.113/./build/linux/unbundle/replace_gn_files.py" : Error 2 : No such file or directory.
 
Do you have a nice tutorial to share where I can learn how to cross compile chromium for arm64 on X64 bit ?
There is a Building Packages Through Emulation wiki page, using poudrier (ports-mgmt/poudriere , ports-mgmt/poudriere-devel)

I've tried it, port build time results are not promising, on my test hardware at least (AMD 5700U 1,9 GHz Turbo Core 4.1 GHz).

Here is a comparison between 142amd64 poudriere jail and 142aarch64 jail, qemu-user-mode emulation. A test build of print/indexinfo (distfile is 3853 Byte) took on the 142aarch64 more than 10 times longer to build (aarch64 11 seconds, amd64 1 second).

The dependencies build of pkg and ccache alone took 15 minutes on aarch64 jail (less than 1 minute on amd64).

From indexinfo build log

poudriere jail 142aarch64
Rich (BB code):
...
package name: indexinfo-0.3.1_1
building for: FreeBSD 142aarch64-default-job-01 14.2-RELEASE-p3 FreeBSD 14.2-RELEASE-p3 arm64
...
Host OSVERSION: 1402000
Jail OSVERSION: 1402000
...
---Begin Environment---
...
UNAME_m=arm64
UNAME_p=aarch64
UNAME_r=14.2-RELEASE-p3
...
build time: 00:00:11

poudriere jail 142amd64
Rich (BB code):
...
package name: indexinfo-0.3.1_1
building for: FreeBSD 142amd64-default-job-01 14.2-RELEASE-p3 FreeBSD 14.2-RELEASE-p3 amd64
...
build time: 00:00:01

the easiest but not the fastest is to run a freebsd arm64 image in qemu on a powerfull x86 box
I haven't tried it myself, if you are interested ZioMario in arm64/QEMU , have a look.

See also How to build and use QEMU User Mode on FreeBSD (wiki outdated, last edited 2017-08-22)
 
There is a Building Packages Through Emulation wiki page, using poudrier (ports-mgmt/poudriere , ports-mgmt/poudriere-devel)

I've tried it, port build time results are not promising, on my test hardware at least (AMD 5700U 1,9 GHz Turbo Core 4.1 GHz).

Here is a comparison between 142amd64 poudriere jail and 142aarch64 jail, qemu-user-mode emulation. A test build of print/indexinfo (distfile is 3853 Byte) took on the 142aarch64 more than 10 times to build (aarch64 11 seconds, amd64 1 second).

The dependencies build alone of pkg and ccache took 15 minutes on aarch64 jail (less than a 1 minute on amd64).

From indexinfo build log

poudriere jail 142aarch64
Rich (BB code):
...
package name: indexinfo-0.3.1_1
building for: FreeBSD 142aarch64-default-job-01 14.2-RELEASE-p3 FreeBSD 14.2-RELEASE-p3 arm64
...
Host OSVERSION: 1402000
Jail OSVERSION: 1402000
...
---Begin Environment---
...
UNAME_m=arm64
UNAME_p=aarch64
UNAME_r=14.2-RELEASE-p3
...
build time: 00:00:11

poudriere jail 142amd64
Rich (BB code):
...
package name: indexinfo-0.3.1_1
building for: FreeBSD 142amd64-default-job-01 14.2-RELEASE-p3 FreeBSD 14.2-RELEASE-p3 amd64
...
build time: 00:00:01


I haven't tried it myself, if you are interested ZioMario in arm64/QEMU , have a look.

See also How to build and use QEMU User Mode on FreeBSD (wiki outdated, last edited 2017-08-22)

I was able to compile Chromium in one day,but at the very end I've got the error :

Code:
/usr/local/bin/python3.11:
can't open file '/usr/ports/www/chromium/work/chromium-136.0.7103.113/./build/linux/unbundle/replace_gn_files.py" :
Error 2 : No such file or directory.

I suspect that it was caused by these instructions :

Code:
# cd /usr/ports/www/chromium/
# make build-depends-list | cut -c 12- | xargs pkg install -A -y
# make NO_CHECKSUM MAKE_JOBS_UNSAFE=yes install

I think that covacat tried to help me to compile it faster. But it seems that mixing packages and ports didn't work. Now I'm trying to compile it in this way :

Code:
# portmaster www/chromium

It's compiling now. My hope is the error above will disappear.
 
Code:
/usr/local/bin/python3.11:
can't open file '/usr/ports/www/chromium/work/chromium-136.0.7103.113/./build/linux/unbundle/replace_gn_files.py" :
Error 2 : No such file or directory.

How is called the file where the file "replace_gn_files.py" is called ? I've found this file on the Google Chromium repo and I can place it where it should be "/usr/ports/www/chromium/work/chromium-136.0.7103.113/./build/linux/unbundle".

The problem is that when the compilation restarts,the file is deleted from "/usr/ports/www/chromium/work/chromium-136.0.7103.113/./build/linux/unbundle"

So I need to remove it at the root,where it is called and at the same time I will copy it where is needed. In this way the compilation could restart and finish in a little amount of time.
 
an ampere based vm (CAX41)
16 cores
32 GB ram
320 GB storage
20 TB bw
is € 24.49 / mo at hetzner
word on the street is that you can boot in recovery console and dd a (slightly modified / with root ssh keys)freebsd image over the provided one
 
On this post :


covacat explained how to "build an armv7 kernel on a x86 freebsd box". Well,a question comes to my mind now. If I can "build an armv7 kernel on a x86 freebsd box",why I can't "build an armV8 port on a x86 freebsd box"...without using qemu....since when I built the armV7 kernel on my x86 freebsd box I didn't.
 
So,in my X86-64 FreeBSD box,I would do :

Code:
# cd /usr/ports/www/chromium/
# make TARGET=arm TARGET_ARCH=armv8
# make install
 
you can only build kernel or world like that, not ports afaik.
i used qemu to build for my pi zero and it was 2.5x faster than native but pi zero is crap at performance
also the x86 box was not the fastest either (ancient xeon). but on a superfast x86 box you may get par performance with a rk3399 maybe via qemu.
 
I'm reading that maybe I can enable KVM on Linux installed on the Rock chip. Is this good ?


the idea is to virtualize FreeBSD on a qemu+kvm Ubuntu virtual machine created on the Rockchip RK3399.
 
probably yes. but it probably won't be any faster than the emulation from x86 (because the x86 host would be much faster)
 
Back
Top