source: trunk/third/perl/plan9/setup.rc @ 10724

Revision 10724, 1.7 KB checked in by ghudson, 27 years ago (diff)
This commit was generated by cvs2svn to compensate for changes in r10723, which included commits to RCS files with non-trunk default branches.
Line 
1#!/bin/rc
2# This is an rc shell script which unpacks the perl distribution, builds
3# directories, and puts files where they belong.
4# To use, just run it from within the plan9 subdirectory with the appropriate
5# permissions.
6# Last modified 6/30/96 by:
7# Luther Huffman, Strategic Computer Solutions, Inc., lutherh@stratcom.com
8
9awk -f versnum ../patchlevel.h
10. buildinfo
11builddir = `{ cd .. ; pwd }
12if (~ $#* 0) platforms = $objtype
13if not switch($1) {
14        case -a ; platforms = (386 mips sparc 68020)
15        case * ; echo 'Usage: setup.rc [-a]' >[1=2] ; exit
16}
17sourcedir=/sys/src/cmd/perl/$p9pvers
18privlib=/sys/lib/perl
19sitelib=$privlib/site_perl
20
21#Build source directory
22if (test ! -d /sys/src/cmd/perl) mkdir /sys/src/cmd/perl
23if (test ! -d $sourcedir) mkdir $sourcedir
24
25#Populate source directory
26echo Building source directories ...
27{cd $builddir ; tar c .} | { cd $sourcedir ; tar x}
28cp $builddir/plan9/plan9.c $builddir/plan9/plan9ish.h $builddir/plan9/mkfile $sourcedir
29cd $sourcedir/lib ; rm -rf *
30
31#Build library directories
32echo Building library directories ...
33if (test ! -d $privlib) mkdir $privlib
34if (test ! -d $privlib/auto) mkdir $privlib/auto
35if (test ! -d $sitelib) mkdir $sitelib
36for(i in $platforms){
37        archlib=/$i/lib/perl/$p9pvers
38        sitearch=$archlib/site_perl
39        corelib=$archlib/CORE
40        arpalib=$corelib/arpa
41        if (test ! -d /$i/lib/perl) mkdir /$i/lib/perl
42        if (test ! -d $archlib) mkdir $archlib
43        if (test ! -d $sitearch) mkdir $sitearch
44        if (test ! -d $corelib) mkdir $corelib
45        if (test ! -d $arpalib) mkdir $arpalib
46        cp $builddir/*.h $builddir/plan9/*.h  $corelib
47        cp $builddir/plan9/arpa/*.h  $arpalib
48}
49
50#Populate library directories
51{cd $builddir/lib ; tar c . } | {cd $privlib ; tar x }
Note: See TracBrowser for help on using the repository browser.