uazo / cromite

Cromite a Bromite fork with ad blocking and privacy enhancements; take back your browser!
https://www.cromite.org/
GNU General Public License v3.0
3.58k stars 86 forks source link

JXL and adblock_update_service do not compile #1552

Closed Kawanaao closed 1 month ago

Kawanaao commented 1 month ago

Hello! Recently I wanted to compile cromite for Gentoo, glibc and encountered a problem, jxl seems to require an upgrade, because: ImageDecoder() in Add-jxl-support requires 5 arguments, not 4

https://github.com/uazo/cromite/blob/d13f5bbd7f877685e62e09e6a5f7c72d2274e374/build/patches/Add-support-to-jxl.patch#L827-L830

../../third_party/blink/renderer/platform/image-decoders/jxl/jxl_image_decoder.cc:66:7: error: no matching constructor for initialization of 'ImageDecoder'
   66 |     : ImageDecoder(alpha_option,
      |       ^            ~~~~~~~~~~~~~
   67 |                    high_bit_depth_decoding_option,
      |                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   68 |                    color_behavior,
      |                    ~~~~~~~~~~~~~~~
   69 |                    max_decoded_bytes) {
      |                    ~~~~~~~~~~~~~~~~~
../../third_party/blink/renderer/platform/image-decoders/image_decoder.h:455:3: note: candidate constructor not viable: requires 5 arguments, but 4 were provided
  455 |   ImageDecoder(AlphaOption alpha_option,
      |   ^            ~~~~~~~~~~~~~~~~~~~~~~~~~
  456 |                HighBitDepthDecodingOption high_bit_depth_decoding_option,
      |                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  457 |                ColorBehavior color_behavior,
      |                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  458 |                cc::AuxImage aux_image,
      |                ~~~~~~~~~~~~~~~~~~~~~~~
  459 |                wtf_size_t max_decoded_bytes);
      |                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Chromium - 129.0.6668.100 Cromite commit - 5a4953031c9c9322dda2d3bba3ef23d33c753005

Kawanaao commented 1 month ago

When I removed the flag for jxl support, another error appeared in the Bromite-subresource-adblocker.patch patch, apparently the service relies on a .h file, which is initially broken for some reason, I checked now while building chromium, checked the chromium source tree and the file 'content/common/buildflags.h' was missing everywhere, maybe no one just referenced render_process_host.h? or do I need to enable some flag to generate buildflags.h?

In file included from ../../components/component_updater/adblock_updater_service.cc:18:
In file included from ../../components/component_updater/adblock_updater_service.h:34:
In file included from ../../components/subresource_filter/content/shared/browser/ruleset_service.h:47:
In file included from ../../components/subresource_filter/content/shared/browser/ruleset_publisher.h:20:
../../content/public/browser/render_process_host.h:25:10: fatal error: 'content/common/buildflags.h' file not found
   25 | #include "content/common/buildflags.h"
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
uazo commented 1 month ago

Hello! Recently I wanted to compile cromite for Gentoo, glibc and encountered a problem, jxl seems to require an upgrade, because: ImageDecoder() in Add-jxl-support requires 5 arguments, not 4

sorry, although those problems are easily solved, I do not recommend compiling cromite with jxl for now. there is a problem of potential skia insecurity to be solved first. see https://github.com/uazo/cromite/issues/1365

When I removed the flag for jxl support, another error appeared in the Bromite-subresource-adblocker.patch patch,

I got that error with 130, what are you building? I solved this with the v130 patches, wait for it to come out.

uazo commented 1 month ago

these are the changes required:

https://github.com/uazo/cromite/commit/24a8567895389c741ab6f5e9cb13412b92034819#diff-cac73ff22d668162efecc67f752f52bc9538e27398e7ce8fb7d05d017c953b92R784-R788

I close the issue because jxl will be reactivated with https://github.com/uazo/cromite/issues/1365