Problems getting python console to launch
Emil Kantis
e.kantis at gmail.com
Tue Mar 29 18:30:30 EDT 2011
Christian Stimming skrev 2011-03-29 10:34:
> Zitat von Emil Kantis <e.kantis at gmail.com>:
>> I'm looking into applying to the Python reporting and scripting
>> engine project and I've built the gnucash source, with the
>> src/python/init.py line changed as described in
>> http://lists.gnucash.org/pipermail/gnucash-devel/2011-March/031506.html
>> I ran ./configure --prefix=/opt/gnucash and set the Pythonpath to
>> /usr/local/lib/python2.6/ (also tried /opt/gnucash/lib/python) but
>> the python console won't load. Another person in the IRC had the same
>> problem. Help appreciated.
>
> Dear Emil,
>
> this sounds good so far. However, what error message do you see on
> program launch? Is there some message in the trace file
> http://wiki.gnucash.org/wiki/Tracefile ?
>
> In my setup, when I forgot to adapt the PYTHON_PATH, I see some error
> message like "could not import * from gnucash" or similar in the trace
> file in one line that indicates that init.py cannot be run. Once I
> chose the correct PYTHON_PATH, there was no such error message but
> instead plenty of debug output that is run in the python code. With
> your prefix=/opt/gnucash, the PYTHON_PATH probably needs to be
> export PYTHON_PATH=/opt/gnucash/lib/python
> or "python2.6" - whatever directory is existing there after you ran
> "make install". Also note that of course you need to enable the python
> module at configure time, using ./configure --enable-python
> --prefix=/your/prefix/blabla
>
> Regards,
>
> Christian
>
>
Hi Christian,
I must've missed the documentation regarding the python-specific build
options (--enable-python in ./configure), or maybe it's obvious to
people with experience. After running
./configure --enable-python --enable-compile-warnings
--prefix=/opt/gnucash/
make clean
make
make exits with the following error
swig-app-utils-python.c: In function 'SwigPyObject_richcompare':
swig-app-utils-python.c:1519: error: dereferencing pointer 'res'
does break strict-aliasing rules
swig-app-utils-python.c:1519: error: dereferencing pointer 'res'
does break strict-aliasing rules
swig-app-utils-python.c:1516: note: initialized from here
swig-app-utils-python.c:1518: note: initialized from here
make[3]: *** [swig-app-utils-python.lo] Error 1
make[3]: Leaving directory `/home/kantis/gnucash/src/app-utils'
make[2]: *** [install-recursive] Error 1
make[2]: Leaving directory `/home/kantis/gnucash/src/app-utils'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/home/kantis/gnucash/src'
make: *** [install-recursive] Error 1
More information about the gnucash-devel
mailing list