- deb: added python3-packaging dependency.
- rpm:
* make python3-notify2 package optional.
* Added python3-packaging as dependency to load dynamically the
protobuffers (python3-packaging for Fedora, python-rpm-packaging
metapackage for OpenSuse).
Protobuffers compiled with protobuf < 3.20.0 are incompatible with
protobuf >= 4.0.0:
https://github.com/evilsocket/opensnitch/wiki/GUI-known-problems#gui-does-not-show-up
This has been a source of problems for some users (#1214, #647), and
in some distributions, previous protobuffer does no longer work due to
incompatibility with the protobuf package version installed
(OpenSuse Tumbleweed).
So in order to solve this issue, we provide several protobuffers,
for old and new protobuf versions:
proto/ui_pb2* for protobuf >= 4.0.0
proto/pre3200/ui_pb2* for protobuf >= 3.6.0 and < 3.20.0
To avoid import errors, each protobuffer must be placed in its own
directory, and the name of the protobuffer files must be named with
the syntax <prefix>_pb2.py/<prefix>_pb2_grpc.py:
ui_pb2.py and ui_pb2_grpc.py
The default compiled protobuffer will be opensnitch/proto/ui_*.py
instead of opensnitch/ui_*.py
Previously after installing the rpm GUI package, we created a symlink to
our .desktop file for all users, under /home/*/.config/autostart/
If the path didn't exist we created it, unfortunately as root, which
caused some problems with other applications like Gnome Tweaks.
Now a link is created under /etc/xdg/autostart/, which is what we use
with the debian packages.
Closes: #1068
Starting from a python3 release, distutils no longer install scripts
under /usr/bin by default, but under /usr/local/bin.
(around opensnitch v1.6.0-c5).
This causes on some immutable distros not to install the GUI, for
example Fedora SilverBlue:
https://github.com/projectatomic/rpm-ostree/issues/233Closes#880