Setting up xpra for client use in OS X

6,560

Solution 1

Now (as of March 2016) available via 'brew install Caskroom/cask/xpra'

Solution 2

The most usable version on OSX is via gtk-osx, you can follow the build instructions for winswitch (aka shifter) here but skip some steps if you want:

  • Requirements: yes, you need that
  • jhbuild: yes, that's what will install gtk-osx
  • gtk-osx: the OSX native GTK port
  • GStreamer: skip this (not used by Xpra)
  • ige-mac-bundler: skip this (not going to build an installer)
  • Python dependencies: skip this - not needed by Xpra
  • Build Protocol Support: Yes, just follow the xpra instructions

After that, your "jhbuild shell" will contain an xpra installation ready to use: the python scripts it has created should be on your PATH.

Alternatively, you can try with the version of Python shipped with OSX, but I don't know how well that works, if at all... The page linked above also has a link to the macports build version (you may skip the unnecessary steps which will be similar to the ones above)

Edit: the latest version also includes a PKG installer.

Solution 3

You can use Homebrew with a user-supplied tap:

$ brew tap victor-ono/homebrew-xpra
$ brew install xpra
Share:
6,560

Related videos on Youtube

Jonathan
Author by

Jonathan

Updated on September 17, 2022

Comments

  • Jonathan
    Jonathan over 1 year

    I've been trying to get xpra to run on OS X for the last few days to connect to my Ubuntu server. Note that there's a GUI for it called shifter, but that (at least on OS X) is still far too buggy.

    For those who don't know what xpra is, if you know what screen is, it's like screen for GUI X Windows apps tunneled over ssh. You can render a remote X app locally so it's faster than sending a series of compresses screen shots (like VNC), but with xpra you can disconnect and reconnect on different computers. To get the basic functionality you can just type "ssh -X server.location" and any GUI app you open from the command line will open locally.

    I've been able to get xpra to build by doing the following:

    1. Download pari-all-0.0.6.tar.gz from the xpra site listed under upstream and untar it.
    2. Issue the following Mac Ports command (Dependencies thanks to RogBlog): sudo port install python25 python26 py26-pyrex py26-gtk xorg-libXtst py25-gobject py25-gtk py25-nose py26-nose xorg-libXdamage xorg-libXcomposite xorg-libXtst xorg-libXfixes
    3. In the upstream list of v0.0.06 patches (NOT 0.0.8pre!) on the xpra site listed above, download mswindows-conditional-pyrex.patch.
    4. Open the patch with your favorite text editor and change the single occurrence of "win" in it to "darwin".
    5. Apply the patch to setup.py.
    6. Run do-build in the command line.

    Now where I'm stumped: how do I run xpra? The build produces a sub directory called install/bin in which xpra is located, but when I try to run it I get the following error:

    Traceback (most recent call last):
      File "./xpra", line 4, in <module>
        import xpra.scripts.main
    ImportError: No module named xpra.scripts.main
    

    There is a file called main.py under xpra/scripts, but I don't know any python and I'm not sure if this is what it's looking for, and what to do with it even if it is.

    My goal is to set up xpra so I can install it into /usr/bin (or some other common path for executables) and execute it whenever I please. What do I do next?

  • Mark Fisher
    Mark Fisher over 9 years
    sadly, this has stopped working. I've raised an issue on github.com/ska-sa/homebrew-tap/issues/12 - looks like the src-file the brew relied on has been removed with the version bump and rename of the package from xpra to winswitch
  • Baptiste Goudey
    Baptiste Goudey over 7 years
    curl: (22) The requested URL returned error: 404 Not Found Error: Failed to download resource "xpra--cython" Download failed: cython.org/release/Cython-0.22.tar.gz
  • Baptiste Goudey
    Baptiste Goudey over 7 years
    Fixed the above error in my fork: github.com/victor-ono/homebrew-xpra
  • Andy
    Andy over 6 years
    Quick note that this version doesn't include the server, just the client.