build chromium from sources for ozone-gbm-lima target

Post Reply
debian-server-fanboy
Posts: 12
Joined: Fri Aug 09, 2019 11:05 pm
languages_spoken: english
ODROIDs: odroid-c2
Has thanked: 1 time
Been thanked: 3 times
Contact:

build chromium from sources for ozone-gbm-lima target

Unread post by debian-server-fanboy » Fri Aug 16, 2019 2:34 am

scope:
  • usability evaluation of lima kernel driver;
build instructions:

debian-server-fanboy
Posts: 12
Joined: Fri Aug 09, 2019 11:05 pm
languages_spoken: english
ODROIDs: odroid-c2
Has thanked: 1 time
Been thanked: 3 times
Contact:

Re: build chromium from sources for ozone-gbm-lima target

Unread post by debian-server-fanboy » Fri Aug 16, 2019 11:11 pm

Because I did run into a problem, I have to put this project on the shelf until I will learn how to use cross-compilers.

Code: Select all

root@debian-stretch:~/3rd-party/chromium/src# build/install-build-deps.sh
Only x86 architectures are currently supported

User avatar
meveric
Posts: 10527
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105)
Has thanked: 17 times
Been thanked: 149 times
Contact:

Re: build chromium from sources for ozone-gbm-lima target

Unread post by meveric » Fri Aug 16, 2019 11:43 pm

This error has nothing to do with cross-compilers.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

debian-server-fanboy
Posts: 12
Joined: Fri Aug 09, 2019 11:05 pm
languages_spoken: english
ODROIDs: odroid-c2
Has thanked: 1 time
Been thanked: 3 times
Contact:

Re: build chromium from sources for ozone-gbm-lima target

Unread post by debian-server-fanboy » Sat Aug 17, 2019 12:28 am

@meveric,
I don't know the real reason of this error, nether how many other errors I will get during *native* build process.
Checking out and building Chromium on Linux web page clearly specify system requirements:
A 64-bit Intel machine with at least 8GB of RAM.
https://chromium.googlesource.com/chrom ... uctions.md

User avatar
meveric
Posts: 10527
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105)
Has thanked: 17 times
Been thanked: 149 times
Contact:

Re: build chromium from sources for ozone-gbm-lima target

Unread post by meveric » Sat Aug 17, 2019 3:16 am

Chromium is available on a variety of OSes for armhf arm64 and even armel.
You might think this is a "set rule" that it requires a 64-bit Intel machine, but it's not.

Chromium runs fine on Debian and Ubuntu for ARM64 boards such as the N1 and C2 (and even in part for N2), so there's definitely no restrictions about this.

The error above which you don't know what's causing this, is rather simple:
It's running the code as you can see here: https://chromium.googlesource.com/chrom ... ld-deps.sh (or if you open the script in an editor)
at some point it does this section of code:

Code: Select all

if [ 0 -eq "${do_unsupported-0}" ] && [ 0 -eq "${do_quick_check-0}" ] ; then
  if [[ ! $distro_codename =~ $supported_codenames &&
        ! $distro_id =~ $supported_ids ]]; then
    echo -e "ERROR: The only supported distros are\n" \
      "\tUbuntu 14.04 LTS (trusty with EoL April 2022)\n" \
      "\tUbuntu 16.04 LTS (xenial with EoL April 2024)\n" \
      "\tUbuntu 18.04 LTS (bionic with EoL April 2028)\n" \
      "\tUbuntu 19.04 (disco)\n" \
      "\tDebian 8 (jessie) or later" >&2
    exit 1
  fi
  if ! uname -m | egrep -q "i686|x86_64"; then
    echo "Only x86 architectures are currently supported" >&2
    exit
  fi
fi
First it tests if the OS you're running is supported, then it checks if the output of the command uname -m returns either i686 or x86_64.
If not, it shows the error that you see.
But in fact you already skipped several lines of options at this point.
Both passing --unsupported or --quick-check will jump over this point and the install of the requirements will continue.
In fact the entire script is rather unnecessary as Ubuntu and Debian already support Chromium there's also a build description on how to build chromium build into your systems, and since the only thing this script does is to install the build dependencies for Chromium, you can achieve the same with the command:

