AcknowledgementsA starting point came fromhttps://blog.jacobstoner.com/wayweston-rdp/ Package ListAs I've experimented with various different build configurations, I'm not sure if all of these are necessary. I have both Code Ready and EPEL repos enabled. sudo yum install meson nasm dbus-devel pkg-config cmake xorg-x11-server-Xwayland libxkbcommon-devel wayland-protocols-devel wayland-devel libinput-devel libevdev-devel libdrm-devel mesa-libEGL-devel systemd-devel pam-devel libXcursor-devel lcms2-devel colord-devel mesa-libgbm-devel librsvg2-devel
BuildingHere are the basic building blocks for compilation and installation (into a local directory) #!/bin/bashcd $(dirname $0)BASE=$(readlink -f base)PREFIX=$BASE/installmkdir -p $BASE# OPENH264SRC_OPENH264=$BASE/openh264BLD_OPENH264=$BASE/build/openh264cd $BASEgit clone https://github.com/cisco/openh264mkdir -p $BLD_OPENH264cd $SRC_OPENH264meson setup -Dprefix=$PREFIX $BLD_OPENH264ninja -C $BLD_OPENH264 install# FreeRDPSRC_FREERDP=$BASE/FreeRDP-mirrorBLD_FREERDP=$BASE/build/FreeRDP-mirrorcd $BASEgit clone https://github.com/microsoft/FreeRDP-mirror.gitmkdir -p $BLD_FREERDPcmake -GNinja -DCMAKE_INSTALL_PREFIX=$PREFIX -DWITH_SERVER=ON -DWITH_X11=OFF -DWITH_OPENH264=ON -DWITH_FFMPEG=OFF -DCHANNEL_URBDRC=OFF -H$SRC_FREERDP -B$BLD_FREERDPcmake --build $BLD_FREERDP --target install# WestonSRC_WESTON=$BASE/weston-mirrorBLD_WESTON=$BASE/build/weston-mirrorcd $BASEgit clone https://github.com/microsoft/weston-mirror.gitperl -p -i -e 's/RemoteFxCodec = FALSE/RemoteFxCodec = TRUE/' $SRC_WESTON/libweston/backend-rdp/rdp.cperl -p -i -e 's/context->SetVolume/\/\/context->SetVolume/' $SRC_WESTON/compositor/rdpaudio.cmkdir -p $BLD_WESTONcd $SRC_WESTONexport PKG_CONFIG_PATH=$PREFIX/lib64/pkgconfigmeson setup -Dprefix=$PREFIX -Dpipewire=false -Dbackend-fbdev=false -Dbackend-x11=false -Dbackend-wayland=false -Dbackend-headless=false -Dbackend-drm-screencast-vaapi=false -Dbackend-drm=false -Dbackend-default=rdp -Dremoting=false $BLD_WESTONninja -C $BLD_WESTON install
Creating the TLS CertificatesAs per:https://man.archlinux.org/man/extra/weston/weston-rdp.7.en#Generating_cryptographic_material_for_the_RDP_backend $ openssl genrsa -out tls.key 2048Generating RSA private key, 2048 bit long modulus[...]$ openssl req -new -key tls.key -out tls.csr[...]$ openssl x509 -req -days 365 -signkey tls.key -in tls.csr -out tls.crt[...]
StartupGiven we haven't installed it into a known location, we'll need to update the environment #!/bin/bashBASE=/path/to/base/as/aboveexport LD_LIBRARY_PATH=$BASE/install/lib64export PATH=$BASE/install/bin:$PATHweston --backend=rdp-backend.so --xwayland --shell=rdprail-shell.so --rdp-tls-cert=tls.crt --rdp-tls-key=tls.key --logger-scopes=rdp-backend,log
Firewall ConfigurationExample firewall command sudo firewall-cmd --permanent --add-port=3389/tcpsudo firewall-cmd --reload
Example .rdp file from windowsHere's an example which runs xterm from windows. You will probably need to update "full address:s:192.168.0.1" xterm.rdp screen mode id:i:2use multimon:i:1desktopwidth:i:1920desktopheight:i:1080session bpp:i:32winposstr:s:0,1,269,155,1920,1032compression:i:1keyboardhook:i:2audiocapturemode:i:0videoplaybackmode:i:1connection type:i:7networkautodetect:i:1bandwidthautodetect:i:1displayconnectionbar:i:1enableworkspacereconnect:i:0remoteappmousemoveinject:i:1disable wallpaper:i:0allow font smoothing:i:0allow desktop composition:i:0disable full window drag:i:1disable menu anims:i:1disable themes:i:0disable cursor setting:i:0bitmapcachepersistenable:i:1full address:s:192.168.0.1audiomode:i:0redirectprinters:i:1redirectlocation:i:0redirectcomports:i:0redirectsmartcards:i:1redirectwebauthn:i:1redirectclipboard:i:1redirectposdevices:i:0autoreconnection enabled:i:1authentication level:i:2prompt for credentials:i:1negotiate security layer:i:1alternate shell:s:shell working directory:s:gatewayhostname:s:gatewayusagemethod:i:4gatewaycredentialssource:i:4gatewayprofileusagemethod:i:0promptcredentialonce:i:0gatewaybrokeringtype:i:0use redirection server name:i:0rdgiskdcproxy:i:0kdcproxyname:s:enablerdsaadauth:i:0remoteapplicationmode:i:1remoteapplicationname:s:xtermremoteapplicationprogram:s:/usr/bin/xtermremoteapplicationcmdline:s:
|