FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora Development

 
 
LinkBack Thread Tools
 
Old 06-02-2008, 06:31 PM
"Peter Robinson"
 
Default howto push dependencies into sub packages

Hi All,

I maintain the geoclue package. It has a number of providers that can
be compiled in. I've tried to introduce a couple of subpackages for
the gpsd and gypsy providers so that you can just install the
providers you need and not have to pull in extra packages that you
might not need (gpsd and gypsy do essentially the same thing so you
probably don't need both). The problem I'm having is that with the
addition of the gpsd provider (see F-9 testing if you aren't on
rawhide) pulls in gpsd for the main package and not for the
geoclue-gpsd package. How do I push this requirement down to the sub
package so that it doesn't affect the main package (I've got the gpsd
requirements in the sub package).

Cheers,
Peter

--
fedora-devel-list mailing list
fedora-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/fedora-devel-list
 
Old 07-02-2008, 10:12 AM
Nils Philippsen
 
Default howto push dependencies into sub packages

Hi Peter,

On Mon, 2008-06-02 at 19:31 +0100, Peter Robinson wrote:

> I maintain the geoclue package. It has a number of providers that can
> be compiled in. I've tried to introduce a couple of subpackages for
> the gpsd and gypsy providers so that you can just install the
> providers you need and not have to pull in extra packages that you
> might not need (gpsd and gypsy do essentially the same thing so you
> probably don't need both). The problem I'm having is that with the
> addition of the gpsd provider (see F-9 testing if you aren't on
> rawhide) pulls in gpsd for the main package and not for the
> geoclue-gpsd package. How do I push this requirement down to the sub
> package so that it doesn't affect the main package (I've got the gpsd
> requirements in the sub package).

I see nobody's answered yet... I guess what you want to do is to have
your -gpsd subpackage requires gpsd so if it is installed, gpsd will be
there as well?

In that case, just put the "Requires: gpsd ..." line in the "%package
gpsd" section, right beside the "Requires: geoclue = %{PACKAGE_VERSION}"
line.

HTH,
Nils
--
Nils Philippsen / Red Hat / nphilipp@redhat.com
"Those who would give up Essential Liberty to purchase a little Temporary
Safety, deserve neither Liberty nor Safety." -- B. Franklin, 1759
PGP fingerprint: C4A8 9474 5C4C ADE3 2B8F 656D 47D8 9B65 6951 3011

--
fedora-devel-list mailing list
fedora-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/fedora-devel-list
 
Old 07-02-2008, 10:28 AM
"Peter Robinson"
 
Default howto push dependencies into sub packages

Hi Nils,

>> I maintain the geoclue package. It has a number of providers that can
>> be compiled in. I've tried to introduce a couple of subpackages for
>> the gpsd and gypsy providers so that you can just install the
>> providers you need and not have to pull in extra packages that you
>> might not need (gpsd and gypsy do essentially the same thing so you
>> probably don't need both). The problem I'm having is that with the
>> addition of the gpsd provider (see F-9 testing if you aren't on
>> rawhide) pulls in gpsd for the main package and not for the
>> geoclue-gpsd package. How do I push this requirement down to the sub
>> package so that it doesn't affect the main package (I've got the gpsd
>> requirements in the sub package).
>
> I see nobody's answered yet... I guess what you want to do is to have
> your -gpsd subpackage requires gpsd so if it is installed, gpsd will be
> there as well?
>
> In that case, just put the "Requires: gpsd ..." line in the "%package
> gpsd" section, right beside the "Requires: geoclue = %{PACKAGE_VERSION}"
> line.

That's what I thought would be the case and have done but it seems
that rpm with the auto deps still wants the dependency for the root
package as well.

For example with a package I maintain called geoclue I have two
subpackages called geoclue-gypsy and geoclue-gpsd to try and keep the
deps down (gypsy and gpsd essentially do the same thing) but if you
just install geoclue without any of the sub packages it will still
pull in both gpsd and gypsy as deps. This is what I want to avoid. A
yum output eg below.

Cheers,
Peter

[root@euuklonw7300b1n ~]# yum install geoclue
Loaded plugins: refresh-packagekit, refresh-updatesd
Setting up Install Process
Parsing package install arguments
Resolving Dependencies
--> Running transaction check
---> Package geoclue.x86_64 0:0.11.1-9.fc9 set to be updated
--> Processing Dependency: libgypsy.so.0()(64bit) for package: geoclue
--> Processing Dependency: libgps.so.17()(64bit) for package: geoclue
--> Running transaction check
---> Package gypsy.x86_64 0:0.6-3.fc9 set to be updated
---> Package gpsd.x86_64 0:2.37-2.fc9 set to be updated
--> Finished Dependency Resolution

Dependencies Resolved

