https://bugs.kde.org/show_bug.cgi?id=478987

            Bug ID: 478987
           Summary: Fails to build against libjxl 0.9
    Classification: Applications
           Product: krita
           Version: 5.2.2
          Platform: Other
                OS: Other
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: General
          Assignee: krita-bugs-n...@kde.org
          Reporter: reiter.christ...@gmail.com
  Target Milestone: ---

The last libjxl release removed some deprecated things and changed API/ABI in
some places: https://github.com/libjxl/libjxl/releases/tag/v0.9.0

The build currently fails like this (there might be more issues):

-----
C:/msys64/home/user/M/mingw-w64-krita/src/krita-5.2.2/plugins/impex/jxl/JPEGXLImport.cpp:513:20:
error: no matching function for call to 'JxlDecoderGetColorAsEncodedProfile'
  513 |                 == JxlDecoderGetColorAsEncodedProfile(dec.get(),
      |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:/msys64/clang64/include/jxl/decode.h:749:29: note: candidate function not
viable: requires 3 arguments, but 4 were provided
  749 | JXL_EXPORT JxlDecoderStatus JxlDecoderGetColorAsEncodedProfile(
      |                             ^
  750 |     const JxlDecoder* dec, JxlColorProfileTarget target,
      |     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  751 |     JxlColorEncoding* color_encoding);
      |     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/user/M/mingw-w64-krita/src/krita-5.2.2/plugins/impex/jxl/JPEGXLImport.cpp:638:24:
error: no matching function for call to 'JxlDecoderGetICCProfileSize'
  638 |                     != JxlDecoderGetICCProfileSize(dec.get(), nullptr,
JXL_COLOR_PROFILE_TARGET_DATA, &iccSize)) {
      |                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~
C:/msys64/clang64/include/jxl/decode.h:775:29: note: candidate function not
viable: requires 3 arguments, but 4 were provided
  775 | JXL_EXPORT JxlDecoderStatus JxlDecoderGetICCProfileSize(
      |                             ^
  776 |     const JxlDecoder* dec, JxlColorProfileTarget target, size_t* size);
      |     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/user/M/mingw-w64-krita/src/krita-5.2.2/plugins/impex/jxl/JPEGXLImport.cpp:645:24:
error: no matching function for call to 'JxlDecoderGetColorAsICCProfile'
  645 |                     != JxlDecoderGetColorAsICCProfile(dec.get(),
      |                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:/msys64/clang64/include/jxl/decode.h:793:29: note: candidate function not
viable: requires 4 arguments, but 5 were provided
  793 | JXL_EXPORT JxlDecoderStatus JxlDecoderGetColorAsICCProfile(
      |                             ^
  794 |     const JxlDecoder* dec, JxlColorProfileTarget target, uint8_t*
icc_profile,
      |    
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  795 |     size_t size);
      |     ~~~~~~~~~~~
C:/msys64/home/user/M/mingw-w64-krita/src/krita-5.2.2/plugins/impex/jxl/JPEGXLImport.cpp:659:28:
error: no matching function for call to 'JxlDecoderGetICCProfileSize'
  659 |                         != JxlDecoderGetICCProfileSize(dec.get(),
      |                            ^~~~~~~~~~~~~~~~~~~~~~~~~~~
C:/msys64/clang64/include/jxl/decode.h:775:29: note: candidate function not
viable: requires 3 arguments, but 4 were provided
  775 | JXL_EXPORT JxlDecoderStatus JxlDecoderGetICCProfileSize(
      |                             ^
  776 |     const JxlDecoder* dec, JxlColorProfileTarget target, size_t* size);
      |     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/user/M/mingw-w64-krita/src/krita-5.2.2/plugins/impex/jxl/JPEGXLImport.cpp:669:28:
error: no matching function for call to 'JxlDecoderGetColorAsICCProfile'
  669 |                         != JxlDecoderGetColorAsICCProfile(dec.get(),
      |                            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:/msys64/clang64/include/jxl/decode.h:793:29: note: candidate function not
viable: requires 4 arguments, but 5 were provided
  793 | JXL_EXPORT JxlDecoderStatus JxlDecoderGetColorAsICCProfile(
      |                             ^
  794 |     const JxlDecoder* dec, JxlColorProfileTarget target, uint8_t*
icc_profile,
      |    
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  795 |     size_t size);
      |     ~~~~~~~~~~~
5 errors generated.
-----

Here is how other projects deal with the API differences, as an example:
https://gitlab.gnome.org/GNOME/gimp/-/merge_requests/970/diffs

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to