LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 05-22-2018, 01:20 AM   #1
black-clover
Member
 
Registered: Jun 2017
Distribution: Devuan Daedalus, Debian Testing, SliTaz, Alpine Linux.
Posts: 207

Rep: Reputation: Disabled
wxpython in Alpine Linux


I'm trying to install Trelby in Alpine Linux.
When I launch python setup.py install, I get the following error:


Code:
    alpine# python setup.py install                               
    Traceback (most recent call last):
    File "setup.py", line 114, in <module>
    import misc
    File "src/misc.py", line 3, in <module>
    import gutil
    File "src/gutil.py", line 3, in <module>
    import util
    File "src/util.py", line 20, in <module>
    import wx
    ImportError: No module named wx
Now the Trelby readme indicates these dependencies:

External dependencies required: 1) Python 2.7 2) wxWidgets (2.8) and its Python bindings (wxPython) 3) lxml

I installed Trelby in Arch and Debian which indicate these dependencies:

ARCH 1) python2 (pypy19, stackless-python2, placeholder) 2) python2-lxml 3) python2-setuptools 4) wxpython (wxpython-nuitka, wxpython-gtk2, python2-wxpython3)

DEBIAN 1) python2 2) python-lxml 3) python-crypto 4) python-wxgtk3.0

In Alpine I installed the following packages:

ALPINE (installed) 1) python2, python2-dev 2) py-lxml, py2lxml, py3xlml 3) py-setuptools 4) wxgtk-base-3.0.3, wxgtk-3.0.3, wxgtk-dev, wxgtk2.8-dev, wxgtk2.8, wxgtk2.8-base

I also installed mock, py2-mock, py3-mock

And still I get the above error.

My question is: which package is missing, since I can't find any other wx widgets package in the Alpine repo that might fit the bill?
 
Old 05-22-2018, 02:07 AM   #2
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,850

Rep: Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309
if I understand it well the wxpython* packages are missing on alpine. But it is only a guess.
 
Old 05-22-2018, 02:16 AM   #3
black-clover
Member
 
Registered: Jun 2017
Distribution: Devuan Daedalus, Debian Testing, SliTaz, Alpine Linux.
Posts: 207

Original Poster
Rep: Reputation: Disabled
Yes, I installed all those listed under Alpine (installed) to see if one fulfilled the requirement but none did. The error, I assume, has to do with wx.
 
Old 05-22-2018, 02:59 AM   #4
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,850

Rep: Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309
for me the wx module is located here:
Quote:
<module 'wx' from '/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode/wx/__init__.pyc'>
probably:
Code:
pip install wxPython
pip install wxPython-common
helps, but probably you need first install pip.
 
Old 05-22-2018, 02:25 PM   #5
black-clover
Member
 
Registered: Jun 2017
Distribution: Devuan Daedalus, Debian Testing, SliTaz, Alpine Linux.
Posts: 207

Original Poster
Rep: Reputation: Disabled
pan64

Good input, I compared Alpine /usr/lib/python2.7 dir with Debian and Arch and wx is not there.

Pip failed to bulid wxpython:

Command "/usr/bin/python2 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-OL1x9j/wxpython/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-PWxUsy/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-OL1x9j/wxpython/


Further digging verified that wxwidgets seems to be absent among Alpine packages.
There is wxgtk but it doesn't seem to provide wxwidgets or python bindings.
I hope someone well versed in Alpine can provide a workaround solution.
 
Old 05-22-2018, 10:38 PM   #6
black-clover
Member
 
Registered: Jun 2017
Distribution: Devuan Daedalus, Debian Testing, SliTaz, Alpine Linux.
Posts: 207

Original Poster
Rep: Reputation: Disabled
I downloaded the wxpython.tar.gz (there is no wheel for alpine linux) and installed the sources with build.py.
now the trelby install passes wx but gives this error:

File "/usr/lib/python2.7/site-packages/wx/__init__.py", line 17, in <module>
from wx.core import *
File "/usr/lib/python2.7/site-packages/wx/core.py", line 12, in <module>
from ._core import *
ImportError: No module named _core
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Alpine Linux Goes All In for Docker LXer Syndicated Linux News 0 02-10-2016 04:30 AM
Does Alpine Linux contain blobs? Soderlund Linux - Distributions 9 01-22-2016 04:26 PM
Alpine Linux and grsecurity WhiteHatGuy Linux - Security 1 08-20-2015 11:40 PM
Updated Alpine Linux repository omitchell Linux - Newbie 0 03-08-2012 09:16 AM
[SOLVED] Disable IPv6 in Alpine Linux omitchell Linux - Networking 2 01-30-2012 08:57 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:40 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration