tunix: move man pages in unix ports - plan9port - [fork] Plan 9 from user space
 (HTM) git clone git://src.adamsgaard.dk/plan9port
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
 (DIR) commit f5fcdeeedfd70da11a3990d3d91fe165f0bf8ef7
 (DIR) parent 9f0d3523fc61e53d6348d628df6fd16a7543cec4
 (HTM) Author: Russ Cox <rsc@swtch.com>
       Date:   Sun, 20 Jul 2008 06:17:17 -0400
       
       unix: move man pages in unix ports
       
       Diffstat:
         M unix/make/Makefile.MID              |       8 ++++----
         M unix/make/Makefile.bio              |       4 ++--
         M unix/make/Makefile.fmt              |       7 ++++---
         M unix/make/Makefile.regexp           |       4 ++--
         M unix/make/Makefile.utf              |       8 ++++----
         M unix/mkfile                         |      14 +++++++-------
         M unix/mkfile.fmt                     |      18 +++++++++++++++++-
         M unix/mkfile.utf                     |      12 +++++++++++-
       
       8 files changed, 51 insertions(+), 24 deletions(-)
       ---
 (DIR) diff --git a/unix/make/Makefile.MID b/unix/make/Makefile.MID
       t@@ -31,11 +31,11 @@ HFILES=\
        all: $(LIB)
        
        install: $(LIB)
       -        test -d $(PREFIX)/man/man3 || mkdir $(PREFIX)/man/man3
       -        install -c -m 0644 isalpharune.3 $(PREFIX)/man/man3/isalpharune.3
       +        test -d $(PREFIX)/share/man/man3 || mkdir $(PREFIX)/share/man/man3
       +        install -c -m 0644 isalpharune.3 $(PREFIX)/share/man/man3/isalpharune.3
                install -c -m 0644 utf.7 $(PREFIX)/man/man7/utf.7
       -        install -c -m 0644 rune.3 $(PREFIX)/man/man3/rune.3
       -        install -c -m 0644 runestrcat.3 $(PREFIX)/man/man3/runestrcat.3
       +        install -c -m 0644 rune.3 $(PREFIX)/share/man/man3/rune.3
       +        install -c -m 0644 runestrcat.3 $(PREFIX)/share/man/man3/runestrcat.3
                install -c -m 0644 utf.h $(PREFIX)/include/utf.h
                install -c -m 0644 $(LIB) $(PREFIX)/lib/$(LIB)
        
 (DIR) diff --git a/unix/make/Makefile.bio b/unix/make/Makefile.bio
       t@@ -28,8 +28,8 @@ HFILES=\
        all: $(LIB)
        
        install: $(LIB)
       -        mkdir -p $(PREFIX)/man/man3
       -        install -m 0644 bio.3 $(PREFIX)/man/man3/bio.3
       +        mkdir -p $(PREFIX)/share/man/man3
       +        install -m 0644 bio.3 $(PREFIX)/share/man/man3/bio.3
                mkdir -p $(PREFIX)/include
                install -m 0644 bio.h $(PREFIX)/include
                mkdir -p $(PREFIX)/lib
 (DIR) diff --git a/unix/make/Makefile.fmt b/unix/make/Makefile.fmt
       t@@ -17,6 +17,7 @@ OFILES=\
                fmtfdflush.$O\
                fmtlocale.$O\
                fmtlock.$O\
       +        fmtnull.$O\
                fmtprint.$O\
                fmtquote.$O\
                fmtrune.$O\
       t@@ -51,9 +52,9 @@ HFILES=\
        all: $(LIB)
        
        install: $(LIB)
       -        test -d $(PREFIX)/man/man3 || mkdir -p $(PREFIX)/man/man3
       -        install -m 0644 print.3 $(PREFIX)/man/man3/print.3
       -        install -m 0644 fmtinstall.3 $(PREFIX)/man/man3/fmtinstall.3
       +        test -d $(PREFIX)/share/man/man3 || mkdir -p $(PREFIX)/share/man/man3
       +        install -m 0644 print.3 $(PREFIX)/share/man/man3/print.3
       +        install -m 0644 fmtinstall.3 $(PREFIX)/share/man/man3/fmtinstall.3
                mkdir -p $(PREFIX)/include
                install -m 0644 fmt.h $(PREFIX)/include/fmt.h
                mkdir -p $(PREFIX)/lib
 (DIR) diff --git a/unix/make/Makefile.regexp b/unix/make/Makefile.regexp
       t@@ -19,8 +19,8 @@ HFILES=\
        all: $(LIB)
        
        install: $(LIB)
       -        mkdir -p $(PREFIX)/man/man3 $(PREFIX)/man/man7
       -        install -m 0644 regexp9.3 $(PREFIX)/man/man3/regexp9.3
       +        mkdir -p $(PREFIX)/share/man/man3 $(PREFIX)/man/man7
       +        install -m 0644 regexp9.3 $(PREFIX)/share/man/man3/regexp9.3
                install -m 0644 regexp9.7 $(PREFIX)/man/man7/regexp9.7
                mkdir -p $(PREFIX)/lib
                install -m 0644 $(LIB) $(PREFIX)/lib/$(LIB)
 (DIR) diff --git a/unix/make/Makefile.utf b/unix/make/Makefile.utf
       t@@ -31,11 +31,11 @@ HFILES=\
        all: $(LIB)
        
        install: $(LIB)
       -        mkdir -p $(PREFIX)/man/man3 $(PREFIX)/man/man7
       -        install -c -m 0644 isalpharune.3 $(PREFIX)/man/man3/isalpharune.3
       +        mkdir -p $(PREFIX)/share/man/man3 $(PREFIX)/man/man7
       +        install -c -m 0644 isalpharune.3 $(PREFIX)/share/man/man3/isalpharune.3
                install -c -m 0644 utf.7 $(PREFIX)/man/man7/utf.7
       -        install -c -m 0644 rune.3 $(PREFIX)/man/man3/rune.3
       -        install -c -m 0644 runestrcat.3 $(PREFIX)/man/man3/runestrcat.3
       +        install -c -m 0644 rune.3 $(PREFIX)/share/man/man3/rune.3
       +        install -c -m 0644 runestrcat.3 $(PREFIX)/share/man/man3/runestrcat.3
                mkdir -p $(PREFIX)/include
                install -c -m 0644 utf.h $(PREFIX)/include/utf.h
                mkdir -p $(PREFIX)/lib
 (DIR) diff --git a/unix/mkfile b/unix/mkfile
       t@@ -17,14 +17,14 @@ test-%:V:
                t=$stem
                path=($PLAN9/bin $path)
                mk new-$t
       -        cd $t
                switch($t){
       -        case bio;        d=libbio
       -        case regexp;        d=libregexp
       -        case fmt;        d=lib9/fmt
       -        case utf:        d=lib9/utf
       -        case mk;        d=cmd/mk
       +        case bio;        d=libbio; td=libbio
       +        case regexp;        d=libregexp; td=libregexp
       +        case fmt;        d=lib9/fmt; td=libfmt
       +        case utf;        d=lib9/utf; td=libutf
       +        case mk;        d=cmd/mk; td=mk
                }
       +        cd $td
                d=$PLAN9/src/$d
                for(i in `{ls -p $d/*.c})
                        if(! test -f $i)
       t@@ -34,7 +34,7 @@ test-%:V:
                        if(! test -f `{echo $i | sed 's/.c$/.o/'})
                                echo XXX not building $i
                cd ..
       -        rm -r $t
       +        rm -r $td
        
        lib%.tgz:V:
                mk new-$stem
 (DIR) diff --git a/unix/mkfile.fmt b/unix/mkfile.fmt
       t@@ -1,10 +1,12 @@
        MAKEALL=`{cd ../make; ls Make.*}
       +CFILES=`{9 ls -p $PLAN9/src/lib9/fmt/*.c}
       +CFILES1=`{9 ls -p $PLAN9/src/lib9/fmt/*.c |grep -v test}
        TARG=\
                $MAKEALL\
       +        $CFILES\
                NOTICE\
                README\
                Makefile\
       -        `{9 ls -p $PLAN9/src/lib9/fmt/*.c}\
                fmt.h\
                fmtdef.h\
                nan.h\
       t@@ -19,3 +21,17 @@ WHAT=fmt
        %: $PLAN9/src/lib9/fmt/%
                cp $prereq $target
        
       +fmt1.c: plan9.h $CFILES1
       +        (echo '#include <stdarg.h>'; \
       +         echo '#include <string.h>'; \
       +         echo '#include <stdlib.h>'; \
       +         echo '#include <errno.h>'; \
       +         echo '#include <limits.h>'; \
       +         echo '#include <math.h>'; \
       +         echo '#include <float.h>'; \
       +         cat plan9.h; \
       +         echo '#include "utf.h"'; \
       +         echo '#include "fmt.h"'; \
       +         cat fmtdef.h; \
       +         grep -hv '^#include' $CFILES1) >$target
       +
 (DIR) diff --git a/unix/mkfile.utf b/unix/mkfile.utf
       t@@ -1,10 +1,11 @@
        MAKEALL=`{cd ../make; ls Make.*}
       +CFILES=`{9 ls -p $PLAN9/src/lib9/utf/*.c}
        TARG=\
                $MAKEALL\
                NOTICE\
                README\
                Makefile\
       -        `{9 ls -p $PLAN9/src/lib9/utf/*.c}\
       +        $CFILES\
                plan9.h\
                utf.h\
                utfdef.h\
       t@@ -23,3 +24,12 @@ utf.h: $PLAN9/include/utf.h
        %: $PLAN9/src/lib9/utf/%
                cp $prereq $target
        
       +utf1.c:D: plan9.h $CFILES
       +        (cat plan9.h; \
       +         echo '#include <stdlib.h>'; \
       +         echo '#include <string.h>'; \
       +         echo '#include <unistd.h>'; \
       +         echo '#define bsearch utf_bsearch'; \
       +         echo '#include "utf.h"'; \
       +         grep -hv '^#include' $CFILES) >$target
       +