Sensing-Dev / sensing-dev-installer

0 stars 2 forks source link

PyGObject and GObject-introspection in this project #16

Open Fixstars-momoko opened 9 months ago

Fixstars-momoko commented 9 months ago

I leave this note on the issue for the future note.

The reason for having PyGObject and GObject-introspection is to enable users to use Aravis in Python.

import gi
gi.require_version("Aravis", "0.8")
from gi.repository import Aravis

GObject-introspection

To generate "aravis\lib\girepository-1.0\Aravis-0.8.typelib", we need to enable gobject-introspection option on to build

PyGObject

For module gi we need pygobject.

Fixstars-momoko commented 9 months ago

With pip install PyGObject without C++ environment, it caused the following error.

      error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for PyGObject
Failed to build PyGObject
ERROR: Could not build wheels for PyGObject, which is required to install pyproject.toml-based projects

Since we include Aravis-0.8.typelib for python user who does not use C++ environment, it does not make sense to make them install Microsoft Visual C++ 14.0.; therefore , we will include PyGObject in our SDK.