Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chromium: Update to 121.0.6167.184 #791

Merged
merged 1 commit into from
Mar 20, 2024

Conversation

MaxIhlenfeldt
Copy link
Collaborator

@MaxIhlenfeldt MaxIhlenfeldt commented Feb 15, 2024

Release notes:
https://chromereleases.googleblog.com/2024/01/stable-channel-update-for-desktop_23.html
https://chromereleases.googleblog.com/2024/01/stable-channel-update-for-desktop_30.html
https://chromereleases.googleblog.com/2024/02/stable-channel-update-for-desktop.html
https://chromereleases.googleblog.com/2024/02/stable-channel-update-for-desktop_13.html

Build and patch changes:

Drop five backported patches that are included upstream now, and add
three new backports.

Drop arm/0002-Fix-ARM-build-with-recent-glibc.patch as
https://crrev.com/c/5035139 includes an equivalent patch.

Add 0019-Don-t-require-profiler_builtins.rlib.patch to fix a build error
when using OE master.

Rebase and renumber remaining patches.

License changes:

Added licenses:

  • third_party/lit/LICENSE

Removed licenses:

  • base/third_party/xdg_mime/LICENSE
  • native_client/LICENSE
  • not sure which change caused this, but we don't use NativeClient anyways

Updated licenses:

  • third_party/libxml/src/Copyright

Test-built (big thanks to @rjanani-p):

  • chromium-ozone-wayland:
  • master, clang, MACHINE=qemuarm, qemux86-64
  • nanbield, clang, MACHINE=qemuarm64, qemux86-64
  • chromium-x11:
  • master, clang, MACHINE=qemuarm, qemuarm64, qemux86-64
  • nanbield, clang, MACHINE=qemuarm, qemuarm64, qemux86-64

Signed-off-by: Max Ihlenfeldt max@igalia.com

@MaxIhlenfeldt MaxIhlenfeldt linked an issue Feb 15, 2024 that may be closed by this pull request
@MaxIhlenfeldt
Copy link
Collaborator Author

@rjanani-p testing would be greatly appreciated!

@rakuco as already mentioned in #716 (comment), it's sadly not feasible to fix all the compile errors that occur on kirkstone due to using clang 14. I suppose that means we should remove kirkstone from LAYERSERIES_COMPAT for the time being, and add a note to the README that we're working on re-enabling kirkstone support for the latest version? Should we create a kirkstone branch pointing to 0fcfadc?

@rjanani-p
Copy link

@rjanani-p testing would be greatly appreciated!

@rakuco as already mentioned in #716 (comment), it's sadly not feasible to fix all the compile errors that occur on kirkstone due to using clang 14. I suppose that means we should remove kirkstone from LAYERSERIES_COMPAT for the time being, and add a note to the README that we're working on re-enabling kirkstone support for the latest version? Should we create a kirkstone branch pointing to 0fcfadc?

@MaxIhlenfeldt sure, I will start testing

@rjanani-p
Copy link

@rjanani-p testing would be greatly appreciated!

@rakuco as already mentioned in #716 (comment), it's sadly not feasible to fix all the compile errors that occur on kirkstone due to using clang 14. I suppose that means we should remove kirkstone from LAYERSERIES_COMPAT for the time being, and add a note to the README that we're working on re-enabling kirkstone support for the latest version? Should we create a kirkstone branch pointing to 0fcfadc?

