Compare commits

...

60 Commits

Author SHA1 Message Date
Slávek Banko a2804d11d0
Remove cmake submodule since it has now been replaced by cmake-trinity dependency.
3 years ago
TDE Gitea eecb0ac938 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
3 years ago
TDE Gitea 3cc8af3324 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
3 years ago
TDE Gitea 9e520705bf Reset submodule main/applications/kstreamripper/cmake to latest HEAD
3 years ago
TDE Gitea 4f9acf5dfa Reset submodule main/applications/kstreamripper/cmake to latest HEAD
3 years ago
TDE Gitea cd380e2238 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
3 years ago
TDE Gitea 51673582d7 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
3 years ago
TDE Gitea 70ece570be Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea ba61e2be20 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea 596116b401 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea ad35fbec92 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea b924186f5d Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea 084ce40265 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea c26c5f9fcf Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea ff18d7578a Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea 0d633f5092 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea f3a21338a9 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea 6ca3a475a5 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea 5ebb152924 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea f2f2303e6d Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea 80d435b755 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea 9ff400b373 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea a1801a8219 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea f792356f78 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea c6cc353ada Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
TDE Gitea ad8c4eae16 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
4 years ago
Slávek Banko 2e7c87ddc7
Switch all submodules to https.
4 years ago
TDE Gitea 2b55699fb5 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
5 years ago
TDE Gitea dd29db68ea Reset submodule main/applications/kstreamripper/cmake to latest HEAD
5 years ago
TDE Gitea 5d8e73568f Reset submodule main/applications/kstreamripper/cmake to latest HEAD
5 years ago
TDE Gitea 3697611038 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
5 years ago
TDE Gitea 5a3a99ec91 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
5 years ago
TDE Gitea aea68bde15 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
5 years ago
TDE Gitea 732307e6cb Reset submodule main/applications/kstreamripper/cmake to latest HEAD
5 years ago
TDE Gitea 2b6c5d8b8b Reset submodule main/applications/kstreamripper/cmake to latest HEAD
5 years ago
TDE Gitea c5e25ec4e1 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
5 years ago
TDE Gitea 9cb4fd408b Reset submodule main/applications/kstreamripper/cmake to latest HEAD
5 years ago
TDE Gitea 46ea00c008 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
5 years ago
TDE Gitea 652e5d8950 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
5 years ago
Slávek Banko 6d08a2c6a7 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
7 years ago
Slávek Banko 80bb183db1 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
8 years ago
Slávek Banko f96f876cdf Fix FTBFS
11 years ago
Slávek Banko 16eed9395f Reset submodule main/applications/kstreamripper/cmake to latest HEAD
11 years ago
Slávek Banko 2ecd89666b Reset submodule main/applications/kstreamripper/cmake to latest HEAD
11 years ago
Darrell Anderson a98cb051a0 Fix inadvertent tqt changes.
11 years ago
Slávek Banko f322b495bc Reset submodule main/applications/kstreamripper/cmake to latest HEAD
12 years ago
Slávek Banko 5e029725d2 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
12 years ago
Slávek Banko 6d10ac52d4 Reset submodule main/applications/kstreamripper/cmake to latest HEAD
12 years ago
Slávek Banko 7791cb1a7f Reset submodule main/applications/kstreamripper/cmake to latest HEAD
12 years ago
Slávek Banko 620e92c7c4 Update final HTML install path so all modules are consistent.
12 years ago
Slávek Banko f2be7cbd9b Fix FTBFS
12 years ago
Timothy Pearson 77909a22a2 Fix kstreamripper build failures
12 years ago
Timothy Pearson 30478c3449 Update scons to handle TDE
12 years ago
Slávek Banko 48b524d2bc Fix destination HTML directory
12 years ago
Slávek Banko 149306dd99 Update scons for new DSO linkage style
12 years ago
Darrell Anderson f464367a3f Update desktop file.
12 years ago
Timothy Pearson 79a71f3020 Rename obsolete tq methods to standard names
12 years ago
Timothy Pearson 8f97e8d5d5 Remove additional unneeded tq method conversions
12 years ago
Timothy Pearson 90bfd33484 Rename old tq methods that no longer need a unique name
12 years ago
Slávek Banko e3cb7e5685 Add common directories
12 years ago

