Consider two packages, foo and bar. foo's PKGBUILD contains:
whereas bar's contains:
I run packer -S foo bar.
Before packer does anything else, it scrapes dependencies from the various packages' PKGBUILDs by sourcing them. After doing this, pkgname will be an array: (bar baz).
Now packer builds foo, and the first thing it does is source foo's PKGBUILD, which contains pkgname=foo. Unfortunately, bash is terrible, and this leaves pkgname still as an array, but now containing (foo baz).
$ pkgname=(bar baz)
$ echo "${pkgname[@]}"
bar baz
$ pkgname=foo
$ echo "${pkgname[@]}"
foo baz
The foo build will continue, and only at the very end will packer abort the installation with the infuriatingly nonsensical message:
error: 'baz-*.pkg.tar.xz': could not find or read package
This happens to me with mozc, which names itself (mozc ibus-mozc), producing errors about ibus-mozc-*.pkg.tar.xz not being found. This is particularly confusing because ibus-mozc is itself a separate package, so I've tried simply not installing it at the same time, which of course didn't help. (Come to think of it, if mozc can produce ibus-mozc as part of its build, why does packer end up building both?)
packer should take care to completely erase pkgname before a build.
Consider two packages,
fooandbar.foo'sPKGBUILDcontains:whereas
bar's contains:I run
packer -S foo bar.Before
packerdoes anything else, it scrapes dependencies from the various packages'PKGBUILDs by sourcing them. After doing this,pkgnamewill be an array:(bar baz).Now
packerbuildsfoo, and the first thing it does is sourcefoo'sPKGBUILD, which containspkgname=foo. Unfortunately, bash is terrible, and this leavespkgnamestill as an array, but now containing(foo baz).The
foobuild will continue, and only at the very end willpackerabort the installation with the infuriatingly nonsensical message:This happens to me with
mozc, which names itself(mozc ibus-mozc), producing errors aboutibus-mozc-*.pkg.tar.xznot being found. This is particularly confusing becauseibus-mozcis itself a separate package, so I've tried simply not installing it at the same time, which of course didn't help. (Come to think of it, ifmozccan produceibus-mozcas part of its build, why doespackerend up building both?)packershould take care to completely erasepkgnamebefore a build.