05-07-2021, 08:41 AM
(This post was last modified: 05-07-2021, 02:31 PM by Zebulon Walton.)
I just booted up on a mobian SD card for test purposes and built wayvnc from source using the script from the link I posted above. It works!
A few notes...
I built the program in /usr/src/wayvnc. The resulting executable is /usr/src/wayvnc/build/wayvnc. After copying this to /usr/local/bin I found that running "wayvnc" would result in missing libraries. It turns out there are libraries under build that are needed. So to do the complete job of copying wayvnc to /usr/local/bin do the following:
EDIT: I realize now I probably should have copied the libraries to /usr/local/lib instead of /usr/lib, the former being more appropriate for software installed outside the apt system. Not a big deal since it's just a handful of files but maybe I'll move them next time I boot up the Pinephone.
After doing this, everything needed to run wayvnc is in your search path. I also found that simply running wayvnc with no options didn't seem to work and found that by default it only listens to 127.0.0.1. The man page for wayvnc can be found here:
https://www.mankier.com/1/wayvnc
There are a number of options but I just used the following so it would listen to any address on port 5900:
There are also options to add authentication and encryption and to use a config file but I haven't had time to try those out. (Might not bother since I'd only be using this on my home LAN.) More informaton here:
https://github.com/any1/wayvnc
So now I need to just set up an easy way to launch it from the Pinephone screen.
For reference, here is the build script, it does everything and took around 10 or 15 minutes to run (I didn't time it exactly).
A few notes...
I built the program in /usr/src/wayvnc. The resulting executable is /usr/src/wayvnc/build/wayvnc. After copying this to /usr/local/bin I found that running "wayvnc" would result in missing libraries. It turns out there are libraries under build that are needed. So to do the complete job of copying wayvnc to /usr/local/bin do the following:
Code:
sudo -i
cd /usr/src/wayvnc/build
cp wayvnc /usr/local/bin
cd subprojects/neatvnc
cp -a * /usr/lib
cd ../aml
cp -a * /usr/lib
EDIT: I realize now I probably should have copied the libraries to /usr/local/lib instead of /usr/lib, the former being more appropriate for software installed outside the apt system. Not a big deal since it's just a handful of files but maybe I'll move them next time I boot up the Pinephone.
After doing this, everything needed to run wayvnc is in your search path. I also found that simply running wayvnc with no options didn't seem to work and found that by default it only listens to 127.0.0.1. The man page for wayvnc can be found here:
https://www.mankier.com/1/wayvnc
There are a number of options but I just used the following so it would listen to any address on port 5900:
Code:
wayvnc 0.0.0.0 5900
There are also options to add authentication and encryption and to use a config file but I haven't had time to try those out. (Might not bother since I'd only be using this on my home LAN.) More informaton here:
https://github.com/any1/wayvnc
So now I need to just set up an easy way to launch it from the Pinephone screen.
For reference, here is the build script, it does everything and took around 10 or 15 minutes to run (I didn't time it exactly).
Code:
#!/bin/bash
# Install dependencies
DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true apt-get install -y \
build-essential make cmake autoconf git ninja-build meson scdoc pkg-config \
zlib1g-dev libpixman-1-dev libturbojpeg0-dev libgbm-dev \
libgnutls28-dev \
libdrm-dev libdrm-common libxkbcommon-dev libxkbcommon-tools libxkbcommon0 \
wayland-protocols waylandpp-dev wayland-scanner++ libwayland-dev
set -xe
# Build, copied straight from README
git clone https://github.com/any1/wayvnc.git
git clone https://github.com/any1/neatvnc.git
git clone https://github.com/any1/aml.git
mkdir wayvnc/subprojects
cd wayvnc/subprojects
ln -s ../../neatvnc .
ln -s ../../aml .
cd -
mkdir neatvnc/subprojects
cd neatvnc/subprojects
ln -s ../../aml .
cd -
cd wayvnc
meson build
ninja -C build