Bug 752916 - hivex does not support Python 3
hivex does not support Python 3
Status: CLOSED UPSTREAM
Product: Virtualization Tools
Classification: Community
Component: libguestfs (Show other bugs)
unspecified
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Richard W.M. Jones
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2011-11-10 14:07 EST by Michael Terry
Modified: 2011-11-19 12:03 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2011-11-19 11:55:56 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Michael Terry 2011-11-10 14:07:17 EST
Description of problem:
When building on a 64-bit system against Python 3.x, hivex issues warnings like:
../../../python/hivex-py.c:810:3: warning: implicit declaration of
function 'Py_InitModule' [-Wimplicit-function-declaration]

This is almost certainly a bug.  The problem seems to be the use of PyString_* instead of PyBytes_*.  PyString_* is no longer available on Python 3.x.

How reproducible:
Always

Steps to Reproduce:
1. Build on amd64 with Python 3.x

Additional info:
See Debian bug http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=646383
Comment 1 Richard W.M. Jones 2011-11-10 14:50:54 EST
We don't yet support python 3 in hivex, but ought to.

See similar changes made to libguestfs recently:
https://bugzilla.redhat.com/show_bug.cgi?id=750889
http://git.annexia.org/?p=libguestfs.git;a=commitdiff;h=2116f79cbcd4605b4997931285f14dde1f72a992
Comment 3 Richard W.M. Jones 2011-11-19 12:03:01 EST
In case it's not clear, you can select which Python to use
by exporting the PYTHON environment variable before ./configure,
eg:

  PYTHON=python3 ./configure

Note You need to log in before you can comment on or make changes to this bug.