Project

General

Profile

Actions

Bug #12504

closed

Mercurial is broken, seems odd to have python 2.7 errors

Added by Cristian Achim over 2 years ago. Updated over 2 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
-
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Difficulty:
Medium
Tags:

Description

> uname -a
SunOS openindiana 5.11 illumos-a16250662f i86pc i386 i86pc

> hg
Traceback (most recent call last):
File "/usr/bin/hg", line 41, in <module>
dispatch.run()
File "/usr/lib/python2.7/vendor-packages/hgdemandimport/demandimportpy2.py", line 145, in __getattr__
self._load()
File "/usr/lib/python2.7/vendor-packages/hgdemandimport/demandimportpy2.py", line 90, in _load
mod = _hgextimport(_origimport, head, globals, locals, None, level)
File "/usr/lib/python2.7/vendor-packages/hgdemandimport/demandimportpy2.py", line 41, in _hgextimport
return importfunc(name, globals, *args, **kwargs)
File "/usr/lib/python2.7/vendor-packages/mercurial/dispatch.py", line 597, in <module>
class lazyaliasentry(object):
File "/usr/lib/python2.7/vendor-packages/mercurial/dispatch.py", line 607, in lazyaliasentry
@util.propertycache
File "/usr/lib/python2.7/vendor-packages/hgdemandimport/demandimportpy2.py", line 145, in __getattr__
self._load()
File "/usr/lib/python2.7/vendor-packages/hgdemandimport/demandimportpy2.py", line 90, in _load
mod = _hgextimport(_origimport, head, globals, locals, None, level)
File "/usr/lib/python2.7/vendor-packages/hgdemandimport/demandimportpy2.py", line 41, in _hgextimport
return importfunc(name, globals, *args, **kwargs)
File "/usr/lib/python2.7/vendor-packages/mercurial/util.py", line 56, in <module>
osutil = policy.importmod(r'osutil')
File "/usr/lib/python2.7/vendor-packages/mercurial/policy.py", line 101, in importmod
mod = _importfrom(pn, mn)
File "/usr/lib/python2.7/vendor-packages/mercurial/policy.py", line 63, in _importfrom
getattr(mod, r'__doc__', None)
File "/usr/lib/python2.7/vendor-packages/hgdemandimport/demandimportpy2.py", line 159, in __doc__
self._load()
File "/usr/lib/python2.7/vendor-packages/hgdemandimport/demandimportpy2.py", line 90, in _load
mod = _hgextimport(_origimport, head, globals, locals, None, level)
File "/usr/lib/python2.7/vendor-packages/hgdemandimport/demandimportpy2.py", line 41, in _hgextimport
return importfunc(name, globals, *args, **kwargs)
ImportError: ld.so.1: isapython2.7: fatal: relocation error: file /usr/lib/python2.7/vendor-packages/mercurial/cext/osutil.so: symbol __xnet_recvmsg: referenced symbol not found

Actions #1

Updated by Alexander Pyhalov over 2 years ago

The issue is briefly the following.
1) Mercurial osutil module detects if recvmsg() is usable based on CMSG_LEN define, which is available from socket.h in _XPG4_2 mode (XOPEN_SOURCE>=500), but doesn't check if it's available from libc.
2) One of the updates changed Python 2.7 to use XOPEN_SOURCE=600 https://github.com/OpenIndiana/oi-userland/commit/a01f2541633bc2a64c26379bfe81a982e853bd82#diff-1829c10786b4201dffcbc8296db3cc6d

I'm not sure, why issue didn't appear earlier, but just after recent GCC-7 world rebuild.
Upstream issue: https://bz.mercurial-scm.org/show_bug.cgi?id=6299

Proposed fix (included in mercurial update): https://github.com/OpenIndiana/oi-userland/pull/5672

Actions #2

Updated by Alexander Pyhalov over 2 years ago

  • Status changed from New to Resolved
Actions

Also available in: Atom PDF