Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3rd party packages #633

Open
JollyDandy2021 opened this issue Feb 22, 2021 · 28 comments
Open

3rd party packages #633

JollyDandy2021 opened this issue Feb 22, 2021 · 28 comments

Comments

@JollyDandy2021
Copy link

I've been trying to rack my brain to figure out how to install 3rd party packages that don't come standard with thinstation but am at a complete loss.

The app I'm trying to get setup is Zoom. I downloaded the other os version from their website and looks at the template package listed in thinstaiton. There are a lot of executable files that I really don't know what to do with? I saw other posts around that mentioned installing it first in the devstation then use scripts in the template??

Any help you could provide would be awesome! :)

@Doncuppjr
Copy link
Collaborator

It really depends on the complexity of the package, as to how to approach it. The first port of call is crux.nu, then archlinux.org, then AUR. If you can find a port of the package, you can usually modify it to work with ThinStation. Once you have the port compiling and installing, you can mkrepackage the port, and it will turn into a package.

More complicated 3rd party apps like VMView and Citrix Webspace use a sorta of doghouse to get them integrated. We build a container and let the installer do whatever it wants, then we dissolve the container.

AUR has a zoom port.

@JollyDandy2021
Copy link
Author

JollyDandy2021 commented Feb 22, 2021 via email

@Doncuppjr
Copy link
Collaborator

Doncuppjr commented Feb 22, 2021 via email

@UTSBen
Copy link

UTSBen commented Feb 24, 2021

I actually have been having an issue with installing a package as well, mine has an entry in the ArchLinux AUR portal.

Following your video, The only place I think I'm stuck at is while editing the Pkgfile. It has the following references that I'm not sure how I should adjust to work with ThinStation:

  if [ "$CARCH" == "i686" ]; then
    ARCH="x86"
  elif [ "$CARCH" == "x86_64" ]; then
    ARCH="x64"
  fi

  ARCH+="-ubuntu-1604"
  
  #echo "Installing DisplayLink Manager $ARCH"
  install -D -m755 $ARCH/DisplayLinkManager $COREDIR/DisplayLinkManager

The package in question is DisplayLink, https://aur.archlinux.org/packages/displaylink/

Thanks!

@Doncuppjr
Copy link
Collaborator

Remove the conditional and just leave ARCH=“x64”

@UTSBen
Copy link

UTSBen commented Feb 25, 2021

Hey Don, that worked out for me, but I realized it also requires the evdi package, which appears to be pretty finicky. I was able to get the package to build and install, but when checking modprobe it shows that it's not found.

modprobe: FATAL: Module evdi not found in directory /lib/modules/5.4.98TS

Through a fair amount of research and testing, I've found some patches that are supposed to get it to work on this kernel, however, the patches don't appear to be working.

I just wanted to check with you to see if maybe there was something I'm missing, or if you have any sort of experience with getting DisplayLink / evdi (used for docking stations) working with ThinStation.

@Thinstation
Copy link
Collaborator

Thinstation commented Feb 25, 2021 via email

@UTSBen
Copy link

UTSBen commented Feb 25, 2021

When updating it states "Could not find an archive." while pulling evdi

@Doncuppjr
Copy link
Collaborator

Doncuppjr commented Feb 25, 2021 via email

@UTSBen
Copy link

UTSBen commented Feb 25, 2021

So I see the evdi port getting installed now. However, when I try to re-build my displaylink port (pkgmk -d, pkgmk -i, mkrepackage) it's not showing up in my build/packages nor is it present on the ThinStation after building?

@Doncuppjr
Copy link
Collaborator

You kinda glossed over the details there, but I would guess something went wrong with mkrepackage

@UTSBen
Copy link

UTSBen commented Feb 26, 2021

My apologies. I realized yesterday in my tired state I had forgotten the packagename after mkrepackage.

The evdi package is now present, however, it's the evdi-git package, which doesn't work properly with the AUR displaylink port. The regular evdi package builds properly but doesn't actually work with kernel 5.4

I've found this patch DisplayLink/evdi#172 (comment) but using it in the Pkgfile results in several hunk failures and the build ends up failing.

