maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Development (https://talk.maemo.org/forumdisplay.php?f=13)
-   -   Mercurial on Maemo 5/N900 (https://talk.maemo.org/showthread.php?t=37094)

SaintGermain 2009-12-14 00:35

Mercurial on Maemo 5/N900
 
Hello,

I wanted to develop on my N900 so I needed a version control software. I have seen that Subversion was available but I personnally prefer Mercurial.

So I took the last version (1.4.1) and try to build it on the Scratchbox.
Amazingly enough, it works the first time without any problem.

I then just copied the files on my N900 and so far everything is working perfectly.

Maemo 5/N900 is indeed fantastic :)

P.S. : I would gladly try to make a deb and submit it, but I began to read everything about dh_make and maemo-optify and realized that I couldn't do it before next month (not enough time).

www.rzr.online.fr 2009-12-14 13:12

Re: Mercurial on Maemo 5/N900
 
Quote:

Originally Posted by SaintGermain (Post 426468)
Hello,

I wanted to develop on my N900 so I needed a version control software. I have seen that Subversion was available but I personnally prefer Mercurial.

great what about git ? any1 tried ?

Nathan 2009-12-24 21:48

Re: Mercurial on Maemo 5/N900
 
Quote:

Originally Posted by SaintGermain (Post 426468)
Hello,

I wanted to develop on my N900 so I needed a version control software. I have seen that Subversion was available but I personnally prefer Mercurial.

So I took the last version (1.4.1) and try to build it on the Scratchbox.
Amazingly enough, it works the first time without any problem.

I then just copied the files on my N900 and so far everything is working perfectly.

Maemo 5/N900 is indeed fantastic :)

P.S. : I would gladly try to make a deb and submit it, but I began to read everything about dh_make and maemo-optify and realized that I couldn't do it before next month (not enough time).


Actually you just have to create a file in the debian folder to handle the optify now. "echo 'auto' > debian/optify"

As for dh_make. What I do is go find the latest version of the package on the debian site.

If what debian has is fairly recent I might just use that version, but if I want the latest & greatest; then I'll pull the tar.gz from the source web site. Extract it and then I copy the debian folder out of the "older" version into the new version folder.

Then update the changelog to specify it is a maemo port. Fix any minor configurations in the rules file. Then test build the binary packages on armel scratchbox until I get everything fixed.

Sometimes if the package has been ported before to diablo; you can look at those for the debian folder and you can use that instead.

Nathan.

antezz 2011-01-18 16:46

Re: Mercurial on Maemo 5/N900
 
Do someone got a new version of mercurial for N900? The one in repo seems to be broken.

Code:

hg
abort: couldn't find mercurial libraries in [/usr/bin /usr/lib/python2.5 /usr/lib/python2.5/plat-linux2 /usr/lib/python2.5/lib-tk /usr/lib/python2.5/lib-dynload /usr/local/lib/python2.5/site-packages /usr/lib/python2.5/site-packages /usr/lib/python2.5/site-packages/Numeric /usr/lib/python2.5/site-packages/gst-0.10 /usr/lib/pymodules/python2.5 /usr/lib/pymodules/python2.5/gtk-2.0]
(check your install and PYTHONPATH)


antezz 2011-01-23 18:59

Re: Mercurial on Maemo 5/N900
 
I'm bumping this.

eagle_linux 2011-05-23 06:46

Re: Mercurial on Maemo 5/N900
 
Hi,

I hope I'm not beating a dead horse with that answer, but I recently decided to install mercurial on my N900 and I *seem* to have gotten it to work (at least running 'hg' returns the help text and no python messages about missing packages).

It seems that the post-install script of mercurial_1.4.1-maemo1_armel.deb is broken, because it removes the directories mercurial and hgnext under /usr/lib/python2.5/site-packages/ after being installed, supposedly to eliminate "wrong" packages from mercurial-common_1.4.1-maemo1_all.deb, but by doing this, it also removes the version of those directories it provides itself, so the user is left without any python-modules for mercurial :confused:

Anyway, the way I managed to get it to work:
- first install python-dev (omitting this appearently causes the infamous " No module named osutil" error)
- then install the mercurial package (which will install mercurial-common too, as it depends on this package)
- then install the mercurial-common package AGAIN to bring back the site-packages the mercurial postinstall script removed:
Code:

dpkg -i /var/cache/apt/archives/mercurial-common_1.4.1-maemo1_all.deb
If all went well, you should have a functional mercurial installation now (at least as far as I can see, never having used hg before etc. ;) )

It would be nice if the maintainer could fix the package, as I don't really have a clue how to do that, and don't have time atm to dive into the depth of the debian package system...

Regards,
Eagle_Linux

antezz 2011-05-23 10:04

Re: Mercurial on Maemo 5/N900
 
Code:

$ hg
Traceback (most recent call last):
  File "/usr/bin/hg", line 27, in <module>
    mercurial.dispatch.run()
  File "/usr/lib/python2.5/site-packages/mercurial/dispatch.py", line 16, in run
    sys.exit(dispatch(sys.argv[1:]))
  File "/usr/lib/python2.5/site-packages/mercurial/dispatch.py", line 21, in dispatch
    u = _ui.ui()
  File "/usr/lib/python2.5/site-packages/mercurial/ui.py", line 35, in __init__
    for f in util.rcpath():
  File "/usr/lib/python2.5/site-packages/mercurial/util.py", line 1171, in rcpath
    _rcpath = os_rcpath()
  File "/usr/lib/python2.5/site-packages/mercurial/util.py", line 1146, in os_rcpath
    path = system_rcpath()
  File "/usr/lib/python2.5/site-packages/mercurial/posix.py", line 42, in system_rcpath
    '/../etc/mercurial'))
  File "/usr/lib/python2.5/site-packages/mercurial/posix.py", line 31, in rcfiles
    for f, kind in osutil.listdir(rcdir)
  File "/usr/lib/python2.5/site-packages/mercurial/demandimport.py", line 75, in __getattribute__
    self._load()
  File "/usr/lib/python2.5/site-packages/mercurial/demandimport.py", line 47, in _load
    mod = _origimport(head, globals, locals)
ImportError: No module named osutil

I made some googling but didnt have enough time since I had to go to work.

eagle_linux 2011-05-23 11:55

Re: Mercurial on Maemo 5/N900
 
Yeah, I had the osutil problem too, earlier, but installing python-dev seems to have fixed the problem for me. If not, try installing the packages again, first mercurial then mercurial-common, and let me know if it worked :)

antezz 2011-05-23 12:36

Re: Mercurial on Maemo 5/N900
 
I have reinstalled python-dev both before and after mercurial same problem. Have purged the packages and tried install them in all kinds of different orders e.c and no luck. Either i get the first errors with the missing pathes or osutils problem.

eagle_linux 2011-05-23 12:52

Re: Mercurial on Maemo 5/N900
 
Hmm, strange. Did you install with two seperate commands, i.e.

Code:

dpkg -i mercurial_1.4.1-maemo1_armel.deb
dpkg -i mercurial-common_1.4.1-maemo1_armel.deb

?

As a result, there should be a /usr/lib/python2.5/site-packages/mercurial and a /usr/lib/python2.5/site-packages/hgext directory.

Another option would be to extract the deb files with dpkg -X [filename] and then move the site-packages tree to /usr/lib/python2.5 manually. But then again, it worked for me without that, so I'm not sure if it would work or have other unforseen consequences...

EDIT: removed a typo


All times are GMT. The time now is 15:15.

vBulletin® Version 3.8.8