[aur-general] PKGBUILD review request

Dave Reisner d at falconindy.com
Mon Apr 30 09:16:32 EDT 2012

On Mon, Apr 30, 2012 at 11:27:54AM +0200, Bernhard D wrote:
> Hi,
> I wrote a PKGBUILD for the driver package from TBS (www.tbsdtv.com) for
> their dvb cards. I split packaging for modules and firmware and patched

No, please don't make this a split package. You need them both at the
same time, there's no reason to make a split package with a single file
in each.

> the sources to install the modules to /lib/modules/kernelversion/updates

This is wrong. updates/ are for... updates. It's admin territory for
overriding existing (in tree) kernel modules with backports and whatnot.

> and the firmware to /lib/firmware/updates to avoid overwriting existing
> files. It's the first time I'm building kernel modules and there are
> two things I'm not sure about:
> - Are the files under /lib/firmware/updates found and do they have
> precedence?

Yes they have precedence, but for the same reason as above you should
not be installing things here. Additionally, you must adhere to the path
that the module dictates for its firmware. radeon, for example, expects
firmware under radeon/. You can see exactly what it expects with
modinfo, e.g.

  $ modinfo -k 3.3.4-1-ARCH -F firmware radeon | sed 3q

So in this case, firmware is looked for in each of these base paths (in

  /usr/lib/firmware/updates/$(uname -r)
  /lib/firmware/updates/$(uname -r)
  /usr/lib/firmware/$(uname -r)
  /lib/firmware/$(uname -r)

The search stops as soon as udev finds a match.

> - Is "depmod -a" after install, upgrade and removal the right approach
> to rebuild the module dependencies?

No, this is overkill. You should know exactly what kernel you're
building against so only run depmod for that one kernel.


More information about the aur-general mailing list