#!/bin/bash
#
# $Id$
# 
# Finalize installation for mondo
# Now that /bin, /sbin are links to /usr
# move eveything below /usr to avoid issues
# this should be backward compatible with earlier distributions

if [ _"$DESTDIR" != _"" ]; then
	mv $DESTDIR/bin/* $DESTDIR/usr/bin
	mv $DESTDIR/sbin/* $DESTDIR/usr/sbin
	rmdir $DESTDIR/bin $DESTDIR/sbin
	(cd $DESTDIR ; ln -sf usr/bin/busybox linuxrc)
else
	echo "ERROR: DESTDIR variable undefined"
fi
