Bug 1955154 - Remove hard dependency on kernel-devel
Summary: Remove hard dependency on kernel-devel
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: bcc
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Jiri Olsa
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 1906144
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-04-29 14:47 UTC by Rafael Fonseca
Modified: 2021-06-16 01:03 UTC (History)
7 users (show)

Fixed In Version: bcc-0.20.0-2.fc34
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 1906144
Environment:
Last Closed: 2021-06-16 01:03:46 UTC
Type: Bug


Attachments (Terms of Use)

Description Rafael Fonseca 2021-04-29 14:47:24 UTC
+++ This bug was initially created as a clone of Bug #1906144 +++

Now that in-kernel headers have been enabled (CONFIG_IKHEADERS=m), we don't need the kernel-devel package to be installed.

At this point, I haven't decided whether to remove the dependency entirely, or replace it by a weak one (Suggest: or Recommends:). The support of ikheaders should be already in current version of bcc and bpftrace.

Comment 1 Jerome Marchand 2021-04-30 11:33:44 UTC
We should keep a weak dependency on kernel-devel, since it doesn't need the expensive unpacking of kheaders step.

Also, some bpftrace tools doesn't work when kernel-devel is absent, although they should.
https://github.com/iovisor/bpftrace/issues/1820
It's clearly a bpftrace bug that should be fixed, but in the mean time, "Recommends: kernel-devel" should mitigate the issue.

Comment 2 Jiri Olsa 2021-05-02 20:04:57 UTC
(In reply to Jerome Marchand from comment #1)
> We should keep a weak dependency on kernel-devel, since it doesn't need the
> expensive unpacking of kheaders step.

sorry I missed this comment and submitted the change
and have koji build without kernel-devel dependency:
  https://koji.fedoraproject.org/koji/buildinfo?buildID=1742774

I'll check how weak dependency work and make the change
or comment in here

> 
> Also, some bpftrace tools doesn't work when kernel-devel is absent, although
> they should.
> https://github.com/iovisor/bpftrace/issues/1820
> It's clearly a bpftrace bug that should be fixed, but in the mean time,
> "Recommends: kernel-devel" should mitigate the issue.

Comment 3 Jiri Olsa 2021-05-03 13:22:38 UTC
hum, so looks weak dependency won't install only if there would be an error,
so kernel-devel will still keep installing for bcc if it's weak dependency
unless you specifically say not to:

  dnf --setopt=install_weak_deps=False

I'm not sure that this was the original idea for striping kernel-devel
dependency, Stanislav?

Comment 4 Stanislav Kozina 2021-05-03 13:33:56 UTC
Looks like there's the weaker variant 'Hints', aka 'Suggests:' in the spec file:
https://docs.fedoraproject.org/en-US/packaging-guidelines/WeakDependencies/
Would that work?

Comment 6 Jerome Marchand 2021-05-03 15:35:19 UTC
(In reply to Stanislav Kozina from comment #4)
> Looks like there's the weaker variant 'Hints', aka 'Suggests:' in the spec
> file:
> https://docs.fedoraproject.org/en-US/packaging-guidelines/WeakDependencies/
> Would that work?

The reason I went with Recommends: is that it doesn't breaks bpftrace tools in the default install, yet allows to install bcc without kernel-devel.

Comment 7 Stanislav Kozina 2021-05-03 17:48:27 UTC
Nice, so we should be good (there's a way to do what is needed). Thank you Jerome!

Comment 8 Jiri Olsa 2021-05-04 14:17:30 UTC
ok, will add Recommends: to bcc as well then, thanks

Comment 9 Jiri Olsa 2021-05-05 13:27:00 UTC
(In reply to Jiri Olsa from comment #8)
> ok, will add Recommends: to bcc as well then, thanks

in bcc build:
  https://koji.fedoraproject.org/koji/buildinfo?buildID=1744136

Comment 10 Fedora Update System 2021-06-09 21:38:16 UTC
FEDORA-2021-3875b6e442 has been submitted as an update to Fedora 34. https://bodhi.fedoraproject.org/updates/FEDORA-2021-3875b6e442

Comment 11 Fedora Update System 2021-06-10 01:20:36 UTC
FEDORA-2021-3875b6e442 has been pushed to the Fedora 34 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-3875b6e442`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-3875b6e442

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 12 Fedora Update System 2021-06-11 21:54:31 UTC
FEDORA-2021-1ea2bfd57e has been submitted as an update to Fedora 34. https://bodhi.fedoraproject.org/updates/FEDORA-2021-1ea2bfd57e

Comment 13 Fedora Update System 2021-06-12 01:57:38 UTC
FEDORA-2021-1ea2bfd57e has been pushed to the Fedora 34 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-1ea2bfd57e`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-1ea2bfd57e

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 14 Fedora Update System 2021-06-16 01:03:46 UTC
FEDORA-2021-1ea2bfd57e has been pushed to the Fedora 34 stable repository.
If problem still persists, 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.