File project.diff of Package python-imagecodecs

--- imagecodecs_distributor_setup.py.orig
+++ imagecodecs_distributor_setup.py
@@ -30,11 +30,11 @@ def customize_build(EXTENSIONS, OPTIONS)
         'sharpyuv',
         'SvtAv1Enc',
     ]
-    openjpeg_inc = subprocess.check_output(
-        ['pkgconf', '--variable=includedir', 'libopenjp2'],
+    openjpeg_cflags = subprocess.check_output(
+        ['pkg-config', '--cflags', 'libopenjp2'],
         text=True,
         ).strip()
-    EXTENSIONS['jpeg2k']['include_dirs'].append(openjpeg_inc)
+    EXTENSIONS['jpeg2k']['extra_compile_args'].append(openjpeg_cflags)
     EXTENSIONS['jpegxr']['include_dirs'].append(includedir +  'jxrlib')
     EXTENSIONS['jpegxl']['libraries'] = ['jxl', 'jxl_threads']
     EXTENSIONS['rcomp']['include_dirs'].append(includedir +   'cfitsio')
--- python-imagecodecs.spec.orig
+++ python-imagecodecs.spec
@@ -1,5 +1,5 @@
 #
-# spec file for package python-imagecodecs
+# spec file
 #
 # Copyright (c) 2025 SUSE LLC
 #
@@ -47,7 +47,7 @@ BuildRequires:  fdupes
 BuildRequires:  python-rpm-macros
 Requires:       python-numpy
 Requires(post): update-alternatives
-Requires(postun): update-alternatives
+Requires(postun):update-alternatives
 Recommends:     python-Pillow
 Recommends:     python-blosc
 Recommends:     python-lz4
@@ -137,6 +137,10 @@ Bitshuffle, and Float24 (24-bit floating
 
 %prep
 %autosetup -p1 -n imagecodecs-%{version}
+%if %suse_version <= 1500
+# Command pkgconf is pkg-config on SLE15
+sed -i 's/pkgconf/pkg-config/' %{SOURCE1}
+%endif
 cp %{SOURCE1} ./
 dos2unix README.rst
 # These libraries are not linked to, (check SOURCE1)
openSUSE Build Service is sponsored by