#!/bin/sh
# Copyright (c) 1993 by Adobe Systems Incorporated.
# Script called immediately after a package is installed.
# $1=Install directory for package. $2=License data file
########################################################

/usr/bin/cat $1/bin/acroread \
| sed 's%INSTALL_DIR=$%INSTALL_DIR="'$1'"%' \
| sed 's%INSTALL_DIR=""$%INSTALL_DIR="'$1'"%' \
> $1/bin/acroread.new
/usr/bin/rm -f $1/bin/acroread
/usr/bin/mv $1/bin/acroread.new $1/bin/acroread
chmod 555 $1/bin/acroread

if $1/desktop/deskinstall ; then status=0; else status=1; fi
if [ $status != 0 ]; then
	echo ""
	echo "Integration of Acrobat Reader onto the desktop failed."
	echo "Easy/quick installation was unsuccessful."
	echo "Re-install following the longer custom installation instructions."
	echo ""
	exit 1
fi

exit 0
