libjxl 0.8.1's 'cjxl' can losslessly convert a regular JPEG image to JPEG XL format. The resulting .jxl file has Exif metadata compressed using the Brotli algorithm. exiftool supports reading Brotli-compressed Exif metadata, but it needs an additional Perl module installed. (dev-perl/IO-Compress-Brotli) This patch adds a brotli USE flag and adds dev-perl/IO-Compress-Brotli as a runtime dependency. Reproducible: Always Steps to Reproduce: 1. Convert a JPEG image to JPEG XL using `cjxl`. 2. Attempt to view metadata using `exiftool file.jxl`. Actual Results: `exiftool` shows: Warning : Install IO::Uncompress::Brotli to decode Brotli-compressed metadata Expected Results: `exiftool` shows the JPEG XL metadata.
Created attachment 872189 [details, diff] exiftool-12.64: Add brotli USE flag
It would seem very non-obvious by USE=brotli enabling JPEG XL features in packages. USE=jpegxl is an established flag for that purpose.
Created attachment 872219 [details, diff] exiftool-12.64: Add jpegxl USE flag I used brotli as the USE flag because exiftool does support some JPEG XL functionality without it, but shows a warning that IO::Compress::Brotli is needed for full metadata spuport. Since it's mainly used for JPEG XL, it does make sense to rename it. Attached is the same patch as before but with USE=jpegxl instead of USE=brotli.
exiftool depends on optional Perl libraries. # exiftool -ver -v ExifTool version 12.76 Perl version 5.040000 (-C0) Platform: linux Optional libraries: Archive::Zip (not installed) Compress::Zlib 2.212 Digest::MD5 2.58_01 Digest::SHA 6.04 IO::Compress::Bzip2 2.212 Time::Piece 1.3401_01 Time::Local 1.35 Unicode::LineBreak 2019.001 Compress::Raw::Lzma (not installed) IO::Compress::RawDeflate 2.212 IO::Uncompress::RawInflate 2.212 IO::Compress::Brotli (not installed) IO::Uncompress::Brotli (not installed) Maybe to keep ebuild maintenance low. Use single USE flag 'minimal' to NOT pull all optional perl libraries. Default should be to pull all optional Perl libraries.