================================================== ===========================
Package Arch Version Repository Size
================================================== ===========================
Installing:
geoclue x86_64 0.11.1-9.fc9 updates 82 k
Installing for dependencies:
gpsd x86_64 2.37-2.fc9 fedora 188 k
gypsy x86_64 0.6-3.fc9 updates 41 k

Transaction Summary
================================================== ===========================
Install 3 Package(s)
Update 0 Package(s)
Remove 0 Package(s)

Total download size: 311 k
Is this ok [y/N]:

--
fedora-devel-list mailing list
fedora-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/fedora-devel-list
 
Old 07-02-2008, 10:36 AM
Nils Philippsen
 
Default howto push dependencies into sub packages

Hi Peter,

On Wed, 2008-07-02 at 11:28 +0100, Peter Robinson wrote:

> For example with a package I maintain called geoclue I have two
> subpackages called geoclue-gypsy and geoclue-gpsd to try and keep the
> deps down (gypsy and gpsd essentially do the same thing) but if you
> just install geoclue without any of the sub packages it will still
> pull in both gpsd and gypsy as deps. This is what I want to avoid. A
> yum output eg below.
>
> Cheers,
> Peter
>
> [root@euuklonw7300b1n ~]# yum install geoclue
> Loaded plugins: refresh-packagekit, refresh-updatesd
> Setting up Install Process
> Parsing package install arguments
> Resolving Dependencies
> --> Running transaction check
> ---> Package geoclue.x86_64 0:0.11.1-9.fc9 set to be updated
> --> Processing Dependency: libgypsy.so.0()(64bit) for package: geoclue
> --> Processing Dependency: libgps.so.17()(64bit) for package: geoclue

This suggests that geoclue (the main package) has files which link
directly to the gypsy and gps libs respectively; rpmbuild detects this
and sets automatic dependencies.

>From looking at your spec file, you include the
%{_libexecdir}/geoclue-{gpsd,gypsy} files not only in their subpackages
but also in the main package (by way of "%{_libexecdir}/geoclue-*"). To
avoid that, you should either list all other files in that directory for
the main package or use this construct:

%files
...
%{_libexecdir}/geoclue-*
%exclude %{_libexecdir}/geoclue-gpsd
%exclude %{_libexecdir}/geoclue-gypsy

Nils
--
Nils Philippsen / Red Hat / nphilipp@redhat.com
"Those who would give up Essential Liberty to purchase a little Temporary
Safety, deserve neither Liberty nor Safety." -- B. Franklin, 1759
PGP fingerprint: C4A8 9474 5C4C ADE3 2B8F 656D 47D8 9B65 6951 3011

--
fedora-devel-list mailing list
fedora-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/fedora-devel-list
 
Old 07-02-2008, 11:03 AM
"Peter Robinson"
 
Default howto push dependencies into sub packages

Hi Nils,

>> For example with a package I maintain called geoclue I have two
>> subpackages called geoclue-gypsy and geoclue-gpsd to try and keep the
>> deps down (gypsy and gpsd essentially do the same thing) but if you
>> just install geoclue without any of the sub packages it will still
>> pull in both gpsd and gypsy as deps. This is what I want to avoid. A
>> yum output eg below.
>>
>> Cheers,
>> Peter
>>
>> [root@euuklonw7300b1n ~]# yum install geoclue
>> Loaded plugins: refresh-packagekit, refresh-updatesd
>> Setting up Install Process
>> Parsing package install arguments
>> Resolving Dependencies
>> --> Running transaction check
>> ---> Package geoclue.x86_64 0:0.11.1-9.fc9 set to be updated
>> --> Processing Dependency: libgypsy.so.0()(64bit) for package: geoclue
>> --> Processing Dependency: libgps.so.17()(64bit) for package: geoclue
>
> This suggests that geoclue (the main package) has files which link
> directly to the gypsy and gps libs respectively; rpmbuild detects this
> and sets automatic dependencies.
>
> >From looking at your spec file, you include the
> %{_libexecdir}/geoclue-{gpsd,gypsy} files not only in their subpackages
> but also in the main package (by way of "%{_libexecdir}/geoclue-*"). To
> avoid that, you should either list all other files in that directory for
> the main package or use this construct:
>
> %files
> ...
> %{_libexecdir}/geoclue-*
> %exclude %{_libexecdir}/geoclue-gpsd
> %exclude %{_libexecdir}/geoclue-gypsy

Thanks for pointing that out, I was under the misguided impression
that if it was listed in the subpackage that it wouldn't be picked up
in the main package. I should have actually done a rpm -ql on the
package to see for myself. I also noticed a couple of other related
files that should have been put in the subpackage as well.

Looks like I have now fixed the issue. Thanks for your help!

Peter

--
fedora-devel-list mailing list
fedora-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/fedora-devel-list
 

Thread Tools




All times are GMT. The time now is 06:28 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org