From 212605f710177ebb41fb2297960dd2bf76c68abf Mon Sep 17 00:00:00 2001 From: Sergio Gonzalez Date: Mon, 11 May 2026 08:35:17 +0000 Subject: [PATCH 1/2] Add missing LICENSE-IJG file The crate's Cargo.toml declares 'license = "(MIT OR Apache-2.0) AND IJG"' but the IJG license file was not shipped alongside LICENSE-APACHE and LICENSE-MIT, which breaks downstream license auditing (e.g. Chromium's README.chromium generator via gnrt expects a License File for each SPDX component). The IJG license text added here is the LEGAL ISSUES section reproduced verbatim from libjpeg-turbo's README.ijg, which SPDX lists as a canonical source for the IJG license identifier: https://github.com/libjpeg-turbo/libjpeg-turbo/blob/main/README.ijg https://spdx.org/licenses/IJG.html The copyright line '(C) 1991-2020, Thomas G. Lane, Guido Vollbeding' matches the IJG notice already used inside this crate's own source headers (see src/fdct.rs). No code or behavior changes. --- LICENSE-IJG | 62 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 LICENSE-IJG diff --git a/LICENSE-IJG b/LICENSE-IJG new file mode 100644 index 0000000..d712742 --- /dev/null +++ b/LICENSE-IJG @@ -0,0 +1,62 @@ +Independent JPEG Group License (IJG) +==================================== + +The following is the LEGAL ISSUES section of the Independent JPEG Group +README, reproduced verbatim from libjpeg-turbo's `README.ijg`: + + https://github.com/libjpeg-turbo/libjpeg-turbo/blob/main/README.ijg + +This text is also referenced by SPDX as canonical source material for the +`IJG` license identifier: + + https://spdx.org/licenses/IJG.html + + +LEGAL ISSUES +============ + +In plain English: + +1. We don't promise that this software works. (But if you find any bugs, + please let us know!) +2. You can use this software for whatever you want. You don't have to pay us. +3. You may not pretend that you wrote this software. If you use it in a + program, you must acknowledge somewhere in your documentation that + you've used the IJG code. + +In legalese: + +The authors make NO WARRANTY or representation, either express or implied, +with respect to this software, its quality, accuracy, merchantability, or +fitness for a particular purpose. This software is provided "AS IS", and you, +its user, assume the entire risk as to its quality and accuracy. + +This software is copyright (C) 1991-2020, Thomas G. Lane, Guido Vollbeding. +All Rights Reserved except as specified below. + +Permission is hereby granted to use, copy, modify, and distribute this +software (or portions thereof) for any purpose, without fee, subject to these +conditions: +(1) If any part of the source code for this software is distributed, then this +README file must be included, with this copyright and no-warranty notice +unaltered; and any additions, deletions, or changes to the original files +must be clearly indicated in accompanying documentation. +(2) If only executable code is distributed, then the accompanying +documentation must state that "this software is based in part on the work of +the Independent JPEG Group". +(3) Permission for use of this software is granted only if the user accepts +full responsibility for any undesirable consequences; the authors accept +NO LIABILITY for damages of any kind. + +These conditions apply to any software derived from or based on the IJG code, +not just to the unmodified library. If you use our work, you ought to +acknowledge us. + +Permission is NOT granted for the use of any IJG author's name or company name +in advertising or publicity relating to this software or products derived from +it. This software may be referred to only as "the Independent JPEG Group's +software". + +We specifically permit and encourage the use of this software as the basis of +commercial products, provided that all warranty or liability claims are +assumed by the product vendor. From 994d482a6bf3e7c08f22219d0f3606220d275a2e Mon Sep 17 00:00:00 2001 From: Sergio Gonzalez Martin Date: Tue, 7 Jul 2026 20:52:40 +0000 Subject: [PATCH 2/2] Add license file --- LICENSE-IJG | 33 ++++++++++++++++++++------------- 1 file changed, 20 insertions(+), 13 deletions(-) diff --git a/LICENSE-IJG b/LICENSE-IJG index d712742..a39a4aa 100644 --- a/LICENSE-IJG +++ b/LICENSE-IJG @@ -1,26 +1,33 @@ -Independent JPEG Group License (IJG) -==================================== +jpeg-encoder IJG License +======================== -The following is the LEGAL ISSUES section of the Independent JPEG Group -README, reproduced verbatim from libjpeg-turbo's `README.ijg`: +The jpeg-encoder crate declares license "(MIT OR Apache-2.0) AND IJG". +The published crate includes MIT and Apache license files, but it does not +currently include a top-level IJG license file. This Chromium-local file +documents the IJG terms for the IJG-derived portions of jpeg-encoder until the +crate publishes the missing license file upstream. - https://github.com/libjpeg-turbo/libjpeg-turbo/blob/main/README.ijg +The IJG-derived portions include, at least: -This text is also referenced by SPDX as canonical source material for the -`IJG` license identifier: +- src/fdct.rs, which is ported from mozjpeg to Rust and states that it was part + of the Independent JPEG Group's software. +- src/avx2/fdct.rs, which is ported from mozjpeg / jfdctint-avx2.asm to Rust + and states that it is based on the x86 SIMD extension for the IJG JPEG + library. - https://spdx.org/licenses/IJG.html +In the IJG terms below, "this software" refers to the IJG-derived portions of +jpeg-encoder listed above, not to the jpeg-encoder crate as a whole. The rest +of jpeg-encoder remains covered by the crate's MIT OR Apache-2.0 terms. - -LEGAL ISSUES -============ +Conditions of distribution and use +================================== In plain English: 1. We don't promise that this software works. (But if you find any bugs, please let us know!) 2. You can use this software for whatever you want. You don't have to pay us. -3. You may not pretend that you wrote this software. If you use it in a +3. You may not pretend that you wrote this software. If you use it in a program, you must acknowledge somewhere in your documentation that you've used the IJG code. @@ -54,7 +61,7 @@ acknowledge us. Permission is NOT granted for the use of any IJG author's name or company name in advertising or publicity relating to this software or products derived from -it. This software may be referred to only as "the Independent JPEG Group's +it. This software may be referred to only as "the Independent JPEG Group's software". We specifically permit and encourage the use of this software as the basis of