view conf/makefiles/mts/mh @ 12:441a2190cfae

Lion fix
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Sat, 21 Apr 2012 13:10:49 +0900
parents bce86c4163a3
children
line wrap: on
line source

##############################################################################
#    Instructions to Make, for compilation of standalone-MTS library
#
#	@(MHWARNING)
# @(#)$Id: mh,v 1.1.1.1 2005/04/18 14:46:03 kono Exp $
##############################################################################

# The following entries were inserted during MH configuration
OPTIONS=	@(MHOPTIONS) -I..

CC	=	@(MHCOMPILER)
@BEGIN: OPTIM
CFLAGS	=	$(OPTIONS)
@END: OPTIM
@BEGIN: DEBUG
CFLAGS	=	      $(OPTIONS)
@END: DEBUG
LINT	=	lint
LFLAGS	=	-bhu $(OPTIONS)
LLIBS	=	
CP	=	@(CP)
LN	=	@(LN)

LIB	=	mhmts.a

CFILES	=	hosts.c netmail.c uucp.c
OFILES	=	hosts.o netmail.o uucp.o


@BEGIN: OPTIM
##############################################################################
#	Generation Rules
##############################################################################
.c.o:;		$(CC) $(CFLAGS) -c $*.c
@BEGIN: NEWLOAD
		-ld -x -r $@
		mv a.out $@
@END: NEWLOAD
@BEGIN: OLDLOAD
		${CC} -s -o $@
@END: OLDLOAD


@END: OPTIM
##############################################################################
#	Here it is...
##############################################################################

all:		$(LIB)
depend:;
lint:		l-mhmts

$(LIB):		$(OFILES)
		-if [ -f $@ ]; then \
		    mv $@ z$@; \
		fi
@BEGIN: RANLIB
		ar r $@ $(OFILES); ranlib $@
@END: RANLIB
@BEGIN: LORDER
		ar r $@ `lorder $(OFILES) | tsort`
@END: LORDER
		-rm -f ../libmts.a
		-cd ..; $(LN) mh/$@ libmts.a
		-rm -f ../llib-lmts
		-cd .. ; $(LN) mh/llib-lmhmts llib-lmts
		-@ls -l $@
		-@echo "standalone-MTS library built normally"

l-mhmts:;	$(LINT) $(LFLAGS) $(CFILES) $(LLIBS)

hosts.o:	Makefile
netmail.o:	Makefile
uucp.o:		Makefile


##############################################################################
#	Miscellaneous tasks
##############################################################################

unconfig:	distribution
		-rm -f Makefile

distribution:   clean

clean:		unclean
		-rm -f *.o $(LIB) z$(LIB)

unclean:;	-rm -f _* :* core *.core