#
# Makefile for replacement beeper
#

KERNEL_SOUND_SRC_DIR	=	/usr/src/linux/drivers/sound

CC				=	gcc
CFLAGS			=	-m486 -Wall -O6 -D__KERNEL__ -DLINUX -I$(KERNEL_SOUND_SRC_DIR)
BEEP_SRC		=	beep.c
BEEP_OBJ		=	beep.o

all:			check-sound-dir Beep.o

check-sound-dir:
	@if [ ! -d $(KERNEL_SOUND_SRC_DIR) ]; then \
		echo 'You need to modify the Makefile: the default kernel sound' ; \
		echo 'drivers source directory ($(KERNEL_SOUND_SRC_DIR)) is wrong.' ; \
		exit 1 ; \
	fi

Beep.o:		$(BEEP_OBJ)
	$(LD) -r -o $@ $^
