#
# $Header: makefile,v 1.1 87/09/18 10:41:27 root Exp $
#
#ident	"@(#):makefile	1.6"
#	Copyright (c) 1984 AT&T
#	  All Rights Reserved

#	THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF AT&T
#	The copyright notice above does not evidence any
#	actual or intended publication of such source code.

#ident	"@(#)libc-port:print/makefile	1.12"
#
# makefile for libc/port/print
#
#
.SUFFIXES: .no .np .fo .fp 
CC=cc
CFLAGS=-O
C81FLAGS=  -f -20 $(CFLAGS)
PROF=
NONPROF=
ROOT=
INC=$(ROOT)/usr/include
INCLIBC=../../inc
DEFLIST=
SDEFLIST=
INCLIST=-I$(INCLIBC)


OBJECTS = \
doprnt.no	fprintf.no	printf.no	sprintf.no	vfprintf.no\
vprintf.no	vsprintf.no

POBJECTS = \
doprnt.np	fprintf.np	printf.np	sprintf.np	vfprintf.np\
vprintf.np	vsprintf.np

FOBJECTS=\
doprnt.fo	fprintf.fo	printf.fo	sprintf.fo	vfprintf.fo\
vprintf.fo	vsprintf.fo

FPOBJECTS=\
doprnt.fp	fprintf.fp	printf.fp	sprintf.fp	vfprintf.fp\
vprintf.fp	vsprintf.fp

nonprof10: $(OBJECTS)

prof10: $(POBJECTS)

nonprof81: $(FOBJECTS)

prof81: $(FPOBJECTS)


printf.no printf.np printf.fo printf.fp: print.h $(INC)/ctype.h \
	$(INC)/stdio.h $(INC)/values.h $(INCLIBC)/shlib.h
doprnt.no doprnt.np doprnt.fo doprnt.fp: print.h $(INC)/ctype.h \
	$(INC)/stdio.h $(INC)/values.h $(INCLIBC)/shlib.h
fprintf.no fprintf.np fprintf.fo fprintf.fp: print.h $(INC)/ctype.h \
	 $(INC)/stdio.h $(INC)/values.h $(INCLIBC)/shlib.h
sprintf.no sprintf.np sprintf.fo sprintf.fp: print.h $(INC)/ctype.h \
	 $(INC)/stdio.h $(INC)/values.h $(INCLIBC)/shlib.h
vfprintf.no vfprintf.np vfprintf.fo vfprintf.fp: print.h $(INC)/ctype.h \
	 $(INC)/stdio.h $(INC)/values.h $(INCLIBC)/shlib.h
vsprintf.no vsprintf.np vsprintf.fo vsprintf.fp: print.h $(INC)/ctype.h \
	 $(INC)/stdio.h $(INC)/values.h $(INCLIBC)/shlib.h
vprintf.no vprintf.np vprintf.fo vprintf.fp: print.h $(INC)/ctype.h \
	 $(INC)/stdio.h $(INC)/values.h $(INCLIBC)/shlib.h

.c.no .c.np:
	$(NONPROF)@echo $*.c:
	$(NONPROF)$(CC) $(DEFLIST) $(SDEFLIST) $(INCLIST) $(CFLAGS) -c $*.c &&\
	$(NONPROF)mv $*.o $*.no
	$(PROF)@echo $*.c:
	$(PROF)$(CC) $(DEFLIST) $(INCLIST) $(CFLAGS) -c -p $*.c && mv $(*F).o $*.np

.c~.no .c~.np:
	$(GET) s.$*.c
	$(NONPROF)@echo $*.c:
	$(NONPROF)$(CC) $(DEFLIST) $(SDEFLIST) $(INCLIST) $(CFLAGS) -c $*.c &&\
	$(NONPROF)mv $*.o $*.no
	$(PROF)@echo $*.c:
	$(PROF)$(CC) $(DEFLIST) $(INCLIST) $(CFLAGS) -c -p $*.c   && mv $(*F).o $*.np
	rm $*.c

.c.fo .c.fp:
	$(NONPROF)@echo $*.c:
	$(NONPROF)$(CC) $(DEFLIST) $(SDEFLIST) $(INCLIST) $(C81FLAGS) -c $*.c
	$(NONPROF)mv $*.o $*.fo
	$(PROF)@echo $*.c:
	$(PROF)$(CC) $(DEFLIST) $(INCLIST) $(C81FLAGS) -c -p $*.c && mv $(*F).o $*.fp

.c~.fo .c~.fp:
	$(GET) s.$*.c
	$(NONPROF)@echo $*.c:
	$(NONPROF)$(CC) $(DEFLIST) $(SDEFLIST) $(INCLIST) $(C81FLAGS) -c $*.c
	$(NONPROF)mv $*.o $*.fo
	$(PROF)@echo $*.c:
	$(PROF)$(CC) $(DEFLIST) $(INCLIST) $(C81FLAGS) -c -p $*.c   && mv $(*F).o $*.fp
	rm $*.c

clean:
	rm -rf *.no *.np *.fo *.fp
