BSD 4_3_Tahoe release
[unix-history] / usr / src / lib / libc / net / Makefile
index 1ece853..a12488a 100644 (file)
@@ -1,38 +1,47 @@
 #
 #
-# 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.13 (Berkeley) 3/18/86
+# 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 University of California, 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'' AND WITHOUT ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
+# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
 #
 #
-SRCS=  getnetbyaddr.c getnetent.c getnetbyname.c \
-       getproto.c getprotoent.c getprotoname.c \
-       getservent.c getservbyport.c getservbyname.c \
-       rcmd.c rexec.c ruserpass.c \
-       res_comp.c res_debug.c res_init.c res_mkquery.c res_send.c
-
-OBJS=  getnetbyaddr.o getnetent.o getnetbyname.o \
-       getproto.o getprotoent.o getprotoname.o \
-       getservent.o getservbyport.o getservbyname.o \
-       rcmd.o rexec.o ruserpass.o \
-       res_comp.o res_debug.o res_init.o res_mkquery.o res_send.o
-
+#      @(#)Makefile    5.19 (Berkeley) 6/27/88
+#
+DEFS=  -DLIBC_SCCS
 CFLAGS=        -O ${DEFS}
 CFLAGS=        -O ${DEFS}
+SRCS=  getnetbyaddr.c getnetent.c getnetbyname.c getproto.c getprotoent.c \
+       getprotoname.c getservent.c getservbyport.c getservbyname.c \
+       herror.c rcmd.c rexec.c ruserpass.c res_comp.c res_debug.c \
+       res_init.c res_mkquery.c res_query.c res_send.c
+OBJS=  getnetbyaddr.o getnetent.o getnetbyname.o getproto.o getprotoent.o \
+       getprotoname.o getservent.o getservbyport.o getservbyname.o \
+       herror.o rcmd.o rexec.o ruserpass.o res_comp.o res_debug.o \
+       res_init.o res_mkquery.o res_query.o res_send.o
 TAGSFILE=tags
 
 .c.o:
 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
        ${CC} ${CFLAGS} -c $*.c
