Initial commit

This commit is contained in:
Christian Schendel 2025-09-03 21:53:56 +02:00
commit 09f2061909
Signed by: doppelhelix
GPG key ID: 5874D2437CD5BBB3
13 changed files with 348 additions and 0 deletions

64
.SRCINFO Normal file
View file

@ -0,0 +1,64 @@
pkgbase = thinlinc-server
pkgdesc = Cendio ThinLinc Linux remote desktop server
pkgver = 4.19.0
pkgrel = 1
url = https://www.cendio.com
install = thinlinc-server.install
arch = x86_64
license = LicenseRef-EULA.txt
license = LicenseRef-open_source_licenses.txt
depends = bash
depends = cron
depends = dbus
depends = gdk-pixbuf2
depends = ghostscript
depends = glib2
depends = glibc
depends = gtk3
depends = hicolor-icon-theme
depends = iproute2
depends = libasyncns
depends = libcap
depends = libsndfile
depends = libx11
depends = libxcb
depends = libxcrypt-compat
depends = nspr
depends = nss
depends = pam
depends = pango
depends = procps-ng
depends = python
depends = python-cairo
depends = python-gobject
depends = python-gssapi
depends = python-numpy
depends = python-six
depends = rtkit
depends = smtp-forwarder
depends = systemd
depends = xdg-utils
depends = xorg-xauth
depends = xorg-xhost
depends = zlib
optdepends = apache: Web integration
optdepends = mod_nss: Web integration
optdepends = python-markdown: Web integration
optdepends = python-pygments: Web integration
optdepends = nfs-utils: Local drive redirection
optdepends = python-ldap: LDAP integration tools
optdepends = libpulse: Audio redirection
optdepends = libcups: Printer redirection
optdepends = krb5: Kerberos integration
source = tl-4.19.0-server.zip::https://www.cendio.com/downloads/server/tl-4.19.0-server.zip
source = tlwebaccess.service
source = tlwebadm.service
source = vsmagent.service
source = vsmserver.service
b2sums = dc8594c54300aa1b29103fce264f0005d5699bcf03e4868514e5e406ecd4a65b2ca5175d6a94ecf4a25f05d8311e97abef3d0e4b4097456892641bcc3a025d16
b2sums = deb7b7788de55b385a5ed993d8072d07bf2af7cab917373c298f3058ef09691d22a67d4fe54d6a1f80a35295be1114e8e68e4c24fcf14e1904fd6ce8ab3af01c
b2sums = 8fd739a5ad3a4222eb62a7114e8d2c337c0b18b124707e1dd8cd2f8f7f916829c23522df11f6796001fde9ee3e3b4384378291a5ea3bdc71300dd9568dc333b1
b2sums = 6824c431018f6f973f8bbd65650d703a4ea3e386b9bce5dcf32d1250955d41317326a6b9eb0dd0c524068d3287c482f558d3b7c5019b945695df0a124c6e878c
b2sums = 71ab781cd45311e8289b8a3f4953fd9d70250a3b89d0d3086c4bd7d08733e2c2e856982f30f63598b03d835e9eea55084b4ef2519ad217b17e5eaf40c68ea312
pkgname = thinlinc-server

18
.gitignore vendored Normal file
View file