The dock works properly in terms of the ethernet and usb ports, but the display still does not, which from what I understand, is due to evdi.

Any and all help you could provide would be awesome.
Thanks!

@Doncuppjr
Copy link
Collaborator

Doncuppjr commented Feb 26, 2021 via email

@UTSBen
Copy link

UTSBen commented Feb 26, 2021

It has a fair amount less than the git version.

Non-GIT

build() {
  cd "$name-$version"
  local src
  for src in "${source[@]}"; do
    src="${src%%::*}"
    src="${src##*/}"
    [[ $src = *.patch ]] || continue
    patch -Np1 < "../$src"
  done


# We only need to build the library in this step, dkms will build the module
cd "library"

make

# Predfine some target folders
SRCDIR="$PKG/usr/src/$name-$version"	# This one is needed for dkms
LIBNAME=lib$name

cd ".."

install -D -m 755 library/$LIBNAME.so $PKG/usr/lib/$LIBNAME.so

install -d $SRCDIR
install -D -m 755 module/* $SRCDIR
}

GIT

build() {
  export CFLAGS="$CFLAGS -Wno-error=format-truncation"
  git clone https://github.com/DisplayLink/evdi
  cd "${_SRC}"
  local _src
  for _src in "${source[@]%%::*}"; do
    _src="${_src##*/}"
    if [[ "${_src}" = *.patch ]]; then
      msg2 "Patch ${_src}"
      patch -Np1 -i "../${_src}"
    fi
  done

  # Fix build for kernel 5.4
  #sed -E -e 's:SUBDIRS=([^ ]+) :M=\1 &:g' -i 'module/Makefile'
  # We only need to build the library in this step, dmks will build the module
  #cd "${_SRC}/library"
  # DKMS builds are hard to debug. We build it here and throw it away.
  CFLAGS="${CFLAGS/-fno-plt/}"
for KERNELTYPE in TS; do
  export REPORT_KERNEL=${kver}$KERNELTYPE
  export KBUILD_MODPOST_WARN=1

  make
  install -Dpm755 "library/lib${name%-git}.so"* -t "${PKG}/usr/lib/"
  pushd "${PKG}/usr/lib/" > /dev/null
  local _libs=(*.so.*)
  if [ "${#_libs[@]}" -ne 1 ]; then
    set +u
    echo "Too many libs"
    false
  fi
  _libs="${_libs[0]}"
  local _libase="${_libs%.so*}.so"
  ln -sf "${_libs}" "${_libase}"
  ln -sf "${_libs}" "${_libase}.0" # bad soname
  popd > /dev/null

  for module in module/evdi.ko; do
	/usr/src/kernels/$REPORT_KERNEL/scripts/sign-file \
	sha256 \
	/etc/ssl/keys/kernel.key \
	/etc/ssl/certs/kernel.crt \
	$module
  done

  local _DKMS="${PKG}/usr/src/${name%-git}-${version}"
