summaryrefslogtreecommitdiffstats
path: root/admin/kde.py
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-04 21:50:57 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-04 21:50:57 +0000
commit8af7968d9309f6869a93ff6f1a4ef51bcff964fb (patch)
treef875b03e53eb9170c93fc2d2a9d1047e570789e8 /admin/kde.py
parent0cbbdc735b3069758b90527554e43ad905e46665 (diff)
downloadtdeio-locate-8af7968d9309f6869a93ff6f1a4ef51bcff964fb.tar.gz
tdeio-locate-8af7968d9309f6869a93ff6f1a4ef51bcff964fb.zip
TQt4 port kio-locate
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kio-locate@1239314 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'admin/kde.py')
-rw-r--r--admin/kde.py30
1 files changed, 17 insertions, 13 deletions
diff --git a/admin/kde.py b/admin/kde.py
index 43927f2..2afdb49 100644
--- a/admin/kde.py
+++ b/admin/kde.py
@@ -107,40 +107,40 @@ def detect_kde(env):
p('GREEN',kde_version)
## Detect the qt library
- print "Checking for the qt library : ",
+ print "Checking for the tqt library : ",
if not qtdir: qtdir = os.getenv("QTDIR")
if qtdir:
- p('GREEN',"qt is in "+qtdir)
+ p('GREEN',"tqt is in "+qtdir)
else:
try:
tmplibdir = os.popen(kde_config+' --expandvars --install lib').read().strip()
libkdeuiSO = env.join(tmplibdir, getSOfromLA(env.join(tmplibdir,'/libkdeui.la')) )
- m = re.search('(.*)/lib/libqt.*', os.popen('ldd ' + libkdeuiSO + ' | grep libqt').read().strip().split()[2])
+ m = re.search('(.*)/lib/libtqt.*', os.popen('ldd ' + libkdeuiSO + ' | grep libtqt').read().strip().split()[2])
except: m=None
if m:
qtdir = m.group(1)
- p('YELLOW',"qt was found as "+m.group(1))
+ p('YELLOW',"tqt was found as "+m.group(1))
else:
- p('RED','qt was not found')
+ p('RED','tqt was not found')
p('RED','Please set QTDIR first (/usr/lib/qt3?) or try scons -h for more options')
env.Exit(1)
env['QTDIR'] = qtdir.strip()
## Find the necessary programs uic and moc
- print "Checking for uic : ",
- uic = qtdir + "/bin/uic"
+ print "Checking for uic-tqt : ",
+ uic = qtdir + "/bin/uic-tqt"
if os.path.isfile(uic):
- p('GREEN',"uic was found as "+uic)
+ p('GREEN',"uic-tqt was found as "+uic)
else:
- uic = os.popen("which uic 2>/dev/null").read().strip()
+ uic = os.popen("which uic-tqt 2>/dev/null").read().strip()
if len(uic):
- p('YELLOW',"uic was found as "+uic)
+ p('YELLOW',"uic-tqt was found as "+uic)
else:
- uic = os.popen("which uic 2>/dev/null").read().strip()
+ uic = os.popen("which uic-tqt 2>/dev/null").read().strip()
if len(uic):
- p('YELLOW',"uic was found as "+uic)
+ p('YELLOW',"uic-tqt was found as "+uic)
else:
- p('RED',"uic was not found - set QTDIR put it in your PATH ?")
+ p('RED',"uic-tqt was not found - set QTDIR put it in your PATH ?")
env.Exit(1)
env['QT_UIC'] = uic
@@ -174,6 +174,10 @@ def detect_kde(env):
# Debian probably
p('YELLOW','the qt headers were found in /usr/include/qt3/')
qtincludes = "/usr/include/qt3"
+ elif os.path.isfile("/usr/include/qt4/Qt/qglobal.h"):
+ # Debian probably
+ p('YELLOW', 'the qt headers were found in /usr/include/qt4/')
+ qtincludes = "/usr/include/qt4"
else:
p('RED',"the qt headers were not found")
env.Exit(1)