* [Buildroot] [PATCH 2/3] package/libjxl: disable benchmark and tests
2023-02-19 14:00 [Buildroot] [PATCH 1/3] package/libjxl: fix build with libjpeg Fabrice Fontaine
@ 2023-02-19 14:00 ` Fabrice Fontaine
2023-02-19 14:00 ` [Buildroot] [PATCH 3/3] package/libjxl: security bump to version 0.8.1 Fabrice Fontaine
` (2 subsequent siblings)
3 siblings, 0 replies; 7+ messages in thread
From: Fabrice Fontaine @ 2023-02-19 14:00 UTC (permalink / raw)
To: buildroot; +Cc: Julien Olivain, Fabrice Fontaine
Disable benchmark and tests which are enabled by default since the
addition of the package in commit
e648d399d8bd609697e78f13f7fa76be06d91a57
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
package/libjxl/libjxl.mk | 2 ++
1 file changed, 2 insertions(+)
diff --git a/package/libjxl/libjxl.mk b/package/libjxl/libjxl.mk
index 02a93ac5d9..77405e4f11 100644
--- a/package/libjxl/libjxl.mk
+++ b/package/libjxl/libjxl.mk
@@ -23,7 +23,9 @@ endif
LIBJXL_CONF_OPTS = \
-DJPEGXL_BUNDLE_LIBPNG=OFF \
-DJPEGXL_BUNDLE_SKCMS=OFF \
+ -DJPEGXL_ENABLE_BENCHMARK=OFF \
-DJPEGXL_ENABLE_DOXYGEN=OFF \
+ -DJPEGXL_ENABLE_EXAMPLES=OFF \
-DJPEGXL_ENABLE_JNI=OFF \
-DJPEGXL_ENABLE_MANPAGES=OFF \
-DJPEGXL_ENABLE_OPENEXR=OFF \
--
2.39.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 7+ messages in thread* [Buildroot] [PATCH 3/3] package/libjxl: security bump to version 0.8.1
2023-02-19 14:00 [Buildroot] [PATCH 1/3] package/libjxl: fix build with libjpeg Fabrice Fontaine
2023-02-19 14:00 ` [Buildroot] [PATCH 2/3] package/libjxl: disable benchmark and tests Fabrice Fontaine
@ 2023-02-19 14:00 ` Fabrice Fontaine
2023-02-19 15:37 ` Julien Olivain
2023-02-19 15:30 ` [Buildroot] [PATCH 1/3] package/libjxl: fix build with libjpeg Julien Olivain
2023-02-20 20:51 ` Thomas Petazzoni via buildroot
3 siblings, 1 reply; 7+ messages in thread
From: Fabrice Fontaine @ 2023-02-19 14:00 UTC (permalink / raw)
To: buildroot; +Cc: Julien Olivain, Fabrice Fontaine
Security: Fix OOB read in exif.h
https://github.com/libjxl/libjxl/releases/tag/v0.8.1
https://github.com/libjxl/libjxl/releases/tag/v0.8.0
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
package/libjxl/libjxl.hash | 2 +-
package/libjxl/libjxl.mk | 10 +++++++---
2 files changed, 8 insertions(+), 4 deletions(-)
diff --git a/package/libjxl/libjxl.hash b/package/libjxl/libjxl.hash
index e71d32e61d..6b4c9d8d0a 100644
--- a/package/libjxl/libjxl.hash
+++ b/package/libjxl/libjxl.hash
@@ -1,4 +1,4 @@
# Locally computed:
-sha256 3114bba1fabb36f6f4adc2632717209aa6f84077bc4e93b420e0d63fa0455c5e libjxl-0.7.0.tar.gz
+sha256 60f43921ad3209c9e180563025eda0c0f9b1afac51a2927b9ff59fff3950dc56 libjxl-0.8.1.tar.gz
sha256 8405932022a556380c2d8c272eff154a923feb197233f348ce5f7334fb0a5ede LICENSE
sha256 91915f8ae056a68a3c5bdf05d9f6f78bb6903e27a8ca3a8434c9e4ac87300575 PATENTS
diff --git a/package/libjxl/libjxl.mk b/package/libjxl/libjxl.mk
index 77405e4f11..095dc06764 100644
--- a/package/libjxl/libjxl.mk
+++ b/package/libjxl/libjxl.mk
@@ -4,7 +4,7 @@
#
################################################################################
-LIBJXL_VERSION = 0.7.0
+LIBJXL_VERSION = 0.8.1
LIBJXL_SITE = $(call github,libjxl,libjxl,v$(LIBJXL_VERSION))
LIBJXL_LICENSE = BSD-3-Clause
LIBJXL_LICENSE_FILES = LICENSE PATENTS
@@ -34,9 +34,13 @@ LIBJXL_CONF_OPTS = \
ifeq ($(BR2_PACKAGE_JPEG_TURBO),y)
LIBJXL_DEPENDENCIES += jpeg-turbo
-LIBJXL_CONF_OPTS += -DJPEGXL_ENABLE_TOOLS=ON
+LIBJXL_CONF_OPTS += \
+ -DJPEGXL_ENABLE_JPEGLI=ON \
+ -DJPEGXL_ENABLE_TOOLS=ON
else
-LIBJXL_CONF_OPTS += -DJPEGXL_ENABLE_TOOLS=OFF
+LIBJXL_CONF_OPTS += \
+ -DJPEGXL_ENABLE_JPEGLI=OFF \
+ -DJPEGXL_ENABLE_TOOLS=OFF
endif
$(eval $(cmake-package))
--
2.39.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [Buildroot] [PATCH 3/3] package/libjxl: security bump to version 0.8.1
2023-02-19 14:00 ` [Buildroot] [PATCH 3/3] package/libjxl: security bump to version 0.8.1 Fabrice Fontaine
@ 2023-02-19 15:37 ` Julien Olivain
0 siblings, 0 replies; 7+ messages in thread
From: Julien Olivain @ 2023-02-19 15:37 UTC (permalink / raw)
To: Fabrice Fontaine; +Cc: buildroot
Hi Fabrice,
On 19/02/2023 15:00, Fabrice Fontaine wrote:
> Security: Fix OOB read in exif.h
>
> https://github.com/libjxl/libjxl/releases/tag/v0.8.1
> https://github.com/libjxl/libjxl/releases/tag/v0.8.0
>
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> ---
> package/libjxl/libjxl.hash | 2 +-
> package/libjxl/libjxl.mk | 10 +++++++---
> 2 files changed, 8 insertions(+), 4 deletions(-)
>
> diff --git a/package/libjxl/libjxl.hash b/package/libjxl/libjxl.hash
> index e71d32e61d..6b4c9d8d0a 100644
> --- a/package/libjxl/libjxl.hash
> +++ b/package/libjxl/libjxl.hash
> @@ -1,4 +1,4 @@
> # Locally computed:
> -sha256
> 3114bba1fabb36f6f4adc2632717209aa6f84077bc4e93b420e0d63fa0455c5e
> libjxl-0.7.0.tar.gz
> +sha256
> 60f43921ad3209c9e180563025eda0c0f9b1afac51a2927b9ff59fff3950dc56
> libjxl-0.8.1.tar.gz
> sha256
> 8405932022a556380c2d8c272eff154a923feb197233f348ce5f7334fb0a5ede
> LICENSE
> sha256
> 91915f8ae056a68a3c5bdf05d9f6f78bb6903e27a8ca3a8434c9e4ac87300575
> PATENTS
> diff --git a/package/libjxl/libjxl.mk b/package/libjxl/libjxl.mk
> index 77405e4f11..095dc06764 100644
> --- a/package/libjxl/libjxl.mk
> +++ b/package/libjxl/libjxl.mk
> @@ -4,7 +4,7 @@
> #
>
> ################################################################################
>
> -LIBJXL_VERSION = 0.7.0
> +LIBJXL_VERSION = 0.8.1
When bumping to version 0.8.1, I observed a segmentation fault crash
while
running the package runtime test with the command:
support/testing/run-tests \
-d dl -o output_folder \
tests.package.test_libjxl
The issue happen only when the libjxl tools are enabled AND there is
no jpeg support enabled.
I have a pull-request upstream which is not merged yet, at:
https://github.com/libjxl/libjxl/pull/2178
Maybe this patch could be included, to make sure the runtime test
will still work?
> LIBJXL_SITE = $(call github,libjxl,libjxl,v$(LIBJXL_VERSION))
> LIBJXL_LICENSE = BSD-3-Clause
> LIBJXL_LICENSE_FILES = LICENSE PATENTS
> @@ -34,9 +34,13 @@ LIBJXL_CONF_OPTS = \
>
> ifeq ($(BR2_PACKAGE_JPEG_TURBO),y)
> LIBJXL_DEPENDENCIES += jpeg-turbo
> -LIBJXL_CONF_OPTS += -DJPEGXL_ENABLE_TOOLS=ON
> +LIBJXL_CONF_OPTS += \
> + -DJPEGXL_ENABLE_JPEGLI=ON \
> + -DJPEGXL_ENABLE_TOOLS=ON
> else
> -LIBJXL_CONF_OPTS += -DJPEGXL_ENABLE_TOOLS=OFF
> +LIBJXL_CONF_OPTS += \
> + -DJPEGXL_ENABLE_JPEGLI=OFF \
> + -DJPEGXL_ENABLE_TOOLS=OFF
> endif
>
> $(eval $(cmake-package))
Best regards,
Julien.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Buildroot] [PATCH 1/3] package/libjxl: fix build with libjpeg
2023-02-19 14:00 [Buildroot] [PATCH 1/3] package/libjxl: fix build with libjpeg Fabrice Fontaine
2023-02-19 14:00 ` [Buildroot] [PATCH 2/3] package/libjxl: disable benchmark and tests Fabrice Fontaine
2023-02-19 14:00 ` [Buildroot] [PATCH 3/3] package/libjxl: security bump to version 0.8.1 Fabrice Fontaine
@ 2023-02-19 15:30 ` Julien Olivain
2023-02-19 16:37 ` Fabrice Fontaine
2023-02-20 20:51 ` Thomas Petazzoni via buildroot
3 siblings, 1 reply; 7+ messages in thread
From: Julien Olivain @ 2023-02-19 15:30 UTC (permalink / raw)
To: Fabrice Fontaine; +Cc: buildroot
Hi Fabrice,
On 19/02/2023 15:00, Fabrice Fontaine wrote:
> Building with libjpeg will raise the following build failure on some
> architectures since the addition of the package in commit
> e648d399d8bd609697e78f13f7fa76be06d91a57:
>
> /tmp/instance-14/output-1/build/libjxl-0.7.0/lib/extras/enc/jpg.cc: In
> function 'jxl::Status
> jxl::extras::{anonymous}::EncodeWithLibJpeg(const
> jxl::extras::PackedImage&, const JxlBasicInfo&, const
> std::vector<unsigned char>&, std::vector<unsigned char>, size_t, const
> string&, std::vector<unsigned char>*)':
> /tmp/instance-14/output-1/build/libjxl-0.7.0/lib/extras/enc/jpg.cc:126:34:
> error: invalid conversion from 'long unsigned int*' to 'size_t*' {aka
> 'unsigned int*'} [-fpermissive]
> 126 | jpeg_mem_dest(&cinfo, &buffer, &size);
> | ^~~~~
> | |
> | long unsigned int*
>
> Upstream advocates to use jpeg-turbo:
> https://github.com/libjxl/libjxl/issues/1802
>
> Fixes:
> -
> http://autobuild.buildroot.org/results/9a2a7c6072876f2562609bf98f32a1ce93631a75
>
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> ---
> package/libjxl/libjxl.mk | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/package/libjxl/libjxl.mk b/package/libjxl/libjxl.mk
> index cc24ba258c..02a93ac5d9 100644
> --- a/package/libjxl/libjxl.mk
> +++ b/package/libjxl/libjxl.mk
> @@ -30,4 +30,11 @@ LIBJXL_CONF_OPTS = \
> -DJPEGXL_ENABLE_SJPEG=OFF \
> -DJPEGXL_ENABLE_SKCMS=OFF
>
> +ifeq ($(BR2_PACKAGE_JPEG_TURBO),y)
> +LIBJXL_DEPENDENCIES += jpeg-turbo
> +LIBJXL_CONF_OPTS += -DJPEGXL_ENABLE_TOOLS=ON
> +else
> +LIBJXL_CONF_OPTS += -DJPEGXL_ENABLE_TOOLS=OFF
Having JPEGXL_ENABLE_TOOLS=ON without any libjpeg is a valid
configuration for libjxl.
Is it possible to disable the tools only if BR2_PACKAGE_LIBJPEG=y?
The configuration with tools and without any libjpeg is the one
used by the package runtime test.
Running the test with command:
support/testing/run-tests \
-d dl -o output_folder \
tests.package.test_libjxl
now fails with output:
AssertionError: 127 != 0 :
Failed to run: cjxl /var/tmp/reference.ppm /var/tmp/encoded.jxl
output was:
-sh: cjxl: not found
> +endif
> +
> $(eval $(cmake-package))
Best regards,
Julien.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [Buildroot] [PATCH 1/3] package/libjxl: fix build with libjpeg
2023-02-19 15:30 ` [Buildroot] [PATCH 1/3] package/libjxl: fix build with libjpeg Julien Olivain
@ 2023-02-19 16:37 ` Fabrice Fontaine
0 siblings, 0 replies; 7+ messages in thread
From: Fabrice Fontaine @ 2023-02-19 16:37 UTC (permalink / raw)
To: Julien Olivain; +Cc: buildroot
[-- Attachment #1.1: Type: text/plain, Size: 2809 bytes --]
Hi Julien,
Le dim. 19 févr. 2023 à 16:31, Julien Olivain <ju.o@free.fr> a écrit :
> Hi Fabrice,
>
> On 19/02/2023 15:00, Fabrice Fontaine wrote:
> > Building with libjpeg will raise the following build failure on some
> > architectures since the addition of the package in commit
> > e648d399d8bd609697e78f13f7fa76be06d91a57:
> >
> > /tmp/instance-14/output-1/build/libjxl-0.7.0/lib/extras/enc/jpg.cc: In
> > function 'jxl::Status
> > jxl::extras::{anonymous}::EncodeWithLibJpeg(const
> > jxl::extras::PackedImage&, const JxlBasicInfo&, const
> > std::vector<unsigned char>&, std::vector<unsigned char>, size_t, const
> > string&, std::vector<unsigned char>*)':
> >
> /tmp/instance-14/output-1/build/libjxl-0.7.0/lib/extras/enc/jpg.cc:126:34:
> > error: invalid conversion from 'long unsigned int*' to 'size_t*' {aka
> > 'unsigned int*'} [-fpermissive]
> > 126 | jpeg_mem_dest(&cinfo, &buffer, &size);
> > | ^~~~~
> > | |
> > | long unsigned int*
> >
> > Upstream advocates to use jpeg-turbo:
> > https://github.com/libjxl/libjxl/issues/1802
> >
> > Fixes:
> > -
> >
> http://autobuild.buildroot.org/results/9a2a7c6072876f2562609bf98f32a1ce93631a75
> >
> > Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> > ---
> > package/libjxl/libjxl.mk | 7 +++++++
> > 1 file changed, 7 insertions(+)
> >
> > diff --git a/package/libjxl/libjxl.mk b/package/libjxl/libjxl.mk
> > index cc24ba258c..02a93ac5d9 100644
> > --- a/package/libjxl/libjxl.mk
> > +++ b/package/libjxl/libjxl.mk
> > @@ -30,4 +30,11 @@ LIBJXL_CONF_OPTS = \
> > -DJPEGXL_ENABLE_SJPEG=OFF \
> > -DJPEGXL_ENABLE_SKCMS=OFF
> >
> > +ifeq ($(BR2_PACKAGE_JPEG_TURBO),y)
> > +LIBJXL_DEPENDENCIES += jpeg-turbo
> > +LIBJXL_CONF_OPTS += -DJPEGXL_ENABLE_TOOLS=ON
> > +else
> > +LIBJXL_CONF_OPTS += -DJPEGXL_ENABLE_TOOLS=OFF
>
> Having JPEGXL_ENABLE_TOOLS=ON without any libjpeg is a valid
> configuration for libjxl.
>
> Is it possible to disable the tools only if BR2_PACKAGE_LIBJPEG=y?
>
Thanks for your review, I'll send a v2 which will set
CMAKE_DISABLE_FIND_PACKAGE_JPEG.
> The configuration with tools and without any libjpeg is the one
> used by the package runtime test.
>
> Running the test with command:
>
> support/testing/run-tests \
> -d dl -o output_folder \
> tests.package.test_libjxl
>
> now fails with output:
>
> AssertionError: 127 != 0 :
> Failed to run: cjxl /var/tmp/reference.ppm /var/tmp/encoded.jxl
> output was:
> -sh: cjxl: not found
>
> > +endif
> > +
> > $(eval $(cmake-package))
>
> Best regards,
>
> Julien.
>
Best Regards,
Fabrice
[-- Attachment #1.2: Type: text/html, Size: 4426 bytes --]
[-- Attachment #2: Type: text/plain, Size: 150 bytes --]
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Buildroot] [PATCH 1/3] package/libjxl: fix build with libjpeg
2023-02-19 14:00 [Buildroot] [PATCH 1/3] package/libjxl: fix build with libjpeg Fabrice Fontaine
` (2 preceding siblings ...)
2023-02-19 15:30 ` [Buildroot] [PATCH 1/3] package/libjxl: fix build with libjpeg Julien Olivain
@ 2023-02-20 20:51 ` Thomas Petazzoni via buildroot
3 siblings, 0 replies; 7+ messages in thread
From: Thomas Petazzoni via buildroot @ 2023-02-20 20:51 UTC (permalink / raw)
To: Fabrice Fontaine; +Cc: Julien Olivain, buildroot
On Sun, 19 Feb 2023 15:00:49 +0100
Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:
> Building with libjpeg will raise the following build failure on some
> architectures since the addition of the package in commit
> e648d399d8bd609697e78f13f7fa76be06d91a57:
>
> /tmp/instance-14/output-1/build/libjxl-0.7.0/lib/extras/enc/jpg.cc: In function 'jxl::Status jxl::extras::{anonymous}::EncodeWithLibJpeg(const jxl::extras::PackedImage&, const JxlBasicInfo&, const std::vector<unsigned char>&, std::vector<unsigned char>, size_t, const string&, std::vector<unsigned char>*)':
> /tmp/instance-14/output-1/build/libjxl-0.7.0/lib/extras/enc/jpg.cc:126:34: error: invalid conversion from 'long unsigned int*' to 'size_t*' {aka 'unsigned int*'} [-fpermissive]
> 126 | jpeg_mem_dest(&cinfo, &buffer, &size);
> | ^~~~~
> | |
> | long unsigned int*
>
> Upstream advocates to use jpeg-turbo:
> https://github.com/libjxl/libjxl/issues/1802
>
> Fixes:
> - http://autobuild.buildroot.org/results/9a2a7c6072876f2562609bf98f32a1ce93631a75
>
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> ---
> package/libjxl/libjxl.mk | 7 +++++++
> 1 file changed, 7 insertions(+)
To be honest, I find quite ugly the fact that only jpeg-turbo is
supported, but it indeed seems like libjpeg and jpeg-turbo are not 100%
compatible, unfortunately.
So: entire series applied, thanks!
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 7+ messages in thread