#  install -Dpm644 module/* -t "${_DKMS}/"
  install -Dpm644 module/*.ko -t $PKG/lib/modules/$REPORT_KERNEL/kernel/extra/
#  make -j1 -C "${_DKMS}" clean
done
}

@Doncuppjr
Copy link
Collaborator

Doncuppjr commented Feb 26, 2021 via email

@UTSBen
Copy link

UTSBen commented Feb 26, 2021

Rebuilding the Kernel and signing it is definitely out of my realm of knowledge. If you have a good guide I can follow I can try and take a stab at it

@Doncuppjr
Copy link
Collaborator

Try the latest push

@UTSBen
Copy link

UTSBen commented Mar 1, 2021

Building the evdi package fails due to a footprint mismatch.

=======> ERROR: Footprint mismatch found:
MISSING   drwxr-xr-x      root/root       lib/modules/5.4.98TS/
MISSING   drwxr-xr-x      root/root       lib/modules/5.4.98TS/kernel/
MISSING   drwxr-xr-x      root/root       lib/modules/5.4.98TS/kernel/drivers/
MISSING   drwxr-xr-x      root/root       lib/modules/5.4.98TS/kernel/drivers/gpu/
MISSING   drwxr-xr-x      root/root       lib/modules/5.4.98TS/kernel/drivers/gpu/drm/
MISSING   drwxr-xr-x      root/root       lib/modules/5.4.98TS/kernel/drivers/gpu/drm/evdi/
MISSING   -rw-r--r--      root/root       lib/modules/5.4.98TS/kernel/drivers/gpu/drm/evdi/evdi.ko
NEW       drwxr-xr-x      root/root       lib/modules/<kernel-version>/
NEW       drwxr-xr-x      root/root       lib/modules/<kernel-version>/kernel/
NEW       drwxr-xr-x      root/root       lib/modules/<kernel-version>/kernel/drivers/
NEW       drwxr-xr-x      root/root       lib/modules/<kernel-version>/kernel/drivers/gpu/
NEW       drwxr-xr-x      root/root       lib/modules/<kernel-version>/kernel/drivers/gpu/drm/
NEW       drwxr-xr-x      root/root       lib/modules/<kernel-version>/kernel/drivers/gpu/drm/evdi/
NEW       -rw-r--r--      root/root       lib/modules/<kernel-version>/kernel/drivers/gpu/drm/evdi/evdi.ko
=======> ERROR: Building '/ts/ports/kernel-modules/evdi/evdi#1.7.2-1.pkg.tar.xz' failed.

Entire log can be found here: https://pastebin.com/48hGLepQ

@Doncuppjr
Copy link
Collaborator

Doncuppjr commented Mar 1, 2021 via email

@UTSBen
Copy link

UTSBen commented Mar 1, 2021

Booting into ThinStation I can see that evdi is running. However, it's still not outputting any video.

I noticed in the Pkgfile the following section is commented out:

  # Fix build for kernel 5.4
  #sed -E -e 's:SUBDIRS=([^ ]+) :M=\1 &:g' -i 'module/Makefile'

Which is where I'd think the issue is.

@Doncuppjr
Copy link
Collaborator

Doncuppjr commented Mar 1, 2021 via email

@UTSBen
Copy link

UTSBen commented Mar 1, 2021

So for whatever reason, it's still not working. At this point I'm not 100% if its the evdi package or if its the displaylink package that's causing the issues, but I am totally stumped.

The only other thing I've noticed is it looks like the displaylink package is supposed to have a tray icon, but currently doesn't. I've tried manually executing the scripts and the executable, as well as stopped and restarting the service.

I don't know if perhaps the issue could be in XORG?

Thank you for everything so far. You've been absolutely awesome!

@Doncuppjr
Copy link
Collaborator

Which I could be of more help, but I don't have anything like that to test.

@rohrbachger
Copy link
Contributor

I'm also interested in a zoom package.
We are using thinstation already in our video conference rooms.
Tools like zoom, avaya spaces, teeams, big blue button, openmeetings work well in the browser,
but for more functionality I would prefer a zoom package.
If you have a first solution, can you upload it?

With all the home-offices I would like also to get Teamviewer running on thinstation.
I spend some time, but gave up for the moment.
Currently the guys take he company pc to their home.( with windows). We do have vmware view, so they do not need VPN.
But I would like to use thinstation on the PC´s. We made some tests with Lenovo M625p, cost < 290$.
The modell 715q was better, but is not anymore available.
Horizon View client works well on thinstation, dual screen 24"

That works in general very well, but sometimes it is helpful for analysing remote problems.
Internally we already use a while vnc, user has to accept connection.
But for external connection this is not possible.

@Thinstation
Copy link
Collaborator

I added Teams. A zoom app should be pretty easy to integrate.

@hesamkhatami
Copy link

hi
How can install RPM packag manager? I can't install it becuase can't create directory in read-only file system.
How can change read-only file system?

@Doncuppjr
Copy link
Collaborator

Doncuppjr commented Nov 6, 2022 via email

@hesamkhatami
Copy link

THX but I want install RPM in thinstation server not image.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants