Jguer / yay

Yet another Yogurt - An AUR Helper written in Go
GNU General Public License v3.0
10.95k stars 358 forks source link

Yay pulls in other architectures' depends #2344

Open drws opened 7 months ago

drws commented 7 months ago

Affected Version

yay v12.2.0 - libalpm v13.0.2

Describe the bug

If a PKGBUILD contains:

...
arch=("x86_64" "i686")
depends_i686=(...)
...

...Yay installs dependencies from depends_i686 even on an x86_64 system. These are orphans afterwards.

Reproduction Steps

  1. Install a package with depends_i686 declared on an x86_64 system.
  2. Observe dependencies from depends_i686 pulled in even though they're unnecessary.

Expected behavior

The depends_i686 packages are not installed.

Jguer commented 7 months ago

This is unfortunately a RPC limitation. We can solve with SRCINFO parsing but it's somewhat hacky.

drws commented 7 months ago

Anything would be useful (even if not enabled by default). This is a serious limitation in a multiplatform world, so there's probably hope for relevant fix upstream someday.