Hi @MaxIhlenfeldt , I have tested the pull request for below configurations:

  1. **poky_nanbield+MaxIhlenfeldt/**meta-browser at 121.0.6167.184 (github.com) +clang_ nanbield for chromium ozone wayland recipe, it got compiled successfully without build issues (built the image for 3 targets qemux86-64, qemuarm64, qemuarm)

Status:
but facing below issue while I executed the chromium 1.1.1.1 command on terminal, and I have used the core-image-sato command to create the images
image
chromium_ozone_wayland_testresult1

  1. Chromium version for poky_master+MaxIhlenfeldt/meta-browser at 121.0.6167.184 (github.com) +clang_master for chromium x11 recipe, it got compiled successfully without build issues (built the image for 3 targets qemux86-64, qemuarm64, qemuarm) and I have used the core-image-sato command to create the images
    status:
    for 2 targets(qemux86-64,qemuarm64) able to check the chromium version but for qemuarm target chromium application is not loading fully to check chromium version.

I am sharing the results in document
Chromium_121_0_6167_184_test_cases.pdf
, please find the results and let me work on pending test activities.

  1. build and test poky_nanbield with chromium x11 receipe(4 targets,i.e. qemux86-64 qemuarm qemuarm64,raspberrypi4-64)
  2. build and test poky_master with chromium ozone wayland ((4 targets,i.e. qemux86-64 qemuarm qemuarm64,raspberrypi4-64)
  3. build and test poky_kirkstone with chromium x11 & chromium ozone wayland (4 targets,i.e. qemux86-64 qemuarm qemuarm64,raspberrypi4-64)
  4. build and test poky_mickledore with chromium x11 & chromium ozone wayland (4 targets,i.e. qemux86-64 qemuarm qemuarm64,raspberrypi4-64)

please correct me if I am doing any mistakes. Thank you

@rjanani-p
Copy link

rjanani-p commented Feb 22, 2024

@rjanani-p testing would be greatly appreciated!

@rakuco as already mentioned in #716 (comment), it's sadly not feasible to fix all the compile errors that occur on kirkstone due to using clang 14. I suppose that means we should remove kirkstone from LAYERSERIES_COMPAT for the time being, and add a note to the README that we're working on re-enabling kirkstone support for the latest version? Should we create a kirkstone branch pointing to 0fcfadc?

@MaxIhlenfeldt I have completed the build & testing for nanbield branch for below machines, sharing the testing status below:

chromium worked well for qemux86-64, qemuarm64 machines but for qemuarm machine chromium browser not loading fully to check chromium version for chromium-ozone-wayland && chromium-x11 recipes:

  • chromium-ozone-wayland: qemux86-64, qemuarm64 machines chromium worked well && for qemuarm machine chromium browser not loading fully to check chromium version

:

  • chromium-x11: **qemux86-64, qemuarm64 machines chromium worked well ** && for qemuarm machine chromium browser not loading fully to check chromium version

**I didn't test with rpi4 due to hardware unavailability. **

next, I have started the build for master branch.

@rjanani-p
Copy link

rjanani-p commented Feb 23, 2024

Hi @MaxIhlenfeldt , I have completed the build & testing for poky master branch for below machines, sharing the testing status below:

chromium worked well for qemux86-64, qemuarm64 machines but for qemuarm machine chromium browser not loading fully to check chromium version for chromium-x11 recipe and for chromium-ozone-wayland able to build the source code but getting below error during testing the qemux86-64, qemuarm64 && for qemuarm machine /target images.

root@qemux86-64:~# chromium --no-sandbox 1.1.1.1
error: XDG_RUNTIME_DIR is invalid or not set in the environment.
[365:365:0222/123545.512019:ERROR:wayland_connection.cc(193)] Failed to connect to Wayland display: No such file or directory (2)
[365:365:0222/123545.512060:ERROR:ozone_platform_wayland.cc(259)] Failed to initialize Wayland platform
[365:365:0222/123545.512081:ERROR:env.cc(257)] The platform failed to initialize. Exiting
.

**I didn't test with rpi4 due to hardware unavailability. **

could you please share your input how to fix the issue?

@rjanani-p
Copy link

rjanani-p commented Feb 26, 2024

Hi @MaxIhlenfeldt @kraj , I have tried to build 791 pull request with poky mickledore and poky kirkstone branches but getting build issues for chromium-x11 recipe. Here I am sharing snippet of build log, could you please share your input how to resolve the issue.

| ninja: build stopped: subcommand failed.
| WARNING: /buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_mickledore/tmp/work/core2-64-poky-linux/chromium-x11/121.0.6167.184-r0/temp/run.do_compile.845499:147 exit 1 from '**ninja -v -j 64 chrome chrome_sandbox chromedriver.unstripped**'
| WARNING: Backtrace (BB generated script):
|       #1: do_compile, /buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_mickledore/tmp/work/core2-64-poky-linux/chromium-x11/121.0.6167.184-r0/temp/run.do_compile.845499, line 147
|       #2: main, /buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_mickledore/tmp/work/core2-64-poky-linux/chromium-x11/121.0.6167.184-r0/temp/run.do_compile.845499, line 151
ERROR: Task (/buildarea/eng1/rpandi/wrkspc/repos/max_pull_req_791/meta-browser/meta-chromium/recipes-browser/chromium/chromium-x11_121.0.6167.184.bb:do_compile) failed with exit code '1'
NOTE: Tasks Summary: Attempted 3005 tasks of which 2990 didn't need to be rerun and 1 failed.

Summary: 1 task failed:
  /buildarea/eng1/rpandi/wrkspc/repos/max_pull_req_791/meta-browser/meta-chromium/recipes-browser/chromium/chromium-x11_121.0.6167.184.bb:do_compile

# line: 494, file: /buildarea/eng1/rpandi/wrkspc/repos/max_pull_req_791/meta-browser/meta-chromium/recipes-browser/chromium/chromium-gn.inc
**do_compile() {
        ninja -v -j 64 chrome chrome_sandbox chromedriver.unstripped
}**

is the error expected for poky kirkstone & mickledore branches

@MaxIhlenfeldt
Copy link
Collaborator Author

@rjanani-p thanks for testing! I'm not sure I can help much with the runtime issues, maybe @rwmacleod knows more.

Regarding the build issues:

  • mickledore is EOL, I'm not sure we should spend time fixing errors specific to it.
  • kirkstone will currently not work due to chromium: use clang >= 16 #716.

@rjanani-p
Copy link

@rjanani-p thanks for testing! I'm not sure I can help much with the runtime issues, maybe @rwmacleod knows more.

Regarding the build issues:

  • mickledore is EOL, I'm not sure we should spend time fixing errors specific to it.
  • kirkstone will currently not work due to chromium: use clang >= 16 #716.

Thanks for the response @MaxIhlenfeldt , sure I will check with @rwmacleod .

@MaxIhlenfeldt
Copy link
Collaborator Author

@rjanani-p any updates on the runtime issues? m122 is already shipping to stable, so I'd like to get this PR merged and start working on the next version update.

@rjanani-p
Copy link

@MaxIhlenfeldt, I will work on it. I would like to inform; I am getting compilation issues for both poky nanbield and poky master branches for chromium-x11 package. Have you tried to build the chromium recently? for same pull request. I have observed that clang++ tried to compile the changes getting compilation issues. Here I am sharing the build issue snippet for reference, could you please share your input anything I need to add?

m/build_poky_master/tmp/work/cortexa15t2hf-neon-poky-linux-gnueabi/chromium-x11/121.0.6167.184/recipe-sysroot-native= -g1 -fvisibility-inlines-hidden -stdlib=libc++ -c ../../third_party/webrtc/pc/legacy_stats_collector.cc -o obj/third_party/webrtc/pc/legacy_stats_collector/legacy_stats_collector.o
| ../../third_party/webrtc/pc/legacy_stats_collector.cc:191:54: error: non-constant-expression cannot be narrowed from type 'double' to 'float' in initializer list [-Wc++11-narrowing-const-reference]
| 191 | {StatsReport::kStatsValueNameTotalAudioEnergy, info.total_output_energy},
| | ^~~~~~~~~~~~~~~~~~~~~~~~
| ../../third_party/webrtc/pc/legacy_stats_collector.cc:193:8: error: non-constant-expression cannot be narrowed from type 'double' to 'float' in initializer list [-Wc++11-narrowing-const-reference]
| 193 | info.total_output_duration}};
| | ^~~~~~~~~~~~~~~~~~~~~~~~~~
| ../../third_party/webrtc/pc/legacy_stats_collector.cc:247:54: error: non-constant-expression cannot be narrowed from type 'double' to 'float' in initializer list [-Wc++11-narrowing-const-reference]
| 247 | {StatsReport::kStatsValueNameTotalAudioEnergy, info.total_input_energy},
| | ^~~~~~~~~~~~~~~~~~~~~~~
| ../../third_party/webrtc/pc/legacy_stats_collector.cc:249:8: error: non-constant-expression cannot be narrowed from type 'double' to 'float' in initializer list [-Wc++11-narrowing-const-reference]
| 249 | info.total_input_duration}};
| | ^~~~~~~~~~~~~~~~~~~~~~~~~
| ../../third_party/webrtc/pc/legacy_stats_collector.cc:343:51: error: non-constant-expression cannot be narrowed from type 'uint32_t' (aka 'unsigned int') to 'int' in initializer list [-Wc++11-narrowing-const-reference]
| 343 | {StatsReport::kStatsValueNameFramesDecoded, info.frames_decoded},
| | ^~~~~~~~~~~~~~~~~~~
| ../../third_party/webrtc/pc/legacy_stats_collector.cc:386:52: error: type 'double' cannot be narrowed to 'int' in initializer list [-Wc++11-narrowing-const-reference]
| 386 | {StatsReport::kStatsValueNameFrameRateInput, round(info.framerate_input)},
| | ^~~~~~~~~~~~~~~~~~~~~~~~~~~
| ../../third_party/webrtc/pc/legacy_stats_collector.cc:389:51: error: non-constant-expression cannot be narrowed from type 'uint32_t' (aka 'unsigned int') to 'int' in initializer list [-Wc++11-narrowing-const-reference]
| 389 | {StatsReport::kStatsValueNameNacksReceived, info.nacks_received},
| | ^~~~~~~~~~~~~~~~~~~
| ../../third_party/webrtc/pc/legacy_stats_collector.cc:393:51: error: non-constant-expression cannot be narrowed from type 'uint32_t' (aka 'unsigned int') to 'int' in initializer list [-Wc++11-narrowing-const-reference]
| 393 | {StatsReport::kStatsValueNameFramesEncoded, info.frames_encoded},
| | ^~~~~~~~~~~~~~~~~~~
| ../../third_party/webrtc/pc/legacy_stats_collector.cc:394:52: error: non-constant-expression cannot be narrowed from type 'uint32_t' (aka 'unsigned int') to 'int' in initializer list [-Wc++11-narrowing-const-reference]
| 394 | {StatsReport::kStatsValueNameHugeFramesSent, info.huge_frames_sent},
| | ^~~~~~~~~~~~~~~~~~~~~
| 9 errors generated.
| [1055/36866] clang++ -MMD -MF yocto_native/obj/base/base/utf_offset_string_conversions.o.d -DBASE_IMPLEMENTATION -DIS_RAW_PTR_IMPL -DUSE_SYMBOLIZE -DUSE_UDEV

@VaginAY
Copy link

VaginAY commented Mar 12, 2024

Good day!

With Yocto master branch repositories and this commit, i get next error, when compile for arm64 :

energy_metrics_provider_linux.o
../../components/power_metrics/energy_metrics_provider_linux.cc:64:26: error: non-constant-expression cannot be narrowed from type 'long' to 'element_type' (aka 'int') in initializer list [-Wc++11-narrowing-const-reference]
   64 |   base::ScopedFD perf_fd{syscall(__NR_perf_event_open, perf_attr, /*pid=*/-1,
      |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   65 |                                  /*cpu=*/0, /*group_fd=*/-1,
      |                                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~
   66 |                                  PERF_FLAG_FD_CLOEXEC)};
      |                                  ~~~~~~~~~~~~~~~~~~~~~
