# Ported to QNX from Linux by Alan Chester (achester@lucent.com) on 11/15/96.


#
# Define this if you want pnpdump to dump the device configuration
# registers (not normally useful as it is before configuration)
#
#PNPDUMPFLAGS = -DDUMPREGS
#
# Define REALTIME if you want to run with realtime scheduling, this
# cuts down the isolation and configuration time for a single card
# from 6s to less than 100ms.
# NOTE though, if it hangs, no other process will get processor time.
# You can use ^C to kill it.
# This can only be used with recent kernels, and I have only tested
# it on Linux.2.0.0. It certainly won't work on 1.2.13.
# nanosleep only went into the kernel at 1.3.67, but whether it
# worked or not, I know not.
#
#PNPFLAGS = -DREALTIME
PNPFLAGS = 

CFLAGS = -T1 -5 -g -O -M $(PNPDUMPFLAGS) $(PNPFLAGS)

all:	pnpdump isapnp

pnpdump: pnpdump.o
	cc -g -o pnpdump -T1 -5 pnpdump.o

pnpdump.o: pnp.h Makefile

isapnp: isapnp.o 
	cc -g -o isapnp -T1 -5 isapnp.o

# QNX flex can't parse the file syntax, so use the isapnp.c file
# that was created on a Linux system.
isapnp.o: pnp.h isapnp.c

isapnp.c: pnp.h Makefile
	#flex -S/usr/local/lib/flex.skel -i -t isapnp.y > isapnp.c

clean:
	rm -f *.o

clobber: spotless

spotless: clean
	rm -f pnpdump isapnp