-       -ld -x -r $*.o
-       mv a.out $*.o
+       @-ld -x -r $*.o
+       @mv a.out $*.o
 
 
-netlib netlib_p: ${OBJS}
-       @echo "building profiled netlib"
-       @cd profiled; ar cru ../netlib_p ${OBJS}
-       @echo "building normal netlib"
-       @ar cru netlib ${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`; \
 
 tags:
        cwd=`pwd`; \
@@ -41,34 +50,14 @@ tags:
        done
 
 clean:
        done
 
 clean:
-       rm -f *.o profiled/*.o errs a.out core netlib netlib_p \
-               tags Makefile.bak
+       rm -f *.o profiled/* a.out core ${TAGSFILE}
 
 depend:
 
 depend:
-       for i in ${SRCS}; do \
-           cc -M ${CFLAGS} $$i | awk ' { if ($$1 != prev) \
-               { if (rec != "") print rec; rec = $$0; prev = $$1; } \
-               else { if (length(rec $$2) > 78) { print rec; rec = $$0; } \
-               else rec = rec " " $$2 } } \
-               END { print rec } ' >> makedep; done
-       echo '/^# DO NOT DELETE THIS LINE/+2,$$d' >eddep
-       echo '$$r makedep' >>eddep
-       echo 'w' >>eddep
-       cp Makefile Makefile.bak
-       ed - Makefile < eddep
-       rm eddep makedep
-       echo '# DEPENDENCIES MUST END AT END OF FILE' >> Makefile
-       echo '# IF YOU PUT STUFF HERE IT WILL GO AWAY' >> Makefile
-       echo '# see make depend above' >> Makefile
+       mkdep ${CFLAGS} ${SRCS}
 
 
-# DO NOT DELETE THIS LINE -- make depend uses it
+# DO NOT DELETE THIS LINE -- mkdep uses it.
+# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.
 
 
-getnetbyaddr.o: getnetbyaddr.c /usr/include/netdb.h
-getnetent.o: getnetent.c /usr/include/stdio.h /usr/include/sys/types.h
-getnetent.o: /usr/include/sys/socket.h /usr/include/netdb.h
-getnetent.o: /usr/include/ctype.h
-getnetbyname.o: getnetbyname.c /usr/include/netdb.h
-getproto.o: getproto.c /usr/include/netdb.h
 getnetbyaddr.o: getnetbyaddr.c /usr/include/netdb.h
 getnetent.o: getnetent.c /usr/include/stdio.h /usr/include/sys/types.h
 getnetent.o: /usr/include/sys/socket.h /usr/include/netdb.h
 getnetbyaddr.o: getnetbyaddr.c /usr/include/netdb.h
 getnetent.o: getnetent.c /usr/include/stdio.h /usr/include/sys/types.h
 getnetent.o: /usr/include/sys/socket.h /usr/include/netdb.h
@@ -79,16 +68,22 @@ getprotoent.o: getprotoent.c /usr/include/stdio.h /usr/include/sys/types.h
 getprotoent.o: /usr/include/sys/socket.h /usr/include/netdb.h
 getprotoent.o: /usr/include/ctype.h
 getprotoname.o: getprotoname.c /usr/include/netdb.h
 getprotoent.o: /usr/include/sys/socket.h /usr/include/netdb.h
 getprotoent.o: /usr/include/ctype.h
 getprotoname.o: getprotoname.c /usr/include/netdb.h
-getservent.o: getservent.c /usr/include/stdio.h /usr/include/sys/types.h
+getservent.o: getservent.c /usr/include/stdio.h /usr/include/sys/param.h
+getservent.o: /usr/include/sys/types.h /usr/include/signal.h
+getservent.o: /usr/include/machine/trap.h /usr/include/machine/machparam.h
+getservent.o: /usr/include/machine/endian.h /usr/include/sys/types.h
 getservent.o: /usr/include/sys/socket.h /usr/include/netdb.h
 getservent.o: /usr/include/ctype.h
 getservbyport.o: getservbyport.c /usr/include/netdb.h
 getservbyname.o: getservbyname.c /usr/include/netdb.h
 getservent.o: /usr/include/sys/socket.h /usr/include/netdb.h
 getservent.o: /usr/include/ctype.h
 getservbyport.o: getservbyport.c /usr/include/netdb.h
 getservbyname.o: getservbyname.c /usr/include/netdb.h
+herror.o: herror.c /usr/include/sys/types.h /usr/include/sys/uio.h
 rcmd.o: rcmd.c /usr/include/stdio.h /usr/include/ctype.h /usr/include/pwd.h
 rcmd.o: rcmd.c /usr/include/stdio.h /usr/include/ctype.h /usr/include/pwd.h
-rcmd.o: /usr/include/sys/param.h /usr/include/machine/machparam.h
-rcmd.o: /usr/include/signal.h /usr/include/sys/types.h
-rcmd.o: /usr/include/sys/socket.h /usr/include/sys/stat.h
-rcmd.o: /usr/include/netinet/in.h /usr/include/netdb.h /usr/include/errno.h
+rcmd.o: /usr/include/sys/param.h /usr/include/sys/types.h /usr/include/signal.h
+rcmd.o: /usr/include/machine/trap.h /usr/include/machine/machparam.h
+rcmd.o: /usr/include/machine/endian.h /usr/include/sys/file.h
+rcmd.o: /usr/include/sys/signal.h /usr/include/sys/socket.h
+rcmd.o: /usr/include/sys/stat.h /usr/include/netinet/in.h /usr/include/netdb.h
+rcmd.o: /usr/include/errno.h
 rexec.o: rexec.c /usr/include/sys/types.h /usr/include/sys/socket.h
 rexec.o: /usr/include/netinet/in.h /usr/include/stdio.h /usr/include/netdb.h
 rexec.o: /usr/include/errno.h
 rexec.o: rexec.c /usr/include/sys/types.h /usr/include/sys/socket.h
 rexec.o: /usr/include/netinet/in.h /usr/include/stdio.h /usr/include/netdb.h
 rexec.o: /usr/include/errno.h
@@ -105,12 +100,20 @@ res_init.o: /usr/include/arpa/nameser.h /usr/include/resolv.h
 res_mkquery.o: res_mkquery.c /usr/include/stdio.h /usr/include/sys/types.h
 res_mkquery.o: /usr/include/netinet/in.h /usr/include/arpa/nameser.h
 res_mkquery.o: /usr/include/resolv.h
 res_mkquery.o: res_mkquery.c /usr/include/stdio.h /usr/include/sys/types.h
 res_mkquery.o: /usr/include/netinet/in.h /usr/include/arpa/nameser.h
 res_mkquery.o: /usr/include/resolv.h
-res_send.o: res_send.c /usr/include/sys/param.h
-res_send.o: /usr/include/machine/machparam.h /usr/include/signal.h
-res_send.o: /usr/include/sys/types.h /usr/include/sys/time.h
-res_send.o: /usr/include/time.h /usr/include/sys/socket.h
+res_query.o: res_query.c /usr/include/sys/param.h /usr/include/sys/types.h
+res_query.o: /usr/include/signal.h /usr/include/machine/trap.h
+res_query.o: /usr/include/machine/machparam.h /usr/include/machine/endian.h
+res_query.o: /usr/include/sys/socket.h /usr/include/netinet/in.h
+res_query.o: /usr/include/ctype.h /usr/include/netdb.h /usr/include/stdio.h
+res_query.o: /usr/include/errno.h /usr/include/strings.h
+res_query.o: /usr/include/arpa/inet.h /usr/include/arpa/nameser.h
+res_query.o: /usr/include/resolv.h
+res_send.o: res_send.c /usr/include/sys/param.h /usr/include/sys/types.h
+res_send.o: /usr/include/signal.h /usr/include/machine/trap.h
+res_send.o: /usr/include/machine/machparam.h /usr/include/machine/endian.h
+res_send.o: /usr/include/sys/time.h /usr/include/time.h
+res_send.o: /usr/include/sys/socket.h /usr/include/sys/uio.h
 res_send.o: /usr/include/netinet/in.h /usr/include/stdio.h /usr/include/errno.h
 res_send.o: /usr/include/arpa/nameser.h /usr/include/resolv.h
 res_send.o: /usr/include/netinet/in.h /usr/include/stdio.h /usr/include/errno.h
 res_send.o: /usr/include/arpa/nameser.h /usr/include/resolv.h
-# DEPENDENCIES MUST END AT END OF FILE
-# IF YOU PUT STUFF HERE IT WILL GO AWAY
-# see make depend above
+
+# IF YOU PUT ANYTHING HERE IT WILL GO AWAY