From 237d2d6ab15f0e240e30411707b3aae268819d1b Mon Sep 17 00:00:00 2001 From: Keith Bostic Date: Fri, 20 May 1988 20:48:25 -0800 Subject: [PATCH] restructuring libc SCCS-vsn: lib/libc/net/SCCS/hosttable/Makefile 5.6 SCCS-vsn: lib/csu/vax/Makefile 5.6 SCCS-vsn: lib/libcompat/4.1/Makefile 5.7 SCCS-vsn: lib/libcompat/4.3/Makefile 5.2 SCCS-vsn: lib/csu/tahoe/Makefile 5.3 --- usr/src/lib/csu/tahoe/Makefile | 42 +++++++++++-------- usr/src/lib/csu/vax/Makefile | 23 +++++++---- usr/src/lib/libc/net/SCCS/hosttable/Makefile | 42 +++++++++++-------- usr/src/lib/libcompat/4.1/Makefile | 43 ++++++++++++-------- usr/src/lib/libcompat/4.3/Makefile | 36 +++++++++------- 5 files changed, 110 insertions(+), 76 deletions(-) diff --git a/usr/src/lib/csu/tahoe/Makefile b/usr/src/lib/csu/tahoe/Makefile index ffd92b0341..4ef356b288 100644 --- a/usr/src/lib/csu/tahoe/Makefile +++ b/usr/src/lib/csu/tahoe/Makefile @@ -1,46 +1,52 @@ # -# Copyright (c) 1987 Regents of the University of California. -# All rights reserved. The Berkeley software License Agreement -# specifies the terms and conditions for redistribution. +# Copyright (c) 1988 Regents of the University of California. +# All rights reserved. # -# @(#)Makefile 5.2 (Berkeley) %G% +# Redistribution and use in source and binary forms are permitted +# provided that this notice is preserved and that due credit is given +# to the University of California at Berkeley. 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'' without express or implied warranty. +# +# @(#)Makefile 5.3 (Berkeley) %G% # -DESTDIR= CFLAGS= -O OBJS= crt0.o mcrt0.o gcrt0.o +TAGSFILE=tags .s.o: ${AS} -o $*.o $*.s ld -x -r $*.o mv a.out $*.o -all: ${OBJS} +all link: ${OBJS} -mcrt0.o: moncrt0.o mon.o - ld -x -r -o mcrt0.o moncrt0.o mon.o +mcrt0.o: moncrt0.o mon.o + ld -x -r -o $@ moncrt0.o mon.o -gcrt0.o: moncrt0.o gmon.o - ld -x -r -o gcrt0.o moncrt0.o gmon.o +gcrt0.o: moncrt0.o gmon.o + ld -x -r -o $@ moncrt0.o gmon.o -moncrt0.o: mcrt0.s - $(AS) -o moncrt0.o mcrt0.s +moncrt0.o: mcrt0.s + ${AS} -o $@ mcrt0.s -mon.o: mon.c +mon.o: mon.c ${CC} -S ${CFLAGS} mon.c ex - mon.s < mon.ex - $(AS) -o mon.o mon.s + ${AS} -o $@ mon.s -gmon.o: gmon.c +gmon.o: gmon.c ${CC} -S ${CFLAGS} gmon.c ex - gmon.s < mon.ex - ${AS} -o gmon.o gmon.s + ${AS} -o $@ gmon.s -install: all +install: install -o bin -g bin -m 444 crt0.o ${DESTDIR}/lib/crt0.o install -o bin -g bin -m 444 mcrt0.o ${DESTDIR}/lib/mcrt0.o install -o bin -g bin -m 444 gcrt0.o ${DESTDIR}/usr/lib/gcrt0.o clean: - rm -f ${OBJS} *mon.s moncrt0.o mon.o gmon.o a.out errs core + rm -f *.o *mon.s a.out core ${TAGSFILE} depend: diff --git a/usr/src/lib/csu/vax/Makefile b/usr/src/lib/csu/vax/Makefile index 4d4b20ae18..86728ea8cd 100644 --- a/usr/src/lib/csu/vax/Makefile +++ b/usr/src/lib/csu/vax/Makefile @@ -1,27 +1,32 @@ # -# Copyright (c) 1980 Regents of the University of California. -# All rights reserved. The Berkeley software License Agreement -# specifies the terms and conditions for redistribution. +# Copyright (c) 1988 Regents of the University of California. +# All rights reserved. # -# @(#)Makefile 5.5 (Berkeley) %G% +# Redistribution and use in source and binary forms are permitted +# provided that this notice is preserved and that due credit is given +# to the University of California at Berkeley. 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'' without express or implied warranty. +# +# @(#)Makefile 5.6 (Berkeley) %G% # # crt0 Normal C run time startoff # mcrt0 C run time start off for profiling, ``prof'' conventions # gcrt0 C run time start off for profiling, ``gprof'' conventions # -DESTDIR= SRCS= crt0.c mon.c gmon.c OBJS= crt0.o mcrt0.o gcrt0.o mon.o gmon.o TAGSFILE=tags -all: ${OBJS} +all link: ${OBJS} -install: ${OBJS} +install: install -o bin -g bin -m 444 crt0.o ${DESTDIR}/lib/crt0.o install -o bin -g bin -m 444 mcrt0.o ${DESTDIR}/lib/mcrt0.o install -o bin -g bin -m 444 gcrt0.o ${DESTDIR}/usr/lib/gcrt0.o -crt0.o: crt0.c +crt0.o: crt0.c ${CC} -S ${DFLAGS} -DCRT0 crt0.c /lib/cpp crt0.s > x.s as -o x.o x.s @@ -62,7 +67,7 @@ tags: done clean: - rm -f ${OBJS} *.o *.s core errs tags + rm -f *.o a.out core ${TAGSFILE} lint: crt0.c lint crt0.c -DMCRT0 diff --git a/usr/src/lib/libc/net/SCCS/hosttable/Makefile b/usr/src/lib/libc/net/SCCS/hosttable/Makefile index b11e36ac28..66a3b539ab 100644 --- a/usr/src/lib/libc/net/SCCS/hosttable/Makefile +++ b/usr/src/lib/libc/net/SCCS/hosttable/Makefile @@ -1,29 +1,35 @@ - # -# Copyright (c) 1983 Regents of the University of California. -# All rights reserved. The Berkeley software License Agreement -# specifies the terms and conditions for redistribution. +# Copyright (c) 1988 Regents of the University of California. +# All rights reserved. # -# @(#)Makefile 5.5 (Berkeley) %G% +# Redistribution and use in source and binary forms are permitted +# provided that this notice is preserved and that due credit is given +# to the University of California at Berkeley. 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'' without express or implied warranty. # - +# @(#)Makefile 5.6 (Berkeley) %G% +# +CFLAGS= -O ${DEFS} OBJS= gethostnamadr.o gethostent.o SRCS= gethostnamadr.c gethostent.c -CFLAGS= -O ${DEFS} +TAGSFILE=tags .c.o: - ${CC} -p -c ${CFLAGS} $*.c - -ld -X -r $*.o - mv a.out profiled/$*.o + @${CC} -p -c ${CFLAGS} $*.c + @-ld -X -o profiled/$*.o -r $*.o ${CC} ${CFLAGS} -c $*.c - -ld -x -r $*.o - mv a.out $*.o + @-ld -x -r $*.o + @mv a.out $*.o + +all: ${OBJS} -hostlib hostlib_p: ${OBJS} - @echo "building profiled hostlib" - @cd profiled; ar cru ../hostlib_p ${OBJS} - @echo "building normal netlib" - @ar cru hostlib ${OBJS} +link: ${OBJS} + (cd ../../library; rm -f ${OBJS}) + (cd ../../profiled; rm -f ${OBJS}) + ln ${OBJS} ../../library + (cd profiled; ln ${OBJS} ../../../profiled) tags: cwd=`pwd`; \ @@ -32,7 +38,7 @@ tags: done clean: - rm -f *.o errs a.out core hostlib hostlib_p profiled/*.o tags + rm -f *.o profiled/* a.out core ${TAGSFILE} depend: mkdep ${CFLAGS} ${SRCS} diff --git a/usr/src/lib/libcompat/4.1/Makefile b/usr/src/lib/libcompat/4.1/Makefile index 716666f40f..baed1cbd75 100644 --- a/usr/src/lib/libcompat/4.1/Makefile +++ b/usr/src/lib/libcompat/4.1/Makefile @@ -1,9 +1,15 @@ # -# Copyright (c) 1980 Regents of the University of California. -# All rights reserved. The Berkeley software License Agreement -# specifies the terms and conditions for redistribution. +# Copyright (c) 1988 Regents of the University of California. +# All rights reserved. # -# @(#)Makefile 5.6 (Berkeley) %G% +# Redistribution and use in source and binary forms are permitted +# provided that this notice is preserved and that due credit is given +# to the University of California at Berkeley. 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'' without express or implied warranty. +# +# @(#)Makefile 5.7 (Berkeley) %G% # CFLAGS= -O ${DEFS} STDSRCS=ftime.c gtty.c nice.c pause.c rand.c stty.c tell.c \ @@ -18,18 +24,19 @@ OBJS= ${STD} ${TRASH} TAGSFILE=tags .c.o: - ${CC} -p ${CFLAGS} -c $*.c - -ld -X -r $*.o - mv a.out profiled/$*.o + @${CC} -p ${CFLAGS} -c $*.c + @-ld -X -o profiled/$*.o -r $*.o ${CC} ${CFLAGS} -c $*.c - -ld -x -r $*.o - mv a.out $*.o + @-ld -x -r $*.o + @mv a.out $*.o + +all: ${OBJS} -compat-4.1lib compat-4.1lib_p: ${OBJS} - @echo "building profiled compat-4.1lib" - @cd profiled; ar cru ../compat-4.1lib_p ${OBJS} - @echo "building normal compat-4.1lib" - @ar cru compat-4.1lib ${OBJS} +link: ${OBJS} + (cd ../library; rm -f ${OBJS}) + (cd ../profiled; rm -f ${OBJS}) + ln ${OBJS} ../library + (cd profiled; ln ${OBJS} ../../profiled) tags: cwd=`pwd`; \ @@ -38,7 +45,7 @@ tags: done clean: - rm -f compat-4.1lib compat-4.1lib_p *.o profiled/*.o tags + rm -f *.o profiled/* a.out core ${TAGSFILE} depend: mkdep ${CFLAGS} ${SRCS} @@ -49,13 +56,15 @@ depend: ftime.o: ftime.c /usr/include/sys/types.h /usr/include/sys/time.h ftime.o: /usr/include/time.h gtty.o: gtty.c /usr/include/sgtty.h /usr/include/sys/ioctl.h -gtty.o: /usr/include/sys/ttychars.h /usr/include/sys/ttydev.h +gtty.o: /usr/include/sys/ttychars.h /usr/include/sys/ttydefaults.h +gtty.o: /usr/include/sys/ttydev.h nice.o: nice.c /usr/include/sys/time.h /usr/include/time.h nice.o: /usr/include/sys/resource.h pause.o: pause.c rand.o: rand.c stty.o: stty.c /usr/include/sgtty.h /usr/include/sys/ioctl.h -stty.o: /usr/include/sys/ttychars.h /usr/include/sys/ttydev.h +stty.o: /usr/include/sys/ttychars.h /usr/include/sys/ttydefaults.h +stty.o: /usr/include/sys/ttydev.h tell.o: tell.c times.o: times.c /usr/include/sys/time.h /usr/include/time.h times.o: /usr/include/sys/resource.h diff --git a/usr/src/lib/libcompat/4.3/Makefile b/usr/src/lib/libcompat/4.3/Makefile index 927fb8f105..9ed3ee5df1 100644 --- a/usr/src/lib/libcompat/4.3/Makefile +++ b/usr/src/lib/libcompat/4.3/Makefile @@ -9,26 +9,27 @@ # software without specific prior written permission. This software # is provided ``as is'' without express or implied warranty. # -# @(#)Makefile 5.1 (Berkeley) %G% +# @(#)Makefile 5.2 (Berkeley) %G% # CFLAGS= -O ${DEFS} -SRCS= -OBJS= +SRCS= ecvt.c gcvt.c sibuf.c sobuf.c strout.c +OBJS= ecvt.o gcvt.o sibuf.o sobuf.o strout.o TAGSFILE=tags .c.o: - ${CC} -p ${CFLAGS} -c $*.c - -ld -X -r $*.o - mv a.out profiled/$*.o + @${CC} -p ${CFLAGS} -c $*.c + @-ld -X -o profiled/$*.o -r $*.o ${CC} ${CFLAGS} -c $*.c - -ld -x -r $*.o - mv a.out $*.o + @-ld -x -r $*.o + @mv a.out $*.o -compat-4.3lib compat-4.3lib_p: ${OBJS} - @echo "building profiled compat-4.3lib" - @cd profiled; ar cru ../compat-4.3lib_p ${OBJS} - @echo "building normal compat-4.3lib" - @ar cru compat-4.3lib ${OBJS} +all: ${OBJS} + +link: ${OBJS} + (cd ../library; rm -f ${OBJS}) + (cd ../profiled; rm -f ${OBJS}) + ln ${OBJS} ../library + (cd profiled; ln ${OBJS} ../../profiled) tags: cwd=`pwd`; \ @@ -37,7 +38,7 @@ tags: done clean: - rm -f compat-4.3lib compat-4.3lib_p *.o profiled/*.o tags + rm -f *.o profiled/* a.out core ${TAGSFILE} depend: mkdep ${CFLAGS} ${SRCS} @@ -45,3 +46,10 @@ depend: # DO NOT DELETE THIS LINE -- mkdep uses it. # DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY. +ecvt.o: ecvt.c +gcvt.o: gcvt.c +sibuf.o: sibuf.c /usr/include/stdio.h +sobuf.o: sobuf.c /usr/include/stdio.h +strout.o: strout.c /usr/include/stdio.h + +# IF YOU PUT ANYTHING HERE IT WILL GO AWAY -- 2.20.1