# This has to assume the use of upgradepkg to work.
# Ever wondered why we install new packages twice?
# Here's an example:
if [ -d etc/X11/xkb/symbols/pc ]; then
  mv etc/X11/xkb etc/X11/xkb.old.bak.$$
  mkdir -p etc/X11/xkb/rules etc/X11/xkb
fi
( cd usr/share/X11 ; rm -rf xkb )
( cd usr/share/X11 ; ln -sf ../../../etc/X11/xkb xkb )
( cd etc/X11/xkb/rules ; rm -rf xorg.xml )
( cd etc/X11/xkb/rules ; ln -sf base.xml xorg.xml )
( cd etc/X11/xkb/rules ; rm -rf xfree86.xml )
( cd etc/X11/xkb/rules ; ln -sf base.xml xfree86.xml )
( cd etc/X11/xkb/rules ; rm -rf xorg.lst )
( cd etc/X11/xkb/rules ; ln -sf base.lst xorg.lst )
( cd etc/X11/xkb/rules ; rm -rf xfree86.lst )
( cd etc/X11/xkb/rules ; ln -sf base.lst xfree86.lst )
( cd etc/X11/xkb/rules ; rm -rf xorg )
( cd etc/X11/xkb/rules ; ln -sf base xorg )
( cd etc/X11/xkb/rules ; rm -rf xfree86 )
( cd etc/X11/xkb/rules ; ln -sf base xfree86 )
