#
# Copyright (c) 1988 University College London
# All rights reserved.
#
# Redistribution and use in source and binary forms are permitted
# provided that the above copyright notice and this paragraph are
# duplicated in all such forms and that any documentation,
# advertising materials, and other materials related to such
# distribution and use acknowledge that the software was developed
# by the Department of Computer Science, University College London.
# The name of the University may not be used to
# endorse or promote products derived from this software without
# specific prior written permission.
# THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#

# Makefile for UNIX objects and attributes
#
# By Graham Knight, after George Pavlou, May 1991


LIBS	=	libuxmib.a
HFILES	=	UxAttr.h \
		uxObj1.h uxObj1.inc.h \
		uxObj2.h uxObj2.inc.h uxObj2.inc.hcl
CLEANFILES =	uxObj1.cc uxObj1.h uxObj2.cc uxObj2.h \
		gdmo.log oidtable.tmp Makefile.mo
OMIBFILES =	uxObj1.o uxObj2.o


all:		lib

lib:		$(LIBS)

glib:		$(GLIBS)

install:	install-h install-lib

clean:;		rm -f *.o *.a *.ph core $(CLEANFILES) *~

install-lib:	$(LIBS)
		@for i in $(LIBS); \
		    do (echo "cp $$i $(LIB)/$$i; ranlib $(LIB)/$$i"; \
			      cp $$i $(LIB)/$$i; ranlib $(LIB)/$$i); \
		    done

install-glib:

install-h:	$(HFILES)
		@for i in $(HFILES); \
		    do (echo "cp $$i $(H)/$$i"; \
			      cp $$i $(H)/$$i); \
		    done

libuxmib.a:	$(OMIBFILES)
		ar ruv libuxmib.a $(OMIBFILES)
		ranlib libuxmib.a

uxObj1.o:	uxObj1.h uxObj1.inc.h uxObj1.inc.cc UxAttr.h

uxObj2.o:	uxObj2.h uxObj2.inc.h uxObj2.inc.hcl uxObj2.inc.cc \
		uxObj1.h uxObj1.inc.h

uxObj1.h uxObj1.cc uxObj2.h uxObj2.cc:	MIB.gdmo MIB.syntax.dat
		$(GDMO-CMPL) MIB.gdmo -s MIB.syntax.dat

