Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.user > #268466 > unrolled thread
| Started by | Detlef Vollmann <dv@vollmann.ch> |
|---|---|
| First post | 2024-03-21 10:10 +0100 |
| Last post | 2024-03-21 23:10 +0100 |
| Articles | 3 — 3 participants |
Back to article view | Back to linux.debian.user
Dependency meaning Detlef Vollmann <dv@vollmann.ch> - 2024-03-21 10:10 +0100
Re: Dependency meaning The Wanderer <wanderer@fastmail.fm> - 2024-03-21 12:20 +0100
Re: Dependency meaning Sven Joachim <svenjoac@gmx.de> - 2024-03-21 23:10 +0100
| From | Detlef Vollmann <dv@vollmann.ch> |
|---|---|
| Date | 2024-03-21 10:10 +0100 |
| Subject | Dependency meaning |
| Message-ID | <IkmAW-BJX-11@gated-at.bofh.it> |
This is essentially a follow-up on my question about the 64bit time_t transition. I'm trying to upgrade some packages manually. For this, I'm trying to understand the dependencies. 'apt-cache showpkg libssl3t64' gives me this: > Dependencies: > 3.1.5-1.1 - libc6 (2 2.34) libssl3 (3 3.1.5-1.1) openssh-client (3 1:9.4p1) openssh-server (3 1:9.4p1) python3-m2crypto (3 0.38.0-4) libssl3 (0 (null)) libssl3:i386 (3 3.1.5-1.1) libssl3:i386 (0 (null)) openssh-client:i386 (3 1:9.4p1) openssh-server:i386 (3 1:9.4p1) python3-m2crypto:i386 (3 0.38.0-4) libssl3t64:i386 (35 3.1.5-1.1) libssl3t64:i386 (38 3.1.5-1.1) I'm trying to understand, what the numbers in parentheses mean. The second numbers are obviously version numbers. I guess the first numbers are dependency types, but I have no idea, what they mean. The man page says "For the specific meaning of the remainder of the output it is best to consult the apt source code." I'd like to avoid this. Can anybody point me to a list what these numbers mean? Detlef
[toc] | [next] | [standalone]
| From | The Wanderer <wanderer@fastmail.fm> |
|---|---|
| Date | 2024-03-21 12:20 +0100 |
| Message-ID | <IkoCK-CUg-9@gated-at.bofh.it> |
| In reply to | #268466 |
[Multipart message — attachments visible in raw view] — view raw
On 2024-03-21 at 05:02, Detlef Vollmann wrote: > This is essentially a follow-up on my question about the > 64bit time_t transition. > I'm trying to upgrade some packages manually. > For this, I'm trying to understand the dependencies. > > 'apt-cache showpkg libssl3t64' gives me this: You might also try 'apt-cache show libssl3t64', and compare the dependency-related parts of the results. >> Dependencies: >> 3.1.5-1.1 - libc6 (2 2.34) libssl3 (3 3.1.5-1.1) openssh-client (3 1:9.4p1) openssh-server (3 1:9.4p1) python3-m2crypto (3 0.38.0-4) libssl3 (0 (null)) libssl3:i386 (3 3.1.5-1.1) libssl3:i386 (0 (null)) openssh-client:i386 (3 1:9.4p1) openssh-server:i386 (3 1:9.4p1) python3-m2crypto:i386 (3 0.38.0-4) libssl3t64:i386 (35 3.1.5-1.1) libssl3t64:i386 (38 3.1.5-1.1) > > I'm trying to understand, what the numbers in parentheses mean. > The second numbers are obviously version numbers. > I guess the first numbers are dependency types, but I have no idea, > what they mean. > The man page says "For the specific meaning of the remainder of the > output it is best to consult the apt source code." > I'd like to avoid this. Can anybody point me to a list what these > numbers mean? I don't think I even knew 'showpkg' was a verb for apt-cache, before this. That said, by comparing against the output of 'apt-cache show' for the same package name: it looks as if '2' is 'Depends:' and '3' is 'Breaks:'. I'm less sure about '35' and '38', but they might be 'Replaces:' and 'Provides" in some order. I was actually running the commands against the non-'t64' version of the package, because the one with that suffix isn't available in my configured repositories yet. That one doesn't include the '0' dependencies. Based on the fact that those dependencies are listed for the 't64' version of the package, my guess is that '0' is 'Conflicts:'. -- The Wanderer The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore all progress depends on the unreasonable man. -- George Bernard Shaw
[toc] | [prev] | [next] | [standalone]
| From | Sven Joachim <svenjoac@gmx.de> |
|---|---|
| Date | 2024-03-21 23:10 +0100 |
| Message-ID | <IkyLL-J6z-13@gated-at.bofh.it> |
| In reply to | #268466 |
On 2024-03-21 10:02 +0100, Detlef Vollmann wrote:
> This is essentially a follow-up on my question about the
> 64bit time_t transition.
> I'm trying to upgrade some packages manually.
> For this, I'm trying to understand the dependencies.
>
> 'apt-cache showpkg libssl3t64' gives me this:
>> Dependencies: 3.1.5-1.1 - libc6 (2 2.34) libssl3 (3 3.1.5-1.1)
>> openssh-client (3 1:9.4p1) openssh-server (3 1:9.4p1)
>> python3-m2crypto (3 0.38.0-4) libssl3 (0 (null)) libssl3:i386 (3
>> 3.1.5-1.1) libssl3:i386 (0 (null)) openssh-client:i386 (3 1:9.4p1)
>> openssh-server:i386 (3 1:9.4p1) python3-m2crypto:i386 (3 0.38.0-4)
>> libssl3t64:i386 (35 3.1.5-1.1) libssl3t64:i386 (38 3.1.5-1.1)
>
> I'm trying to understand, what the numbers in parentheses mean.
> The second numbers are obviously version numbers.
> I guess the first numbers are dependency types, but I have no idea,
> what they mean.
> The man page says "For the specific meaning of the remainder of the
> output it is best to consult the apt source code."
> I'd like to avoid this. Can anybody point me to a list what these
> numbers mean?
No, but I can point you to the source code. In cmdline/apt-cache.cc we
can find this passage where "Dependencies:" is printed:
,----
| cout << "Dependencies: " << endl;
| for (pkgCache::VerIterator Cur = Pkg.VersionList(); Cur.end() != true; ++Cur)
| {
| cout << Cur.VerStr() << " - ";
| for (pkgCache::DepIterator Dep = Cur.DependsList(); Dep.end() != true; ++Dep)
| cout << Dep.TargetPkg().FullName(true) << " (" << (int)Dep->CompareOp << " " << DeNull(Dep.TargetVer()) << ") ";
| cout << endl;
| }
`----
Don't worry if you do not understand everything, neither do I. The
mysterious first number is (int)Dep->CompareOp, so we need to figure out
what that is. The "Dep" structure is declared in apt-pkg/pkgcache.h:
,----
| // These are all the constants used in the cache structures
|
| // WARNING - if you change these lists you must also edit
| // the stringification in pkgcache.cc and also consider whether
| // the cache file will become incompatible.
| struct Dep
| {
| enum DepType {Depends=1,PreDepends=2,Suggests=3,Recommends=4,
| Conflicts=5,Replaces=6,Obsoletes=7,DpkgBreaks=8,Enhances=9};
| /** \brief available compare operators
|
| The lower 4 bits are used to indicate what operator is being specified and
| the upper 4 bits are flags. OR indicates that the next package is
| or'd with the current package. */
| enum DepCompareOp {NoOp=0,LessEq=0x1,GreaterEq=0x2,Less=0x3,
| Greater=0x4,Equals=0x5,NotEquals=0x6,
| Or=0x10, /*!< or'ed with the next dependency */
| MultiArchImplicit=0x20, /*!< generated internally, not spelled out in the index */
| ArchSpecific=0x40 /*!< was decorated with an explicit architecture in index */
| };
| };
`----
Using that information it is possible to decipher the numbers. For
example, "libc6 (2 2.34)" means that libssl3t64 has a relationship with
libc6 (>= 2.34), "libssl3 (3 3.1.5-1.1)" means a relationship with
libssl3 (<< 3.1.5-1.1), and the strange numbers 35 and 38 for
libssl3t64:i386 appear because 0x20 (==32) is added (the
MultiArchImplicit flag).
How useful is all that? Probably not much, considering that we cannot
even tell the type of relation. It is probably better to just use
"apt-cache show".
Cheers,
Sven
[toc] | [prev] | [standalone]
Back to top | Article view | linux.debian.user
csiph-web