Howto install Pida on Windows
Pida is running on windows. Follow these steps to test it. Please report problems. On windows there is no DBUS so you are limted to medit.
The best way for helping if you run the below steps in a virtual machine, and you can easily go back to a previous stage if something goes wrong. (example: windows xp installed in a virtualbox).
Step-by-step instruction
1. get this all-in-one installer:
It will install for you:
- python 2.5.2
- gtk 2.10
- pycairo
- pygtk
- pygobject
- pywin32
- pyopengl and pygtkglExt are not necessary
2. Install python-setuptools
http://pypi.python.org/pypi/setuptools Scroll down to the files, download and install: setuptools-0.6c9.win32-py2.5.exe or newer
3. Needs to fix your paths variable
Although this all in one installer is very handy, it does not set the path variable right.
Do the following:
- Right click on My computer, and select properties
- Under the tab Specials select the Environment variables button
- set the PATH variable to the following: C:\Program Files\Gtk\bin; C:\Python25; C:\Python25\Scripts
4. Install simplejson
Just do
easy_install simplejsonIf you correctly set the path, simplejson installs
5. Install kiwi
http://ftp.gnome.org/pub/GNOME/binaries/win32/kiwi/kiwi-1.9.23.win32.exe
6. Install gazpacho
http://ftp.gnome.org/pub/GNOME/sources/gazpacho/0.7/gazpacho-0.7.2.win32.exe
7. Install mercurial
8. download medit with python support:
If you download medit with python support, you do not need to compile pida/contrib/moo directory. (it is a fallback mechanism if medit is missing python bindings)
You need at least version 0.9.4. But newer version would be better (some serious bugs fixed already in hg trunk).
9. Take the appropriate file from medit source to python directory
After installing medit (with python support), then took out moo.pyd, libmoo.dll, libxml2-2.dll to the c:\python25\dlls folder
default installation: C:\Program Files\medit\lib\moo\plugins\lib\moo.pyd C:\Program Files\medit\bin\libmoo.dll C:\Program Files\medit\bin\libxml2-2.dll
10. Get PIDA:
hg clone http://www.bitbucket.org/RonnyPfannschmidt/pida-win32/
11. Get anyvc. For now, you better skip this. There are problems importing hg on win32.
hg clone http://www.bitbucket.org/RonnyPfannschmidt/anyvc/
Make a externals directory in your pida installation dir. Copy the anyvc dir into externals
12. For the python outliner you need rope:
hg clone http://bitbucket.org/agr/rope
Copy it into externals too
13. For syntaxhighlighting you need the mooeditor languagespecs and style-schemes:
Copy content of
C:\Program Files\medit\share\moo\language-specs\into
your-pida-install\pida\editors\mooedit\shared\language-specs\
14. DBUS
I didnt need DBUS to run pida.
- Install dbus bindings under windows (not tested by me) The deluge project has compiled python dbus bindings. You can download from: http://www.slurdge.org/files/Deluge_on_windows/win32.7z More info: http://www.slurdge.org/deluge-on-windows
- Install the python dbus bindings (not tested) Download the python-dbus source(0.83.0) from freedesktop site. Decompress it, and take the dbus folder from the source tree, and put it at c:\python25\lib folder
- "import dbus", take the dbus' dll and pyd files Note: I dont know (yet) that you take these files from the win32.7z compressed file (step 7) or you need to install deluge on windows. Update 1: You can find the below files in the win32.7z file under:
/win32/dbus-python-bindings/_dbus_glib_bindings.pyd, etc
Take the _dbus_bindings.pyd, _dbus_glib_bindings.pyd, libdbus-1.dll and libdbus-glib-1.dll files from deluge installed folder to c:\python25\dlls
With this, the "import dbus" command will work.
Problems
I have verified the above steps. After going through, Im not able to run pida:
c:\Python25\python.exe run-pida.py could not find dbus-daemon executable 1484: assertion failed "(error) == NULL || dbus_error_is_set ((error))" file "C: \Daten\windbus\cvs-commit-3\dbus\dbus-sysdeps-win.c" line 5423 function _dbus_ge t_autolaunch_address Backtrace: 3 KiIntSystemCall+0x6 3 WaitForSingleObject+0x12 3 dbus_print_backtrace+0x94 3 dbus_abort+0xb 3 dbus_real_assert+0x46 3 dbus_get_autolaunch_address+0x2b3 3 dbus_transport_open+0x540 3 dbus_transport_open+0x10e 3 dbus_connection_close+0x44b 3 dbus_bus_register+0x63f 2 _dbus_bindings.pyd+0x2135 3 PyCFunction_Call+0x5b
It looks like, I need to install deluge from here: http://download.deluge-torrent.org/windows/1.0.5/deluge-1.0.5-32.msi Update 1: I have installed deluge, but it does not start either (the same error). However deluge cant start either. Launching C:\Program Files\Deluge\Scripts\deluged2.cmd results in Entry point (?PyWinLong?_FromHANDLE@@YAPAU_object@@PAX@Z) cant fin indll (pywintypes25.dll).
There are multiple/different pywintypes25.dll on my system. (c:\windows\system32, c:\ProgramFiles?\Deluge, c:\Python25\lib\site-packages\pywin32_system32)
So I willstart over a fresh install, and try installing deluge before the others.
(Ali) In http://www.slurdge.org/files/Deluge_on_windows/win32.7z there is a dbus-daemon executable. Ali: And where should I put it?
Finding dbus-daemon
In win32.7z file there are dbus-daemon and dbus_daemon_wrapper directory. I have butthe contents of these directory under c:\python25\dbus-daemon directory. And I added this directory to the PATH variable.
Now pida does not complaint anymore about dbus-daemon.exe file, but fails with the following backtrace:
Traceback (most recent call last):
File "run-pida.py", line 9, in <module>
from pida.core import application
File "C:\Documents and Settings\Rendszergazda\Asztal\pida_install\pida-2008112
4\pida-main\pida\core\application.py", line 68, in <module>
from pida.core.boss import Boss
File "C:\Documents and Settings\Rendszergazda\Asztal\pida_install\pida-2008112
4\pida-main\pida\core\boss.py", line 18, in <module>
from .options import OptionsManager
File "C:\Documents and Settings\Rendszergazda\Asztal\pida_install\pida-2008112
4\pida-main\pida\core\options.py", line 20, in <module>
from .pdbus import DbusOptionsManager
File "C:\Documents and Settings\Rendszergazda\Asztal\pida_install\pida-2008112
4\pida-main\pida\core\pdbus.py", line 273, in <module>
from pida.utils.pdbus import (UUID, DBUS_PATH, DBUS_NS, EXPORT,
File "C:\Documents and Settings\Rendszergazda\Asztal\pida_install\pida-2008112
4\pida-main\pida\utils\pdbus.py", line 17, in <module>
BUS = dbus.SessionBus()
File "c:\Python25\lib\dbus\_dbus.py", line 219, in __new__
mainloop=mainloop)
File "c:\Python25\lib\dbus\_dbus.py", line 108, in __new__
bus = BusConnection.__new__(subclass, bus_type, mainloop=mainloop)
File "c:\Python25\lib\dbus\bus.py", line 125, in __new__
bus = cls._new_for_bus(address_or_type, mainloop=mainloop)
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.NoReply: Did not recei
ve a reply. Possible causes include: the remote application did not send a reply
, the message bus security policy blocked the reply, the reply timeout expired,
or the network connection was broken.
So it looks like, we need PROPERLY launch dbus under windows.
Rodferso status
He could make moo and dbus running under windows. He took out gconf (no longer needed, look at Gconf section for more info), he had some unix specific issue (pwd module and other things).
You can download his modification from here. Unzip it and put these file at pida-main\pida\core. (maybe you just need the first lines for options.py file)
Maybe it is no longer needed because ronny already implemented the gconf-free option storage. Need a bit test here.
Medit bindings and what is REALLY required
There is a contrib/moo directory inside pida, but this code is a fallback mechanism. It is ONLY required if medit + its python bindings are missing. (but if you installed medit with python support (see step 4), you do not need to compile this directory.
Dbus
If you want only medit+pida working together, maybe you do not need dbus support. Poelzi has done some works in this area (dbus is not a hard dependency anymore), but for pida-remote and to be fully functional it is highly recommended.
For running vim, dbus are absolutely required.
TODO
- Make a windows installer using NSIS.
- Compile the dbus and medit support using mingw32 (see missing bits section).
Missing bits (works to be done)
Gconf [DONE]
Currently on windows, there is no gconf, and pida use it for config storage. Ronny is doing a replacement, initially he thought using pydbusconf. Final implementation use json az configfile scheme.
Ronny has implemented it (2008-11-07), please see: landing options refactor
Mingw32 (TODO)
For compiling (and not just copying the already compiled stuff) dbus bindings and medit python support, we need mingw32 set up correctly. We need more help with this, so if you are experienced or just want to play with it a bit, please write your progress (or any question) to the pida mailing list. Maybe msys is needed too.
Epilogue:
Maybe we need (see step 7) deluge-on-windows prebuild packages: http://www.slurdge.org/files/Deluge_on_windows/win32.7z
