Bug 863231 - packaging deficiencies in libjpeg-turbo
Summary: packaging deficiencies in libjpeg-turbo
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: libjpeg-turbo
Version: 18
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Adam Tkac
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-10-04 18:42 UTC by Tom Lane
Modified: 2013-07-03 03:46 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-12-20 15:53:44 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Tom Lane 2012-10-04 18:42:46 UTC
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 12:22:43 UTC
(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 13:24:47 UTC
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 15:32:15 UTC
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 15:53:47 UTC
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.