1 error generated.

Clang version 18.1
For experiment, i tried to update to 121.0.6167.212 and get same error.

Any ideas?

@kraj
Copy link
Collaborator

kraj commented Mar 12, 2024

Good day!

With Yocto master branch repositories and this commit, i get next error, when compile for arm64 :

energy_metrics_provider_linux.o
../../components/power_metrics/energy_metrics_provider_linux.cc:64:26: error: non-constant-expression cannot be narrowed from type 'long' to 'element_type' (aka 'int') in initializer list [-Wc++11-narrowing-const-reference]
   64 |   base::ScopedFD perf_fd{syscall(__NR_perf_event_open, perf_attr, /*pid=*/-1,
      |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   65 |                                  /*cpu=*/0, /*group_fd=*/-1,
      |                                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~
   66 |                                  PERF_FLAG_FD_CLOEXEC)};
      |                                  ~~~~~~~~~~~~~~~~~~~~~
1 error generated.

Clang version 18.1 For experiment, i tried to update to 121.0.6167.212 and get same error.

Any ideas?

Please port https://cgit.freebsd.org/ports/commit/?id=4c36b9d0387620442dced802e25078a06fb930ce to meta-chromium

@MaxIhlenfeldt
Copy link
Collaborator Author

Please port https://cgit.freebsd.org/ports/commit/?id=4c36b9d0387620442dced802e25078a06fb930ce to meta-chromium

Done, thanks for finding the needed patches! @rjanani-p can you please try again to see if all compilation errors are fixed now?

@rjanani-p
Copy link

Please port https://cgit.freebsd.org/ports/commit/?id=4c36b9d0387620442dced802e25078a06fb930ce to meta-chromium

Done, thanks for finding the needed patches! @rjanani-p can you please try again to see if all compilation errors are fixed now?

sure @MaxIhlenfeldt, I will check and update the results.

@rjanani-p
Copy link

@MaxIhlenfeldt , I am getting below compilation issue for qemux86-64 target,

for both chromium-ozone-wayland && chromium-x11 recipes

-stdlib=libc++ -c ../../components/power_metrics/energy_metrics_provider_linux.cc -o obj/components/power_metrics/power_metrics/energy_metrics_provider_linux.o
| FAILED: obj/components/power_metrics/power_metrics/energy_metrics_provider_linux.o

poky-linux/chromium-x11/121.0.6167.184/chromium-121.0.6167.184/out/Release=/usr/src/debug/chromium-x11/121.0.6167.184 -fdebug-prefix-map=/buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-x11/121.0.6167.184/recipe-sysroot= -fmacro-prefix-map=/buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-x11/121.0.6167.184/recipe-sysroot= -fdebug-prefix-map=/buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-x11/121.0.6167.184/recipe-sysroot-native= -g1 -fvisibility-inlines-hidden -stdlib=libc++ -c ../../components/power_metrics/energy_metrics_provider_linux.cc -o obj/components/power_metrics/power_metrics/energy_metrics_provider_linux.o
| ../../components/power_metrics/energy_metrics_provider_linux.cc:64:26: **error: non-constant-expression cannot be narrowed from type 'long' to 'element_type' (aka 'int') in initializer list [-Wc++11-narrowing-const-reference]
| 64 | base::ScopedFD perf_fd{syscall(__NR_perf_event_open, perf_attr, /pid=/-1,
| | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| 65 | /cpu=/0, /group_fd=/-1,
| | ~~~~~~~~~~~~~~~~~~~~~~~~~~~
| 66 | PERF_FLAG_FD_CLOEXEC)};
| | ~~~~~~~~~~~~~~~~~~~~~**

| 1 error generated.

I will start compiling changes for poky nanbield, thank you.

@MaxIhlenfeldt
Copy link
Collaborator Author

Forgot to add the new backports to chromium-gn.inc 🤦 sorry, should be fixed now.

@VaginAY
Copy link

VaginAY commented Mar 15, 2024

Thank you very much for fix!

But after all is compiled, linker give me this error.

aarch64-pm-linux-ld.lld: error: undefined symbol: gl::NativeViewGLSurfaceEGL::NativeViewGLSurfaceEGL(gl::GLDisplayEGL*, void*, std::__1::unique_ptr<gfx::VSyncProvider, std::__1::default_delete<gfx::VSyncProvider>>) | >>> referenced by gl_surface_wayland.cc:35 (./../../ui/ozone/platform/wayland/gpu/gl_surface_wayland.cc:35) | >>> obj/ui/ozone/platform/wayland/wayland/chrome.lto.gl_surface_wayland.o:(ui::GLSurfaceWayland::GLSurfaceWayland(gl::GLDisplayEGL*, std::__1::unique_ptr<wl_egl_window, ui::EGLWindowDeleter>, ui::WaylandWindow*)) | aarch64-pm-linux-clang++: error: linker command failed with exit code 1 (use -v to see invocation) | ninja: build stopped: subcommand failed.

Clang 18.1 (i fix it, because 18.1.1 from master branch of meta-clang give new error on compilation}
imx8mp processor.
Patches from meta-imx doesn't help.

There was no error in the previous version of clang on 120 version of chromium with mickledore version of meta-openembedd and poky!

I had a similar problem when I tried to switch to version 123 on my own after finalizing all the patches.

@VaginAY
Copy link

VaginAY commented Mar 15, 2024

Last week NXP posted an update to their ecosystem to Nanbield and a new branch appeared in meta-imx.

