Граф коммитов

1907 Коммитов

Автор SHA1 Сообщение Дата
Barton Cline b165605d7d From a667bc8b29744a4baafaccc3806d19830a7bdeeb Mon Sep 17 00:00:00 2001
From: Alexey Borzenkov <snaury@gmail.com>
Date: Tue, 16 Dec 2008 12:08:31 +0300
Subject: Build Python.Net with Python 2.6
2010-07-28 03:06:31 +00:00
Joe Frayne 2086db1cae Just revisited this and tried to rebuild and I realized I had the instructions wrong, and I hadn't checked in the last of our changes last time we got it working. Sorry, I don't remember why these changes were done, but it's what we're using, and it works for us (I just built it on OSX and tested it a little and it's working.) 2009-07-02 02:03:03 +00:00
Christian Heimes c7aed5c3f0 Fixed PythonDotNET for Python 2.6
PythonDotNET does *not* support several new features like the backported buffer protocol, bytearray and version tags (yet)
2008-05-30 22:48:04 +00:00
Joe Frayne 36604d56a3 -fix for binding to certain overloaded methods while running under mono (thanks to Geoff Norton at Novell.) 2008-04-25 20:20:49 +00:00
Joe Frayne decf508b11 Added fixes to get Python.NET working under Mono 1.9 on Mac OS X.
-added workaround to clrmod.c for mono error: "Symbol not found: _environ" (a fix has been added to Mono SVN, according to Geoff Norton at Novell.)

-changed ordering of mono_config_parse(NULL) call in pynetinit.c, to handle latest changes to mono embedding interface (a fix has been added to Mono SVN, according to Geoff Norton.)

-fixed TypeManager static constructor to properly handle .NET exceptions (thanks to Geoff Norton.)

-added to pynetinit.c to make clr.so search the site-packages folder of the currently running python to find the Python.Runtime.dll, instead of just the cwd (thanks to Peter Shinners and Wei Qiao at Blizzard Entertainment.)

-updated one of the Python.Runtime.dll.config to map to .dylib instead of .so (thanks to Wei Qiao.) This should be looked at further, as there are a few of these files floating around...

-changed the Makefile to be self-contained and create the clr.so (thanks to Wei Qiao.) This should be looked at further, as running setup.py currently builds the clr.so, but gives an error afterwards.

-updated README.txt a bit more.
2008-04-17 01:23:12 +00:00
John Burnett 1dbded1e74 Just a fake commit to make a note in history that revision 95 is from Joe Frayne. 2008-02-27 19:45:53 +00:00
John Burnett cad6af4758 Fixes for a bad merge in the last couple of patches... 2008-02-27 01:59:14 +00:00
John Burnett d0988c2fd1 1. In cases where the generic parameters do not match the arguments on overloaded methods, the method binder often picked the wrong method. This is because it picks the method when it looks at the generic parameters, before it knows what the arguments are. Now when it gets to evaluating the arguments, it uses the generic parameters in the picked method AND the arguments to try to re-bind to the proper method. This works with calls like this:
foo = bar.GetValue[str](int arg1, int arg2, str arg3)

...but I did NOT implement a fix for using the __overloads__ syntax. It is still broken (I'm not quite clear on when it is ever even necessary.)

2. Added unit tests for the above.

3. Added some text to the monoclr README.txt to describe how to compile the clr.so that is needed for MacOS X -- I still haven't been able to get everything working myself, so I'm not 100% on it, but the file was blank before, so I figure something is better that nothing.)
2008-02-27 01:45:08 +00:00
John Burnett 1b6d6e6d4f Adding support for conversion from python float to object... patch #1801233 from anonymous 2008-02-27 01:39:42 +00:00
John Burnett 02848fa864 Under cpython 2.5.1 and Microsoft .NET 2.x, CodeGenerator's ctor was causing an exception when calling Thread.GetDomain().DefineDynamicAssembly. A "fix" for this seems to be to make this call happen before Python.Runtime.Runtime.Initialize(). To do this, CodeGenerator is no longer a static class (along with the classes that use it). DelegateManager (the owner of the only CodeGenerator instance) is then created in PythonEngine.Initialize, ahead of the Runtime.Initialize() call. This "fix" is probably masking some bad mojo happening somewhere down in Runtime.Initialize(). 2008-02-27 01:35:22 +00:00
John Burnett 14e8f42f44 64-bit support on Windows. Note I didn't update anything to do with "mdp" files or makefile, as I don't know anything about those. These changes purely update the Visual Studio files to have an option to build 64bit (the x64 solution platform).
clrmodule.il:
- Rewrote entirely to be more human readable/writable. Heavily commented with C# equivalents. Added #ifdef'd debug prints.
- Supports loading out of PYTHONPATH (based on idea by Maksim Kozyarchuk). Default behavior is the same, and only falls back to PYTHONPATH if Python.Runtime can't be found. Note that the ".assembly extern Python.Runtime" block is removed now, as we're no longer binding to it at compile time.
- If/when Python.Runtime.dll gets a solid version and/or strong name, clrmodule can be set to bind more closely with that build by using the USE_PYTHON_RUNTIME_VERSION and USE_PYTHON_RUNTIME_PUBLIC_KEY_TOKEN defines. See comments for details.
- Updated mscorlib reference to 2.0 (required for 64-bit compat).
- Removed ".corflags 0x00000002" (Not compatible with 64 bit version, and no longer needed for 32 bit version when using ilasm v2).

Other files:
- And added "runtime\x86\clrmodule-platform.il" and "runtime\x64\clrmodule-platform.il" subdirectories. 32/64 bit specific IL code is in there, and included into "runtime\clrmodule.il". Clunky, but since ilasm doesn't support command-line #defines, I think this is the best to be done to get the machine-specific stuff out of clrmodule.il.
- Deleted oldmodule.il (seems to be left over drit that was basically the same as clrmodule.il anyway, casing notwithstanding).
- Added an x64 platform target for the solution and Python.Runtime project. The platform is passed into the newly added buildclrmodule.bat, which builds the appropriate clr.pyd.
- Removed Console.csproj.user, and put its Debug build StartArguments into Console.csproj, so it's no longer necessary to keep the .user file around in source control.
- All projects are responsible for copying only their specific output (i.e. console no longer delets/builds/copies clr.pyd). Project dependencies should make sure things work still.
2008-02-27 01:34:13 +00:00
John Burnett 86669a5bef testStrOfException was depending on implementation detail that was half-way through an Exception.StackTrace. The detail changed in Windows .NET 2.0+, so now it checks the base of the trace ("System.Convert.ToDateTime"). 2008-02-27 01:26:41 +00:00
Christian Heimes 5b6eb9e66a Added setup.py to release files
Added Python.Runtime.dll.config
2007-11-18 19:59:36 +00:00
Virgil Dupras 252828efd1 Improved PyLong so it actually supports int64. 2007-10-19 11:50:43 +00:00
Christian Heimes 529cf1f538 Fixed bug in UCS2/UCS4 detection. Thx to Sanghyeon Seo 2007-10-18 20:05:57 +00:00
Christian Heimes 221715e4e5 Updated Makefile
Bumped version of clrmodule.il
Added Python.Runtime.dll.config
2007-10-17 12:14:19 +00:00
Virgil Dupras 462a4291c7 Changed the PythonException.Message value so it displays the name of the exception class instead ("Exception") instead of its representation ("<type 'exceptions.Exception'>"). 2007-08-12 22:20:52 +00:00
Christian Heimes e2aff663e4 Err, somehow the unit test fix for clr.get/setPreload got lost ... 2007-08-03 12:12:48 +00:00
Christian Heimes de6f4cc179 Updated readme.html
Added code for Python 2.3 (not officially supported)
Changed clr.preload to clr.setPreload() and clr.getPreload(). I know that setters and getters are old school but even Python doesn't support module properties :(
2007-08-03 11:58:36 +00:00
Christian Heimes 1429b9f718 Fixed mono_config.txt
Some fixes and enhancements for the Makefile under Windows and for make dist
Fixed PyObject_TYPE for Py_DEBUG builds
Fixed an issue with implicit calls of generic methods
2007-08-01 08:43:36 +00:00
Christian Heimes 79a8b84923 The mono based clr module now raises an import error when it can't load the assembly or initialize PythonNet
Mono exceptions are dumped as well.
2007-07-31 17:20:35 +00:00
Christian Heimes 358ea50e3d Default to Python 2.5
Renamed solution file to pythonnet.sln. It's not Python 2.5 specific
Enhanced make dist. It builds a signed assemblies for 2.4 and 2.5 for both UCS 2 and 4 with GPG keys, md5 and sha256 sum
2007-07-30 16:17:22 +00:00
Christian Heimes a376c3a2ab Fixed new Makefile for Windows
Updated changes.txt
2007-07-29 00:40:46 +00:00
Christian Heimes ddd6f4b8a1 Code cleanup: Replaced \t with 8 spaces in all *.cs files 2007-07-29 00:25:03 +00:00
Christian Heimes fcd38170ac Removed old makefiles
Added a one size fits all Makefile for Windows and Mono including support for autodetection of UCS 2/3 and Python version
2007-07-29 00:22:49 +00:00
Christian Heimes 035b7ad006 Merged revision r43:75 from https://pythonnet.svn.sourceforge.net/svnroot/pythonnet/branches/clr-2.0-python-2.5-branch into the trunk 2007-07-27 17:32:55 +00:00
Virgil Dupras 78d991b1c4 Added PyIter, an easy way to enumerate python iterators or sequences. 2006-11-24 16:12:44 +00:00
Virgil Dupras 2c994e1467 PythonException now has a meaningful message (The message of the actual python exception that was raised). 2006-11-24 16:02:49 +00:00
Virgil Dupras 43eca3a9c2 Made PyObject.ToString() and PyString(string) work with unicode strings.
Added embed_tests.
2006-11-24 15:42:35 +00:00
Brian Lloyd beffbb4547 checkpoint 2006-06-05 20:37:19 +00:00
Brian Lloyd 067ea8ec61 update changes.txt 2006-06-05 14:16:00 +00:00
Brian Lloyd 8842290a24 fix unboxing of value types in generated delegate code 2006-06-05 14:11:57 +00:00
Brian Lloyd 9dfb7ebdef checkpoint 2006-06-02 20:46:05 +00:00
Brian Lloyd ba7224c04b update download link 2006-06-02 19:22:05 +00:00
Brian Lloyd 18cb8daa90 update download links 2006-06-02 19:15:22 +00:00
Brian Lloyd aa5d99c261 checkpoint 2006-04-22 18:47:36 +00:00
Brian Lloyd f5249197a3 checkpoint 2006-04-19 01:54:42 +00:00
Brian Lloyd a141b404fc checkpoint 2006-04-19 00:54:53 +00:00
Brian Lloyd ac992c8cbe checkpoint 2006-04-11 20:24:58 +00:00
Brian Lloyd fa8629ec62 checkpoint 2006-04-10 20:23:57 +00:00
Brian Lloyd 4e2a3bd454 merged method selections and fixes from the trunk 2006-04-08 14:33:28 +00:00
Brian Lloyd 3fccfd5afc commit fix for noticing wrapped exception types 2006-04-08 13:50:03 +00:00
Brian Lloyd c11c50a32c commit method overload selection 2006-04-08 13:16:22 +00:00
Brian Lloyd 9f06a5e15a work branch 2006-04-08 01:52:59 +00:00
Brian Lloyd 8363502fd8 debug commit - I know, I'm breaking the rules, but its only me for now ;) 2006-04-08 01:51:34 +00:00
Brian Lloyd e073a2e386 land import syntax refactoring on trunk 2006-04-06 17:07:16 +00:00
Brian Lloyd 804cd5160a land import syntax refactoring on 1.x branch 2006-04-06 17:01:15 +00:00
Brian Lloyd 1456e253dd commit import refactoring 2006-04-05 20:22:03 +00:00
Brian Lloyd d66d9620de update index page to reflect switch to svn 2006-04-04 18:58:54 +00:00
Brian Lloyd 7c42ea3c04 fixups 2006-04-04 18:13:48 +00:00