Makefile 1.48 KB
#!smake
#ident	"$Revision: 1.1.1.1 $

DEPTH?=..
include $(ROOT)/usr/include/make/kcommondefs
KPATH=$(TOP)/master.d
.PATH:$(KPATH)

# N.B. install rules below depend on $(MASTERS) == "" for non-u64 systems
MASTERS=

#if $(CPUBOARD) == "IP22"
MASTERS=u64
#endif


SYSTEMGEN=system.u64
DOTSMFILE=u64.sm
SYSTEMS=system.ship system.dl system.kdebug

TARGETS=$(SYSTEMS)

# Options passed to all versions
# SYSCONFIGDEFS can come from klocaldefs
# The -ICPUINSTDIR is for developers, the -I. is for production kernel
PRODOPTS= $(CDEFS) $(SYSCONFIGDEFS) -DDCCOPTS="$(CFLAGS)" -DDLDOPTS="$(LDFLAGS)" -DCPUINSTDIRINC="-I$(ROOT)/$(CPUINSTDIR) -I." -DGFXBOARD_"$(GFXBOARD)"

# Options on system.gen
SHIPOPTS= -Dship $(PRODOPTS)
MROPTS= -Dnoprobe -Dmr $(PRODOPTS)
KDEBUGOPTS= -Dkdebug -Dnoprobe $(PRODOPTS)
DLOPTS= -Ddiskless -Dnoprobe $(PRODOPTS)
INTDIRT=$(SYSTEMS)
INSTFILE= $(INSTALL) -m 444 -idb "config(update)"
INSTMAST= $(INSTFILE) -F $(MASTERDIR)
SHIP_INSTMAST= $(INSTFILE) -F $(SHIP_MASTERDIR)

#
# Rules
#
KCOMMONPREF=m
include $(ROOT)/usr/include/make/kcommonrules

$(KCOMMONPREF)default:$(TARGETS)
	if test -n "$(MASTERS)"; then \
	    cd $(KPATH);\
	    RAWIDB= $(INSTALL) -F $(MASTERDIR) -m 444 $(MASTERS) ;\
	fi

$(KCOMMONPREF)install: ksysinstall
	if test -n "$(MASTERS)"; then \
	    cd $(KPATH) ;\
	    $(SHIP_INSTMAST) $(MASTERS) ;\
	fi

mrmtargets!
	rm -f $(TARGETS)
	if test -d $(ROOT)/$(CPUINSTDIR); then \
		cd $(ROOT)/$(CPUINSTDIR); \
		rm -fr */u64.sm; \
	fi

mclean!kclean
mclobber:kclobber
mlint!mlint