@ -0,0 +1,18 @@
# Ignore everything
*
# But not these files...
!.gitignore
!PKGBUILD
!.SRCINFO
!LICENSE
!chroot-build
!.nvchecker.toml
!/keys
!/keys/pgp
!/keys/pgp/*.asc
!/LICENSES
!/LICENSES/*.txt
!REUSE.toml
!*.install
!*.service

5
.nvchecker.toml Normal file
View file

@ -0,0 +1,5 @@
[thinlinc-server-bin]
source = "regex"
regex = "https://www.cendio.com/downloads/server/tl-(\\d+\\.\\d+\\.\\d+)-server.zip"
url = "https://www.cendio.com/downloads"

12
LICENSE Normal file
View file

@ -0,0 +1,12 @@
Copyright Arch Linux Contributors
Permission to use, copy, modify, and/or distribute this software for
any purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED “AS IS” AND THE AUTHOR DISCLAIMS ALL
WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE
FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY
DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

1
LICENSES/0BSD.txt Symbolic link
View file

@ -0,0 +1 @@
../LICENSE

111
PKGBUILD Normal file
View file

@ -0,0 +1,111 @@
# Maintainer: Christian Schendel <doppelhelix@gmail.com>
# Contributor: Cebtenzzre <cebtenzzre (at) gmail (dot) com>
pkgname=thinlinc-server-bin
pkgver=4.19.0
pkgrel=1
pkgdesc="Cendio ThinLinc Linux remote desktop server"
url="https://www.cendio.com"
install="$pkgname.install"
arch=('x86_64')
license=(
LicenseRef-EULA.txt
LicenseRef-open_source_licenses.txt
)
depends=(
bash
cron
dbus
gdk-pixbuf2
ghostscript
glib2
glibc
gtk3
hicolor-icon-theme
iproute2
libasyncns
libcap
libsndfile
libx11
libxcb
libxcrypt-compat
nspr
nss
pam
pango
procps-ng
python
python-cairo
python-gobject
python-gssapi
python-numpy
python-six
rtkit
smtp-forwarder
systemd
xdg-utils
xorg-xauth
xorg-xhost
zlib
)
optdepends=(
"apache: Web integration"
"mod_nss: Web integration"
"python-markdown: Web integration"
"python-pygments: Web integration"
"nfs-utils: Local drive redirection"
"python-ldap: LDAP integration tools"
"libpulse: Audio redirection"
"libcups: Printer redirection"
"krb5: Kerberos integration"
)
_archive_name="tl-$pkgver-server"
_extract_dir="extract"
source=(
"$_archive_name.zip::$url/downloads/server/tl-$pkgver-server.zip"
tlwebaccess.service
tlwebadm.service
vsmagent.service
vsmserver.service
)
b2sums=('dc8594c54300aa1b29103fce264f0005d5699bcf03e4868514e5e406ecd4a65b2ca5175d6a94ecf4a25f05d8311e97abef3d0e4b4097456892641bcc3a025d16'
'deb7b7788de55b385a5ed993d8072d07bf2af7cab917373c298f3058ef09691d22a67d4fe54d6a1f80a35295be1114e8e68e4c24fcf14e1904fd6ce8ab3af01c'
'8fd739a5ad3a4222eb62a7114e8d2c337c0b18b124707e1dd8cd2f8f7f916829c23522df11f6796001fde9ee3e3b4384378291a5ea3bdc71300dd9568dc333b1'
'6824c431018f6f973f8bbd65650d703a4ea3e386b9bce5dcf32d1250955d41317326a6b9eb0dd0c524068d3287c482f558d3b7c5019b945695df0a124c6e878c'
'71ab781cd45311e8289b8a3f4953fd9d70250a3b89d0d3086c4bd7d08733e2c2e856982f30f63598b03d835e9eea55084b4ef2519ad217b17e5eaf40c68ea312')
prepare() {
cd "$srcdir/$_archive_name/packages"
mkdir -p "$_extract_dir"
for deb in *amd64*deb; do
bsdtar -C "$_extract_dir" -xf "$deb"
done
}
package() {
cd "$srcdir/$_archive_name/packages/$_extract_dir"
bsdtar -xf data.tar.gz -C "$pkgdir/"
rm -Rf "$pkgdir/usr/lib32/.build-id"
ln -s "/opt/thinlinc/modules" "$pkgdir/usr/lib/$pkgname"
cd "$srcdir"
install -Dm0644 -t "$pkgdir/usr/lib/systemd/system" \
tlwebaccess.service \
tlwebadm.service \
vsmagent.service \
vsmserver.service
cd "$srcdir/$_archive_name"
install -dm0775 "$pkgdir/usr/share/doc/$pkgname"
cp -aR doc/* "$pkgdir/usr/share/doc/$pkgname"
install -Dm0644 -t "$pkgdir/usr/share/doc/$pkgname" \
README.txt \
THINLINC-GPG-KEY
install -Dm0644 -t "$pkgdir/usr/share/licenses/$pkgname" \
open_source_licenses.txt \
EULA.txt
}
# vim: set ft=sh ts=4 sw=4 et:

23
REUSE.toml Normal file
View file

@ -0,0 +1,23 @@
version = 1
[[annotations]]
path = [
"PKGBUILD",
"README.md",
"keys/**",
".SRCINFO",
".nvchecker.toml",
".gitignore",
"*.install",
"*.sysusers",
"*.tmpfiles",
"*.logrotate",
"*.pam",
"*.service",
"*.socket",
"*.timer",
"*.desktop",
"*.hook",
]
SPDX-FileCopyrightText = "Arch Linux contributors"
SPDX-License-Identifier = "0BSD"

65
chroot-build Executable file
View file

@ -0,0 +1,65 @@
#!/bin/bash
# SPDX-FileCopyrightText: Christian Schendel
# SPDX-License-Identifier: 0BSD
set -euo pipefail
use_tmpfs=true
CHROOT="/tmp/mkarchroot"
check_available_ram() {
if [ "$(awk '/^MemAvailable:/ { print $2; }' /proc/meminfo)" -lt 50000 ]; then
use_tmpfs=false
fi
}
create_chroot_directory() {
if [ $use_tmpfs ]; then
sudo mount --mkdir -t tmpfs -o defaults,size=20G tmpfs $CHROOT
else
sudo mkdir -p "$CHROOT"
fi
}
create_chroot_environment() {
if [[ ! -d "$CHROOT/root" ]]; then
mkarchroot -M ~/.config/pacman/makepkg.conf "$CHROOT/root" base-devel
fi
}
build_package(){
arch-nspawn "$CHROOT/root" pacman -Syu
if makechrootpkg -c -r "$CHROOT" -- -Asf . ; then
makepkg --printsrcinfo >.SRCINFO
else
delete_chroot_environment && echo -e "\n\e[1;31m==> BUILD FAILED: \e[1;37m$CHROOT removed\e[0m " && exit 1
fi
}
sign_package(){
PACKAGE="$(makepkg --packagelist)"
gpg --use-agent --output "$PACKAGE.sig" --detach-sign "$PACKAGE"
}
delete_chroot_environment() {
if [ "$(stat -f --format=%T "$CHROOT")" == "btrfs" ]; then
{
sudo btrfs subvolume delete "$CHROOT/root/var/lib/portables"
sudo btrfs subvolume delete "$CHROOT/root/var/lib/machines"
sudo btrfs subvolume delete "$CHROOT/root"
sudo rm -Rf $CHROOT
} >>/dev/null 2>&1
elif [ "$(stat -f --format=%T "$CHROOT")" == "tmpfs" ]; then
sudo umount -f $CHROOT
fi
sudo rm -Rf $CHROOT
}
check_available_ram
create_chroot_directory
create_chroot_environment
build_package
sign_package
delete_chroot_environment
# vim: set ts=4 sw=4 et:

9
thinlinc-server.install Normal file
View file

@ -0,0 +1,9 @@
post_install()
{
/opt/thinlinc/sbin/tl-setup
}
post_upgrade()
{
/opt/thinlinc/sbin/tl-setup
}

10
tlwebaccess.service Executable file
View file

@ -0,0 +1,10 @@
[Unit]
Description=ThinLinc Web Access
[Service]
Type=simple
PIDFile=/run/tlwebaccess.pid
ExecStart=/opt/thinlinc/sbin/tlwebaccess
[Install]
WantedBy=multi-user.target

10
tlwebadm.service Executable file
View file

@ -0,0 +1,10 @@
[Unit]
Description=ThinLinc Web Administration
[Service]
Type=simple
PIDFile=/run/tlwebadm.pid
ExecStart=/opt/thinlinc/sbin/tlwebadm
[Install]
WantedBy=multi-user.target

10
vsmagent.service Executable file
View file

@ -0,0 +1,10 @@
[Unit]
Description=ThinLinc vsmagent
[Service]
Type=simple
PIDFile=/run/vsmagent.pid
ExecStart=/opt/thinlinc/sbin/vsmagent
[Install]
WantedBy=multi-user.target

10
vsmserver.service Executable file
View file

@ -0,0 +1,10 @@
[Unit]
Description=ThinLinc vsmserver
[Service]
Type=simple
PIDFile=/run/vsmserver.pid
ExecStart=/opt/thinlinc/sbin/vsmserver
[Install]
WantedBy=multi-user.target