On Thu, 2008-12-04 at 12:36 +1100, Jayen Ashar wrote: > Hi, > > I've found that the e1000e driver isn't up-to-date for some new hardware > our school has received. I'm trying to package it [properly], but I'm > having trouble finding instructions on packaging a kernel module. You should build the package in two stages. In the first stage you build a "binary" package containing the source tarball, plus information for module-assistant. In the second stage you use module-assistant to build for a specific kernel version. Read the documentation for module-assistant. > If someone could look at what I tried (below) and tell me what I'm doing > wrong, that would be appreciated. Thanks. > > * lspci to find hardware id (0x10de) > * google search to find hardware name (intel 82567LM-3) > * intel download search to find driver > * > http://downloadcenter.intel.com/confirm.aspx?httpDown=http://downloadmirror.intel.com/15817/eng/e1000e-0.5.8.2.tar.gz&agr=&ProductID=3003&DwnldId=15817&strOSs=&OSFullName=〈=eng > tar -zxvf e1000e-0.5.8.2.tar.gz > cd e1000e-0.5.8.2/ > cat > Makefile << end > default: > $(MAKE) -C src default > install: > $(MAKE) -C src install > end > dh_make -e jayen@science.unsw.edu.au -f ../e1000e-0.5.8.2.tar.gz -s -p > e1000e > sed -i s/INSTALL_MOD_PATH/DESTDIR/ src/Makefile > fakeroot debian/rules binary > > sudo dpkg --force-overwrite -i e1000e_0.5.8.2-1_i386.deb > > The main thing I'm uncomfortable with is the --force-overwrite, but I'm > also worried I'm using -s (single binary) instead of -k (kernel module) > with dh_make. What can I do to not make it so hacky? Instead of overwriting the module that comes with the kernel, you should install the replacement in /lib/modules/$(KVER)/updates (depmod automatically gives this directory higher priority). You will probably need to patch the makefile to do this. Ben. -- Ben Hutchings If God had intended Man to program, we'd have been born with serial I/O ports.
Attachment:
signature.asc
Description: This is a digitally signed message part