SIP and PyQt5 Build issue

Building the GUI requires sip and pyqt5. I managed to build pyqt5 but the cmake file still requests the sip which im struggling to build outside a pip environment. I dont want salome to run in pip.

Has anyone dealt with this sip issue when building the gui?

Finally it seems that elements are shared with freecad. Wouldnt it be better to replace pyqt5 with pyside 2 as well?

Cheers

what is your OS and SALOME version in use and what error message do you get?
Sip as well as PyQt can be easily compiled with SAT and compilation scripts are sitting in:
products/compil_scripts/sip-5.5.0.{.sh, bat}
and
products/compil_scripts/PyQt-5.15.{.sh, bat}

1 Like

Hi Nabil,

Thanks for this. I will try it asap. Im using debian 12 but i have compiled alot of packages for freecad and elmer so i want to use the same for salome rather than having containers.

Im building salome from the git repository.

On Debian 12, we use system packages instead.

Thus, install with apt package manager:

sudo apt install python3-sip-dev python3-sip python3-pyqt5 pyqt5-dev pyqt5-dev-tools

Note that running:

sat/sat config SALOME-master-native --check_system

should report if these packages are missing from your Debian 12 installation.

HTH.

Thank you I will try it. I just wanted to use a pyqt5 version i built against the qt5 version I built and im using in other applications that is compatible with c++17 and python 3.11.

Hi sorry, where is this products directory here:
https://git.salome-platform.org/gitweb/

Found under sat_salome

Hi I executed the instructions in the sip, but I keep getting errors relating to missing metadata for the sip module and other components. Any idea how to fix this?

Many thanks

can you share the error message if any?

Hi Nabil,

its the following.

StopIteration

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home//SALOME/PyQt5/SIP/Install/local/bin/sip-build", line 33, in <module>
    sys.exit(load_entry_point('sip==6.8.3', 'console_scripts', 'sip-build')())
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home//SALOME/PyQt5/SIP/Install/local/bin/sip-build", line 22, in importlib_load_entry_point
    for entry_point in distribution(dist_name).entry_points
                       ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/importlib/metadata/__init__.py", line 981, in distribution
    return Distribution.from_name(distribution_name)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/importlib/metadata/__init__.py", line 565, in from_name
    raise PackageNotFoundError(name)
importlib.metadata.PackageNotFoundError: No package metadata was found for sip