bug20302.patch 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. From a2cee5aaf51df9660de6df98ada6706546739d13 Mon Sep 17 00:00:00 2001
  2. From: Georg Koppen <gk@torproject.org>
  3. Date: Fri, 7 Oct 2016 09:10:41 +0000
  4. Subject: [PATCH] Compiling with GCC 6.4.0 based mingw-w64 is broken
  5. Due to a bug in Python (https://bugs.python.org/issue11566) compiling
  6. with a GCC 6.4.0 based mingw-w64 is broken. This patch adds a workaround
  7. for this issue.
  8. diff --git a/setup.py b/setup.py
  9. index f546f1f..721b113 100644
  10. --- a/setup.py
  11. +++ b/setup.py
  12. @@ -11,16 +11,16 @@ import os
  13. if os.name == 'nt':
  14. libraries = ['gmp.dll']
  15. + extra_compile_args=['-O3', '-fPIC', '-D_hypot=hypot']
  16. else:
  17. libraries = ['gmp']
  18. + extra_compile_args=['-O3', '-fPIC']
  19. fte_cDFA = Extension('fte.cDFA',
  20. include_dirs=['fte',
  21. 'thirdparty/gmp/include',
  22. ],
  23. - extra_compile_args=['-O3',
  24. - '-fPIC',
  25. - ],
  26. + extra_compile_args=extra_compile_args,
  27. library_dirs=['thirdparty/gmp/bin',
  28. 'thirdparty/gmp/lib',
  29. ],
  30. --
  31. 2.9.3