Makefile revision 47885
147885Sroger# Makefile for the bktr Brooktree Bt848/Bt878 PCI video capture device 247885Sroger# Using the new FreeBSD 4.x device driver API (newbus) the Bt848 driver 347885Sroger# can be loaded dynamically both in the boot loader phase and once 447885Sroger# the system has booted. 547885Sroger# The driver can also be unloaded, recompiled and reloaded. 647885Sroger# 747885Sroger# Use kldload bktr and kldunload bktr to load/unload the driver 847885Sroger# 947885Sroger# Note - as the driver requires contiguous memory, loading the driver once 1047885Sroger# memory has filled or become fragmented may fail. 1147885Sroger 1247885Sroger# $Id$ 1347885Sroger 1447885SrogerS = ${.CURDIR}/../.. 1547885Sroger.PATH: $S/pci 1647885SrogerKMOD = bktr 1747885SrogerSRCS = brooktree848.c bktr.h opt_devfs.h opt_bktr.h pci.h smbus.h bus_if.h device_if.h pci_if.h 1847885SrogerCLEANFILES += bktr.h opt_devfs.h opt_bktr.h pci.h smbus.h bus_if.h device_if.h pci_if.h 1947885SrogerFLAGS += ${DEBUG_FLAGS} 2047885Sroger 2147885Srogerbktr.h: 2247885Sroger echo "#define NBKTR 1" > bktr.h 2347885Sroger 2447885Srogerpci.h: 2547885Sroger echo "#define NPCI 1" > pci.h 2647885Sroger 2747885Srogersmbus.h: 2847885Sroger # Do not use SMBUS/IICBUS. Use the old i2c code self contained in 2947885Sroger # the bt848 driver. 3047885Sroger echo "#define NSMBUS 0" > smbus.h 3147885Sroger 3247885Srogeropt_devfs.h: 3347885Sroger touch opt_devfs.h 3447885Sroger 3547885Srogeropt_bktr.h: 3647885Sroger touch opt_bktr.h 3747885Sroger 3847885Srogerdevice_if.h: $S/kern/makedevops.pl $S/kern/device_if.m 3947885Sroger perl5 $S/kern/makedevops.pl -h $S/kern/device_if.m 4047885Sroger 4147885Srogerbus_if.h: $S/kern/makedevops.pl $S/kern/bus_if.m 4247885Sroger perl5 $S/kern/makedevops.pl -h $S/kern/bus_if.m 4347885Sroger 4447885Srogerpci_if.h: $S/kern/makedevops.pl $S/pci/pci_if.m 4547885Sroger perl5 $S/kern/makedevops.pl -h $S/pci/pci_if.m 4647885Sroger 4747885Sroger.include <bsd.kmod.mk> 48