@ -39,26 +39,47 @@ def detect_kde(env):
kdeincludes= env['ARGS'].get('kdeincludes', None)
kdelibs = env['ARGS'].get('kdelibs', None)
qtincludes = env['ARGS'].get('qtincludes', None)
tqtincludes= env['ARGS'].get('tqtincludes', None)
qtlibs = env['ARGS'].get('qtlibs', None)
kdedir = env['ARGS'].get('kdedir', None)
## Detect the kde libraries
print "Checking for kde-config : ",
kde_config = os.popen("which kde-config 2>/dev/null").read().strip()
str="which kde-config 2>/dev/null"
if kdedir: str="which %s 2>/dev/null" % (kdedir+'/bin/kde-config')
kde_config = os.popen(str).read().strip()
if len(kde_config):
print GREEN + "kde-config was found" + NORMAL
print GREEN + 'kde-config was found as ' + kde_config + NORMAL
else:
print RED + "kde-config was NOT found in your PATH"+ NORMAL
if kdedir: print RED + 'kde-config was NOT found in the folder given ' + kdedir + NORMAL
else: print RED + 'kde-config was NOT found in your PATH' + NORMAL
print "Make sure kde is installed properly"
print "(missing package kdebase-devel?)"
env.Exit(1)
env['KDEDIR'] = os.popen('kde-config -prefix').read().strip()
if kdedir: env['KDEDIR']=kdedir
else: env['KDEDIR'] = os.popen(kde_config+' -prefix').read().strip()
print "Checking for kde version : ",
kde_version = os.popen("kde-config --version|grep KDE").read().strip().split()[1]
if int(kde_version[0]) != 3 or int(kde_version[2]) < 2:
kde_version = os.popen(kde_config+" --version|grep KDE").read().strip().split()[1]
kde_major = kde_version.split('.')[0].lstrip('R')
kde_minor = kde_version.split('.')[1]
kde_patch = kde_version.split('.')[2]
try:
env['KDEm1']=int(kde_major)
except:
pass
try:
env['KDEm2']=int(kde_minor)
except:
pass
try:
env['KDEm3']=int(kde_patch)
except:
pass
if int(kde_major) != 3 or int(kde_minor) < 2:
print RED + kde_version
print RED + "Your kde version can be too old" + NORMAL
print RED + "Please make sure kde is at least 3.2" + NORMAL
print RED + "Your kde version might be too old" + NORMAL
print RED + "Please make sure TDE is at least 3.2" + NORMAL
else:
print GREEN + kde_version + NORMAL
@ -68,9 +89,13 @@ def detect_kde(env):
if qtdir:
print GREEN + "qt is in " + qtdir + NORMAL
else:
libdir = os.popen('kde-config --expandvars --install lib').read().strip()
libdir = os.popen(kde_config + ' --expandvars --install lib').read().strip()
libkdeuiSO = libdir+'/'+getSOfromLA(libdir+'/libkdeui.la')
try:
m = re.search('(.*)/lib/libqt.*', os.popen('ldd '+libkdeuiSO+' | grep libqt').read().strip().split()[2])
except:
m = re.search('(.*)/lib/libtqt.*', os.popen('ldd ' + libkdeuiSO + ' | grep libtqt').read().strip().split()[2])
pass
if m:
qtdir = m.group(1)
print YELLOW+"qt was found as " + m.group(1) + NORMAL
@ -114,30 +139,48 @@ def detect_kde(env):
env.Exit(1)
env['QT_MOC'] = moc
## check for the qt and kde includes
## check for the tqt includes
print "Checking for the tqt includes : ",
if tqtincludes and os.path.isfile(tqtincludes + "/tqlayout.h"):
# The user told where to look for and it looks valid
print GREEN + "ok " + tqtincludes + NORMAL
else:
if os.path.isfile(qtdir + "/include/tqlayout.h"):
# Automatic detection
print GREEN + "ok " + qtdir + "/include/ " + NORMAL
tqtincludes = qtdir + "/include/"
elif os.path.isfile("/usr/include/tqt/tqlayout.h"):
# Debian probably
print YELLOW + "the qt headers were found in /usr/include/tqt/ " + NORMAL
tqtincludes = "/usr/include/tqt"
elif os.path.isfile("/usr/include/qt4/Qt/qglobal.h"):
# Debian probably
print YELLOW + "the qt headers were found in /usr/include/qt4/ " + NORMAL
tqtincludes = "/usr/include/qt4"
else:
print RED + "the qt headers were not found" + NORMAL
env.Exit(1)
## check for the qt includes
print "Checking for the qt includes : ",
if qtincludes and os.path.isfile(qtincludes + "/qlayout.h"):
if qtincludes and os.path.isfile(qtincludes + "/qglobal.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/qglobal.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/qt3/qglobal.h"):
# Debian probably
print YELLOW + "the qt headers were found in /usr/include/qt3/ " + NORMAL
qtincludes = "/usr/include/qt3"
elif os.path.isfile("/usr/include/qt4/Qt/qglobal.h"):
# Debian probably
print YELLOW+"the qt headers were found in /usr/include/qt4/ "+NORMAL
qtincludes = "/usr/include/qt4"
else:
print RED + "the qt headers were not found" + NORMAL
env.Exit(1)
print "Checking for the kde includes : ",
kdeprefix = os.popen("kde-config --prefix").read().strip()
kdeprefix = os.popen(kde_config + " --prefix").read().strip()
if not kdeincludes:
kdeincludes = kdeprefix+"/include/"
if os.path.isfile(kdeincludes + "/klineedit.h"):
@ -161,44 +204,45 @@ def detect_kde(env):
libdir = execprefix+"/lib"
subst_vars = lambda x: x.replace('${exec_prefix}',execprefix).replace('${datadir}',datadir).replace('${libdir}',libdir)
env['KDEBIN'] = subst_vars(os.popen('kde-config --install exe').read().strip())
env['KDEAPPS'] = subst_vars(os.popen('kde-config --install apps').read().strip())
env['KDEDATA'] = subst_vars(os.popen('kde-config --install data').read().strip())
env['KDEMODULE']= subst_vars(os.popen('kde-config --install module').read().strip())
env['KDELOCALE']= subst_vars(os.popen('kde-config --install locale').read().strip())
env['KDEDOC'] = subst_vars(os.popen('kde-config --install html').read().strip())
env['KDEKCFG'] = subst_vars(os.popen('kde-config --install kcfg').read().strip())
env['KDEXDG'] = subst_vars(os.popen('kde-config --install xdgdata-apps').read().strip())
env['KDEMENU'] = subst_vars(os.popen('kde-config --install apps').read().strip())
env['KDEMIME'] = subst_vars(os.popen('kde-config --install mime').read().strip())
env['KDEICONS'] = subst_vars(os.popen('kde-config --install icon').read().strip())
env['KDESERV'] = subst_vars(os.popen('kde-config --install services').read().strip())
env['KDEBIN'] = subst_vars(os.popen(kde_config + ' --install exe').read().strip())
env['KDEAPPS'] = subst_vars(os.popen(kde_config + ' --install apps').read().strip())
env['KDEDATA'] = subst_vars(os.popen(kde_config + ' --install data').read().strip())
env['KDEMODULE']= subst_vars(os.popen(kde_config + ' --install module').read().strip())
env['KDELOCALE']= subst_vars(os.popen(kde_config + ' --install locale').read().strip())
env['KDEDOC'] = subst_vars(os.popen(kde_config + ' --install html').read().strip())
env['KDEKCFG'] = subst_vars(os.popen(kde_config + ' --install kcfg').read().strip())
env['KDEXDG'] = subst_vars(os.popen(kde_config + ' --install xdgdata-apps').read().strip())
env['KDEMENU'] = subst_vars(os.popen(kde_config + ' --install apps').read().strip())
env['KDEMIME'] = subst_vars(os.popen(kde_config + ' --install mime').read().strip())
env['KDEICONS'] = subst_vars(os.popen(kde_config + ' --install icon').read().strip())
env['KDESERV'] = subst_vars(os.popen(kde_config + ' --install services').read().strip())
else:
# the user has given no prefix, install as a normal kde app
env['PREFIX'] = os.popen('kde-config --prefix').read().strip()
env['KDEBIN'] = os.popen('kde-config --expandvars --install exe').read().strip()
env['KDEAPPS'] = os.popen('kde-config --expandvars --install apps').read().strip()
env['KDEDATA'] = os.popen('kde-config --expandvars --install data').read().strip()
env['KDEMODULE']= os.popen('kde-config --expandvars --install module').read().strip()
env['KDELOCALE']= os.popen('kde-config --expandvars --install locale').read().strip()
env['KDEDOC'] = os.popen('kde-config --expandvars --install html').read().strip()
env['KDEKCFG'] = os.popen('kde-config --expandvars --install kcfg').read().strip()
env['KDEXDG'] = os.popen('kde-config --expandvars --install xdgdata-apps').read().strip()
env['KDEMENU'] = os.popen('kde-config --expandvars --install apps').read().strip()
env['KDEMIME'] = os.popen('kde-config --expandvars --install mime').read().strip()
env['KDEICONS'] = os.popen('kde-config --expandvars --install icon').read().strip()
env['KDESERV'] = os.popen('kde-config --expandvars --install services').read().strip()
env['QTPLUGINS']=os.popen('kde-config --expandvars --install qtplugins').read().strip()
env['PREFIX'] = os.popen(kde_config + ' --prefix').read().strip()
env['KDEBIN'] = os.popen(kde_config + ' --expandvars --install exe').read().strip()
env['KDEAPPS'] = os.popen(kde_config + ' --expandvars --install apps').read().strip()
env['KDEDATA'] = os.popen(kde_config + ' --expandvars --install data').read().strip()
env['KDEMODULE']= os.popen(kde_config + ' --expandvars --install module').read().strip()
env['KDELOCALE']= os.popen(kde_config + ' --expandvars --install locale').read().strip()
env['KDEDOC'] = os.popen(kde_config + ' --expandvars --install html').read().strip()
env['KDEKCFG'] = os.popen(kde_config + ' --expandvars --install kcfg').read().strip()
env['KDEXDG'] = os.popen(kde_config + ' --expandvars --install xdgdata-apps').read().strip()
env['KDEMENU'] = os.popen(kde_config + ' --expandvars --install apps').read().strip()
env['KDEMIME'] = os.popen(kde_config + ' --expandvars --install mime').read().strip()
env['KDEICONS'] = os.popen(kde_config + ' --expandvars --install icon').read().strip()
env['KDESERV'] = os.popen(kde_config + ' --expandvars --install services').read().strip()
env['QTPLUGINS']=os.popen(kde_config + ' --expandvars --install qtplugins').read().strip()
## kde libs and includes
env['KDEINCLUDEPATH']= kdeincludes
if not kdelibs:
kdelibs = os.popen('kde-config --expandvars --install lib').read().strip()
kdelibs = os.popen(kde_config + ' --expandvars --install lib').read().strip()
env['KDELIBPATH']= kdelibs
## qt libs and includes
env['QTINCLUDEPATH']= qtincludes
env['TQTINCLUDEPATH']=tqtincludes
if not qtlibs:
qtlibs = qtdir+"/lib"
env['QTLIBPATH']= qtlibs
@ -251,6 +295,7 @@ def generate(env):
"""+BOLD+"""* execprefix """+NORMAL+""": install path for binaries, ie: /usr/bin
"""+BOLD+"""* datadir """+NORMAL+""": install path for the data, ie: /usr/local/share
"""+BOLD+"""* libdir """+NORMAL+""": install path for the libs, ie: /usr/lib
"""+BOLD+"""* kdedir """+NORMAL+""": path to TDE directory, ie: /opt/trinity
"""+BOLD+"""* kdeincludes"""+NORMAL+""": path to the kde includes (/usr/include/kde on debian, ...)
"""+BOLD+"""* qtincludes """+NORMAL+""": same punishment, for qt includes (/usr/include/qt on debian, ...)
"""+BOLD+"""* kdelibs """+NORMAL+""": path to the kde libs, for linking the programs
@ -303,7 +348,7 @@ ie: """+BOLD+"""scons configure libdir=/usr/local/lib qtincludes=/usr/include/qt
opts.Save(cachefile, env)
## set default variables, one can override them in sconscript files
env.Append(CXXFLAGS = ['-I'+env['KDEINCLUDEPATH'], '-I'+env['QTINCLUDEPATH'] ])
env.Append(CXXFLAGS = ['-I'+env['KDEINCLUDEPATH'], '-I'+env['QTINCLUDEPATH'], '-I'+env['TQTINCLUDEPATH'], '-include', 'tqt.h' ])
env.Append(LIBPATH = [env['KDELIBPATH'], env['QTLIBPATH'] ])
env['STATIC_AND_SHARED_OBJECTS_ARE_THE_SAME'] = 1
@ -340,7 +385,7 @@ ie: """+BOLD+"""scons configure libdir=/usr/local/lib qtincludes=/usr/include/qt
act.append('cat '+target[1].path+'.tmp >> '+target[1].path)
act.append('rm -f '+target[1].path+'.tmp')
act.append('echo \'#include "' + target[2].name + '"\' >> '+target[1].path)
act.append('$QT_MOC -o '+target[2].path+' '+target[0].path)
act.append('moc-tqt $QT_MOC '+target[0].path+' '+target[2].path)
return act
def uicEmitter(target, source, env):
@ -367,7 +412,7 @@ ie: """+BOLD+"""scons configure libdir=/usr/local/lib qtincludes=/usr/include/qt
src_suffix = '.ui' )
###### moc file processing
env['QT_MOCCOM'] = ('$QT_MOC -o ${TARGETS[0]} $SOURCE')
env['QT_MOCCOM'] = ('moc-tqt $QT_MOC $SOURCE ${TARGETS[0]}')
MOC_BUILDER = Builder(
action = '$QT_MOCCOM',

@ -79,5 +79,5 @@ def processfolder(folder, lang, destination=""):
myenv.KDEinstall( 'KDEDOC', lang+'/'+destination, folder+'/index.cache.bz2' )
## Use processfolder for each documentation directory
processfolder('en/', 'en')
processfolder('en/', 'en', 'kstreamripper')

142
kde.py

@ -37,41 +37,50 @@ def detect_kde(env):
kdeincludes = env['ARGS'].get('kdeincludes', None)
kdelibs = env['ARGS'].get('kdelibs', None)
qtincludes = env['ARGS'].get('qtincludes', None)
tqtincludes = env['ARGS'].get('tqtincludes', None)
qtlibs = env['ARGS'].get('qtlibs', None)
kdedir = env['ARGS'].get('kdedir', None)
if libdir:
libdir = libdir+libsuffix
## Detect the kde libraries
print "Checking for kde-config : ",
kde_config = os.popen("which kde-config 2>/dev/null").read().strip()
str="which kde-config 2>/dev/null"
if kdedir: str="which %s 2>/dev/null" % (kdedir+'/bin/kde-config')
kde_config = os.popen(str).read().strip()
if len(kde_config):
print GREEN+"kde-config was found"+NORMAL
print GREEN + 'kde-config was found as ' + kde_config + NORMAL
else:
print RED+"kde-config was NOT found in your PATH"+NORMAL
if kdedir: print RED + 'kde-config was NOT found in the folder given ' + kdedir + NORMAL
else: print RED + 'kde-config was NOT found in your PATH' + NORMAL
print "Make sure kde is installed properly"
print "(missing package kdebase-devel?)"
env.Exit(1)
env['KDEDIR'] = os.popen('kde-config -prefix').read().strip()
if kdedir: env['KDEDIR']=kdedir
else: env['KDEDIR'] = os.popen(kde_config+' -prefix').read().strip()
print "Checking for kde version : ",
kde_version = os.popen("kde-config --version|grep KDE").read().strip().split()[1]
kde_version = os.popen(kde_config + " --version|grep KDE").read().strip().split()[1]
kde_major = kde_version.split('.')[0].lstrip('R')
kde_minor = kde_version.split('.')[1]
kde_patch = kde_version.split('.')[2]
try:
env['KDEm1']=int(kde_version[0])
env['KDEm1']=int(kde_major)
except:
pass
try:
env['KDEm2']=int(kde_version[2])
env['KDEm2']=int(kde_minor)
except:
pass
try:
env['KDEm3']=int(kde_version[4])
env['KDEm3']=int(kde_patch)
except:
pass
if int(kde_version[0]) != 3 or int(kde_version[2]) < 2:
if int(kde_major) != 3 or int(kde_minor) < 2:
print RED + kde_version
print RED+"Your kde version can be too old"+NORMAL
print RED+"Please make sure kde is at least 3.2"+NORMAL
print RED + "Your kde version might be too old" + NORMAL
print RED + "Please make sure TDE is at least 3.2" + NORMAL
else:
print GREEN + kde_version + NORMAL
@ -81,9 +90,13 @@ def detect_kde(env):
if qtdir:
print GREEN+"qt is in "+qtdir+NORMAL
else:
libdir = os.popen('kde-config --expandvars --install lib').read().strip()
libdir = os.popen(kde_config + ' --expandvars --install lib').read().strip()
libkdeuiSO = libdir+'/'+getSOfromLA(libdir+'/libkdeui.la')
try:
m = re.search('(.*)/lib/libqt.*', os.popen('ldd ' + libkdeuiSO + ' | grep libqt').read().strip().split()[2])
except:
m = re.search('(.*)/lib/libtqt.*', os.popen('ldd ' + libkdeuiSO + ' | grep libtqt').read().strip().split()[2])
pass
if m:
qtdir = m.group(1)
print YELLOW+"qt was found as "+m.group(1)+NORMAL
@ -127,30 +140,48 @@ def detect_kde(env):
env.Exit(1)
env['QT_MOC'] = moc
## check for the qt and kde includes
## check for the tqt includes
print "Checking for the tqt includes : ",
if tqtincludes and os.path.isfile(tqtincludes + "/tqlayout.h"):
# The user told where to look for and it looks valid
print GREEN + "ok " + tqtincludes + NORMAL
else:
if os.path.isfile(qtdir + "/include/tqlayout.h"):
# Automatic detection
print GREEN + "ok " + qtdir + "/include/ " + NORMAL
tqtincludes = qtdir + "/include/"
elif os.path.isfile("/usr/include/tqt/tqlayout.h"):
# Debian probably
print YELLOW + "the qt headers were found in /usr/include/tqt/ " + NORMAL
tqtincludes = "/usr/include/tqt"
elif os.path.isfile("/usr/include/qt4/Qt/qglobal.h"):
# Debian probably
print YELLOW + "the qt headers were found in /usr/include/qt4/ " + NORMAL
tqtincludes = "/usr/include/qt4"
else:
print RED + "the qt headers were not found" + NORMAL
env.Exit(1)
## check for the qt includes
print "Checking for the qt includes : ",
if qtincludes and os.path.isfile(qtincludes + "/qlayout.h"):
if qtincludes and os.path.isfile(qtincludes + "/qglobal.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/qglobal.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/qt3/qglobal.h"):
# Debian probably
print YELLOW + "the qt headers were found in /usr/include/qt3/ " + NORMAL
qtincludes = "/usr/include/qt3"
elif os.path.isfile("/usr/include/qt4/Qt/qglobal.h"):
# Debian probably
print YELLOW + "the qt headers were found in /usr/include/qt4/ " + NORMAL
qtincludes = "/usr/include/qt4"
else:
print RED + "the qt headers were not found" + NORMAL
env.Exit(1)
print "Checking for the kde includes : ",
kdeprefix = os.popen("kde-config --prefix").read().strip()
kdeprefix = os.popen(kde_config + " --prefix").read().strip()
if not kdeincludes:
kdeincludes = kdeprefix+"/include/"
if os.path.isfile(kdeincludes + "/klineedit.h"):
@ -175,46 +206,47 @@ def detect_kde(env):
subst_vars = lambda x: x.replace('${exec_prefix}', execprefix).replace('${datadir}',datadir).replace('${libdir}', libdir)
debian_fix = lambda x: x.replace('/usr/share', '${datadir}')
env['KDEBIN'] = subst_vars(os.popen('kde-config --install exe').read().strip())
env['KDEAPPS'] = subst_vars(os.popen('kde-config --install apps').read().strip())
env['KDEDATA'] = subst_vars(os.popen('kde-config --install data').read().strip())
env['KDEMODULE']= subst_vars(os.popen('kde-config --install module').read().strip())
env['KDELOCALE']= subst_vars(os.popen('kde-config --install locale').read().strip())
env['KDEDOC'] = subst_vars( debian_fix(os.popen('kde-config --install html').read().strip()) )
env['KDEKCFG'] = subst_vars(os.popen('kde-config --install kcfg').read().strip())
env['KDEXDG'] = subst_vars(os.popen('kde-config --install xdgdata-apps').read().strip())
env['KDEXDGDIR']= subst_vars(os.popen('kde-config --install xdgdata-dirs').read().strip())
env['KDEMENU'] = subst_vars(os.popen('kde-config --install apps').read().strip())
env['KDEMIME'] = subst_vars(os.popen('kde-config --install mime').read().strip())
env['KDEICONS'] = subst_vars(os.popen('kde-config --install icon').read().strip())
env['KDESERV'] = subst_vars(os.popen('kde-config --install services').read().strip())
env['KDEBIN'] = subst_vars(os.popen(kde_config + ' --install exe').read().strip())
env['KDEAPPS'] = subst_vars(os.popen(kde_config + ' --install apps').read().strip())
env['KDEDATA'] = subst_vars(os.popen(kde_config + ' --install data').read().strip())
env['KDEMODULE']= subst_vars(os.popen(kde_config + ' --install module').read().strip())
env['KDELOCALE']= subst_vars(os.popen(kde_config + ' --install locale').read().strip())
env['KDEDOC'] = subst_vars( debian_fix(os.popen(kde_config + ' --install html').read().strip()) )
env['KDEKCFG'] = subst_vars(os.popen(kde_config + ' --install kcfg').read().strip())
env['KDEXDG'] = subst_vars(os.popen(kde_config + ' --install xdgdata-apps').read().strip())
env['KDEXDGDIR']= subst_vars(os.popen(kde_config + ' --install xdgdata-dirs').read().strip())
env['KDEMENU'] = subst_vars(os.popen(kde_config + ' --install apps').read().strip())
env['KDEMIME'] = subst_vars(os.popen(kde_config + ' --install mime').read().strip())
env['KDEICONS'] = subst_vars(os.popen(kde_config + ' --install icon').read().strip())
env['KDESERV'] = subst_vars(os.popen(kde_config + ' --install services').read().strip())
else:
# the user has given no prefix, install as a normal kde app
env['PREFIX'] = os.popen('kde-config --prefix').read().strip()
env['KDEBIN'] = os.popen('kde-config --expandvars --install exe').read().strip()
env['KDEAPPS'] = os.popen('kde-config --expandvars --install apps').read().strip()
env['KDEDATA'] = os.popen('kde-config --expandvars --install data').read().strip()
env['KDEMODULE']= os.popen('kde-config --expandvars --install module').read().strip()
env['KDELOCALE']= os.popen('kde-config --expandvars --install locale').read().strip()
env['KDEDOC'] = os.popen('kde-config --expandvars --install html').read().strip()
env['KDEKCFG'] = os.popen('kde-config --expandvars --install kcfg').read().strip()
env['KDEXDG'] = os.popen('kde-config --expandvars --install xdgdata-apps').read().strip()
env['KDEXDGDIR']= os.popen('kde-config --expandvars --install xdgdata-dirs').read().strip()
env['KDEMENU'] = os.popen('kde-config --expandvars --install apps').read().strip()
env['KDEMIME'] = os.popen('kde-config --expandvars --install mime').read().strip()
env['KDEICONS'] = os.popen('kde-config --expandvars --install icon').read().strip()
env['KDESERV'] = os.popen('kde-config --expandvars --install services').read().strip()
env['QTPLUGINS']=os.popen('kde-config --expandvars --install qtplugins').read().strip()
env['PREFIX'] = os.popen(kde_config + ' --prefix').read().strip()
env['KDEBIN'] = os.popen(kde_config + ' --expandvars --install exe').read().strip()
env['KDEAPPS'] = os.popen(kde_config + ' --expandvars --install apps').read().strip()
env['KDEDATA'] = os.popen(kde_config + ' --expandvars --install data').read().strip()
env['KDEMODULE']= os.popen(kde_config + ' --expandvars --install module').read().strip()
env['KDELOCALE']= os.popen(kde_config + ' --expandvars --install locale').read().strip()
env['KDEDOC'] = os.popen(kde_config + ' --expandvars --install html').read().strip()
env['KDEKCFG'] = os.popen(kde_config + ' --expandvars --install kcfg').read().strip()
env['KDEXDG'] = os.popen(kde_config + ' --expandvars --install xdgdata-apps').read().strip()
env['KDEXDGDIR']= os.popen(kde_config + ' --expandvars --install xdgdata-dirs').read().strip()
env['KDEMENU'] = os.popen(kde_config + ' --expandvars --install apps').read().strip()
env['KDEMIME'] = os.popen(kde_config + ' --expandvars --install mime').read().strip()
env['KDEICONS'] = os.popen(kde_config + ' --expandvars --install icon').read().strip()
env['KDESERV'] = os.popen(kde_config + ' --expandvars --install services').read().strip()
env['QTPLUGINS']=os.popen(kde_config + ' --expandvars --install qtplugins').read().strip()
## kde libs and includes
env['KDEINCLUDEPATH']=kdeincludes
if not kdelibs:
kdelibs=os.popen('kde-config --expandvars --install lib').read().strip()
kdelibs=os.popen(kde_config + ' --expandvars --install lib').read().strip()
env['KDELIBPATH']=kdelibs
## qt libs and includes
env['QTINCLUDEPATH']=qtincludes
env['TQTINCLUDEPATH']=tqtincludes
if not qtlibs:
qtlibs=qtdir+"/lib"
env['QTLIBPATH']=qtlibs
@ -230,6 +262,7 @@ def generate(env):
"""+BOLD+"""* execprefix """+NORMAL+""": install path for binaries, ie: /usr/bin
"""+BOLD+"""* datadir """+NORMAL+""": install path for the data, ie: /usr/local/share
"""+BOLD+"""* libdir """+NORMAL+""": install path for the libs, ie: /usr/lib
"""+BOLD+"""* kdedir """+NORMAL+""": path to TDE directory, ie: /opt/trinity
"""+BOLD+"""* libsuffix """+NORMAL+""": suffix of libraries on amd64, ie: 64, 32
"""+BOLD+"""* kdeincludes"""+NORMAL+""": path to the kde includes (/usr/include/kde on debian, ...)
"""+BOLD+"""* qtincludes """+NORMAL+""": same punishment, for qt includes (/usr/include/qt on debian, ...)
@ -385,6 +418,7 @@ ie: """+BOLD+"""scons configure libdir=/usr/local/lib qtincludes=/usr/include/qt
('QTDIR', 'root of qt directory'),
('QTLIBPATH', 'path to the qt libraries'),
('QTINCLUDEPATH', 'path to the qt includes'),
('TQTINCLUDEPATH', 'path to the tqt includes'),
('QT_UIC', 'moc directory'),
('QT_MOC', 'moc executable command'),
('QTPLUGINS', 'uic executable command'),
@ -419,7 +453,7 @@ ie: """+BOLD+"""scons configure libdir=/usr/local/lib qtincludes=/usr/include/qt
opts.Save(cachefile, env)
## set default variables, one can override them in sconscript files
env.Append(CXXFLAGS = ['-I'+env['KDEINCLUDEPATH'], '-I'+env['QTINCLUDEPATH'] ])
env.Append(CXXFLAGS = ['-I'+env['KDEINCLUDEPATH'], '-I'+env['QTINCLUDEPATH'], '-I'+env['TQTINCLUDEPATH'], '-include', 'tqt.h' ])
env.Append(LIBPATH = [env['KDELIBPATH'], env['QTLIBPATH'] ])
env['STATIC_AND_SHARED_OBJECTS_ARE_THE_SAME'] = 1
@ -452,7 +486,7 @@ ie: """+BOLD+"""scons configure libdir=/usr/local/lib qtincludes=/usr/include/qt
act.append('cat '+target[1].path+'.tmp >> '+target[1].path)
act.append('rm -f '+target[1].path+'.tmp')
act.append('echo \'#include "' + target[2].name + '"\' >> '+target[1].path)
act.append('$QT_MOC -o '+target[2].path+' '+target[0].path)
act.append('moc-tqt $QT_MOC '+target[0].path+' '+target[2].path)
return act
def uicEmitter(target, source, env):
@ -479,7 +513,7 @@ ie: """+BOLD+"""scons configure libdir=/usr/local/lib qtincludes=/usr/include/qt
src_suffix = '.ui')
## moc file processing
env['QT_MOCCOM'] = ('$QT_MOC -o ${TARGETS[0]} $SOURCE')
env['QT_MOCCOM'] = ('moc-tqt $QT_MOC $SOURCE ${TARGETS[0]}')
MOC_BUILDER = Builder(
action = '$QT_MOCCOM',

@ -43,7 +43,7 @@ myenv.KDEprogram( "kstreamripper", kstreamripper_sources )
myenv.KDEaddpaths_includes( ['./', '../'] )
## Necessary libraries to link against
myenv.KDEaddlibs( ['tqt', 'kio', 'kdeui'] )
myenv.KDEaddlibs( ['qt-mt', 'tqt', 'kdecore', 'kio', 'kdeui'] )
if env['KDEm2']>3: myenv.KDEaddlibs( ['kdnssd'])
#############################
## Data to install

@ -191,7 +191,7 @@ void KStreamRipper::tuneInButtonClicked()
void KStreamRipper::serviceAdded(DNSSD::RemoteService::Ptr srv)
{
ProcessListViewItem * proc = new ProcessListViewItem( m_streamsListView, srv->serviceName(), "", "");
proc->getProcessController()->setUrl( TQString("http://%1:%2%3").tqarg(srv->hostName()).tqarg(srv->port()).tqarg(srv->textData()["path"]) );
proc->getProcessController()->setUrl( TQString("http://%1:%2%3").arg(srv->hostName()).arg(srv->port()).arg(srv->textData()["path"]) );
proc->getProcessController()->setDescription( i18n("found by Zeroconf") );
proc->getProcessController()->setAutomatic(true);
proc->getProcessController()->setService(srv);
@ -269,8 +269,8 @@ void KStreamRipper::selectedNewListItem()
ProcessController * ProcCtl = ((ProcessListViewItem*)m_streamsListView->currentItem())->getProcessController();
// reconfigure what the user is allowed to do based on if this process is ripping
m_ripButton->setEnabled( !ProcCtl->gettqStatus() );
m_stopRipButton->setEnabled( ProcCtl->gettqStatus() );
m_ripButton->setEnabled( !ProcCtl->getStatus() );
m_stopRipButton->setEnabled( ProcCtl->getStatus() );
m_tuneInButton->setEnabled( true );
m_deleteStreamButton->setEnabled( !ProcCtl->getAutomatic() );

@ -2,15 +2,10 @@
Encoding=UTF-8
Name=KStreamRipper
Name[xx]=xxKStreamRipperxx
GenericName=Stream Ripper
Exec=kstreamripper
Icon=kstreamripper
Type=Application
Comment=A simple KDE Application
Comment[da]=Et simpelt KDE program
Comment[es]=Una aplicación de KDE sencilla
Comment[hu]=Egyszerű KDE-alkalmazás
Comment[pt]=Uma aplicação KDE simples
Comment[pt_BR]=Um simples Aplicativo do KDE
Comment[sl]=Preprost program za KDE
Comment[sv]=Ett enkelt KDE-program
Comment[xx]=xxA simple KDE Applicationxx
Comment=A streamripper GUI for KDE
DocPath=kstreamripper/index.html
Categories=Qt;KDE;AudioVideo;Audio;Player;

@ -27,7 +27,7 @@
#include <dnssd/servicebrowser.h>
#include <dnssd/remoteservice.h>
#else
// damned tqmoc will create slots regardless of #if macro
// damned moc will create slots regardless of #if macro
// this is hack to avoid undefined type
namespace DNSSD { namespace RemoteService { typedef int Ptr; } }
#endif

@ -29,7 +29,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
<property name="tqsizeHint">
<property name="sizeHint">
<size>
<width>31</width>
<height>20</height>
@ -46,7 +46,7 @@
</widget>
<widget class="TQLayoutWidget" row="6" column="1">
<property name="name">
<cstring>tqlayout10</cstring>
<cstring>layout10</cstring>
</property>
<hbox>
<property name="name">
@ -80,7 +80,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
<property name="tqsizeHint">
<property name="sizeHint">
<size>
<width>421</width>
<height>21</height>

@ -23,7 +23,7 @@
#include "processlistviewitem.h"
ProcessController::ProcessController(ProcessListViewItem * parent)
: TQObject((TQObject *)parent), myParent(parent), mytqStatus(false), myAutomatic(false), myProcess(new TQProcess(this))
: TQObject((TQObject *)parent), myParent(parent), myStatus(false), myAutomatic(false), myProcess(new TQProcess(this))
{
connect (myProcess, TQT_SIGNAL( readyReadStdout() ), (ProcessController *) this, TQT_SLOT( readStdout()) );
// connect (myProcess, TQT_SIGNAL( destroyed() ), myProcess, TQT_SLOT( kill()) );
@ -71,7 +71,7 @@ void ProcessController::readStdout()
void ProcessController::startRip(TQString destination, TQString time)
{
mytqStatus = true;
myStatus = true;
myParent->setText( 1, "Ripping" );
myProcess->clearArguments();
@ -92,7 +92,7 @@ void ProcessController::startRip(TQString destination, TQString time)
void ProcessController::stopRip()
{
mytqStatus = false;
myStatus = false;
myParent->setText( 1, "" );
myParent->setText( 2, "" );
@ -101,9 +101,9 @@ void ProcessController::stopRip()
}
bool ProcessController::gettqStatus()
bool ProcessController::getStatus()
{
return mytqStatus;
return myStatus;
}
TQString ProcessController::getUrl()

@ -40,7 +40,7 @@ public:
ProcessController(ProcessListViewItem * parent);
~ProcessController();
bool gettqStatus();
bool getStatus();
bool getAutomatic();
void setAutomatic(bool a);
#if KDE_IS_VERSION(3,3,90)
@ -59,7 +59,7 @@ protected slots:
private:
ProcessListViewItem * myParent;
bool mytqStatus;
bool myStatus;
bool myAutomatic;
#if KDE_IS_VERSION(3,3,90)
DNSSD::RemoteService::Ptr myService;

Loading…
Cancel
Save