Bug 200025 - ports-mgmt/pkg: searching package contents via pkg-rquery(8)
Summary: ports-mgmt/pkg: searching package contents via pkg-rquery(8)
Status: Open
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-pkg (Nobody)
URL:
Keywords: feature
Depends on:
Blocks:
 
Reported: 2015-05-07 12:08 UTC by Atte Peltomäki
Modified: 2022-12-10 13:42 UTC (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Atte Peltomäki 2015-05-07 12:08:16 UTC
Scenario:
I want to know which binary package provides `some_lib.so`.

Problem:
pkg-rquery(8) doesn't support searching package contents.

Workarounds:
1) grep through /usr/ports/*/*/pkg-plist
2) http://www.secnetix.de/tools/porgle/porgle.py

The second workaround should also really be an official FreeBSD service hosted under freebsd.org, much like http://packages.debian.org is for Debian Linux.
Comment 1 Atte Peltomäki 2015-05-07 12:24:30 UTC
For reference, this is how Debian solves the problem:

% apt-get install apt-file
% apt-file update
% apt-file search filename

apt-file downloads file lists of all configured package sources, which can be then searched locally.
Comment 2 Baptiste Daroussin freebsd_committer freebsd_triage 2015-05-18 10:23:02 UTC
Assign to pkg@
Comment 3 Baptiste Daroussin freebsd_committer freebsd_triage 2015-05-18 10:25:19 UTC
A functionality like apt-file is planned but not yet developed should not be very hard but it is not yet there as we are a small amount of devs and priorities are not there for now :) but if someone brings patches we will be glad to merge them
Comment 4 Atte Peltomäki 2015-05-18 10:29:51 UTC
Do you have any planning references, design documents or such? (what exactly to implement and how)
Comment 5 Mageirias Anastasios 2016-10-06 19:27:24 UTC
I'm really interested in developing that feature. Do you have any resources that can help me develop that ?
Comment 6 Tobias Kortkamp freebsd_committer freebsd_triage 2018-03-14 07:00:57 UTC
This should be solved by https://www.freshports.org/ports-mgmt/pkg-provides
Comment 7 Graham Perrin freebsd_committer freebsd_triage 2019-02-02 08:43:04 UTC
<https://redd.it/agwhy5> ▶ 

Less Known pkg(8) Features
<https://vermaden.wordpress.com/2019/01/17/less-known-pkg8-features/> ▶

rosorio/pkg-provides: pkgng plugin for querying which package provides a particular file
<https://github.com/rosorio/pkg-provides>
Comment 8 Graham Perrin freebsd_committer freebsd_triage 2022-11-10 07:28:58 UTC
Triage: reduce the severity to the norm for an enhancement request.