[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Question about rules file

Martin Kelly <aomighty@gmail.com> writes:

> I am creating a package for the of rtl8180-sa2400 drivers
> (http://sourceforge.net/projects/rtl8180-sa2400) and I have a question
> about editing the rules file in debian/ in the source archive after
> dh_make.

> I wish for the package to install some files in three places:
> 1. /lib/modules/$(uname -r)/kernel/wireless (kernel modules)
> 2. /lib/modules/$(uname -r)/kernel/wireless/alg (more kernel modules)
> 3. /usr/sbin (some load and unload module scripts)

> I edited the Makefile to install into DESTDIR and defined DESTDIR to be
> /lib/modules/$(uname -r)/kernel/wireless so that should work.

You almost certainly don't want to be using uname -r.  That installs
modules into the directories for the currently running kernel, and it is
quite common for people to want to build modules for the *new* kernel that
they just installed, before they reboot and start actually running it.

You probably want to use the kernel-package framework for handling this
sort of thing, since that's used by both kernel-package and
module-assistant and handles all of these interesting special cases.  See
/usr/share/doc/kernel-package/README.modules, particularly at the end of
that file.

Russ Allbery (rra@debian.org)               <http://www.eyrie.org/~eagle/>

Reply to: