Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 280412 - init scripts: "provide" is missing some capabilities
Summary: init scripts: "provide" is missing some capabilities
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo's Team for Core System packages
Depends on:
Reported: 2009-08-05 06:26 UTC by Helmut Auer
Modified: 2009-08-19 18:31 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Note You need to log in before you can comment on or make changes to this bug.
Description Helmut Auer 2009-08-05 06:26:15 UTC
When I have two init scripts both using the same provide name (in my case I have two scripts with "provide lirc" in the depend section), there are some problems.
1. reports:
 *  Service 'lircd' already provides 'lirc'!;
 *  Not adding service 'inputlircd'...

2. Its not possible to make one of the packages the default to be started from depend int scripts.

Here a concrete scenario:
lircd and inputlircd are providing lirc and both int scripts are in /etc/init.d
irexec has the depend flag: "need lirc"
Now starting irexec wil start inputlircd or lircd, which ever was taken first, regardless of the runlevel settings.
I have a gentoo based distribution so I need several lirc packages, and the user can choose which one he needs via gui.
What I would expect is that the script which needs lirc (irexec) will start the lirc script which is added to a runlevel.
So the only "dirty" workaround I found til now is to patch the depend section of the init scripts, so that only the active lirc script have a "provide lirc" statement, but imho the gentoo init/runlevel handling should provide a clean solution, maybe I'm missing something ?

Reproducible: Always

Steps to Reproduce:
- install lirc
- execute
- cp /etc/init.d/lircd /etc/init.d/lircd2
- rc-update add lircd2 default
- rc-update del lircd
- /etc/init.d/irexec start
Actual Results:  
irexec will start lircd

Expected Results:  
irexec should start lircd2 because that one is added to a runlevel.
Comment 1 SpanKY gentoo-dev 2009-08-19 17:58:45 UTC
you need to post `emerge --info` with every bug report like the documentation says
Comment 2 Helmut Auer 2009-08-19 18:31:16 UTC
Sorry for bothering you - forget what I said, I have my workaround and you can save your time.