Bug 863231 - packaging deficiencies in libjpeg-turbo
packaging deficiencies in libjpeg-turbo
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: libjpeg-turbo (Show other bugs)
18
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Adam Tkac
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-10-04 14:42 EDT by Tom Lane
Modified: 2013-07-02 23:46 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-12-20 10:53:44 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Tom Lane 2012-10-04 14:42:46 EDT
Description of problem:
While repackaging libjpeg-turbo for RHEL6, I noted a couple of problems.

First, I don't think the Provides: for "libjpeg" are quite right; they should include the dist tag.  Plus you forgot to provide the isa-specific variant.
This can be fixed along the lines of

 Obsoletes:	libjpeg < 6b-47
 # add provides (even if it not needed) to workaround bad packages, like
 # java-1.6.0-openjdk (#rh607554) -- atkac
-Provides:	libjpeg = 6b-47
+Provides:	libjpeg = 6b-47%{?dist}
+%if "%{?_isa}" != ""
+Provides:	libjpeg%{_isa} = 6b-47%{?dist}
+%endif
 
 Patch0:		libjpeg-turbo12-noinst.patch
 
and

 %package devel
 Summary:	Headers for the libjpeg-turbo library
 Group:		Development/Libraries
 Obsoletes:	libjpeg-devel < 6b-47
-Provides:	libjpeg-devel = 6b-47
+Provides:	libjpeg-devel = 6b-47%{?dist}
 %if "%{?_isa}" != ""
-Provides:	libjpeg-devel%{_isa} = 6b-47
+Provides:	libjpeg-devel%{_isa} = 6b-47%{?dist}
 %endif
 Requires:	libjpeg-turbo%{?_isa} = %{version}-%{release}
 
and

 %package static
 Summary:	Static version of the libjpeg-turbo library
 Group:		Development/Libraries
 Obsoletes:	libjpeg-static < 6b-47
-Provides:	libjpeg-static = 6b-47
+Provides:	libjpeg-static = 6b-47%{?dist}
 %if "%{?_isa}" != ""
-Provides:	libjpeg-static%{_isa} = 6b-47
+Provides:	libjpeg-static%{_isa} = 6b-47%{?dist}
 %endif
 Requires:	libjpeg-turbo-devel%{?_isa} = %{version}-%{release}
 
While this is no longer terribly important for Fedora itself, I think it is critical that we have this right (not only mostly right) for RHEL7.

Second, the packaging of the "new API" libturbojpeg is really quite bogus:

%files -n turbojpeg
%{_libdir}/libturbojpeg.so

%files -n turbojpeg-devel
%{_includedir}/turbojpeg.h

Surely the base package should contain a version-numbered .so, and "libturbojpeg.so" should be a symlink provided only in the -devel package.

Version-Release number of selected component (if applicable):
libjpeg-turbo-1.2.1-2.fc18

How reproducible:
100%

Steps to Reproduce:
1. Compare --provides of current packages to those of libjpeg packages they replaced.
2. Inspect contents of turbojpeg packages.
Comment 1 Adam Tkac 2012-10-18 08:22:43 EDT
(In reply to comment #0)
> Description of problem:
> While repackaging libjpeg-turbo for RHEL6, I noted a couple of problems.
> 
> First, I don't think the Provides: for "libjpeg" are quite right; they
> should include the dist tag.  Plus you forgot to provide the isa-specific
> variant.
> This can be fixed along the lines of
> 
>  Obsoletes:	libjpeg < 6b-47
>  # add provides (even if it not needed) to workaround bad packages, like
>  # java-1.6.0-openjdk (#rh607554) -- atkac
> -Provides:	libjpeg = 6b-47
> +Provides:	libjpeg = 6b-47%{?dist}
> +%if "%{?_isa}" != ""
> +Provides:	libjpeg%{_isa} = 6b-47%{?dist}
> +%endif
>  
>  Patch0:		libjpeg-turbo12-noinst.patch
>  
> and
> 
>  %package devel
>  Summary:	Headers for the libjpeg-turbo library
>  Group:		Development/Libraries
>  Obsoletes:	libjpeg-devel < 6b-47
> -Provides:	libjpeg-devel = 6b-47
> +Provides:	libjpeg-devel = 6b-47%{?dist}
>  %if "%{?_isa}" != ""
> -Provides:	libjpeg-devel%{_isa} = 6b-47
> +Provides:	libjpeg-devel%{_isa} = 6b-47%{?dist}
>  %endif
>  Requires:	libjpeg-turbo%{?_isa} = %{version}-%{release}
>  
> and
> 
>  %package static
>  Summary:	Static version of the libjpeg-turbo library
>  Group:		Development/Libraries
>  Obsoletes:	libjpeg-static < 6b-47
> -Provides:	libjpeg-static = 6b-47
> +Provides:	libjpeg-static = 6b-47%{?dist}
>  %if "%{?_isa}" != ""
> -Provides:	libjpeg-static%{_isa} = 6b-47
> +Provides:	libjpeg-static%{_isa} = 6b-47%{?dist}
>  %endif
>  Requires:	libjpeg-turbo-devel%{?_isa} = %{version}-%{release}
>  
> While this is no longer terribly important for Fedora itself, I think it is
> critical that we have this right (not only mostly right) for RHEL7.

Right you are, thanks for report & patch.

> Second, the packaging of the "new API" libturbojpeg is really quite bogus:
> 
> %files -n turbojpeg
> %{_libdir}/libturbojpeg.so
> 
> %files -n turbojpeg-devel
> %{_includedir}/turbojpeg.h
> 
> Surely the base package should contain a version-numbered .so, and
> "libturbojpeg.so" should be a symlink provided only in the -devel package.

Reported to upstream, I'm not going to include downstream patch for this:

https://sourceforge.net/p/libjpeg-turbo/feature-requests/16

> Version-Release number of selected component (if applicable):
> libjpeg-turbo-1.2.1-2.fc18
> 
> How reproducible:
> 100%
> 
> Steps to Reproduce:
> 1. Compare --provides of current packages to those of libjpeg packages they
> replaced.
> 2. Inspect contents of turbojpeg packages.
Comment 2 Fedora Update System 2012-10-18 09:24:47 EDT
libjpeg-turbo-1.2.1-3.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/libjpeg-turbo-1.2.1-3.fc18
Comment 3 Fedora Update System 2012-10-18 11:32:15 EDT
Package libjpeg-turbo-1.2.1-3.fc18:
* should fix your issue,
* was pushed to the Fedora 18 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing libjpeg-turbo-1.2.1-3.fc18'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-16403/libjpeg-turbo-1.2.1-3.fc18
then log in and leave karma (feedback).
Comment 4 Fedora Update System 2012-12-20 10:53:47 EST
libjpeg-turbo-1.2.1-3.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.