Makefile revision 1.41
11.21Smycroft# from: @(#)Makefile 5.45.1.1 (Berkeley) 5/6/91 21.41Sjtc# $Id: Makefile,v 1.41 1994/06/21 04:06:33 jtc Exp $ 31.21Smycroft 41.1Scgd# Doing a make install builds /usr/include 51.1Scgd# 61.1Scgd# The ``rm -rf''s used below are safe because rm doesn't follow symbolic 71.1Scgd# links. 81.6Scgd 91.1Scgd# Missing: mp.h 101.1Scgd 111.1ScgdFILES= a.out.h ar.h assert.h bitstring.h ctype.h db.h dirent.h disktab.h \ 121.41Sjtc err.h fnmatch.h fstab.h fts.h glob.h grp.h kvm.h langinfo.h limits.h \ 131.41Sjtc locale.h math.h memory.h mpool.h ndbm.h netdb.h nlist.h nl_types.h \ 141.41Sjtc paths.h pwd.h ranlib.h regex.h regexp.h resolv.h \ 151.36Scgd search.h setjmp.h sgtty.h signal.h stab.h stdarg.h stddef.h \ 161.28Sjtc stdio.h stdlib.h string.h strings.h struct.h sysexits.h time.h \ 171.38Scgd ttyent.h tzfile.h unistd.h utime.h utmp.h vis.h malloc.h \ 181.28Sjtc link.h 191.1Scgd 201.37ScgdMFILES= float.h frame.h varargs.h 211.36ScgdLFILES= errno.h fcntl.h syslog.h termios.h 221.1Scgd 231.26ScgdDIRS= arpa protocols rpc rpcsvc 241.30ScgdLDIRS= dev net netinet netccitt netiso netns nfs sys ufs vm 251.40Scgd# the following only used when making copies 261.40ScgdLSUBDIRS= ufs/ffs ufs/lfs ufs/mfs ufs/ufs 271.1Scgd 281.1ScgdNOOBJ= noobj 291.1Scgd 301.20Sbrezak# Change SYS_INCLUDE in bsd.own.mk to "symlinks" if you don't want copies 311.31Scgd.include <bsd.own.mk> 321.31ScgdSYS_INCLUDE?= copies 331.1Scgd 341.22Smycroftrealinstall: 351.1Scgd @echo installing ${FILES} 361.1Scgd @-for i in ${FILES}; do \ 371.1Scgd cmp -s $$i ${DESTDIR}/usr/include/$$i || \ 381.34Scgd install -c -m 444 $$i ${DESTDIR}/usr/include/$$i; \ 391.1Scgd done 401.1Scgd @echo installing ${DIRS} 411.1Scgd @-for i in ${DIRS}; do \ 421.34Scgd install -d -o bin -g bin -m 755 ${DESTDIR}/usr/include/$$i; \ 431.1Scgd (cd $$i; for j in *.[ih]; do \ 441.1Scgd cmp -s $$j ${DESTDIR}/usr/include/$$i/$$j || \ 451.34Scgd install -c -m 444 $$j ${DESTDIR}/usr/include/$$i/$$j; \ 461.1Scgd done); \ 471.1Scgd done 481.1Scgd @echo installing ${LFILES} 491.1Scgd @-for i in ${LFILES}; do \ 501.1Scgd rm -f ${DESTDIR}/usr/include/$$i; \ 511.1Scgd ln -s sys/$$i ${DESTDIR}/usr/include/$$i; \ 521.1Scgd done 531.1Scgd @echo installing ${MFILES} 541.1Scgd @-for i in ${MFILES}; do \ 551.1Scgd rm -f ${DESTDIR}/usr/include/$$i; \ 561.1Scgd ln -s machine/$$i ${DESTDIR}/usr/include/$$i; \ 571.1Scgd done 581.34Scgd chown -R ${BINOWN}:${BINGRP} ${DESTDIR}/usr/include 591.34Scgd find ${DESTDIR}/usr/include -type f | \ 601.34Scgd xargs chmod a-w 611.1Scgd 621.8Scgdbeforeinstall: 631.33Scgd install -d -o bin -g bin -m 755 ${DESTDIR}/usr/include 641.8Scgd 651.1Scgdcopies: 661.1Scgd @echo copies: ${LDIRS} 671.1Scgd @-for i in ${LDIRS}; do \ 681.40Scgd rm -rf ${DESTDIR}/usr/include/$$i; \ 691.40Scgd cd ../sys; \ 701.40Scgd install -d -o bin -g bin -m 755 ${DESTDIR}/usr/include/$$i ; \ 711.40Scgd tar cf - $$i/*.h | (cd ${DESTDIR}/usr/include; tar xpfB -); \ 721.40Scgd done 731.40Scgd @-for i in ${LSUBDIRS}; do \ 741.1Scgd rm -rf ${DESTDIR}/usr/include/$$i; \ 751.11Scgd cd ../sys; \ 761.34Scgd install -d -o bin -g bin -m 755 ${DESTDIR}/usr/include/$$i ; \ 771.1Scgd tar cf - $$i/*.h | (cd ${DESTDIR}/usr/include; tar xpfB -); \ 781.1Scgd done 791.3Scgd rm -rf ${DESTDIR}/usr/include/machine 801.34Scgd install -d -o bin -g bin -m 755 ${DESTDIR}/usr/include/machine 811.16Scgd cd ../sys/arch/${MACHINE}/include; \ 821.31Scgd tar cf - *.h | (cd ${DESTDIR}/usr/include/machine; tar xpfB -); 831.31Scgd rm -rf ${DESTDIR}/usr/include/${MACHINE_ARCH} 841.35Scgd if test ${MACHINE} != ${MACHINE_ARCH} -a \ 851.35Scgd -d ../sys/arch/${MACHINE_ARCH}/include ; then \ 861.34Scgd install -d -o bin -g bin -m 755 \ 871.34Scgd ${DESTDIR}/usr/include/${MACHINE_ARCH} ; \ 881.31Scgd cd ../sys/arch/${MACHINE_ARCH}/include ; \ 891.31Scgd tar cf - *.h | \ 901.31Scgd (cd ${DESTDIR}/usr/include/${MACHINE_ARCH} ; tar xpfB -); \ 911.31Scgd else \ 921.31Scgd ln -s machine ${DESTDIR}/usr/include/${MACHINE_ARCH} ; \ 931.31Scgd fi 941.1Scgd 951.1Scgdsymlinks: 961.1Scgd @echo symlinks: ${LDIRS} 971.13Sproven @for i in ${LDIRS}; do \ 981.13Sproven rm -rf ${DESTDIR}/usr/include/$$i; \ 991.13Sproven ln -s /sys/$$i ${DESTDIR}/usr/include/$$i; \ 1001.13Sproven done 1011.13Sproven rm -rf ${DESTDIR}/usr/include/machine 1021.16Scgd ln -s /sys/arch/${MACHINE}/include ${DESTDIR}/usr/include/machine 1031.31Scgd rm -rf ${DESTDIR}/usr/include/${MACHINE_ARCH} 1041.35Scgd if test ${MACHINE} != ${MACHINE_ARCH} -a \ 1051.35Scgd -d ../sys/arch/${MACHINE_ARCH}/include ; then \ 1061.31Scgd ln -s /sys/arch/${MACHINE_ARCH}/include \ 1071.31Scgd ${DESTDIR}/usr/include/${MACHINE_ARCH} ; \ 1081.31Scgd else \ 1091.31Scgd ln -s machine ${DESTDIR}/usr/include/${MACHINE_ARCH} ; \ 1101.31Scgd fi 1111.14Sproven 1121.14Sproven.include <bsd.prog.mk> 1131.23Smycroft 1141.23Smycroftrealinstall: ${SYS_INCLUDE} 115