## This was causing problems compiling KDE for unknown reasons.
## So, we'll symlink the libraries into /opt/kde3 again...
# Add QT library directory to /etc/ld.so.conf:
if ! grep /opt/kde3/lib etc/ld.so.conf 1> /dev/null 2> /dev/null ; then
  echo "/opt/kde3/lib" >> etc/ld.so.conf
fi
if [ -x /sbin/ldconfig ]; then
  /sbin/ldconfig 2> /dev/null
fi
( cd opt/kde3/bin ; rm -rf lrelease )
( cd opt/kde3/bin ; ln -sf ../lib/qt3-3.3.8b/bin/lrelease lrelease )
( cd opt/kde3/bin ; rm -rf qmake )
( cd opt/kde3/bin ; ln -sf ../lib/qt3-3.3.8b/bin/qmake qmake )
( cd opt/kde3/bin ; rm -rf uic )
( cd opt/kde3/bin ; ln -sf ../lib/qt3-3.3.8b/bin/uic uic )
( cd opt/kde3/bin ; rm -rf moc )
( cd opt/kde3/bin ; ln -sf ../lib/qt3-3.3.8b/bin/moc moc )
( cd opt/kde3/bin ; rm -rf designer )
( cd opt/kde3/bin ; ln -sf ../lib/qt3-3.3.8b/bin/designer designer )
( cd opt/kde3/bin ; rm -rf linguist )
( cd opt/kde3/bin ; ln -sf ../lib/qt3-3.3.8b/bin/linguist linguist )
( cd opt/kde3/bin ; rm -rf qm2ts )
( cd opt/kde3/bin ; ln -sf ../lib/qt3-3.3.8b/bin/qm2ts qm2ts )
( cd opt/kde3/bin ; rm -rf assistant )
( cd opt/kde3/bin ; ln -sf ../lib/qt3-3.3.8b/bin/assistant assistant )
( cd opt/kde3/bin ; rm -rf lupdate )
( cd opt/kde3/bin ; ln -sf ../lib/qt3-3.3.8b/bin/lupdate lupdate )
( cd opt/kde3/bin ; rm -rf qtconfig )
( cd opt/kde3/bin ; ln -sf ../lib/qt3-3.3.8b/bin/qtconfig qtconfig )
( cd opt/kde3/lib ; rm -rf libqui.so.1.0 )
( cd opt/kde3/lib ; ln -sf qt3-3.3.8b/lib/libqui.so.1.0 libqui.so.1.0 )
( cd opt/kde3/lib ; rm -rf libqt-mt.so )
( cd opt/kde3/lib ; ln -sf qt3-3.3.8b/lib/libqt-mt.so libqt-mt.so )
( cd opt/kde3/lib/qt3-3.3.8b/mkspecs/linux-g++ ; rm -rf linux-g++ )
( cd opt/kde3/lib/qt3-3.3.8b/mkspecs/linux-g++ ; ln -sf /tmp/txz/qt3/qt-x11-free-3.3.8b/mkspecs/linux-g++ linux-g++ )
( cd opt/kde3/lib/qt3-3.3.8b/mkspecs ; rm -rf default )
( cd opt/kde3/lib/qt3-3.3.8b/mkspecs ; ln -sf linux-g++ default )
( cd opt/kde3/lib/qt3-3.3.8b/lib ; rm -rf libqui.so.1.0 )
( cd opt/kde3/lib/qt3-3.3.8b/lib ; ln -sf libqui.so.1.0.0 libqui.so.1.0 )
( cd opt/kde3/lib/qt3-3.3.8b/lib ; rm -rf libqt-mt.so )
( cd opt/kde3/lib/qt3-3.3.8b/lib ; ln -sf libqt-mt.so.3.3.8 libqt-mt.so )
( cd opt/kde3/lib/qt3-3.3.8b/lib ; rm -rf libqui.so )
( cd opt/kde3/lib/qt3-3.3.8b/lib ; ln -sf libqui.so.1.0.0 libqui.so )
( cd opt/kde3/lib/qt3-3.3.8b/lib ; rm -rf libqt-mt.so.3.3 )
( cd opt/kde3/lib/qt3-3.3.8b/lib ; ln -sf libqt-mt.so.3.3.8 libqt-mt.so.3.3 )
( cd opt/kde3/lib/qt3-3.3.8b/lib ; rm -rf libqt-mt.so.3 )
( cd opt/kde3/lib/qt3-3.3.8b/lib ; ln -sf libqt-mt.so.3.3.8 libqt-mt.so.3 )
( cd opt/kde3/lib/qt3-3.3.8b/lib ; rm -rf libqui.so.1 )
( cd opt/kde3/lib/qt3-3.3.8b/lib ; ln -sf libqui.so.1.0.0 libqui.so.1 )
( cd opt/kde3/lib ; rm -rf libqui.so )
( cd opt/kde3/lib ; ln -sf qt3-3.3.8b/lib/libqui.so libqui.so )
( cd opt/kde3/lib ; rm -rf libqui.so.1.0.0 )
( cd opt/kde3/lib ; ln -sf qt3-3.3.8b/lib/libqui.so.1.0.0 libqui.so.1.0.0 )
( cd opt/kde3/lib ; rm -rf libqt-mt.so.3.3 )
( cd opt/kde3/lib ; ln -sf qt3-3.3.8b/lib/libqt-mt.so.3.3 libqt-mt.so.3.3 )
( cd opt/kde3/lib/pkgconfig ; rm -rf qt-mt.pc )
( cd opt/kde3/lib/pkgconfig ; ln -sf ../qt3-3.3.8b/lib/pkgconfig/qt-mt.pc qt-mt.pc )
( cd opt/kde3/lib ; rm -rf libqt-mt.so.3 )
( cd opt/kde3/lib ; ln -sf qt3-3.3.8b/lib/libqt-mt.so.3 libqt-mt.so.3 )
( cd opt/kde3/lib ; rm -rf libqt-mt.so.3.3.8 )
( cd opt/kde3/lib ; ln -sf qt3-3.3.8b/lib/libqt-mt.so.3.3.8 libqt-mt.so.3.3.8 )
( cd opt/kde3/lib ; rm -rf libqui.so.1 )
( cd opt/kde3/lib ; ln -sf qt3-3.3.8b/lib/libqui.so.1 libqui.so.1 )
( cd opt/kde3/lib ; rm -rf qt3 )
( cd opt/kde3/lib ; ln -sf qt3-3.3.8b qt3 )
