summaryrefslogtreecommitdiffstats
path: root/qt4/kqt4-wrapper.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'qt4/kqt4-wrapper.cmake')
-rwxr-xr-xqt4/kqt4-wrapper.cmake29
1 files changed, 29 insertions, 0 deletions
diff --git a/qt4/kqt4-wrapper.cmake b/qt4/kqt4-wrapper.cmake
new file mode 100755
index 0000000..84205b6
--- /dev/null
+++ b/qt4/kqt4-wrapper.cmake
@@ -0,0 +1,29 @@
+#!/bin/bash
+
+#
+# This script is part of the KGtk package.
+#
+# (C) Craig Drummond, 2007
+#
+# Craig.Drummond@lycos.co.uk
+#
+# --
+# Released under the GPL v2 or later
+# --
+#
+
+app=`basename $0`
+
+if [ "$app" = "kqt4-wrapper" ] ; then
+ LD_PRELOAD=@CMAKE_INSTALL_PREFIX@/lib/kgtk/libkqt4.so:$LD_PRELOAD "$@"
+else
+ dir=`dirname $0`
+ oldPath=$PATH
+ PATH=`echo $PATH | sed s:$dir::g`
+ real=`which $app`
+ PATH=$oldPath
+
+ if [ "$real" != "" ] && [ "`dirname $real`" != "$dir" ] ; then
+ LD_PRELOAD=@CMAKE_INSTALL_PREFIX@/lib@LIB_SUFFIX@/kgtk/libkqt4.so:$LD_PRELOAD $real "$@"
+ fi
+fi