Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

macos client-only builds fail #4338

Open
totaam opened this issue Aug 28, 2024 · 1 comment
Open

macos client-only builds fail #4338

totaam opened this issue Aug 28, 2024 · 1 comment
Labels
bug Something isn't working macos packaging

Comments

@totaam
Copy link
Collaborator

totaam commented Aug 28, 2024

Very strange one.
CLIENT_ONLY=1 ./make-all.sh fails with:

cat /Users/macos12/xpra/py2app.log
Traceback (most recent call last):
  File "/Users/macos12/xpra/./setup.py", line 2836, in <module>
    main()
  File "/Users/macos12/xpra/./setup.py", line 2832, in main
    setup(**setup_options)
  File "/Users/macos12/gtk/inst/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 185, in setup
    return run_commands(dist)
           ^^^^^^^^^^^^^^^^^^
  File "/Users/macos12/gtk/inst/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 201, in run_commands
    dist.run_commands()
  File "/Users/macos12/gtk/inst/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 969, in run_commands
    self.run_command(cmd)
  File "/Users/macos12/gtk/inst/lib/python3.11/site-packages/setuptools/dist.py", line 1234, in run_command
    super().run_command(command)
  File "/Users/macos12/gtk/inst/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
    cmd_obj.run()
  File "/Users/macos12/gtk/inst/lib/python3.11/site-packages/py2app/build_app.py", line 987, in run
    self._run()
  File "/Users/macos12/gtk/inst/lib/python3.11/site-packages/py2app/build_app.py", line 1217, in _run
    self.run_normal()
  File "/Users/macos12/gtk/inst/lib/python3.11/site-packages/py2app/build_app.py", line 1436, in run_normal
    o = __import__(m1, fromlist=[m2])
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/macos12/xpra/xpra/server/base.py", line 13, in <module>
    from xpra.server.core import ServerCore
  File "/Users/macos12/xpra/xpra/server/core.py", line 27, in <module>
    from xpra.scripts.server import deadly_signal, clean_session_files, rm_session_dir
  File "/Users/macos12/xpra/xpra/scripts/server.py", line 56, in <module>
    from xpra.util.child_reaper import getChildReaper
  File "/Users/macos12/xpra/xpra/util/child_reaper.py", line 21, in <module>
    GLib = gi_import("GLib")
           ^^^^^^^^^^^^^^^^^
  File "/Users/macos12/xpra/xpra/os_util.py", line 54, in gi_import
    return importlib.import_module(f"gi.repository.{mod}")
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/macos12/gtk/inst/lib/python3.11/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1147, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 676, in _load_unlocked
  File "<frozen importlib._bootstrap>", line 573, in module_from_spec
  File "/Users/macos12/gtk/inst/lib/python3.11/site-packages/gi/importer.py", line 147, in create_module
    dynamic_module = load_overrides(introspection_module)
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/macos12/gtk/inst/lib/python3.11/site-packages/gi/overrides/__init__.py", line 112, in load_overrides
    override_mod = importlib.import_module(override_package_name)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/macos12/gtk/inst/lib/python3.11/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/macos12/gtk/inst/lib/python3.11/site-packages/gi/overrides/GLib.py", line 37, in <module>
    from gi import _option as option
  File "/Users/macos12/gtk/inst/lib/python3.11/site-packages/gi/_option.py", line 41, in <module>
    OPTION_CONTEXT_ERROR_QUARK = GLib.quark_to_string(GLib.option_error_quark())
                                                      ^^^^^^^^^^^^^^^^^^^^^^^^^
gi._error.GError: g-invoke-error-quark: Could not locate g_option_error_quark: dlopen(libglib-2.0.0.dylib, 0x0009): tried: 'libglib-2.0.0.dylib' (no such file), '/usr/local/lib/libglib-2.0.0.dylib' (no such file), '/usr/lib/libglib-2.0.0.dylib' (no such file), '/Users/macos12/xpra/libglib-2.0.0.dylib' (no such file) (1)

There aren't any major differences between regular and client-only builds:

BUILD_ARGS="${BUILD_ARGS} --without-server --without-shadow --without-proxy"

Why would this have any effect on a GLib import!?

@totaam totaam added bug Something isn't working packaging macos labels Aug 28, 2024
@Xpra-org Xpra-org deleted a comment Aug 28, 2024
@totaam
Copy link
Collaborator Author

totaam commented Aug 28, 2024

Even more strange, on my x86_64 build system, this also triggers the problem:
python3 -c "from xpra.os_util import gi_import;gi_import('GLib')"
But on the arm64 build system, it does not!
Both systems fail with CLIENT_ONLY=1!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working macos packaging
Projects
None yet
Development

No branches or pull requests

1 participant