|
|
DataMuseum.dkPresents historical artifacts from the history of: DKUUG/EUUG Conference tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about DKUUG/EUUG Conference tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: T i
Length: 4182 (0x1056)
Types: TextFile
Names: »install.sh«
└─⟦2d1937cfd⟧ Bits:30007241 EUUGD22: P.P 5.0
└─⟦041b9c0f8⟧ »EurOpenD22/isode/pepsy.system-6.0.Z«
└─⟦d49939f05⟧
└─⟦this⟧ »install.sh«
#! /bin/sh
#
# Install the pepsy system into ISODE in a subdirectory of others
#
echo "Making a copy of the parts of isode we need in others/pepsy"
echo "All files are linked (with hard links). Then patches are applied which"
echo "makes a copy of any file it needs to change"
if mkdir others/pepsy
then
cd others/pepsy
else
echo "can not make directory"
exit 1
fi
# copy all the directories
for dir in psap2 acsap ftam ftam2 pepy
do
if test -d ../../$dir
then
:
else
echo "missing $dir: $0 failed"
exit 1
fi
echo making $dir
mkdir $dir
if ln ../../$dir/*.[ch] $dir
then echo linked C files
fi
if ln ../../$dir/*.py $dir
then echo linked ASN.1 files
fi
if ln ../../$dir/Makefile ../../$dir/make $dir
then echo linked Makefile and make
fi
done
# back up all the directories
for dir in h psap ssap tsap compat support config dirent
do
if test -d ../../$dir
then
:
else
echo "missing $dir: $0 failed"
exit 1
fi
mkdir $dir
if ln ../../$dir/*.[ch] $dir
then echo linked C files
fi
if test -f ../../$dir/Makefile && ln ../../$dir/Makefile $dir
then echo -n linked Makefile
fi
if test -f ../../$dir/make && ln ../../$dir/make $dir
then echo ' and make'
fi
echo $dir made
done
# especially for util
if mkdir util && ln ../../util/*.sh util
then
echo linked util/*.sh
else
echo "Failed to link util/*.sh files"
exit 2
fi
# especially for pepy
if ln ../../pepy/*.gnrc pepy
then
echo linked pepy/*.gnrc
else
echo "Failed to link pepy/*.gnrc files"
exit 2
fi
# Especially for compat
if ln ../../compat/*.sh compat
then
echo linked compat/*.sh
else
echo "Failed to link compat/*.sh files"
exit 2
fi
# especially to eliminate OPTIONS= -DDEBUG
/bin/rm -f config/CONFIG.make
if cp ../../config/CONFIG.make config
then
echo copied CONFIG.make
# if grep OPTIONS config/CONFIG.make | grep -e -DDEBUG
# then
# echo "removing debug option. Unavailable at the moment"
# if ed - config/CONFIG.make << !
#/OPTIONS/
#s/-DDEBUG//p
#w
#q
#!
# then
# echo edit succeeded
# else
# echo edit of config/CONFIG.make failed
# exit 2
# fi
else
echo "Failed to copy CONFIG.make"
exit 2
fi
fi
if ln ../../Makefile ../../make .
then
echo linked ./Makefile and ./make
else
echo linked ./Makefile and ./make: failed
exit 2
fi
# extract the new files
if tar xf ../../pepsy.tar
then
echo "New files extracted"
else
echo "failed to extract new files"
exit 4
fi
# Apply patches: We make use of the fact that linked files DO NOT get patched
if patch -p < ../../pepsy.patches
then
echo "Patched sucessfully"
else
echo "Failed: !"
exit 3
fi
# Don't need these any more
# /* create the *-print.o files to keep the Makefiles happy */
#for f in psap2/PS acsap/ACS ftam/CONT ftam/FADU ftam/FTAM ftam/DOCS
# do
# cp /dev/null $f-print.o
#done
#
#
# Not any more we don't
# /* Need library from somewhere */
#
#if test -f ../../libisode.a
# then
# if cp ../../libisode.a .
# then :
# else
# cannot copy libisode.a
# exit 7
# fi
# else
# # calculate where library might be installed.
# set - `grep \^LIBDIR config/CONFIG.make | head -1 `
# lib=$3/libisode.a
# if test -f $lib
# then
# if cp $lib libisode.a
# then :
# else
# echo cannot copy $lib
# exit 8
# fi
# else
# echo cannot find library
# exit 6
# fi
#fi
# Too bad if you are not 4.2 ?
#ranlib libisode.a
#
# Finished
echo 'Now type "cd others/pepsy"'
hname=`hostname`
if test -f config/CONFIG.make
then
: # got CONFIG file
else
echo "You need a config/CONFIG.make file !"
echo "Copy and edit (if neccessary) one from the config directory"
echo "to config/CONFIG.make.
echo "You should link it to config/${hname}.make"
fi
if test -f h/config.h
then
: # got config.h
else
echo "You need a h/config.h file !"
echo "Copy and edit (if necessary) one from config directory"
echo "You should link it to config/${hname}.h"
fi
echo 'then "./make all"'
echo 'and finally "./make all-ftam"'