FaithLife-Community / LogosLinuxInstaller

A Python application that helps install and maintain FaithLife's Logos Bible (Verbum) Software on Linux through Wine.
MIT License
35 stars 10 forks source link

Fix #14. Add *BSD Support #219

Open thw26 opened 1 month ago

thw26 commented 1 month ago

Fixes #14. There is one blocking issue and one additional problem.

I have added install pointers to the wiki. It presently requires use of the ports tool to get different versions of Wine and Python, but, as noted below, we don't have the Python version we need.

This is untested. This PR has been opened as a base working model. Of the testing I did do, I worked on GhostBSD.

Some of the commands we use are GNU versions of commands (e.g., sed, grep) and therefore they may not work out of the box on *BSD.

You will need to install Python 3.12, which as of 20241026, was unavailable in GhostBSD. You can build this using our ensure-python script, but will need to install the dev tools.

sudo pkg install -g 'GhostBSD*-dev'

Once installed, run ./scripts/ensure-python.sh to build it.

You will also need to install the following packages.

sudo pkg install wget gsed gnugrep gawk cabextract 7-zip samba416 curl

Until we can build it in GitHub, you will have to run from source or pip. Once you activate the Python virtual environment (see CONTRIBUTING), you will then need to install some Python modules.

pip install tk psutil packaging distro requests

If Wine is <9.10, you will need to install Wine-Devel ≥9.10 through ports.

thw26 commented 1 month ago

After building Python 3.12, I was able to make Ou Dedetai run with TK but not with curses. CLI --help works. Attempting to run via curses spits out this error. I am unsure why this is happening.

/scripts/run_app.py
Traceback (most recent call last):
  File "/home/thwright/Dev/LogosLinuxInstaller/./scripts/run_app.py", line 14, in <module>
    sys.exit(ou_dedetai.main.main())
             ^^^^^^^^^^^^^^^^^^^^^^
  File "/home/thwright/Dev/LogosLinuxInstaller/ou_dedetai/main.py", line 469, in main
    run()
  File "/home/thwright/Dev/LogosLinuxInstaller/ou_dedetai/main.py", line 406, in run
    config.ACTION()  # run control_panel right away
    ^^^^^^^^^^^^^^^
  File "/home/thwright/Dev/LogosLinuxInstaller/ou_dedetai/main.py", line 317, in run_control_panel
    raise e
  File "/home/thwright/Dev/LogosLinuxInstaller/ou_dedetai/main.py", line 302, in run_control_panel
    curses.wrapper(tui_app.control_panel_app)
  File "/opt/lib/python3.12/curses/__init__.py", line 94, in wrapper
    return func(stdscr, *args, **kwds)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/thwright/Dev/LogosLinuxInstaller/ou_dedetai/tui_app.py", line 1140, in control_panel_app
    TUI(stdscr).run()
  File "/home/thwright/Dev/LogosLinuxInstaller/ou_dedetai/tui_app.py", line 344, in run
    self.display()
  File "/home/thwright/Dev/LogosLinuxInstaller/ou_dedetai/tui_app.py", line 305, in display
    self.active_screen.display()
    ^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'display'