sip.patch 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. diff -Nuar a/configure.py b/configure.py
  2. --- a/configure.py 2018-10-01 16:38:10.000000000 +0300
  3. +++ b/configure.py 2018-02-27 13:43:42.000000000 +0300
  4. @@ -2440,7 +2364,7 @@
  5. the target configuration.
  6. """
  7. - sip_flags = ['-n', 'PyQt5.sip']
  8. + sip_flags = []
  9. # If we don't check for signed interpreters, we exclude the 'VendorID'
  10. # feature
  11. @@ -2477,7 +2401,7 @@
  12. sip_flags.append('-x')
  13. sip_flags.append('Py_v3')
  14. - return sip_flags
  15. + return ' '.join(sip_flags)
  16. def mk_clean_dir(name):
  17. @@ -2513,7 +2437,7 @@
  18. the number of parts the generated code should be split into. tracing is
  19. set if the generated code should include tracing calls. mname is the name
  20. of the module to generate the code for. fatal_warnings is set if warnings
  21. - are fatal. sip_flags is the list of flags to pass to sip. doc_support
  22. + are fatal. sip_flags is the string of flags to pass to sip. doc_support
  23. is set if documentation support is to be generated for the module.
  24. qpy_sources is the optional list of QPy support code source files.
  25. qpy_headers is the optional list of QPy support code header files.
  26. @@ -2524,9 +2448,7 @@
  27. mk_clean_dir(mname)
  28. # Build the SIP command line.
  29. - argv = [target_config.sip, '-w']
  30. -
  31. - argv.extend(sip_flags)
  32. + argv = [quote(target_config.sip), '-w', sip_flags]
  33. if fatal_warnings:
  34. argv.append('-f')
  35. @@ -2580,7 +2502,7 @@
  36. # Add the name of the .sip file.
  37. argv.append('%s/%s/%smod.sip' % (sip_dir, mname, mname))
  38. - run_command(' '.join([quote(a) for a in argv]), verbose)
  39. + run_command(' '.join(argv), verbose)
  40. # Check the result.
  41. if mname == 'Qt':
  42. @@ -2600,7 +2522,7 @@
  43. os.path.join('QtCore', 'qpycore_post_init.cpp'))
  44. for line in in_f:
  45. - line = line.replace('@@PYQT_SIP_FLAGS@@', ' '.join(sip_flags))
  46. + line = line.replace('@@PYQT_SIP_FLAGS@@', sip_flags)
  47. out_f.write(line)
  48. in_f.close()
  49. ###############################################################################