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

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

if [ -x /usr/bin/gtk-update-icon-cache ]; then
  /usr/bin/gtk-update-icon-cache  -f -q /usr/share/icons/hicolor &> /dev/null
fi

( cd usr/bin ; rm -rf realplay )
( cd usr/bin ; ln -sf /opt/real/RealPlayer/realplay realplay )
( cd usr/share/pixmaps ; rm -rf realplay.png )
( cd usr/share/pixmaps ; ln -sf /opt/real/RealPlayer/share/realplay.png realplay.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-video-generic.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-video-generic_48x48.png realplay-video-generic.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-audio-au.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-audio-au_48x48.png realplay-audio-au.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-video-ogg.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-video-ogg_48x48.png realplay-video-ogg.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-audio-aiff.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-audio-aiff_48x48.png realplay-audio-aiff.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-audio-ogg.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-audio-ogg_48x48.png realplay-audio-ogg.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-application-smil.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-application-smil_48x48.png realplay-application-smil.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-application-ram.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-application-ram_48x48.png realplay-application-ram.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-text-realtext.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-text-realtext_48x48.png realplay-text-realtext.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-audio-generic.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-audio-generic_48x48.png realplay-audio-generic.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-audio-wav.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-audio-wav_48x48.png realplay-audio-wav.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-application-generic.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-application-generic_48x48.png realplay-application-generic.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-application-ogg.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-application-ogg_48x48.png realplay-application-ogg.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; rm -rf realplay-application-rpm.png )
( cd usr/share/icons/hicolor/48x48/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-application-rpm_48x48.png realplay-application-rpm.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-video-generic.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-video-generic_192x192.png realplay-video-generic.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-audio-au.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-audio-au_192x192.png realplay-audio-au.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-video-ogg.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-video-ogg_192x192.png realplay-video-ogg.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-audio-aiff.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-audio-aiff_192x192.png realplay-audio-aiff.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-audio-ogg.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-audio-ogg_192x192.png realplay-audio-ogg.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-application-smil.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-application-smil_192x192.png realplay-application-smil.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-application-ram.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-application-ram_192x192.png realplay-application-ram.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-text-realtext.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-text-realtext_192x192.png realplay-text-realtext.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-audio-generic.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-audio-generic_192x192.png realplay-audio-generic.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-audio-wav.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-audio-wav_192x192.png realplay-audio-wav.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-application-generic.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-application-generic_192x192.png realplay-application-generic.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-application-ogg.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-application-ogg_192x192.png realplay-application-ogg.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; rm -rf realplay-application-rpm.png )
( cd usr/share/icons/hicolor/192x192/mimetypes ; ln -sf /opt/real/RealPlayer/share/icons/mime-application-rpm_192x192.png realplay-application-rpm.png )
( cd usr/share/locale/zh_TW/LC_MESSAGES ; rm -rf realplay.mo )
( cd usr/share/locale/zh_TW/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/zh_TW/player.mo realplay.mo )
( cd usr/share/locale/zh_TW/LC_MESSAGES ; rm -rf widget.mo )
( cd usr/share/locale/zh_TW/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/zh_TW/widget.mo widget.mo )
( cd usr/share/locale/hi/LC_MESSAGES ; rm -rf realplay.mo )
( cd usr/share/locale/hi/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/hi/player.mo realplay.mo )
( cd usr/share/locale/hi/LC_MESSAGES ; rm -rf widget.mo )
( cd usr/share/locale/hi/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/hi/widget.mo widget.mo )
( cd usr/share/locale/pt_BR/LC_MESSAGES ; rm -rf realplay.mo )
( cd usr/share/locale/pt_BR/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/pt_BR/player.mo realplay.mo )
( cd usr/share/locale/pt_BR/LC_MESSAGES ; rm -rf widget.mo )
( cd usr/share/locale/pt_BR/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/pt_BR/widget.mo widget.mo )
( cd usr/share/locale/it/LC_MESSAGES ; rm -rf realplay.mo )
( cd usr/share/locale/it/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/it/player.mo realplay.mo )
( cd usr/share/locale/it/LC_MESSAGES ; rm -rf widget.mo )
( cd usr/share/locale/it/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/it/widget.mo widget.mo )
( cd usr/share/locale/de/LC_MESSAGES ; rm -rf realplay.mo )
( cd usr/share/locale/de/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/de/player.mo realplay.mo )
( cd usr/share/locale/de/LC_MESSAGES ; rm -rf widget.mo )
( cd usr/share/locale/de/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/de/widget.mo widget.mo )
( cd usr/share/locale/pl/LC_MESSAGES ; rm -rf realplay.mo )
( cd usr/share/locale/pl/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/pl/player.mo realplay.mo )
( cd usr/share/locale/pl/LC_MESSAGES ; rm -rf widget.mo )
( cd usr/share/locale/pl/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/pl/widget.mo widget.mo )
( cd usr/share/locale/es/LC_MESSAGES ; rm -rf realplay.mo )
( cd usr/share/locale/es/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/es/player.mo realplay.mo )
( cd usr/share/locale/es/LC_MESSAGES ; rm -rf widget.mo )
( cd usr/share/locale/es/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/es/widget.mo widget.mo )
( cd usr/share/locale/ja/LC_MESSAGES ; rm -rf realplay.mo )
( cd usr/share/locale/ja/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/ja/player.mo realplay.mo )
( cd usr/share/locale/ja/LC_MESSAGES ; rm -rf widget.mo )
( cd usr/share/locale/ja/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/ja/widget.mo widget.mo )
( cd usr/share/locale/fr/LC_MESSAGES ; rm -rf realplay.mo )
( cd usr/share/locale/fr/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/fr/player.mo realplay.mo )
( cd usr/share/locale/fr/LC_MESSAGES ; rm -rf widget.mo )
( cd usr/share/locale/fr/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/fr/widget.mo widget.mo )
( cd usr/share/locale/ko/LC_MESSAGES ; rm -rf realplay.mo )
( cd usr/share/locale/ko/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/ko/player.mo realplay.mo )
( cd usr/share/locale/ko/LC_MESSAGES ; rm -rf widget.mo )
( cd usr/share/locale/ko/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/ko/widget.mo widget.mo )
( cd usr/share/locale/zh_CN/LC_MESSAGES ; rm -rf realplay.mo )
( cd usr/share/locale/zh_CN/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/zh_CN/player.mo realplay.mo )
( cd usr/share/locale/zh_CN/LC_MESSAGES ; rm -rf widget.mo )
( cd usr/share/locale/zh_CN/LC_MESSAGES ; ln -sf /opt/real/RealPlayer/share/locale/zh_CN/widget.mo widget.mo )
