2007-09-03 22:59:46 +00:00
|
|
|
/*
|
|
|
|
-----BEGIN QCMOD-----
|
2012-02-20 18:49:31 +00:00
|
|
|
name: Qt >= 4.6
|
2011-01-01 17:03:23 +00:00
|
|
|
arg: enable-debug, Enable debug mode
|
2011-01-01 17:14:52 +00:00
|
|
|
arg: disable-gui, Disable qBittorrent Graphical user interface for headless running
|
2007-09-03 22:59:46 +00:00
|
|
|
-----END QCMOD-----
|
|
|
|
*/
|
|
|
|
class qc_qt4 : public ConfObj
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
qc_qt4(Conf *c) : ConfObj(c) {}
|
2012-02-20 18:49:31 +00:00
|
|
|
QString name() const { return "Qt >= 4.6"; }
|
|
|
|
QString shortname() const { return "Qt 4.6"; }
|
2007-09-03 22:59:46 +00:00
|
|
|
bool exec()
|
|
|
|
{
|
2011-01-01 17:03:23 +00:00
|
|
|
// NOX mode
|
2009-12-15 10:36:18 +00:00
|
|
|
if(!conf->getenv("QC_DISABLE_GUI").isEmpty()) {
|
2010-11-20 17:21:40 +00:00
|
|
|
conf->addExtra("CONFIG += nox");
|
2011-01-01 17:03:23 +00:00
|
|
|
}
|
|
|
|
// Debug mode
|
|
|
|
if(!conf->getenv("QC_ENABLE_DEBUG").isEmpty()) {
|
2011-04-16 08:22:34 +00:00
|
|
|
conf->addExtra("CONFIG -= release");
|
2011-01-01 17:03:23 +00:00
|
|
|
conf->addExtra("CONFIG += debug");
|
2011-04-16 08:18:58 +00:00
|
|
|
} else {
|
|
|
|
conf->addExtra("CONFIG -= debug");
|
|
|
|
conf->addExtra("CONFIG += release");
|
2011-01-01 17:03:23 +00:00
|
|
|
}
|
2011-01-15 09:30:41 +00:00
|
|
|
#ifdef Q_OS_FREEBSD
|
|
|
|
conf->addLib("-lexecinfo");
|
|
|
|
conf->addExtra("MANPREFIX = $$PREFIX");
|
|
|
|
#else
|
|
|
|
conf->addExtra("MANPREFIX = $$PREFIX/share");
|
|
|
|
#endif
|
2012-02-20 18:49:31 +00:00
|
|
|
return(QT_VERSION >= 0x040600);
|
2007-09-03 22:59:46 +00:00
|
|
|
}
|
|
|
|
};
|