#
# Sun RPC is a product of Sun Microsystems, Inc. and is provided for
# unrestricted use provided that this legend is included on all tape
# media and as a part of the software program in whole or part.  Users
# may copy or modify Sun RPC without charge, but are not authorized
# to license or distribute it to anyone else except as part of a product or
# program developed by the user or with the express written consent of
# Sun Microsystems, Inc.
#
# SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
# WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
# PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
#
# Sun RPC is provided with no support and without any obligation on the
# part of Sun Microsystems, Inc. to assist in its use, correction,
# modification or enhancement.
#
# SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
# INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
# OR ANY PART THEREOF.
#
# In no event will Sun Microsystems, Inc. be liable for any lost revenue
# or profits or other special, indirect and consequential damages, even if
# Sun has been advised of the possibility of such damages.
#
# Sun Microsystems, Inc.
# 2550 Garcia Avenue
# Mountain View, California  94043
#
# @(#)Makefile      1.11 91/03/11 TIRPC 1.0 <MODIFIED>
#
# Copyright (c) 1990 by Sun Microsystems, Inc.
#

#
# Makefile for loadable drivers (and non-loadable drivers)
#

DESTDIR =
INSTALLDIR = $(DESTDIR)/install
SYSDIR  = $(INSTALLDIR)/sys
HDRSDIR = $(SYSDIR)/nettli
ETCDIR  = $(INSTALLDIR)/etc
MODULEDIR = $(ETCDIR)/modules

LDFLAGS = -r
LINT	= lint
INCFLAGS= -I. -I.. -I$(DESTDIR)/include
CPPFLAGS= $(INCFLAGS) -DKERNEL -D`mach`
# prevent us from getting changed CFLAGS.  -O4 will break tcp_tli.o
KERNEL_CFLAGS = -O



#
# These conditional defines are for building the loadable module objects
#
udp_tli_sun4.o  := CPPFLAGS += -DDYNAMIC
udp_tli_sun4c.o := CPPFLAGS += -DDYNAMIC
lodg_tli_sun4.o := CPPFLAGS += -DDYNAMIC
lodg_tli_sun4c.o:= CPPFLAGS += -DDYNAMIC

MODULES = udptli_sun4.o lodgtli_sun4.o udptli_sun4c.o lodgtli_sun4c.o
INITS   = lodgtli_load.sh udptli_load.sh
# OBJECTS are for the non-loadable version of the drivers
OBJECTS = udp_tli.o lodg_tli.o

UDPHDRS =	udp_tli.h \
	udp_tlivar.h

UDPOBJS =	udp_tlisubr.o \
	udp_tliaux.o

LODGHDRS =	lodg_tli.h

LODGOBJS =

HDRS    = $(LODGHDRS) $(UDPHDRS)
OBJS    = $(LODGOBJS) $(UDPOBJS) $(OBJECTS)

install:
	if [ ! -d $(INSTALLDIR) ]; then\
		install -d -m 755 -o root -g staff $(INSTALLDIR);\
	fi
	if [ ! -d $(SYSDIR) ]; then\
		install -d -m 755 -o root -g staff $(SYSDIR);\
	fi
	if [ ! -d $(HDRSDIR) ]; then\
		install -d -m 755 -o root -g staff $(HDRSDIR);\
	fi
	install -m 644 -o root -g staff $(HDRS) $(HDRSDIR)
# The next line is for the non-loadable version of drivers.  We include
# them in the release in case target system has no loadable driver slots
# available
	install -m 644 -o root -g staff $(OBJECTS) $(UDPOBJS) $(LODGOBJS) $(HDRSDIR)
	if [ ! -d $(ETCDIR) ]; then\
		install -d -m 755 -o root -g staff $(ETCDIR);\
	fi
	if [ ! -d $(MODULEDIR) ]; then\
		install -d -m 755 -o root -g staff $(MODULEDIR);\
	fi
	install -m 755 -o root -g staff $(INITS) $(MODULEDIR)
	install -m 755 -o root -g staff $(MODULES) $(MODULEDIR)

lint:
	@echo "No source files in sys/nettli."

clean:

clobber: clean

FORCE:
