Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] View of /sml/trunk/src/system/installml
ViewVC logotype

View of /sml/trunk/src/system/installml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 569 - (download) (annotate)
Tue Mar 7 04:01:07 2000 UTC (19 years, 6 months ago) by blume
File size: 1917 byte(s)
- size info in BOOTLIST
     * no fixed upper limits for number of bootfiles or length of
       bootfile names in runtime
     * falling back to old behavior if no BOOTLIST size info found
- allocation size heuristics in .run-sml
     * tries to read cache size from /proc/cpuinfo (this is important for
        small-cache Celeron systems!)
- install.sh robustified
- CM manual updates
- paranoid mode
     * no more CMB.deliver() (i.e., all done by CMB.make())
     * can re-use existing sml.boot.* files
     * init.cmi now treated as library
     * library stamps for consistency checks
- sml.boot.<arch>-<os>/PIDMAP file
     * This file is read by the CM startup code.  This is used to minimize
       the amount of dynamic state that needs to be stowed away for the
       purpose of sharing between interactive system and user code.
- CM.Anchor.anchor instead of CM.Anchor.{set,cancel}
     * Upon request by Elsa.  Anchors now controlled by get-set-pair
       like most other CM state variables.
- Compiler.CMSA eliminated
     * No longer supported by CM anyway.
- fixed bugs in pickler that kept biting Stefan
     * past refs to past refs (was caused by the possibility that
       ad-hoc sharing is more discriminating than hash-cons sharing)
     * integer overflow on LargeInt.minInt
- ml-{lex,yacc} build scripts now use new mechanism
  for building standalone programs
- fixed several gcc -Wall warnings that were caused by missing header
  files, missing initializations, etc., in runtime (not all warnings
  eliminated, though)
#!/bin/sh

# The tmpfile is for pathconfig editing (see below).
tmpfile=pathconfig.tmp.$$

trap 'rm -f $tmpfile; exit 1' 0 1 2 3 15

here=`pwd`
cd ../..
twoup=`pwd`
cd $here

MAIN_HEAP_DIR=$twoup/bin/.heap
MAIN_LIB_DIR=$twoup/lib

if [ $# -gt 0 ] ; then
    STEM=$1
else
    STEM=sml
fi

if [ -f ../../bin/.arch-n-opsys ]; then
  ARCH_N_OPSYS=`../../bin/.arch-n-opsys`
  if [ "$?" = "0" ]; then
    eval $ARCH_N_OPSYS
  else
    echo "Cannot determine architecture/os."
    exit 1
  fi
fi

# A function to move all stable library files to a parallel directory
# hierarchy.
# The first argument must be a simple path (no / inside), and
# the second argument must be an absolute path.
move() {
    if [ -d $1 ] ; then
	if [ ! -d $2 ] ; then
	    if [ -f $2 ] ; then
		echo installml: $2 exists as a non-directory.
		exit 1
	    fi
	    mkdir $2
	fi
	cd $1
	for i in * ; do
	    move $i $2/$i
	done
	cd ..
    elif [ -f $1 ] ; then
	rm -f $2
	mv $1 $2
    fi
}

HEAP_FILE=$STEM.$ARCH-$OPSYS
LIB_DIR=$STEM.lib

if [ ! -f $HEAP_FILE ] ; then
    echo "The heap file $HEAP_FILE is missing."
    exit 1
fi

if [ ! -d $LIB_DIR ] ; then
    echo "The library directory $LIB_DIR is missing."
    exit 1
fi

# Moving the heap image to its place
mv $HEAP_FILE $MAIN_HEAP_DIR/sml.$ARCH-$OPSYS

# Moving each individual library...
cd $LIB_DIR
list=`echo *.cm`
for lib in init.cmi $list ; do
    move $lib $MAIN_LIB_DIR/$lib
done
cd ..

# Update the pathconfig file in $MAIN_LIB_DIR
#  The awk script below replaces the original binding in $pcfile
#  with its fresh counterpart should there be one.  Other bindings
#  are retained and brand new ones are added.
pcfile=$MAIN_LIB_DIR/pathconfig
if [ -f $pcfile ] ; then
    cp $pcfile $tmpfile
fi
rm -f $pcfile
cat $LIB_DIR/pathconfig >>$tmpfile
awk <$tmpfile >$pcfile 'NF == 2 { mapping[$1] = $2 }
NF != 2 { print $0 }
END { for (i in mapping) print i, mapping[i] }'

rm -r $LIB_DIR

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0