Initial fixes to abakus build system

git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/abakus@1231032 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
v3.5.13-sru
tpearson 14 years ago
parent 40411f9e47
commit 4488b6112c

@ -47,7 +47,7 @@ def KDEuse(lenv, flags):
if 'thread' in _flags:
## Uncomment the following if you need threading support
lenv.KDEaddflags_cxx( ['-DQT_THREAD_SUPPORT', '-D_REENTRANT'] )
if 'fastmoc' in _flags:
if 'fasmoc' in _flags:
lenv['BKSYS_FASTMOC']=1
if not 'nohelp' in _flags:
if lenv['_CONFIGURE'] or lenv['HELP']:
@ -132,21 +132,21 @@ def detect_kde(env):
env.Exit(1)
env['QTDIR'] = qtdir.strip()
## Find the necessary programs uic and moc
print "Checking for uic : ",
uic = qtdir + "/bin/uic"
## Find the necessary programs uic-tqt and moc
print "Checking for uic-tqt : ",
uic = qtdir + "/bin/uic-tqt"
if os.path.isfile(uic):
print GREEN+"uic was found as "+uic+NORMAL
print GREEN+"uic-tqt was found as "+uic+NORMAL
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):
print YELLOW+"uic was found as "+uic+NORMAL
print YELLOW+"uic-tqt was found as "+uic+NORMAL
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):
print YELLOW+"uic was found as "+uic+NORMAL
print YELLOW+"uic-tqt was found as "+uic+NORMAL
else:
print RED+"uic was not found - set QTDIR put it in your PATH ?"+NORMAL
print RED+"uic-tqt was not found - set QTDIR put it in your PATH ?"+NORMAL
env.Exit(1)
env['QT_UIC'] = uic
@ -166,22 +166,25 @@ def detect_kde(env):
env.Exit(1)
env['QT_MOC'] = moc
## check for the qt and kde includes
print "Checking for the qt includes : ",
if qtincludes and os.path.isfile(qtincludes + "/qlayout.h"):
## check for the tqt and kde includes
print "Checking for the tqt includes : ",
if qtincludes and os.path.isfile(qtincludes + "/tqt.h"):
# The user told where to look for and it looks valid
print GREEN + "ok " + qtincludes + NORMAL
else:
if os.path.isfile(qtdir + "/include/qlayout.h"):
if os.path.isfile(qtdir + "/include/tqt.h"):
# Automatic detection
print GREEN + "ok " + qtdir + "/include/ " + NORMAL
qtincludes = qtdir + "/include/"
elif os.path.isfile("/usr/include/qt3/qlayout.h"):
elif os.path.isfile("/usr/include/tqt.h"):
print YELLOW + "the tqt headers were found in /usr/include/ " + NORMAL
qtincludes = "/usr/include"
elif os.path.isfile("/usr/include/tqt/tqt.h"):
# Debian probably
print YELLOW + "the qt headers were found in /usr/include/qt3/ " + NORMAL
qtincludes = "/usr/include/qt3"
print YELLOW + "the tqt headers were found in /usr/include/tqt/ " + NORMAL
qtincludes = "/usr/include/tqt"
else:
print RED + "the qt headers were not found" + NORMAL
print RED + "the tqt headers were not found" + NORMAL
env.Exit(1)
print "Checking for the kde includes : ",
@ -291,9 +294,9 @@ ie: b[scons configure libdir=/usr/local/lib qtincludes=/usr/include/qt]
('QTDIR', ''),
('QTLIBPATH', 'path to the qt libraries'),
('QTINCLUDEPATH', 'path to the qt includes'),
('QT_UIC', 'uic command'),
('QT_UIC', 'uic-tqt command'),
('QT_MOC', 'moc command'),
('QTPLUGINS', 'uic executable command'),
('QTPLUGINS', 'uic-tqt executable command'),
('KDEDIR', ''),
('KDELIBPATH', 'path to the installed kde libs'),
@ -442,7 +445,7 @@ ie: b[scons configure libdir=/usr/local/lib qtincludes=/usr/include/qt]
# We have the header corresponding to the cpp file
if h_ext:
needscan=0
# User asked for fastmoc, try to avoid scanning
# User asked for fasmoc, try to avoid scanning
if env.has_key('BKSYS_FASTMOC'):
if os.path.isfile(bs+'.moc'):
lenv.Moc(bs+h_ext)
@ -521,7 +524,7 @@ ie: b[scons configure libdir=/usr/local/lib qtincludes=/usr/include/qt]
for ofile in other_files:
if ofile == file:
print RED+"WARNING: You have included "+file+".ui and another file of the same prefix"+NORMAL
print "Files generated by uic (file.h, file.cpp must not be included"
print "Files generated by uic-tqt (file.h, file.cpp must not be included"
for file in kcfg_files:
for ofile in other_files:
if ofile == file:

@ -56,7 +56,7 @@ if myenv.Dictionary().has_key('PARSER_INCLUDED'):
if myenv['HAVE_ASNEEDED']:
myenv.Append(LINKFLAGS = '-Wl,--as-needed')
myenv.Append(CXXFLAGS = '-Wno-non-virtual-dtor')
myenv.Append(CXXFLAGS = '-Wno-non-virtual-dtor -I/usr/include/tqt -include tqt.h -DTQT_THREAD_SUPPORT')
############################
## Customization

Loading…
Cancel
Save