From 3e82fc1f2850b1ebc4984d003a217a140c15a02a Mon Sep 17 00:00:00 2001 From: QuantApp Date: Wed, 5 Jul 2017 20:56:30 +0000 Subject: [PATCH 01/11] from clang 2 gcc v1 --- src/runtime/Python.Runtime.csproj | 50 ++++++++++++++++++++++++++++++- tools/geninterop/geninterop.py | 2 +- 2 files changed, 50 insertions(+), 2 deletions(-) diff --git a/src/runtime/Python.Runtime.csproj b/src/runtime/Python.Runtime.csproj index 9999f8303..3a53a9528 100644 --- a/src/runtime/Python.Runtime.csproj +++ b/src/runtime/Python.Runtime.csproj @@ -9,7 +9,7 @@ Python.Runtime bin\Python.Runtime.xml bin\ - v4.0 + v4.5 1591 ..\..\ @@ -70,6 +70,54 @@ false full + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + diff --git a/tools/geninterop/geninterop.py b/tools/geninterop/geninterop.py index bf5fdb96b..49ed4367c 100644 --- a/tools/geninterop/geninterop.py +++ b/tools/geninterop/geninterop.py @@ -185,7 +185,7 @@ def preprocess_python_headers(): defines.extend(("-D", "PYTHON_WITH_WIDE_UNICODE")) python_h = os.path.join(include_py, "Python.h") - cmd = ["clang", "-I"] + include_dirs + defines + ["-E", python_h] + cmd = ["gcc", "-I"] + include_dirs + defines + ["-E", python_h] # normalize as the parser doesn't like windows line endings. lines = [] From d4bda42c20d2482de8599aa3a91f4e0bdb3ca6de Mon Sep 17 00:00:00 2001 From: QuantApp Date: Wed, 5 Jul 2017 21:18:52 +0000 Subject: [PATCH 02/11] clang 2 gcc v2 (.NET 4.5) --- setup.py | 2 +- src/clrmodule/clrmodule.csproj | 54 +++++++++++++++++-- src/clrmodule/packages.config | 4 +- src/console/Console.csproj | 57 +++++++++++++++++++-- src/console/app.config | 3 ++ src/embed_tests/Python.EmbeddingTest.csproj | 50 +++++++++++++++++- src/embed_tests/packages.config | 6 +-- src/testing/Python.Test.csproj | 54 +++++++++++++++++-- 8 files changed, 214 insertions(+), 16 deletions(-) create mode 100644 src/console/app.config diff --git a/setup.py b/setup.py index c23f6b5bd..366398416 100644 --- a/setup.py +++ b/setup.py @@ -368,7 +368,7 @@ def run(self): setup( name="pythonnet", - version="2.4.0.dev0", + version="2.4.0.dev1", description=".Net and Mono integration for Python", url='https://pythonnet.github.io/', license='MIT', diff --git a/src/clrmodule/clrmodule.csproj b/src/clrmodule/clrmodule.csproj index 6e5ff4966..1664a6414 100644 --- a/src/clrmodule/clrmodule.csproj +++ b/src/clrmodule/clrmodule.csproj @@ -1,4 +1,4 @@ - + Debug @@ -9,7 +9,7 @@ clrmodule bin\clrmodule.xml bin\ - v4.0 + v4.5 1591 ..\..\ @@ -65,6 +65,54 @@ true pdbonly + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + ..\..\packages\UnmanagedExports.1.2.7\lib\net\RGiesecke.DllExport.Metadata.dll @@ -92,4 +140,4 @@ - + \ No newline at end of file diff --git a/src/clrmodule/packages.config b/src/clrmodule/packages.config index 2a95dc54d..7fd2cb100 100644 --- a/src/clrmodule/packages.config +++ b/src/clrmodule/packages.config @@ -1,4 +1,4 @@ - + - + \ No newline at end of file diff --git a/src/console/Console.csproj b/src/console/Console.csproj index ea88b6356..b9157ee1c 100644 --- a/src/console/Console.csproj +++ b/src/console/Console.csproj @@ -1,4 +1,4 @@ - + Debug @@ -9,7 +9,7 @@ Python.Runtime bin\nPython.xml bin\ - v4.0 + v4.5 1591 ..\..\ @@ -72,6 +72,54 @@ $(PythonManifest) + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + @@ -94,8 +142,11 @@ Python.Runtime + + + - + \ No newline at end of file diff --git a/src/console/app.config b/src/console/app.config new file mode 100644 index 000000000..51278a456 --- /dev/null +++ b/src/console/app.config @@ -0,0 +1,3 @@ + + + diff --git a/src/embed_tests/Python.EmbeddingTest.csproj b/src/embed_tests/Python.EmbeddingTest.csproj index d45c622f9..6aa327c8d 100644 --- a/src/embed_tests/Python.EmbeddingTest.csproj +++ b/src/embed_tests/Python.EmbeddingTest.csproj @@ -9,7 +9,7 @@ Python.EmbeddingTest bin\Python.EmbeddingTest.xml bin\ - v4.0 + v4.5 1591 ..\..\ @@ -68,6 +68,54 @@ true pdbonly + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + diff --git a/src/embed_tests/packages.config b/src/embed_tests/packages.config index 4cb01d3be..e4ced02df 100644 --- a/src/embed_tests/packages.config +++ b/src/embed_tests/packages.config @@ -1,5 +1,5 @@ - + - + - + \ No newline at end of file diff --git a/src/testing/Python.Test.csproj b/src/testing/Python.Test.csproj index 8a8d9ed2b..94f5fd8bf 100644 --- a/src/testing/Python.Test.csproj +++ b/src/testing/Python.Test.csproj @@ -1,4 +1,4 @@ - + Debug @@ -9,7 +9,7 @@ Python.Test bin\Python.Test.xml bin\ - v4.0 + v4.5 1591,0067 ..\..\ @@ -69,6 +69,54 @@ true pdbonly + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + + + false + @@ -110,4 +158,4 @@ - + \ No newline at end of file From 6b3d6b0f64a96e3699f58aeb97fc664eb843aa62 Mon Sep 17 00:00:00 2001 From: QuantApp Date: Wed, 5 Jul 2017 21:31:48 +0000 Subject: [PATCH 03/11] compilation without shared --- setup.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index 366398416..02ca2d193 100644 --- a/setup.py +++ b/setup.py @@ -364,11 +364,11 @@ def run(self): setup_requires = [] if not os.path.exists(_get_interop_filename()): - setup_requires.append("pycparser") + setup_requires.append("pycparser").append("PYTHON_WITHOUT_ENABLE_SHARED") setup( name="pythonnet", - version="2.4.0.dev1", + version="2.4.0.dev2", description=".Net and Mono integration for Python", url='https://pythonnet.github.io/', license='MIT', From 533021a764dd133e2c31cdc831560f2cad33b09e Mon Sep 17 00:00:00 2001 From: QuantApp Date: Wed, 5 Jul 2017 21:42:50 +0000 Subject: [PATCH 04/11] force no share --- setup.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index 02ca2d193..52a6e6f93 100644 --- a/setup.py +++ b/setup.py @@ -169,7 +169,7 @@ def build_extension(self, ext): defines.append("MONO_OSX" if on_darwin else "MONO_LINUX") # Check if --enable-shared was set when Python was built - enable_shared = sysconfig.get_config_var("Py_ENABLE_SHARED") + enable_shared = False #sysconfig.get_config_var("Py_ENABLE_SHARED") if enable_shared: # Double-check if libpython is linked dynamically with python ldd_cmd = ["otool", "-L"] if on_darwin else ["ldd"] @@ -364,7 +364,7 @@ def run(self): setup_requires = [] if not os.path.exists(_get_interop_filename()): - setup_requires.append("pycparser").append("PYTHON_WITHOUT_ENABLE_SHARED") + setup_requires.append("pycparser") setup( name="pythonnet", From a0de697b2c93619b41575d0341f6311023859c99 Mon Sep 17 00:00:00 2001 From: QuantApp Date: Wed, 5 Jul 2017 21:44:54 +0000 Subject: [PATCH 05/11] v3 --- setup.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index 52a6e6f93..e0c877351 100644 --- a/setup.py +++ b/setup.py @@ -169,7 +169,7 @@ def build_extension(self, ext): defines.append("MONO_OSX" if on_darwin else "MONO_LINUX") # Check if --enable-shared was set when Python was built - enable_shared = False #sysconfig.get_config_var("Py_ENABLE_SHARED") + enable_shared = sysconfig.get_config_var("Py_ENABLE_SHARED") if enable_shared: # Double-check if libpython is linked dynamically with python ldd_cmd = ["otool", "-L"] if on_darwin else ["ldd"] @@ -180,6 +180,7 @@ def build_extension(self, ext): if not enable_shared: defines.append("PYTHON_WITHOUT_ENABLE_SHARED") + defines.append("PYTHON_WITHOUT_ENABLE_SHARED") if hasattr(sys, "abiflags"): if "d" in sys.abiflags: defines.append("PYTHON_WITH_PYDEBUG") @@ -368,7 +369,7 @@ def run(self): setup( name="pythonnet", - version="2.4.0.dev2", + version="2.4.0.dev3", description=".Net and Mono integration for Python", url='https://pythonnet.github.io/', license='MIT', From 6ff1e0127d0978a0867a39e8c4b17d0b20a8204d Mon Sep 17 00:00:00 2001 From: QuantApp Date: Wed, 5 Jul 2017 21:46:05 +0000 Subject: [PATCH 06/11] v3 --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index e0c877351..e7a2cdef6 100644 --- a/setup.py +++ b/setup.py @@ -180,7 +180,7 @@ def build_extension(self, ext): if not enable_shared: defines.append("PYTHON_WITHOUT_ENABLE_SHARED") - defines.append("PYTHON_WITHOUT_ENABLE_SHARED") + defines.append("PYTHON_WITHOUT_ENABLE_SHARED") if hasattr(sys, "abiflags"): if "d" in sys.abiflags: defines.append("PYTHON_WITH_PYDEBUG") From 2d7b46ee653d19de9b816b2858366a17996ef6ab Mon Sep 17 00:00:00 2001 From: QuantApp Date: Wed, 5 Jul 2017 22:01:12 +0000 Subject: [PATCH 07/11] v3 --- setup.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/setup.py b/setup.py index e7a2cdef6..ccfb78328 100644 --- a/setup.py +++ b/setup.py @@ -181,6 +181,8 @@ def build_extension(self, ext): defines.append("PYTHON_WITHOUT_ENABLE_SHARED") defines.append("PYTHON_WITHOUT_ENABLE_SHARED") + print('DEFINES!') + print(defines) if hasattr(sys, "abiflags"): if "d" in sys.abiflags: defines.append("PYTHON_WITH_PYDEBUG") From 9fe7c9a3d576fff855d5ef24bea63421d17290b2 Mon Sep 17 00:00:00 2001 From: QuantApp Date: Wed, 5 Jul 2017 22:02:26 +0000 Subject: [PATCH 08/11] v3 --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index ccfb78328..d9bb28820 100644 --- a/setup.py +++ b/setup.py @@ -371,7 +371,7 @@ def run(self): setup( name="pythonnet", - version="2.4.0.dev3", + version="2.4.0.dev4", description=".Net and Mono integration for Python", url='https://pythonnet.github.io/', license='MIT', From 760acb920c47ac6b898dd85edc05477ba76ddf2e Mon Sep 17 00:00:00 2001 From: QuantApp Date: Wed, 5 Jul 2017 22:11:31 +0000 Subject: [PATCH 09/11] v3 --- setup.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index d9bb28820..91d011ed6 100644 --- a/setup.py +++ b/setup.py @@ -21,7 +21,7 @@ # Allow config/verbosity to be set from cli # http://stackoverflow.com/a/4792601/5208670 CONFIG = "Release" # Release or Debug -VERBOSITY = "minimal" # quiet, minimal, normal, detailed, diagnostic +VERBOSITY = "detailed" # quiet, minimal, normal, detailed, diagnostic is_64bits = sys.maxsize > 2**32 DEVTOOLS = "MsDev" if sys.platform == "win32" else "Mono" @@ -371,7 +371,7 @@ def run(self): setup( name="pythonnet", - version="2.4.0.dev4", + version="2.4.0.dev5", description=".Net and Mono integration for Python", url='https://pythonnet.github.io/', license='MIT', From 351cb54072baef5afba3138c59d3eeb820d3ce19 Mon Sep 17 00:00:00 2001 From: QuantApp Date: Wed, 5 Jul 2017 22:20:50 +0000 Subject: [PATCH 10/11] v3 --- setup.py | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/setup.py b/setup.py index 91d011ed6..8fd125adf 100644 --- a/setup.py +++ b/setup.py @@ -20,7 +20,7 @@ # Allow config/verbosity to be set from cli # http://stackoverflow.com/a/4792601/5208670 -CONFIG = "Release" # Release or Debug +CONFIG = "Debug" # Release or Debug VERBOSITY = "detailed" # quiet, minimal, normal, detailed, diagnostic is_64bits = sys.maxsize > 2**32 @@ -179,10 +179,7 @@ def build_extension(self, ext): if not enable_shared: defines.append("PYTHON_WITHOUT_ENABLE_SHARED") - - defines.append("PYTHON_WITHOUT_ENABLE_SHARED") - print('DEFINES!') - print(defines) + if hasattr(sys, "abiflags"): if "d" in sys.abiflags: defines.append("PYTHON_WITH_PYDEBUG") @@ -371,7 +368,7 @@ def run(self): setup( name="pythonnet", - version="2.4.0.dev5", + version="2.4.0.dev6", description=".Net and Mono integration for Python", url='https://pythonnet.github.io/', license='MIT', From 0f1b4610019930b8c877d963ea416ab05ce9f0c3 Mon Sep 17 00:00:00 2001 From: QuantApp Date: Thu, 6 Jul 2017 13:53:47 +0000 Subject: [PATCH 11/11] Net 4.0 --- setup.py | 2 +- src/clrmodule/clrmodule.csproj | 2 +- src/console/Console.csproj | 2 +- src/console/app.config | 2 +- src/embed_tests/Python.EmbeddingTest.csproj | 2 +- src/embed_tests/packages.config | 2 +- src/runtime/Python.Runtime.csproj | 2 +- src/testing/Python.Test.csproj | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/setup.py b/setup.py index 8fd125adf..77386370d 100644 --- a/setup.py +++ b/setup.py @@ -368,7 +368,7 @@ def run(self): setup( name="pythonnet", - version="2.4.0.dev6", + version="2.4.0.dev7", description=".Net and Mono integration for Python", url='https://pythonnet.github.io/', license='MIT', diff --git a/src/clrmodule/clrmodule.csproj b/src/clrmodule/clrmodule.csproj index 1664a6414..c9856fc01 100644 --- a/src/clrmodule/clrmodule.csproj +++ b/src/clrmodule/clrmodule.csproj @@ -9,7 +9,7 @@ clrmodule bin\clrmodule.xml bin\ - v4.5 + v4.0 1591 ..\..\ diff --git a/src/console/Console.csproj b/src/console/Console.csproj index b9157ee1c..d1e7f66c3 100644 --- a/src/console/Console.csproj +++ b/src/console/Console.csproj @@ -9,7 +9,7 @@ Python.Runtime bin\nPython.xml bin\ - v4.5 + v4.0 1591 ..\..\ diff --git a/src/console/app.config b/src/console/app.config index 51278a456..fcd0c9373 100644 --- a/src/console/app.config +++ b/src/console/app.config @@ -1,3 +1,3 @@ - + diff --git a/src/embed_tests/Python.EmbeddingTest.csproj b/src/embed_tests/Python.EmbeddingTest.csproj index 6aa327c8d..d9a6ede8f 100644 --- a/src/embed_tests/Python.EmbeddingTest.csproj +++ b/src/embed_tests/Python.EmbeddingTest.csproj @@ -9,7 +9,7 @@ Python.EmbeddingTest bin\Python.EmbeddingTest.xml bin\ - v4.5 + v4.0 1591 ..\..\ diff --git a/src/embed_tests/packages.config b/src/embed_tests/packages.config index e4ced02df..dfd66da28 100644 --- a/src/embed_tests/packages.config +++ b/src/embed_tests/packages.config @@ -1,5 +1,5 @@  - + \ No newline at end of file diff --git a/src/runtime/Python.Runtime.csproj b/src/runtime/Python.Runtime.csproj index 3a53a9528..7f8fb4cde 100644 --- a/src/runtime/Python.Runtime.csproj +++ b/src/runtime/Python.Runtime.csproj @@ -9,7 +9,7 @@ Python.Runtime bin\Python.Runtime.xml bin\ - v4.5 + v4.0 1591 ..\..\ diff --git a/src/testing/Python.Test.csproj b/src/testing/Python.Test.csproj index 94f5fd8bf..f1b0aef03 100644 --- a/src/testing/Python.Test.csproj +++ b/src/testing/Python.Test.csproj @@ -9,7 +9,7 @@ Python.Test bin\Python.Test.xml bin\ - v4.5 + v4.0 1591,0067 ..\..\