home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / unix / volume6 / rpc2 / part01 / rpc / rpclib / Makefile
Encoding:
Makefile  |  1986-11-30  |  3.5 KB  |  104 lines

  1. #
  2. #     Makefile    1.1    86/02/03
  3. #
  4. DESTDIR=
  5.  
  6. SRC=    auth_none.c auth_unix.c authunix_prot.c \
  7.     clnt_perror.c clnt_raw.c clnt_simple.c clnt_tcp.c clnt_udp.c \
  8.     pmap_clnt.c pmap_getmaps.c pmap_getport.c pmap_prot.c pmap_rmt.c rpc_prot.c \
  9.     svc.c svc_auth.c svc_auth_unix.c svc_raw.c svc_simple.c \
  10.     svc_tcp.c svc_udp.c xdr.c xdr_array.c xdr_float.c xdr_mem.c xdr_rec.c xdr_reference.c xdr_stdio.c
  11.  
  12. OBJ=    auth_none.o auth_unix.o authunix_prot.o clnt_perror.o clnt_raw.o\
  13.     clnt_simple.o clnt_tcp.o clnt_udp.o \
  14.     pmap_clnt.o pmap_getmaps.o pmap_getport.o pmap_prot.o pmap_rmt.o rpc_prot.o \
  15.     svc.o svc_auth.o svc_auth_unix.o svc_raw.o svc_simple.o \
  16.     svc_tcp.o svc_udp.o xdr.o xdr_array.o xdr_float.o xdr_mem.o xdr_rec.o xdr_reference.o xdr_stdio.o
  17. INC=    auth.h auth_unix.h clnt.h pmap_clnt.h\
  18.     pmap_prot.h rpc.h rpc_msg.h svc.h svc_auth.h types.h xdr.h
  19.  
  20. CFLAGS= -O -A-R
  21.  
  22. .c.o:
  23.     ${CC} -p -c ${CFLAGS} $*.c
  24.     -ld -X -r $*.o
  25.     mv a.out profiled/$*.o
  26.     ${CC} ${CFLAGS} -c $*.c
  27.     -ld -x -r $*.o
  28.     mv a.out $*.o
  29.  
  30. rpclib rpclib_p: ${OBJ}
  31.     @echo "building profiled rpclib"
  32.     @cd profiled; ar cru ../rpclib_p ${OBJ}
  33.     @echo "building normal rpclib"
  34.     @ar cru rpclib ${OBJ}
  35.  
  36. install:
  37.     -mkdir ${DESTDIR}/usr/include/rpc && \
  38.         chown bin ${DESTDIR}/usr/include/rpc && \
  39.         chmod 755 ${DESTDIR}/usr/include/rpc
  40.     -for i in *.h; do \
  41.         (install -c -m 644 $$i ${DESTDIR}/usr/include/rpc) done
  42.  
  43. tags: $(SRC) $(KSRC) $(INC)
  44.     ctags -tw $(SRC) $(KSRC) $(INC)
  45.  
  46. ref: tags
  47.     sed 's,    /.*,,' tags | \
  48.     awk ' { printf("%-26s%-16s%s\n", $$1, $$2, $$3) }' > ref
  49.  
  50. lint:
  51.     lint -bnuvx $(SRC)
  52.  
  53. print:
  54.     pr $(INC) $(SRC) $(KSRC) | lpr -Pvp
  55.  
  56. clean:
  57.     rm -f $(OBJ) rpclib rpclib_p linted made profiled/*.o
  58.  
  59. depend:
  60.     @-grep '^#include' $(SRC) | grep -v '<' | grep -v '../' | \
  61.     sed 's/:[^"]*"\([^"]*\)".*/: \1/' | sed 's/\.[cs]:/.o:/' | \
  62.     awk ' { if ($$1 != prev) { print rec; rec = $$0; prev = $$1; } \
  63.         else { if (length(rec $$2) > 78) { print rec; rec = $$0; } \
  64.                else rec = rec " " $$2 } } \
  65.           END { print rec } ' >> makedep
  66.     @echo '/^# DO NOT DELETE THIS LINE/+1,$$d' >eddep
  67.     @echo '$$r makedep' >>eddep
  68.     @echo 'w' >>eddep
  69.     @cp Makefile makefile.bak
  70.     @ed - Makefile < eddep
  71.     @rm eddep makedep makefile.bak
  72.  
  73.  
  74.  
  75. # DO NOT DELETE THIS LINE
  76.  
  77. auth_none.o: types.h xdr.h auth.h
  78. auth_unix.o: types.h xdr.h auth.h auth_unix.h
  79. authunix_prot.o: types.h xdr.h auth.h auth_unix.h
  80. clnt_perror.o: types.h xdr.h auth.h clnt.h rpc_msg.h
  81. clnt_raw.o: types.h xdr.h auth.h clnt.h rpc_msg.h
  82. clnt_tcp.o: types.h xdr.h auth.h clnt.h rpc_msg.h pmap_clnt.h
  83. clnt_udp.o: types.h xdr.h auth.h clnt.h rpc_msg.h pmap_clnt.h
  84. pmap_clnt.o: types.h xdr.h auth.h clnt.h rpc_msg.h pmap_prot.h pmap_clnt.h
  85. pmap_getmaps.o: types.h xdr.h auth.h clnt.h rpc_msg.h pmap_prot.h pmap_clnt.h
  86. pmap_getport.o: types.h xdr.h auth.h clnt.h rpc_msg.h pmap_prot.h pmap_clnt.h
  87. pmap_prot.o: types.h xdr.h pmap_prot.h
  88. pmap_rmt.o: types.h xdr.h auth.h clnt.h rpc_msg.h pmap_prot.h pmap_clnt.h
  89. rpc_prot.o: types.h xdr.h auth.h clnt.h rpc_msg.h
  90. svc.o: types.h xdr.h auth.h clnt.h rpc_msg.h svc.h svc_auth.h pmap_clnt.h
  91. svc_auth.o: types.h xdr.h auth.h clnt.h rpc_msg.h svc.h svc_auth.h
  92. svc_auth_unix.o: types.h xdr.h auth.h clnt.h rpc_msg.h svc.h auth_unix.h
  93. svc_auth_unix.o: svc_auth.h
  94. svc_raw.o: types.h xdr.h auth.h clnt.h rpc_msg.h svc.h
  95. svc_tcp.o: types.h xdr.h auth.h clnt.h rpc_msg.h svc.h
  96. svc_udp.o: types.h xdr.h auth.h clnt.h rpc_msg.h svc.h
  97. xdr.o: types.h xdr.h
  98. xdr_array.o: types.h xdr.h
  99. xdr_float.o: types.h xdr.h
  100. xdr_mem.o: types.h xdr.h
  101. xdr_rec.o: types.h xdr.h
  102. xdr_reference.o: types.h xdr.h
  103. xdr_stdio.o: types.h xdr.h
  104.