Code: Select all

apt build-dep chromium
where it will install all packages required to build chromium which is already available on your distro (which should match the build dependencies of the Chromium you want to build).

Although I don't know why you have to build Chromium for lima-kernel drivers but who knows
These users thanked the author meveric for the post:
debian-server-fanboy (Sat Aug 17, 2019 3:52 am)
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

debian-server-fanboy
Posts: 12
Joined: Fri Aug 09, 2019 11:05 pm
languages_spoken: english
ODROIDs: odroid-c2
Has thanked: 1 time
Been thanked: 3 times
Contact:

Re: build chromium from sources for ozone-gbm-lima target

Unread post by debian-server-fanboy » Sat Sep 07, 2019 5:45 am

I did cross-compile content_shell with ozone-platform-headless backend.
https://chromium.googlesource.com/chrom ... uctions.md
https://chromium.googlesource.com/chrom ... ium_arm.md

Next step is to install content_shell's run-time dependencies on odroid-c2.

debian-server-fanboy
Posts: 12
Joined: Fri Aug 09, 2019 11:05 pm
languages_spoken: english
ODROIDs: odroid-c2
Has thanked: 1 time
Been thanked: 3 times
Contact:

Re: build chromium from sources for ozone-gbm-lima target

Unread post by debian-server-fanboy » Tue Sep 10, 2019 12:20 am

I did use modified install-build-deps.sh to install dependencies.
Following packages are not available for arm64 architecture:
  • libc6-i386
  • lib32gcc1
  • lib32stdc++6
  • g++-6-multilib
Next step is to run content_shell with ozone-platform-headless backend.
These users thanked the author debian-server-fanboy for the post:
odroid (Tue Sep 10, 2019 8:41 am)

debian-server-fanboy
Posts: 12
Joined: Fri Aug 09, 2019 11:05 pm
languages_spoken: english
ODROIDs: odroid-c2
Has thanked: 1 time
Been thanked: 3 times
Contact:

Re: build chromium from sources for ozone-gbm-lima target

Unread post by debian-server-fanboy » Tue Sep 10, 2019 10:40 pm

Here is resulting *.png file of content_shell run with ozone-platform-headless backend:
content-shell-ozone-platform-headless.png
content-shell-ozone-platform-headless.png (103.65 KiB) Viewed 521 times

Code: Select all

root@debian-stretch:~# /dev/shm/mnt/Ozone-arm64/content_shell --no-sandbox --ozone-platform=headless --ozone-dump-file=/dev/shm --disable-gpu --single-process "https://forum.odroid.com/viewtopic.php?f=140&t=36105"
[937:937:0909/113235.824630:INFO:content_main_runner_impl.cc(943)] Chrome is running in full browser mode.
Fontconfig warning: "/etc/fonts/fonts.conf", line 100: unknown element "blank"
[937:937:0909/113235.935317:ERROR:viz_process_transport_factory.cc(302)] Switching to software compositing.

DevTools listening on ws://127.0.0.1:35445/devtools/browser/ece2a781-9f22-478b-9484-033a58e33149
[937:945:0909/113241.853011:WARNING:http_cache_transaction.cc(1177)] Unable to open or create cache entry
These users thanked the author debian-server-fanboy for the post:
odroid (Wed Sep 11, 2019 8:31 am)

debian-server-fanboy
Posts: 12
Joined: Fri Aug 09, 2019 11:05 pm
languages_spoken: english
ODROIDs: odroid-c2
Has thanked: 1 time
Been thanked: 3 times
Contact:

Re: build chromium from sources for ozone-gbm-lima target

Unread post by debian-server-fanboy » Wed Sep 11, 2019 11:41 pm

Next step is to implement 10 ozone interfaces:
  • SurfaceFactoryOzone
  • OverlayManagerOzone
  • CursorFactoryOzone
  • InputController
  • GpuPlatformSupportHost
  • SystemInputInjector
  • PlatformWindow
  • NativeDisplayDelegate
  • InputMethod
  • ClientNativePixmapFactory
https://chromium.googlesource.com/chrom ... verview.md

Post Reply

Return to “Projects”

Who is online

Users browsing this forum: No registered users and 1 guest