Skip to content

Building on OSX (not official)

metalefty edited this page May 31, 2019 · 15 revisions

Disclaimer

xrdp on macOS is supported so far, but we welcome your contributions and volunteers. This document is brought by contributors. Feel free to edit this document but we xrdp team are not involved xrdp on macOS.

To whom want to use xrdp on macOS, SHARE YOUR KNOWLEDGE WITH EACH OTHER.

Building xrdp on OSX

Work in progress.

Since Mac OS 10.10, the OpenSSL headers are not included with the Xcode command line tools. The libraries are available, but they are obsolete (0.9.8). Linking xrdp against those old libraries will fail. You'll need OpenSSL from MacPorts or Homebrew.

Prerequisites

  • Install Xcode command line tools: xcode-select --install
  • Install Homebrew: http://brew.sh/
  • Install OpenSSL from Homebrew: brew install openssl
  • Install Automake + Autoconf: brew install automake
  • Instal Libtool: brew install libtool
  • Install pkgconfig: brew install pkgconfig
  • Install nasm: brew install nasm (needed by librfxcodec)
  • Install XQuartz: https://www.xquartz.org/

Build xrdp

Get the release tarball xrdp-0.9.1.tar.gz and unpack it.

./bootstrap
./configure PKG_CONFIG_PATH=/usr/local/opt/openssl/lib/pkgconfig
make
sudo make install

Build xorgxrdp

Get the release tarball xorgrdp-0.2.0.tar.gz and unpack it.

./bootstrap
./configure PKG_CONFIG_PATH=/opt/X11/lib/pkgconfig
make
sudo make install

Ok, whats next?

  • The remaining work is to be able to start X with the xrdpxorg module. This is the actual stopper.

  • service is in ...

❯ which xrdp
/usr/local/sbin/xrdp
  • a launchDaemon will be responsible to start the service (not needed for the moment)
  • can run sudo /usr/local/sbin/xrdp and connect via client.. but produces black screen why?

Common Troubleshooting Notes

Unknown Type Error

Error: Compiling xrdp fails and the console spits out a bunch of unknown type errors

Example: /usr/include/sys/resource.h:198:2: error: unknown type name 'uint64_t' uint64_t ri_system_time; ^

Fix: The local libraries in /usr/local/include directory are outdated despite updated libraries being installed on the system as part of the OSX commandline tools. As a workaround to tell g++/clang to ignore the outdated libaries in this directory, change the directory name:

# mv /usr/local/include /usr/local/include_old

Make sure you re-run the configuration generation before compiling again:

./bootstrap
./configure PKG_CONFIG_PATH=/usr/local/opt/openssl/lib/pkgconfig

Tested Versions: MacOS 10.14.3 with XRDP v0.9.9

Clone this wiki locally