diff options
| author | Leon Anavi <leon.anavi@konsulko.com> | 2025-05-08 09:33:35 +0300 |
|---|---|---|
| committer | Khem Raj <raj.khem@gmail.com> | 2025-05-08 00:03:27 -0700 |
| commit | 7dd27c20504790eb5090b8732781ae463a99f8b1 (patch) | |
| tree | 55fb0286ee389432942738b027c1380e0fd26593 /meta-python/recipes-devtools/python/python3-pillow-heif | |
| parent | 292e40fe97909bcfc961cdfb8dddd92b105063b5 (diff) | |
| download | meta-openembedded-7dd27c20504790eb5090b8732781ae463a99f8b1.tar.gz | |
python3-pillow-heif: Add recipe
Add recipe for release 0.22.0:
- Boolean pillow_heif.options.DISABLE_SECURITY_LIMITS to bypass
security limit of libheif for the image size.
- libx265 library was updated to the latest 4.1 version.
- libheif was updated from the 1.19.5 to 1.19.7 version.
- AVIF format marked as deprecated and pending for the removal.
This work was sponsored by GOVCERT.LU.
Signed-off-by: Leon Anavi <leon.anavi@konsulko.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-python/recipes-devtools/python/python3-pillow-heif')
| -rw-r--r-- | meta-python/recipes-devtools/python/python3-pillow-heif/0001-setup.py-support-cross-compiling.patch | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/meta-python/recipes-devtools/python/python3-pillow-heif/0001-setup.py-support-cross-compiling.patch b/meta-python/recipes-devtools/python/python3-pillow-heif/0001-setup.py-support-cross-compiling.patch new file mode 100644 index 0000000000..66cf7a9244 --- /dev/null +++ b/meta-python/recipes-devtools/python/python3-pillow-heif/0001-setup.py-support-cross-compiling.patch | |||
| @@ -0,0 +1,56 @@ | |||
| 1 | From 98e6831754712221ce030ce8b27e100a3926c543 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Leon Anavi <leon.anavi@konsulko.com> | ||
| 3 | Date: Mon, 5 May 2025 16:08:37 +0000 | ||
| 4 | Subject: [PATCH] setup.py: support cross compiling | ||
| 5 | |||
| 6 | Upstream-Status: Inappropriate [oe specific] | ||
| 7 | |||
| 8 | Signed-off-by: Leon Anavi <leon.anavi@konsulko.com> | ||
| 9 | --- | ||
| 10 | setup.py | 19 +++++++++++-------- | ||
| 11 | 1 file changed, 11 insertions(+), 8 deletions(-) | ||
| 12 | |||
| 13 | diff --git a/setup.py b/setup.py | ||
| 14 | index 68945e4..67566e8 100644 | ||
| 15 | --- a/setup.py | ||
| 16 | +++ b/setup.py | ||
| 17 | @@ -125,12 +125,12 @@ class PillowHeifBuildExt(build_ext): | ||
| 18 | self._add_directory(library_dirs, match.group(1)) | ||
| 19 | |||
| 20 | # include, rpath, if set as environment variables | ||
| 21 | - for k in ("C_INCLUDE_PATH", "CPATH", "INCLUDE"): | ||
| 22 | + for k in ("C_INCLUDE_PATH", "CPATH", "INCLUDE", "STAGING_INCDIR"): | ||
| 23 | if k in os.environ: | ||
| 24 | for d in os.environ[k].split(os.path.pathsep): | ||
| 25 | self._add_directory(include_dirs, d) | ||
| 26 | |||
| 27 | - for k in ("LD_RUN_PATH", "LIBRARY_PATH", "LIB"): | ||
| 28 | + for k in ("LD_RUN_PATH", "LIBRARY_PATH", "LIB", "STAGING_LIBDIR"): | ||
| 29 | if k in os.environ: | ||
| 30 | for d in os.environ[k].split(os.path.pathsep): | ||
| 31 | self._add_directory(library_dirs, d) | ||
| 32 | @@ -199,12 +199,15 @@ class PillowHeifBuildExt(build_ext): | ||
| 33 | self._update_extension("_pillow_heif", ["heif"], extra_compile_args=["-O3", "-Werror"]) | ||
| 34 | else: # let's assume it's some kind of linux | ||
| 35 | # this old code waiting for refactoring, when time comes. | ||
| 36 | - self._add_directory(include_dirs, "/usr/local/include") | ||
| 37 | - self._add_directory(include_dirs, "/usr/include") | ||
| 38 | - self._add_directory(library_dirs, "/usr/local/lib") | ||
| 39 | - self._add_directory(library_dirs, "/usr/lib64") | ||
| 40 | - self._add_directory(library_dirs, "/usr/lib") | ||
| 41 | - self._add_directory(library_dirs, "/lib") | ||
| 42 | + include_os_path = os.environ.get("STAGING_INCDIR") | ||
| 43 | + if include_os_path: | ||
| 44 | + for path in include_os_path.split(os.pathsep): | ||
| 45 | + self._add_directory(include_dirs, path) | ||
| 46 | + | ||
| 47 | + lib_os_path = os.environ.get("STAGING_LIBDIR") | ||
| 48 | + if lib_os_path: | ||
| 49 | + for path in lib_os_path.split(os.pathsep): | ||
| 50 | + self._add_directory(library_dirs, path) | ||
| 51 | |||
| 52 | self._update_extension("_pillow_heif", ["heif"], extra_compile_args=["-O3", "-Werror"]) | ||
| 53 | |||
| 54 | -- | ||
| 55 | 2.39.5 | ||
| 56 | |||
