[mythtv-users] V35 install on Archlinux using cmake is missing python modules used in find_orphans.py
James Abernathy
jfabernathy at gmail.com
Wed Feb 19 19:20:39 UTC 2025
On Wed, Feb 19, 2025 at 2:14 PM Roland Ernst <rcrernst at gmail.com> wrote:
>
>
> On Wed, Feb 19, 2025 at 8:10 PM James Abernathy <jfabernathy at gmail.com>
> wrote:
>
>>
>>
>> On Wed, Feb 19, 2025 at 1:51 PM Roland Ernst <rcrernst at gmail.com> wrote:
>>
>>>
>>>
>>> On Wed, Feb 19, 2025 at 7:13 PM Bill Meek <keemllib at gmail.com> wrote:
>>>
>>>>
>>>>
>>>> On Wednesday 19 February 2025 12:07:45 PM (-06:00), James Abernathy
>>>> wrote:
>>>>
>>>> > On Wed, Feb 19, 2025 at 11:44 AM James Abernathy <
>>>> jfabernathy at gmail.com>
>>>> > wrote:
>>>> >
>>>> > >
>>>> > >
>>>> > > On Wed, Feb 19, 2025 at 11:22 AM Bill Meek <keemllib at gmail.com>
>>>> wrote:
>>>> > >
>>>> > >>
>>>> > >>
>>>> > >>
>>>> > >> On Wednesday 19 February 2025 09:53:55 AM (-06:00), James
>>>> Abernathy wrote:
>>>> > >>
>>>> > >> > On Wed, Feb 19, 2025 at 10:47 AM Bill Meek <keemllib at gmail.com>
>>>> wrote:
>>>> > >> >
>>>> > >> > >
>>>> > >> > >
>>>> > >> > >
>>>> > >> > > On Wednesday 19 February 2025 08:24:29 AM (-06:00), James
>>>> Abernathy
>>>> > >> wrote:
>>>> > >> > >
>>>> > >> > > > On Wed, Feb 19, 2025 at 9:21 AM James Abernathy <
>>>> > >> jfabernathy at gmail.com>
>>>> > >> > > > wrote:
>>>> > >> > > >
>>>> > >> > > > >
>>>> > >> > > > >
>>>> > >> > > > > On Wed, Feb 19, 2025 at 9:11 AM glen <glenb at glenb.net>
>>>> wrote:
>>>> > >> > > > >
>>>> > >> > > > >> On Wed, 2025-02-19 at 07:42 -0500, James Abernathy wrote:
>>>> > >> > > > >>
>>>> > >> > > > >> So I've got a successful build of Mythtv on Archlinux
>>>> using the
>>>> > >> v35
>>>> > >> > > cmake
>>>> > >> > > > >> method. I used ansible for my dependencies and it works
>>>> fine as
>>>> > >> far
>>>> > >> > > as I
>>>> > >> > > > >> can tell.
>>>> > >> > > > >>
>>>> > >> > > > >> However when I try find_orphans.py I get:
>>>> > >> > > > >>
>>>> > >> > > > >> ./find_orphans.py
>>>> > >> > > > >> Traceback (most recent call last):
>>>> > >> > > > >> File "/home/jim/Downloads/./find_orphans.py", line 3, in
>>>> > >> <module>
>>>> > >> > > > >> from MythTV import MythDB, MythBE, Recorded, MythError
>>>> > >> > > > >> ModuleNotFoundError: No module named 'MythTV'
>>>> > >> > > > >>
>>>> > >> > > > >> I built using sudo like this:
>>>> > >> > > > >>
>>>> > >> > > > >> sudo cmake --preset qt5 -DCMAKE_INSTALL_PREFIX=/usr 2>&1
>>>> | tee
>>>> > >> > > > >> ~/stage1-log
>>>> > >> > > > >> sudo cmake --build build-qt5 2>&1 | tee ~/stage2.log
>>>> > >> > > > >>
>>>> > >> > > > >> I looked through the stage1 and 2 log files I teed off and
>>>> > >> didn't see
>>>> > >> > > > >> anything missing except qt5webkit which is not needed.
>>>> > >> > > > >>
>>>> > >> > > > >> I can post those logs to Google Drive if needed.
>>>> > >> > > > >>
>>>> > >> > > > >> Jim A
>>>> > >> > > > >>
>>>> > >> > > > >>
>>>> > >> > > > >
>>>> > >> > > > >> is mythtv folder in the latest python on your machine in
>>>> > >> > > site-packages ?
>>>> > >> > > > >>
>>>> > >> > > > >
>>>> > >> > > > > No it seems that the build process didn't even build
>>>> them???
>>>> > >> > > > >
>>>> > >> > > > > sudo updatedb
>>>> > >> > > > > sudo plocate site-packages | grep -i mythtv
>>>> > >> > > > >
>>>> > >> > > > > Shows nothing.
>>>> > >> > > > >
>>>> > >> > > > > Jim A
>>>> > >> > > > >
>>>> > >> > > >
>>>> > >> > > > BTW the link to the google drive with the stage 1&2 logs is:
>>>> > >> > > >
>>>> > >> > > >
>>>> > >> > >
>>>> > >>
>>>> https://drive.google.com/drive/folders/1v4beUzxygecF5_Sq4g2OR1s7s6CN9W4u?usp=drive_link
>>>> > >> > > >
>>>> > >> > > > Jim A
>>>> > >> > >
>>>> > >> > > 1. I see pip is missing and it's not in ansible, please try
>>>> pacman and
>>>> > >> > > install python-pip
>>>> > >> > > And python3-pip (I don't see any python3 packages in the pacman
>>>> > >> ansible
>>>> > >> > > tasks.)
>>>> > >> > > I'll push if one of those works.
>>>> > >> > >
>>>> > >> > > 2. If it doesn't help, try adding this:
>>>> -DMYTH_BINDINGS_INSTALL_ROOT=/
>>>> > >> > >
>>>> > >> > >
>>>> > >> > > 3. Are you running cmake as root?
>>>> > >> > > Including user overrides
>>>> > >> /root/.config/MythTV/BuildOverridesPost.cmake
>>>> > >> > > That's my choice as I mimic the 'old' make/sudo make install.
>>>> > >> > > --
>>>> > >> > > Bill
>>>> > >> >
>>>> > >> >
>>>> > >> > python-pip was missing and I installed it. However, python3-pip
>>>> is not
>>>> > >> > found on the Arch repository.
>>>> > >> >
>>>> > >> > I'll see what I can do with that.
>>>> > >> >
>>>> > >> > Jim A
>>>> > >>
>>>> > >> Looks like: https://wiki.archlinux.org/title/Python#Other_versions
>>>> is
>>>> > >> one of the
>>>> > >> answers. If typing: python --version now shows 2.7, then I don't
>>>> > >> understand.
>>>> > >> That's been EOL since 1/1/2020.
>>>> > >>
>>>> > >> Don't know if all packages python3 packages used here are on AUR
>>>> (and my
>>>> > >> Dockere is broken right now).
>>>> > >> --
>>>> > >> Bill
>>>> > >>
>>>> > >>
>>>> > > That error is the same one I get if I try to build from source like
>>>> the
>>>> > > wiki says using the old ./configure, make, sudo make install. I can
>>>> do an
>>>> > > install fine with the AUR package, mythtv-git, but I have to modify
>>>> the
>>>> > > PKGBUILD file to use v35 and eliminate the python-future dependency.
>>>> > > However, I can't remember the last time I did that successfully if
>>>> I test
>>>> > > find_orphans.py.
>>>> > >
>>>> > > I'm betting it's a dependency issue, but having to depend on AUR
>>>> > > maintainers for weird Python packages is suspect at best. In my
>>>> NUCBOX,
>>>> > > it's easy to switch out the NVME drive and test something else. So
>>>> I've
>>>> > > pulled the Arch SSD and put it in timeout so it can think about how
>>>> it
>>>> > > screwed up. In the meantime I'll test something on Debian that I
>>>> wanted to
>>>> > > do for comparison.
>>>> > >
>>>> > > I did find something about pip and AUR. I can't say I understand
>>>> all of it:
>>>> > >
>>>> > > All python PKGBUILDs are built with --without-ensurepip, and pip is
>>>> > > provided via the python-pip package, which is built for the
>>>> system-wide
>>>> > > python environment as a "site-packages" package. If you build any
>>>> other
>>>> > > python version from the AUR, then you're supposed to use virtual
>>>> > > environments for any of those other python versions. In those
>>>> virtual
>>>> > > environments, pip gets installed separately, and this is where you
>>>> can also
>>>> > > upgrade or even remove it.
>>>> > >
>>>> > > $ yay -S python311
>>>> > > $ python -m virtualenv -p /usr/bin/python3.11 /path/to/venv
>>>> > > $ source /path/to/venv/bin/activate
>>>> > > $ python --version
>>>> > > $ python -m pip --version
>>>> > >
>>>> > > Jim A
>>>> > >
>>>> >
>>>> >
>>>> > As a comparison, on an Archlinux VM I used the ansible dependencies
>>>> for
>>>> > mythtv and then git cloned the AUR mythtv-git.
>>>> >
>>>> > I modified only the fixes/35 from 34 in the PKGBUILD file, and then
>>>> built
>>>> > the package with makepkg -si
>>>> >
>>>> > Once it complete I did the sudo updatedb, plocate site-packages |
>>>> grep -i
>>>> > mythtv and this time I got a bunch of files.
>>>> >
>>>> > So I have not built a full mythtv combo BE/FE but this answers part
>>>> of the
>>>> > question.
>>>> >
>>>> > Something is different between the new cmake build and the old
>>>> ./configure,
>>>> > make, sudo make install that is keeping the python bindings from being
>>>> > built for Archlinux.
>>>> >
>>>> > Jim A
>>>>
>>>>
>>>> Did you try adding: -DMYTH_BINDINGS_INSTALL_ROOT=/
>>>> on your cmake command line?
>>>>
>>>> --
>>>> Bill
>>>>
>>>
>>> Jim,
>>> what does the file "MythTV/_versions.py" state as "INSTALL_PREFIX" on
>>> the ArchLinux build?
>>> Does it match the path of the installed MythTV python bindings?
>>>
>>> > Something is different between the new cmake build and the old
>>> ./configure,
>>> > make, sudo make install that is keeping the python bindings from being
>>> > built for Archlinux.
>>>
>>> Nothing is different between the old make and the new cmake process.
>>> If the python installation is protected by the file "EXTERNALLY-MANAGED"
>>> no one except the package manager is allowed to install to it.
>>>
>>> Roland
>>> That's the problem there is no MythTV/_versions.py file anywhere on the
>>> system where I'm building mythtv.
>>
>>
>> plocate _version.py
>> /usr/lib/python3.13/site-packages/_pytest/_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/ansible/posix/plugins/module_utils/_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/cisco/mso/plugins/modules/mso_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/cisco/nxos/plugins/action/vtp_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/cisco/nxos/plugins/modules/nxos_vtp_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/community/crypto/plugins/module_utils/_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/community/general/plugins/lookup/collection_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/community/mysql/plugins/module_utils/_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/community/network/plugins/module_utils/_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/community/network/plugins/modules/avi_api_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/community/postgresql/plugins/module_utils/_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/community/rabbitmq/plugins/module_utils/_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/community/sops/plugins/filter/_latest_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/community/windows/plugins/modules/win_file_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/community/zabbix/plugins/module_utils/_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/fortinet/fortimanager/plugins/modules/fmgr_waf_profile_
>> constraint_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/google/cloud/plugins/modules/gcp_mlengine_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/hetzner/hcloud/plugins/module_utils/vendor/hcloud/_vers
>> ion.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/kubernetes/core/plugins/module_utils/_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/theforeman/foreman/plugins/module_utils/_version.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/theforeman/foreman/plugins/modules/content_export_versi
>> on.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/theforeman/foreman/plugins/modules/content_import_versi
>> on.py
>>
>> /usr/lib/python3.13/site-packages/ansible_collections/theforeman/foreman/plugins/modules/content_view_version
>> .py
>> /usr/lib/python3.13/site-packages/dateutil/_version.py
>> /usr/lib/python3.13/site-packages/iniconfig/_version.py
>> /usr/lib/python3.13/site-packages/paramiko/_version.py
>> /usr/lib/python3.13/site-packages/pip/_vendor/urllib3/_version.py
>> /usr/lib/python3.13/site-packages/pluggy/_version.py
>>
>> /usr/lib/python3.13/site-packages/setuptools/_distutils/tests/test_version.py
>> /usr/lib/python3.13/site-packages/urllib3/_version.py
>> [jim at nucboxg3 build]$
>>
>> This is on the cmake build machine. Do you want to see what it is on the
>> other arch machine where I did the traditional PKGBUILD build?
>>
>> Jim A
>>
>
> > This is on the cmake build machine. Do you want to see what it is on
> the other arch machine where I did the traditional PKGBUILD build?
> Yes
>
> Roland
>
>
okay on the system (Archlinux VM) where I built using the makepkg -si. On
the AUR PKGBUILD method I see:
/home/jim/mythtv-git/pkg/mythtv-git/usr/lib/python3.13/site-packages/MythTV/services_api/_version.py
/home/jim/mythtv-git/src/mythtv/mythtv/bindings/python/MythTV/services_api/_version.py
/home/jim/mythtv-git/src/mythtv/mythtv/bindings/python/build/lib/MythTV/services_api/_version.py
/usr/lib/python3.13/site-packages/MythTV/services_api/_version.py
JIm A
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mythtv.org/pipermail/mythtv-users/attachments/20250219/7083e6c5/attachment.htm>
More information about the mythtv-users
mailing list