I ran the build with it, but I see the following:

  1. clang version 17.0.6
  2. Chromium version downgraded to 117 from 120.
  3. New patches have appeared in the code. Six patches are aimed at correcting the situation I mentioned in the message above. Four of them are easily ported to version 121. But the remaining two, unfortunately, simply could not be ported.

I am attaching a set of patches. Perhaps there is an adaptation option.
ported_patches.zip
not_proted_patches.zip

@rjanani-p
Copy link

rjanani-p commented Mar 15, 2024

Forgot to add the new backports to chromium-gn.inc 🤦 sorry, should be fixed now.

@MaxIhlenfeldt ,I have completed the testing for Poky master with latest changes, sharing the results for reference:

  1. For chromium-x11 & qemux86-64 target: compiled successfully without build issues, able to check chromium version using qemux86-64 emulator

  2. For chromium-x11 & qemuarm target: compiled successfully without issues, to check chromium version using qemuarm emulator unable to check it due to curser / mouse is not working properly while operating with chromium browser

  3. For chromium-x11 & qemuarm64 target compiled successfully without build issues, able to check chromium version using qemuarm64 emulator

  4. for chromium-ozone-wayland & qemux86-64 target: getting compilation issue, sharing the log below for reference
    NOTE: Executing Tasks
    ERROR: chromium-ozone-wayland-121.0.6167.184-r0 do_compile: ExecutionError('/buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-ozone-wayland/121.0.6167.184/temp/run.do_compile.878508', 1, None, None)
    ERROR: Logfile of failure stored in: /buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-ozone-wayland/121.0.6167.184/temp/log.do_compile.878508
    Log data follows:
    | DEBUG: Executing shell function do_compile
    | ninja: error: '../../../recipe-sysroot-native/usr/lib/clang/latest/lib/linux/libclang_rt.builtins-x86_64.a', needed by 'yocto_native/obj/third_party/protobuf/libprotoc_lib.a', missing and no known rule to make it
    | WARNING: /buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-ozone-wayland/121.0.6167.184/temp/run.do_compile.878508:146 exit 1 from 'ninja -v -j 64 chrome chrome_sandbox chromedriver.unstripped'
    | WARNING: Backtrace (BB generated script):

  5. For chromium-ozone-wayland & qemuarm target: compiled successfully without build issues but getting runtime issue, when tried to check chromium version using chromium --no-sandbox 1.1.1.1 command

image

@rakuco
Copy link
Collaborator

rakuco commented Mar 15, 2024

@rakuco as already mentioned in #716 (comment), it's sadly not feasible to fix all the compile errors that occur on kirkstone due to using clang 14. I suppose that means we should remove kirkstone from LAYERSERIES_COMPAT for the time being, and add a note to the README that we're working on re-enabling kirkstone support for the latest version? Should we create a kirkstone branch pointing to 0fcfadc?

Given the above and #789, I think we'll have to stop supporting kirkstone for the time being. I agree with creating a branch as well.

@VaginAY
Copy link

VaginAY commented Mar 15, 2024

Forgot to add the new backports to chromium-gn.inc 🤦 sorry, should be fixed now.

@MaxIhlenfeldt ,I have completed the testing for Poky master with latest changes, sharing the results for reference:

1. **For chromium-x11 & qemux86-64 target:** compiled successfully without build issues, able to check chromium version using qemux86-64 emulator

2. **For chromium-x11 & qemuarm target:** compiled successfully without issues, to check chromium version using qemuarm emulator unable to check it due to curser / mouse is not working properly while operating with chromium browser

3. **For chromium-x11 & qemuarm64 target:**  working on it, will share the results once it is done

4. **for chromium-ozone-wayland & qemux86-64 target:** getting compilation issue, sharing the log below for reference
   **NOTE: Executing Tasks
   ERROR: chromium-ozone-wayland-121.0.6167.184-r0 do_compile: ExecutionError('/buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-ozone-wayland/121.0.6167.184/temp/run.do_compile.878508', 1, None, None)
   ERROR: Logfile of failure stored in: /buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-ozone-wayland/121.0.6167.184/temp/log.do_compile.878508
   Log data follows:
   | DEBUG: Executing shell function do_compile
   | ninja: error: '../../../recipe-sysroot-native/usr/lib/clang/latest/lib/linux/libclang_rt.builtins-x86_64.a', needed by 'yocto_native/obj/third_party/protobuf/libprotoc_lib.a', missing and no known rule to make it
   | WARNING: /buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-ozone-wayland/121.0.6167.184/temp/run.do_compile.878508:146 exit 1 from 'ninja -v -j 64 chrome chrome_sandbox chromedriver.unstripped'
   | WARNING: Backtrace (BB generated script):**

5. **For chromium-ozone-wayland & qemuarm target:** compiled successfully without build issues but getting runtime issue, when tried to check chromium version using chromium --no-sandbox 1.1.1.1 command
image

I got problem 4 when I tried to compile chromium with clang version 18.1.1, version 18.1.0 does not have the problem.

@kraj
Copy link
Collaborator

kraj commented Mar 15, 2024

clang does not install anything under recipe-sysroot-native/usr/lib/clang/latest/ so where is this latest coming from ?
perhaps thats causing the problem if its being created by chromium, because it should always create it and not create
it only first time because compilers will upgrade and version will change, the code adding it has to account for that

@VaginAY
Copy link

VaginAY commented Mar 16, 2024

imx-patches.zip

It works.
Here is my setup for compiling chromium 121 for imx8mp. Maybe it will be useful

@MaxIhlenfeldt thank you for your work

@VaginAY
Copy link

VaginAY commented Mar 16, 2024

clang does not install anything under recipe-sysroot-native/usr/lib/clang/latest/ so where is this latest coming from ? perhaps thats causing the problem if its being created by chromium, because it should always create it and not create it only first time because compilers will upgrade and version will change, the code adding it has to account for that

I got this issue when i add master branch to my manifest without revision and meta-clang automatically takes from latest master branch commit. When i set revision in manifest to eebe4ff2e539f3ffb01c5060cc4ca8b226ea8b52 commit (lksctp-tools: Reset SECURITY_STACK_PROTECTOR with clang) , last before bump to 18.1.1 version, all is good.

@kraj
Copy link
Collaborator

kraj commented Mar 16, 2024

clang does not install anything under recipe-sysroot-native/usr/lib/clang/latest/ so where is this latest coming from ? perhaps thats causing the problem if its being created by chromium, because it should always create it and not create it only first time because compilers will upgrade and version will change, the code adding it has to account for that

I got this issue when i add master branch to my manifest without revision and meta-clang automatically takes from latest master branch commit. When i set revision in manifest to eebe4ff2e539f3ffb01c5060cc4ca8b226ea8b52 commit (lksctp-tools: Reset SECURITY_STACK_PROTECTOR with clang) , last before bump to 18.1.1 version, all is good.

it is not a clang problem as fas as I can tell. Look into how chromium recipe munges with sysroot.

@MaxIhlenfeldt MaxIhlenfeldt linked an issue Mar 18, 2024 that may be closed by this pull request
@MaxIhlenfeldt
Copy link
Collaborator Author

clang does not install anything under recipe-sysroot-native/usr/lib/clang/latest/ so where is this latest coming from ?

This is done by us, in the do_add_clang_symlink task. iiuc the way we currently do that may not play well with a clang version update?

In any case, the issue is separate from this update PR, please file an issue where we can track it. @VaginAY

@MaxIhlenfeldt
Copy link
Collaborator Author

@rjanani-p does the ninja: error: '../../../recipe-sysroot-native/usr/lib/clang/latest/lib/linux/libclang_rt.builtins-x86_64.a', needed by 'yocto_native/obj/third_party/protobuf/libprotoc_lib.a', missing and no known rule to make it happen on a full, clean re-build? If yes, does the recipe-sysroot-native/usr/lib/clang/latest symlink exist, and if so, where does it point to?

Finally, is this specific to this update, or does the issue also happen when you build c76bc3a (the latest commit on master)? If it's unrelated, we might be able to go ahead with this PR and fix the issue separately.

@rjanani-p
Copy link

recipe-sysroot-native/usr/lib/clang/latest/lib/linux/

let me cross check the issue with clean rebuild and I am facing issue with MaxIhlenfeldt:121.0.6167.184 code changes and I haven't tested with meta-browser master branch recently. I will check with meta-browser master branch too.

@VaginAY
Copy link

VaginAY commented Mar 18, 2024

clang does not install anything under recipe-sysroot-native/usr/lib/clang/latest/ so where is this latest coming from ?

This is done by us, in the do_add_clang_symlink task. iiuc the way we currently do that may not play well with a clang version update?

In any case, the issue is separate from this update PR, please file an issue where we can track it. @VaginAY

issue created

@rjanani-p
Copy link

Please port https://cgit.freebsd.org/ports/commit/?id=4c36b9d0387620442dced802e25078a06fb930ce to meta-chromium

Done, thanks for finding the needed patches! @rjanani-p can you please try again to see if all compilation errors are fixed now?

@MaxIhlenfeldt ,I have completed the testing for Poky nanbield with latest changes, sharing the results for reference:

  1. For chromium-x11 & qemux86-64 target: compiled successfully without build issues, able to check chromium version using qemux86-64 emulator

  2. For chromium-x11 & qemuarm target: compiled successfully without issues, to check chromium version using qemuarm emulator unable to check it due to curser / mouse functionality is not working properly while operating with chromium browser

  3. For chromium-x11 & qemuarm64 target: compiled successfully without build issues, able to check chromium version using qemuarm64 emulator

  4. For chromium-ozone-wayland & qemux86-64 target: compiled successfully without build issues, able to check chromium version using qemux86-64 emulator

@rjanani-p
Copy link

@rjanani-p does the ninja: error: '../../../recipe-sysroot-native/usr/lib/clang/latest/lib/linux/libclang_rt.builtins-x86_64.a', needed by 'yocto_native/obj/third_party/protobuf/libprotoc_lib.a', missing and no known rule to make it happen on a full, clean re-build? If yes, does the recipe-sysroot-native/usr/lib/clang/latest symlink exist, and if so, where does it point to?

Finally, is this specific to this update, or does the issue also happen when you build c76bc3a (the latest commit on master)? If it's unrelated, we might be able to go ahead with this PR and fix the issue separately.

  1. I have cross checked the issue with clean build ,issue is not occurred after clean build, didn't get build issue for chromium-ozone-wayland recipe for x86_64 target for poky master branch. I have used the MaxIhlenfeldt:121.0.6167.184 for meta-browser layer and for dependent layers used master branch.
  2. Also, cross checked the issue with meta-browser master branch +for dependent layers also used master branch commits, for this getting below compilation issues.

