Clean up some messy Makefile stuff so that this can be built into the
kernel.
This commit is contained in:
parent
743d0f6640
commit
b953df2a33
@ -28,6 +28,19 @@
|
||||
#ifndef __INCmvOsBsdh
|
||||
#define __INCmvOsBsdh
|
||||
|
||||
/* Taken out of the Makefile magic */
|
||||
#define __KERNEL__ 1
|
||||
#define KERNEL 1
|
||||
#define _KERNEL 1
|
||||
#define _FREEBSD_ 1
|
||||
|
||||
/*
|
||||
* This binary object core for this driver is only for x86, so this constant
|
||||
* will not change.
|
||||
*/
|
||||
#define BITS_PER_LONG 32
|
||||
#define DRIVER_VERSION "1.1"
|
||||
|
||||
#if DBG
|
||||
#define MV_DEBUG_LOG
|
||||
#endif
|
||||
|
@ -221,7 +221,6 @@ int hpt_add_disk_to_array(_VBUS_ARG DEVICEID idArray, DEVICEID idDisk);
|
||||
#define REBUILD_PARITY 2
|
||||
#define VERIFY 3
|
||||
|
||||
extern char DRIVER_VERSION[];
|
||||
/**********************************************************/
|
||||
static __inline struct cam_periph *
|
||||
hpt_get_periph(int path_id,int target_id)
|
||||
|
@ -10,26 +10,13 @@ HPTMV= ${.CURDIR}/../../contrib/dev/hptmv
|
||||
KMOD= hptmv
|
||||
SRCS= opt_scsi.h opt_cam.h
|
||||
SRCS+= bus_if.h device_if.h pci_if.h
|
||||
SRCS+= mv.c entry.c vers.c
|
||||
SRCS+= mv.c entry.c
|
||||
SRCS+= ioctl.c hptproc.c gui_lib.c
|
||||
OBJS+= raid.o
|
||||
OBJS+= hptmvraid.o
|
||||
|
||||
raid.o: ${HPTMV}/i386-elf.raid.o.uu
|
||||
hptmvraid.o: ${HPTMV}/i386-elf.raid.o.uu
|
||||
uudecode -p < ${HPTMV}/i386-elf.raid.o.uu > ${.TARGET}
|
||||
|
||||
#
|
||||
# Driver version number.
|
||||
#
|
||||
.ifndef DRIVER_VERSION
|
||||
DRIVER_VERSION = "1.1"
|
||||
.endif
|
||||
|
||||
vers.c: mv.o
|
||||
@echo char DRIVER_VERSION[]=\"$(DRIVER_VERSION)\"\; > ${.OBJDIR}/$(.TARGET)
|
||||
|
||||
# calculate system pointer size.
|
||||
BITS_PER_LONG= 4
|
||||
|
||||
#
|
||||
# Debug Options:
|
||||
#
|
||||
@ -55,8 +42,6 @@ DEBUGOPT += -DDEBUG_LEVEL=1
|
||||
DEBUGOPT += -DFOR_DEMO
|
||||
.endif
|
||||
|
||||
CFLAGS+= -D__KERNEL__=1 -DKERNEL=1 -D_KERNEL=1 -D_FREEBSD_=1 ${DEBUGOPT} \
|
||||
-DBITS_PER_LONG=$(BITS_PER_LONG)
|
||||
CFLAGS+= ${DEBUGOPT}
|
||||
|
||||
CLEANFILES += vers.c
|
||||
.include <bsd.kmod.mk>
|
||||
|
Loading…
Reference in New Issue
Block a user