DataMuseum.dk

Presents historical artifacts from the history of:

DKUUG/EUUG Conference tapes

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about DKUUG/EUUG Conference tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - metrics - download
Index: T c

⟦a8ce3cf9f⟧ TextFile

    Length: 2501 (0x9c5)
    Types: TextFile
    Names: »config.cf«

Derivation

└─⟦db229ac7e⟧ Bits:30007240 EUUGD20: SSBA 1.2 / AFW Benchmarks
    └─⟦this⟧ »EUUGD20/AFUU-ssba1.21/ssba1.21F/config/config.cf« 

TextFile

#! /bin/sh
#				SSBA 1.21F
#
# Script : config.cf
#
INSTALL=../install
syn=../results/synthese
b=config
log=$b.log
res=$b.res
d=`date`
echo "CONFIGURATION:	BEGIN configuration at $d" >$log
chmod u+x $b.run
printer=`cat $INSTALL/printer.cmd`
optprinter=`cat $INSTALL/printer.opt`
pager=`cat $INSTALL/pager.cmd`
cc=`cat $INSTALL/cc.cmd`
optcc=`cat $INSTALL/cc.opt`
flocc=`cat $INSTALL/cc.flo`
system=`cat $INSTALL/define`
sed -e "s/^PRINTER.*$/PRINTER	=	${printer}/" \
    -e "s/^PRINTOPT.*$/PRINTOPT=	${optprinter}/" \
    -e "s/^PAGER.*$/PAGER	=	${pager}/" \
    -e "s/^COMPILER.*$/COMPILER=	${cc}/" \
    -e "s/^LOCALOPT.*$/LOCALOPT=	${optcc}/" \
    -e "s/^FLOPT.*$/FLOPT=		${flocc}/" \
    -e "s/^SYSTEM.*$/SYSTEM	=	${system}/" \
	<config.mk >config.tmp
mv config.tmp config.mk
#
# Identification du site
#
if [ -f /bin/uname ]
then
	mach=`uname -a`
	methode="(uname)"
elif [ -f /usr/bin/uname ]
then
	mach=`uname -a`
	methode="(uname)"
elif [ -f /usr/bin/uuname ]
then
	mach=`uuname -l`
	methode="(uuname)"
elif [ -f /bin/hostname ]
then
	mach=`hostname`
	methode="(hostname)"
elif [ -f /usr/bin/hostname ]
then
	mach=`hostname`
	methode="(hostname)"
elif [ -f /etc/systemid ]
then
	mach=`cat /etc/systemid`
	methode="(systemid)"
else
	echo "Nom de votre machine :"
	read mach
	if [ "$mach" = "" ]
	then
		mach="unknown"
		methode="(manuel)"
	fi
fi
echo "machine = $mach $methode" >>$res
echo "machine = $mach $methode" >>$syn
echo "$mach" >$INSTALL/machine
#
# Nom du benchmarkeur
#
if [ -f /bin/who ]
then
	user=`who am i`
	echo "whoami = $user" >>$res
	echo "whoami = $user" >>$syn
else
	user=`logname`
	echo "logname = $user" >>$res
	echo "logname = $user" >>$syn
fi	
#
# Determination du HZ
#
rm hz.h 2>/dev/null
rm hz.tmp 2>/dev/null
methode="(calcul)"
make hz -f $b.mk
./hz >HZ
hz=`cat HZ`
if [ "$hz" = "70" ] ; then
	methode="(calcul arrondi)"
	hz=60
	echo $hz > HZ
fi
if [ "$hz" = "0" ] ; then
	grep HZ /usr/include/sys/param.h >hz.tmp
	if grep -c "define.*HZ.*$" hz.tmp >/dev/null ; then
		methode="(param.h)"
		awk ' { if ($2 == "HZ") print $3 } ' <hz.tmp >hz.param
		hz=`cat hz.param`
		rm hz.param
		echo "HZ (calcul) = 0 - HZ (param.h) = $hz" >>$log
		echo $hz > HZ
	else
		methode="(forcage a priori)"
		hz=60
		echo $hz > HZ
	fi
	rm hz.tmp
fi
echo "#define HZ	$hz" >hz.h
echo "#define HZ	$hz" >$INSTALL/hz.h
echo "valeur du HZ = $hz $methode" >>$res
echo "valeur du HZ = $hz $methode" >>$syn
#
# Fin de configuration
#
d=`date`
echo "CONFIGURATION:	END configuration at $d" >>$log