[mythtv-users] missing mythtv python modules in Debian 12 cmake build

Bill Meek keemllib at gmail.com
Thu Feb 20 19:15:28 UTC 2025




On Thursday 20 February 2025 11:07:53 AM (-06:00), James Abernathy wrote:

> On Thu, Feb 20, 2025 at 11:33 AM Bill Meek <keemllib at gmail.com> wrote:
> 
> > On Thursday 20 February 2025 09:36:58 AM (-06:00), James Abernathy wrote:
> >
> > > I used what I learned from my Archlinux build yesterday and tried to do
> > the
> > > same on a Debian VM
> > >
> > > When I finished the build the output directory for "lib" contained no
> > > python directory.
> > > I used the instructions from yesterday's arch build. The only changes I
> > > needed to make was to add a dependency based on an error I saw in the
> > first
> > > run.
> > >
> > > libsqlite3-dev
> > >
> > > The Debian ansible stuff has sqlite3, but not libsqlit3-deb, but I don't
> > > think that was part of the problem here.
> > >
> > > cmake --preset qt5 -DCMAKE_INSTALL_PREFIX=~/mythtv-output
> > > -DMYTH_RUN_PREFIX=/usr
> > > 2>&1 | tee ~/stage1.log
> > > cmake --build build-qt5 2>&1 | tee ~/stage2.log
> > >
> > > The logs are posted here, but they seem to show that all the python and
> > > python-pip stuff that is required is present.
> > >
> > >
> > https://drive.google.com/drive/folders/1v4beUzxygecF5_Sq4g2OR1s7s6CN9W4u?usp=drive_link
> > >
> > > Jim A
> >
> > You created a python virtual environment based on the test I was running.
> > I picked a temporary path just to try things. It will surely change.
> >
> > You'll see: "-- Using python pip install method" in your stage2 log.
> >
> > If you're still using the virtual environment (your prompt will have:
> > "(venv) "
> > in front of it), just type: deactivate  to turn it off, then rebuild.
> >
> > Or try: find /usr/local/lib/venv -name MythTV if you'd like to see where
> > the
> > module ended up.
> >
> > If you keep using venv, note that python programs that use the bindings
> > must have their 1st line changed from #!/usr/bin/python to
> > #!/usr/local/lib/venv/bin/python. Again, that path will likely change.
> >
> > find_orphans would be an example of this.
> >
> > --
> > Bill
> >
> >
> I don't see any evidence that I'm in some virtual environment.  Also
> find /usr/local/lib/venv -name MythTV shows nothing found.

venv won't be active 'til you run the source .... command again.
If you've logged out, it's gone.

Try this: sudo updatedb && locate mythproto.py | grep -v build-qt5

> I checked out fixes/35. Could that be part of it?

No, I think any changes to cmake files went into both master and 35.

> Maybe I should pause my testing for a while until you've finished your venv
> stuff.

Your choice.

> Jim A

Demo without venv active and with it (note that I've changed the path from
yesterday's email.):

bill at ofc1:~$ python -c "import MythTV"

Traceback (most recent call last):
  File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'MythTV'

bill at ofc1:~$ source /usr/local/lib/mythtv/venv/bin/activate
(venv) bill at ofc1:~$ python -c "import MythTV"
(venv) bill at ofc1:~$
-- 
Bill


More information about the mythtv-users mailing list