FAILED: prebuilt_rustc_sysroot/lib/rustlib/x86_64-poky-linux-gnu/lib/libprofiler_builtins.rlib
ln -f obj/build/rust/std/lib/libprofiler_builtins.rlib prebuilt_rustc_sysroot/lib/rustlib/x86_64-poky-linux-gnu/lib/libprofiler_builtins.rlib 2>/dev/null || (rm -rf prebuilt_rustc_sysroot/lib/rustlib/x86_64-poky-linux-gnu/lib/libprofiler_builtins.rlib && cp -af obj/build/rust/std/lib/libprofiler_builtins.rlib prebuilt_rustc_sysroot/lib/rustlib/x86_64-poky-linux-gnu/lib/libprofiler_builtins.rlib)
cp: cannot stat 'obj/build/rust/std/lib/libprofiler_builtins.rlib': No such file or directory

/buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-ozone-wayland/120.0.6099.224/chromium-120.0.6099.224/tools/metrics/histograms/../common/models.py:260: SyntaxWarning: invalid escape sequence '\w'
"""A complex node type that has attributes or other nodes as children.
ninja: build stopped: subcommand failed.
WARNING: /buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-ozone-wayland/120.0.6099.224/temp/run.do_compile.3187182:146 exit 1 from 'ninja -v -j 64 chrome chrome_sandbox chromedriver.unstripped'
WARNING: Backtrace (BB generated script):
#1: do_compile, /buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-ozone-wayland/120.0.6099.224/temp/run.do_compile.3187182, line 146
#2: main, /buildarea/eng1/rpandi/wrkspc/chromium/buildchromium/build_poky_master/tmp/work/core2-64-poky-linux/chromium-ozone-wayland/120.0.6099.224/temp/run.do_compile.3187182, line 150

please find build log and could please check, is these are expected results for if we are building with meta-browser master branch.

@MaxIhlenfeldt
Copy link
Collaborator Author

@rjanani-p thanks for testing!

Regarding the remaining libprofiler_builtins.rlib build error with the current master branch, that is indeed expected, and is fixed by 0019-Don-t-require-profiler_builtins.rlib.patch, which this PR introduces.

@MaxIhlenfeldt
Copy link
Collaborator Author

Given that all m121-specific issues seem to have been resolved by now, I'll go ahead and merge this.

Release notes:
    https://chromereleases.googleblog.com/2024/01/stable-channel-update-for-desktop_23.html
    https://chromereleases.googleblog.com/2024/01/stable-channel-update-for-desktop_30.html
    https://chromereleases.googleblog.com/2024/02/stable-channel-update-for-desktop.html
    https://chromereleases.googleblog.com/2024/02/stable-channel-update-for-desktop_13.html

Build and patch changes:
------------------------

Drop five backported patches that are included upstream now, and add
three new backports.

Drop arm/0002-Fix-ARM-build-with-recent-glibc.patch as
https://crrev.com/c/5035139 includes an equivalent patch.

Add 0019-Don-t-require-profiler_builtins.rlib.patch to fix a build error
when using OE master.

Rebase and renumber remaining patches.

License changes:
----------------

Added licenses:
  * third_party/lit/LICENSE
  - https://chromium-review.googlesource.com/c/chromium/src/+/5046161

Removed licenses:
  * base/third_party/xdg_mime/LICENSE
  - https://chromium-review.googlesource.com/c/chromium/src/+/4996430

  * native_client/LICENSE
  - not sure which change caused this, but we don't use NativeClient anyways

Updated licenses:
  * third_party/libxml/src/Copyright
  - https://chromium-review.googlesource.com/c/chromium/src/+/4985186

Test-built (big thanks to @rjanani-p):
--------------------------------------

* chromium-ozone-wayland:
 - master, clang,   MACHINE=qemuarm, qemux86-64
 - nanbield, clang, MACHINE=qemuarm64, qemux86-64

* chromium-x11:
 - master, clang,   MACHINE=qemuarm, qemuarm64, qemux86-64
 - nanbield, clang, MACHINE=qemuarm, qemuarm64, qemux86-64

Signed-off-by: Max Ihlenfeldt <max@igalia.com>
@MaxIhlenfeldt MaxIhlenfeldt merged commit 7facbf6 into OSSystems:master Mar 20, 2024
MaxIhlenfeldt added a commit to MaxIhlenfeldt/meta-browser that referenced this pull request May 8, 2024
Fixes OSSystems#792.

Build and patch changes:
------------------------

In OSSystems#782, we decided to depend on rust instead of libstd-rs, because the
latter didn't include libprofiler_builtins and also used a naming scheme
that trips up Chromium.

However, in OSSystems#791 we decided to patch Chromium so that it doesn't need
libprofiler_builtins any more, because the master version of the rust
recipe also doesn't include it.

Finally, while investigating OSSystems#792 it turned out that our approach breaks
as soon as we have something that depends on libstd-rs in our dependency
graph. In that scenario, both libstd-rs and rust (the latter due to our
bbappend file) install Rust libraries to /usr/lib/rustlib. This first
leads to Chromium build system errors (due to libstd-rs's naming
scheme), and after fixing these to Rust compiler errors due to multiple
versions being present.

The conclusion is now that we can depend on libstd-rs we should do so.
This only requires a small change to Chromium's Rust build scripts to
adapt them to the slightly different naming scheme.

License changes:
----------------

Added licenses: none.

Removed licenses: none.

Updated licenses: none.

Test-built:
-----------

* chromium-wayland:
 - nanbield, clang, MACHINE=qemuarm64

* chromium-x11:
 - master, clang,   MACHINE=qemuarm

Signed-off-by: Max Ihlenfeldt <max@igalia.com>
MaxIhlenfeldt added a commit to MaxIhlenfeldt/meta-browser that referenced this pull request May 8, 2024
Fixes OSSystems#792.

Build and patch changes:
------------------------

In OSSystems#782, we decided to depend on rust instead of libstd-rs, because the
latter didn't include libprofiler_builtins and also used a naming scheme
that trips up Chromium.

However, in OSSystems#791 we decided to patch Chromium so that it doesn't need
libprofiler_builtins any more, because the master version of the rust
recipe also doesn't include it.

Finally, while investigating OSSystems#792 it turned out that our approach breaks
as soon as we have something that depends on libstd-rs in our dependency
graph. In that scenario, both libstd-rs and rust (the latter due to our
bbappend file) install Rust libraries to /usr/lib/rustlib. This first
leads to Chromium build system errors (due to libstd-rs's naming
scheme), and after fixing these to Rust compiler errors due to multiple
versions being present.

The conclusion is now that we can depend on libstd-rs we should do so.
This only requires a small change to Chromium's Rust build scripts to
adapt them to the slightly different naming scheme.

License changes:
----------------

Added licenses: none.

Removed licenses: none.

Updated licenses: none.

Test-built:
-----------

* chromium-wayland:
 - nanbield, clang, MACHINE=qemuarm64

* chromium-x11:
 - master, clang,   MACHINE=qemuarm

Signed-off-by: Max Ihlenfeldt <max@igalia.com>
MaxIhlenfeldt added a commit to MaxIhlenfeldt/meta-browser that referenced this pull request May 8, 2024
Fixes OSSystems#792.

Build and patch changes:
------------------------

In OSSystems#782, we decided to depend on rust instead of libstd-rs, because the
latter didn't include libprofiler_builtins and also used a naming scheme
that trips up Chromium.

However, in OSSystems#791 we decided to patch Chromium so that it doesn't need
libprofiler_builtins any more, because the master version of the rust
recipe also doesn't include it.

Finally, while investigating OSSystems#792 it turned out that our approach breaks
as soon as we have something that depends on libstd-rs in our dependency
graph. In that scenario, both libstd-rs and rust (the latter due to our
bbappend file) install Rust libraries to /usr/lib/rustlib. This first
leads to Chromium build system errors (due to libstd-rs's naming
scheme), and after fixing these to Rust compiler errors due to multiple
versions being present.

The conclusion is now that we can depend on libstd-rs we should do so.
This only requires a small change to Chromium's Rust build scripts to
adapt them to the slightly different naming scheme.

License changes:
----------------

Added licenses: none.

Removed licenses: none.

Updated licenses: none.

Test-built:
-----------

* chromium-wayland:
 - nanbield, clang, MACHINE=qemuarm64

* chromium-x11:
 - master, clang,   MACHINE=qemuarm

Signed-off-by: Max Ihlenfeldt <max@igalia.com>
MaxIhlenfeldt added a commit that referenced this pull request May 13, 2024
chromium: Depend on libstd-rs instead of rust

Fixes #792.

Build and patch changes:
------------------------

In #782, we decided to depend on rust instead of libstd-rs, because the
latter didn't include libprofiler_builtins and also used a naming scheme
that trips up Chromium.

However, in #791 we decided to patch Chromium so that it doesn't need
libprofiler_builtins any more, because the master version of the rust
recipe also doesn't include it.

Finally, while investigating #792 it turned out that our approach breaks
as soon as we have something that depends on libstd-rs in our dependency
graph. In that scenario, both libstd-rs and rust (the latter due to our
bbappend file) install Rust libraries to /usr/lib/rustlib. This first
leads to Chromium build system errors (due to libstd-rs's naming
scheme), and after fixing these to Rust compiler errors due to multiple
versions being present.

The conclusion is now that we can depend on libstd-rs we should do so.
This only requires a small change to Chromium's Rust build scripts to
adapt them to the slightly different naming scheme.

Also, while we're already reworking our Rust setup, we can remove the
remaining part of our bbappend for the rust recipe and instead inherit
the `rust-common` class, thereby inheriting `rust-target-config` (which
needs stuff from `rust-common`). This means we get the `target.json`
files the Rust compiler needs installed in the directory pointed to by
the `RUST_TARGET_PATH` environment variable.

License changes:
----------------

Added licenses: none.

Removed licenses: none.

Updated licenses: none.

Test-built:
-----------

* chromium-wayland:
 - nanbield, clang, MACHINE=qemuarm64

* chromium-x11:
 - master, clang,   MACHINE=qemuarm

Signed-off-by: Max Ihlenfeldt <max@igalia.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Chromium 120.0.6099.224 fails to build with master OE Update to Chromium 121
5 participants