@@ -25,6 +25,35 @@ XBPS_CCACHE=yes
2525```
2626to ` etc/conf ` .
2727
28+ ## Find out which package owns a specific file
29+ A common sight while dependency hunting is that package's build system complains
30+ about missing file XYZ. This might be a library, a header file or something
31+ else. Knowing how to resolve the filename to a package is crucial for
32+ identifying ` (host)makedepends ` of a template.
33+
34+ XBPS supports this ` file -> package ` lookup. You can use ` xbps-query --ownedby `
35+ for that. But it's pretty slow.
36+
37+ The ` xlocate ` script from the ` xtools ` package can look up packages by
38+ filenames. It works by pulling [ an index from the official
39+ repo] ( https://repo-default.voidlinux.org/xlocate/ ) (which is much faster than
40+ ` xbps-query --ownedby ` ).
41+
42+ You can use ` xlocate ` like this:
43+
44+ ```
45+ > xlocate -S
46+ Fetching objects: 11688, done.
47+ From https://repo-default.voidlinux.org/xlocate/xlocate
48+ + e122c3634...a2659176f master -> master (forced update)
49+ > xlocate xlocate
50+ xtools-0.59_1 /usr/bin/xlocate
51+ xtools-0.59_1 /usr/share/man/man1/xlocate.1 -> /usr/share/man/man1/xtools.1
52+ ```
53+
54+ It is also documented [ in the Void Linux
55+ Handbook] ( https://docs.voidlinux.org/xbps/index.html#finding-files-and-packages ) .
56+
2857## Show dependency install progress
2958Some packages may have large dependencies that take a long time to download.
3059` xbps-src ` shows no progress monitor whatsoever for installing dependency
0 commit comments