if [ -x /usr/bin/update-desktop-database ]; then
  /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
fi

if [ -x /usr/bin/update-mime-database ]; then
  /usr/bin/update-mime-database usr/share/mime >/dev/null 2>&1
fi

if [ -e usr/share/icons/hicolor/icon-theme.cache ]; then
  if [ -x /usr/bin/gtk-update-icon-cache ]; then
    /usr/bin/gtk-update-icon-cache usr/share/icons/hicolor >/dev/null 2>&1
  fi
fi
( cd usr/lib ; rm -rf librep.so )
( cd usr/lib ; ln -sf librep.so.16.0.0 librep.so )
( cd usr/lib ; rm -rf librep.so.16 )
( cd usr/lib ; ln -sf librep.so.16.0.0 librep.so.16 )
( cd usr/lib/rep ; rm -rf readline.so )
( cd usr/lib/rep ; ln -sf rep/io/readline.so readline.so )
( cd usr/lib/rep ; rm -rf gettext.so )
( cd usr/lib/rep ; ln -sf rep/i18n/gettext.so gettext.so )
( cd usr/lib/rep ; rm -rf tables.so )
( cd usr/lib/rep ; ln -sf rep/data/tables.so tables.so )
( cd usr/lib/rep ; rm -rf sdbm.so )
( cd usr/lib/rep ; ln -sf rep/io/db/sdbm.so sdbm.so )
( cd usr/lib/rep ; rm -rf gdbm.so )
( cd usr/lib/rep ; ln -sf rep/io/db/gdbm.so gdbm.so )
( cd usr/lib/rep ; rm -rf timers.so )
( cd usr/lib/rep ; ln -sf rep/io/timers.so timers.so )
( cd usr/share/rep/lisp ; rm -rf records.jl )
( cd usr/share/rep/lisp ; ln -sf rep/data/records.jl records.jl )
( cd usr/share/rep/lisp ; rm -rf disassembler.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/vm/disassembler.jlc disassembler.jlc )
( cd usr/share/rep/lisp ; rm -rf remote-ftp.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/io/file-handlers/remote/ftp.jlc remote-ftp.jlc )
( cd usr/share/rep/lisp ; rm -rf mutex.jl )
( cd usr/share/rep/lisp ; ln -sf rep/threads/mutex.jl mutex.jl )
( cd usr/share/rep/lisp ; rm -rf gaol.jl )
( cd usr/share/rep/lisp ; ln -sf rep/util/gaol.jl gaol.jl )
( cd usr/share/rep/lisp ; rm -rf cgi-get.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/www/cgi-get.jlc cgi-get.jlc )
( cd usr/share/rep/lisp ; rm -rf disassembler.jl )
( cd usr/share/rep/lisp ; ln -sf rep/vm/disassembler.jl disassembler.jl )
( cd usr/share/rep/lisp ; rm -rf lisp-doc.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/lang/compat-doc.jlc lisp-doc.jlc )
( cd usr/share/rep/lisp ; rm -rf cgi-get.jl )
( cd usr/share/rep/lisp ; ln -sf rep/www/cgi-get.jl cgi-get.jl )
( cd usr/share/rep/lisp ; rm -rf gaol.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/util/gaol.jlc gaol.jlc )
( cd usr/share/rep/lisp ; rm -rf ring.jl )
( cd usr/share/rep/lisp ; ln -sf rep/data/ring.jl ring.jl )
( cd usr/share/rep/lisp ; rm -rf mutex.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/threads/mutex.jlc mutex.jlc )
( cd usr/share/rep/lisp ; rm -rf ring.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/data/ring.jlc ring.jlc )
( cd usr/share/rep/lisp ; rm -rf remote-ftp.jl )
( cd usr/share/rep/lisp ; ln -sf rep/io/file-handlers/remote/ftp.jl remote-ftp.jl )
( cd usr/share/rep/lisp ; rm -rf remote-rep.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/io/file-handlers/remote/rep.jlc remote-rep.jlc )
( cd usr/share/rep/lisp ; rm -rf remote-rep.jl )
( cd usr/share/rep/lisp ; ln -sf rep/io/file-handlers/remote/rep.jl remote-rep.jl )
( cd usr/share/rep/lisp ; rm -rf symbol-table.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/data/symbol-table.jlc symbol-table.jlc )
( cd usr/share/rep/lisp ; rm -rf compiler.jl )
( cd usr/share/rep/lisp ; ln -sf rep/vm/compiler.jl compiler.jl )
( cd usr/share/rep/lisp ; rm -rf mailaddr.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/mail/addr.jlc mailaddr.jlc )
( cd usr/share/rep/lisp ; rm -rf memoize.jl )
( cd usr/share/rep/lisp ; ln -sf rep/util/memoize.jl memoize.jl )
( cd usr/share/rep/lisp ; rm -rf queues.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/data/queues.jlc queues.jlc )
( cd usr/share/rep/lisp ; rm -rf mailaddr.jl )
( cd usr/share/rep/lisp ; ln -sf rep/mail/addr.jl mailaddr.jl )
( cd usr/share/rep/lisp ; rm -rf date.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/util/date.jlc date.jlc )
( cd usr/share/rep/lisp ; rm -rf lisp-doc.jl )
( cd usr/share/rep/lisp ; ln -sf rep/lang/compat-doc.jl lisp-doc.jl )
( cd usr/share/rep/lisp ; rm -rf records.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/data/records.jlc records.jlc )
( cd usr/share/rep/lisp ; rm -rf memoize.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/util/memoize.jlc memoize.jlc )
( cd usr/share/rep/lisp ; rm -rf symbol-table.jl )
( cd usr/share/rep/lisp ; ln -sf rep/data/symbol-table.jl symbol-table.jl )
( cd usr/share/rep/lisp ; rm -rf date.jl )
( cd usr/share/rep/lisp ; ln -sf rep/util/date.jl date.jl )
( cd usr/share/rep/lisp ; rm -rf compiler.jlc )
( cd usr/share/rep/lisp ; ln -sf rep/vm/compiler.jlc compiler.jlc )
( cd usr/share/rep/lisp ; rm -rf queues.jl )
( cd usr/share/rep/lisp ; ln -sf rep/data/queues.jl queues.jl )
