summaryrefslogtreecommitdiffstats
path: root/build.py
diff options
context:
space:
mode:
Diffstat (limited to 'build.py')
-rw-r--r--build.py69
1 files changed, 28 insertions, 41 deletions
diff --git a/build.py b/build.py
index 9bfa674..7dbc820 100644
--- a/build.py
+++ b/build.py
@@ -229,9 +229,7 @@ def moduleChecks(maindir):
tryModule(maindir,"tqtnetwork", "tqsocket.h", "TQSocket()")
tryModule(maindir,"tqttable", "tqtable.h", "TQTable()")
tryModule(maindir,"tqtxml", "tqdom.h", "TQDomImplementation()")
-
- if config.tqt_version >= 0x030000:
- tryModule(maindir,"tqtsql", "tqsql.h", "TQSql()")
+ tryModule(maindir,"tqtsql", "tqsql.h", "TQSql()")
# We need a different Makefile for the tqtgl module.
config.patches["@TEST_OPENGL@"] = "opengl"
@@ -244,22 +242,21 @@ def moduleChecks(maindir):
config.create_makefile("tqttest.pro")
# Check for the tqui library.
- if config.tqt_version >= 0x030000:
- if sys.platform == "win32":
- tquilib = r"$(TQTDIR)\lib\tqui.lib"
- else:
- tquilib = "-ltqui"
+ if sys.platform == "win32":
+ tquilib = r"$(TQTDIR)\lib\tqui.lib"
+ else:
+ tquilib = "-ltqui"
- config.patches["@PYTQT_TQUI_LIB@"] = tquilib
+ config.patches["@PYTQT_TQUI_LIB@"] = tquilib
- config.patches["@TEST_TQUI_LIB@"] = tquilib
- config.create_makefile("tqttest.pro")
+ config.patches["@TEST_TQUI_LIB@"] = tquilib
+ config.create_makefile("tqttest.pro")
- tryModule(maindir,"tqtui", "tqwidgetfactory.h", "TQWidgetFactory()")
+ tryModule(maindir,"tqtui", "tqwidgetfactory.h", "TQWidgetFactory()")
- # Put things back.
- config.patches["@TEST_TQUI_LIB@"] = ""
- config.create_makefile("tqttest.pro")
+ # Put things back.
+ config.patches["@TEST_TQUI_LIB@"] = ""
+ config.create_makefile("tqttest.pro")
# Check for the TQScintilla library.
if sciVersion >= 0:
@@ -327,7 +324,7 @@ int main(int argc,char **argv)
fprintf(fp,"-x TQt_THREAD_SUPPORT\\n");
#endif
-#if (defined(Q_OS_WIN32) || defined(Q_OS_WIN64)) && TQT_VERSION >= 0x030000
+#if (defined(Q_OS_WIN32) || defined(Q_OS_WIN64))
if (tqWinVersion() != TQt::WV_XP)
fprintf(fp,"-x TQt_STYLE_WINDOWSXP\\n");
#endif
@@ -525,11 +522,6 @@ def main(argv):
if config.tqt_version == 0:
sip_tqt_config.error("SIP-TQt has been built with TQt support disabled.\n")
- # Early versions of TQt for the Mac didn't include everything. Rather than
- # maintain these in the future we just mandate a later version.
- if sys.platform == "darwin" and config.tqt_version < 0x030100:
- sip_tqt_config.error("PyTQt for MacOS/X requires TQt v3.1.0 or later.\n")
-
# Check the installation directory is valid and add it as a patch.
if not os.access(modDir,os.F_OK):
sip_tqt_config.error("The %s PyTQt destination directory does not seem to exist. Use the -d argument to set the correct directory." % (modDir))
@@ -576,24 +568,21 @@ def main(argv):
# Link in the tqassistantclient library for TQt v3.1+.
tqaclib = ""
- if config.tqt_version >= 0x030100:
- if sys.platform == "win32":
- tqaclib = r"$(TQTDIR)\lib\tqassistantclient.lib"
- else:
- tqaclib = "-ltqassistantclient"
+ if sys.platform == "win32":
+ tqaclib = r"$(TQTDIR)\lib\tqassistantclient.lib"
+ else:
+ tqaclib = "-ltqassistantclient"
config.patches["@PYTQT_TQASSISTANTCLIENT_LIB@"] = tqaclib
# Check for TQScintilla.
- if config.tqt_version >= 0x030000:
- checkTQScintilla()
+ checkTQScintilla()
# Create a build directory that we can compile test programs.
maindir = mkTempBuildDir()
# Check what additional modules to build.
- if config.tqt_version >= 0x020000:
- moduleChecks(maindir)
+ moduleChecks(maindir)
# Work out the platform and TQt version tags to pass to SIP-TQt to generate the
# code we need.
@@ -685,22 +674,20 @@ def main(argv):
# See which version of pyuic to build.
config.patches["@PYTQT_BINDIR@"] = sip_tqt_config.escape(binDir)
- if config.tqt_version >= 0x030000:
- sip_tqt_config.inform("Creating Makefile for pytquic3.")
- subdirs.append("pytquic3")
- olddir = sip_tqt_config.push_dir("pytquic3")
+ sip_tqt_config.inform("Creating Makefile for pytquic3.")
+ subdirs.append("pytquic3")
+ olddir = sip_tqt_config.push_dir("pytquic3")
config.create_makefile("pytquic.pro", [])
sip_tqt_config.pop_dir(olddir)
- # Build pylupdate if TQt v3.0 or later.
- if config.tqt_version >= 0x030000:
- sip_tqt_config.inform("Creating Makefile for pytqlupdate3.")
- subdirs.append("pytqlupdate3")
- olddir = sip_tqt_config.push_dir("pytqlupdate3")
+ # Build pylupdate.
+ sip_tqt_config.inform("Creating Makefile for pytqlupdate3.")
+ subdirs.append("pytqlupdate3")
+ olddir = sip_tqt_config.push_dir("pytqlupdate3")
- config.create_makefile("pytqlupdate.pro", [])
- sip_tqt_config.pop_dir(olddir)
+ config.create_makefile("pytqlupdate.pro", [])
+ sip_tqt_config.pop_dir(olddir)
# Generate the top-level Makefile.
sip_tqt_config.inform("Creating top level Makefile.")