Compiling a version of qt that runs on macos but uses X11 instead of the native macos gui.
-
I would like a version of qt --- particularly qt5 --- that runs on macos, but uses X11 for display.
The reason is so that i can run 'ssh -X' from my ubuntu machine to my macos machine, and then run an application compiled against this special version of qt, and the application would then display on the ubuntu machine (over ssh).
Solutions such as using VNC or other screen sharing will not work for me, because the macos machine may be in use by somebody else at the same time.
The macos machine is running catalina (10.15.7) and the ubuntu machine is running 20.04.
(So, the question is: how to run configure to produce such a thing, what arguments to use to specify the X11 includes and X11 libraries, and what arguments to use to tell configure that regardless of what it thinks the host architecture is, i don't want it to create a native macos gui, but rather an X11 gui.)
-
AFAIK the last support for x11 on macOS was with Qt4 and it was removed with the binning of Qt5.
The only feasible way is for you to write and maintain your own platform plugin and at that point a 2nd, as in your own, macOS pc/laptop is probably the better investment of time and money -
I would like a version of qt --- particularly qt5 --- that runs on macos, but uses X11 for display.
The reason is so that i can run 'ssh -X' from my ubuntu machine to my macos machine, and then run an application compiled against this special version of qt, and the application would then display on the ubuntu machine (over ssh).
Solutions such as using VNC or other screen sharing will not work for me, because the macos machine may be in use by somebody else at the same time.
The macos machine is running catalina (10.15.7) and the ubuntu machine is running 20.04.
(So, the question is: how to run configure to produce such a thing, what arguments to use to specify the X11 includes and X11 libraries, and what arguments to use to tell configure that regardless of what it thinks the host architecture is, i don't want it to create a native macos gui, but rather an X11 gui.)
@dan-ca An alternative approach is to used the built-in VNC platform plugin (triggered by starting the application with the
-platform vncargument). It works by starting a private VNC server that serves just the app window, so somewhat similar to (but more limited than) X11 forwarding. IIRC it isn't built by default on macOS but should be possible to add it to a build.Though I second the point of getting a physical Mac, it is really the path of least resistance... A M2 Mac Mini is reasonably cheap and is a great extra machine to have even if you daily drive Linux.
-
At a glance, it's not obvious that the xcb QPA (qtbase/src/plugins/platforms/xcb/xcb.pro) plugin won't work with recent macOS if the requisite supporting libraries and headers are present. Homebrew lists a few potential matches for "brew search xcb", including "libxcb".