BSD 4_3_Tahoe release
[unix-history] / usr / include / Makefile
index fd75da8..4f03899 100644 (file)
@@ -3,7 +3,7 @@
 # All rights reserved.  The Berkeley software License Agreement
 # specifies the terms and conditions for redistribution.
 #
 # All rights reserved.  The Berkeley software License Agreement
 # specifies the terms and conditions for redistribution.
 #
-#      @(#)Makefile.install    5.2 (Berkeley) 5/11/86
+#      @(#)Makefile.install    5.4 (Berkeley) 1/17/88
 #
 # Makefile for /usr/include, used to convert system include subdirectories
 # between symbolic links and copies of kernel headers.
 #
 # Makefile for /usr/include, used to convert system include subdirectories
 # between symbolic links and copies of kernel headers.
 # follow symbolic links.
 #
 DESTDIR=
 # follow symbolic links.
 #
 DESTDIR=
-MACHINE=vax
-MACHDEP=${MACHINE} vaxif vaxmba vaxuba
-NETDIRS=net netimp netinet netns
-SYSDIRS=${NETDIRS} stand ${MACHDEP}
+MACHDEP.vax=   vaxif vaxmba vaxuba
+MACHDEP.tahoe= tahoeif tahoevba
+NETDIRS=       net netimp netinet netns
+SYSDIRS=       ${NETDIRS} ${MACHINE}
 SYS=/sys
 
 all:
        @echo "\"make symlinks\", \"make copies\", or \"make update\" only"
        @false
 
 SYS=/sys
 
 all:
        @echo "\"make symlinks\", \"make copies\", or \"make update\" only"
        @false
 
-symlinks:
+symlinks: symlinks.${MACHINE}
        for i in ${SYSDIRS}; do \
                rm -rf $$i; \
                ln -s ${SYS}/$$i $$i; \
        done
        for i in ${SYSDIRS}; do \
                rm -rf $$i; \
                ln -s ${SYS}/$$i $$i; \
        done
-       rm -rf sys
+       rm -rf sys machine
        ln -s ${SYS}/h sys
        ln -s ${SYS}/h sys
+       ln -s ${MACHINE} machine
 
 
-copies:
+symlinks.vax:
+       for i in ${MACHDEP.vax}; do \
+               rm -rf $$i; \
+               ln -s ${SYS}/$$i $$i; \
+       done
+
+symlinks.tahoe:
+       for i in ${MACHDEP.tahoe}; do \
+               rm -rf $$i; \
+               ln -s ${SYS}/$$i $$i; \
+       done
+
+copies: copies.${MACHINE}
        -for i in ${SYSDIRS}; do \
                rm -rf $$i; \
                (cd ${SYS}; tar cf - $$i/*.h) | tar xpfB -; \
        -for i in ${SYSDIRS}; do \
                rm -rf $$i; \
                (cd ${SYS}; tar cf - $$i/*.h) | tar xpfB -; \
@@ -40,8 +53,22 @@ copies:
        mkdir sys; 
        chmod 775 sys;
        -(cd ${SYS}/h; tar cf - *.h) | (cd sys; tar xpfB -)
        mkdir sys; 
        chmod 775 sys;
        -(cd ${SYS}/h; tar cf - *.h) | (cd sys; tar xpfB -)
+       rm -f machine
+       ln -s ${MACHINE} machine
+
+copies.vax:
+       -for i in ${MACHDEP.vax}; do \
+               rm -rf $$i; \
+               (cd ${SYS}; tar cf - $$i/*.h) | tar xpfB -; \
+       done
 
 
-update:
+copies.tahoe:
+       -for i in ${MACHDEP.tahoe}; do \
+               rm -rf $$i; \
+               (cd ${SYS}; tar cf - $$i/*.h) | tar xpfB -; \
+       done
+
+update: update.${MACHINE}
        -for i in ${SYSDIRS}; do \
                if [ ! -d $$i ]; \
                then \
        -for i in ${SYSDIRS}; do \
                if [ ! -d $$i ]; \
                then \
@@ -57,3 +84,29 @@ update:
                { echo "install -c -m 444 ${SYS}/h/$$j sys/$$j"; \
                install -c -m 444 ${SYS}/h/$$j sys/$$j; } \
        done;
                { echo "install -c -m 444 ${SYS}/h/$$j sys/$$j"; \
                install -c -m 444 ${SYS}/h/$$j sys/$$j; } \
        done;
+       rm -f machine
+       ln -s ${MACHINE} machine
+
+update.vax:
+       -for i in ${MACHDEP.vax}; do \
+               if [ ! -d $$i ]; \
+               then \
+                       mkdir $$i; \
+               fi; \
+               for j in `cd ${SYS}/$$i; echo *.[ih]`; do \
+                       cmp -s ${SYS}/$$i/$$j $$i/$$j || \
+                       install -c -m 444 ${SYS}/$$i/$$j $$i/$$j; \
+               done; \
+       done
+
+update.tahoe:
+       -for i in ${MACHDEP.tahoe}; do \
+               if [ ! -d $$i ]; \
+               then \
+                       mkdir $$i; \
+               fi; \
+               for j in `cd ${SYS}/$$i; echo *.[ih]`; do \
+                       cmp -s ${SYS}/$$i/$$j $$i/$$j || \
+                       install -c -m 444 ${SYS}/$$i/$$j $$i/$$j; \
+               done; \
+       done