Archive for Mai, 2023

Linux: dynamische Libraries kopieren (Abhängigkeiten)

Donnerstag, Mai 25th, 2023

Folgendes Script kopiert die Abhäängigkeiten eines ausführbaren Programms in den Ordner ./dynlibs. Der Name des Programms wird als Paramater übergeben.


#!/bin/bash
mkdir -p ./dynlibs
deps=$(ldd $1 | awk '{ print $3 }')
for dep in $deps
do
if [ ${#dep} -gt 0 ]
then
cp "$dep" ./dynlibs
fi
done

Das Programm kann dann über dieses Script gestartet werden:
#!/bin/sh
export LD_LIBRARY_PATH=./dynlibs
./programmname

AppImages auf Linux machen

Donnerstag, Mai 25th, 2023

https://www.howtogeek.com/827849/how-to-use-appimages-on-linux/
https://docs.appimage.org/

Das AppImage herunterladen, mit chmod +x ausführbar machen und starten.

SquashFS Filesystem als Alternative zu tar mount

Donnerstag, Mai 25th, 2023

https://en.wikipedia.org/wiki/SquashFS
https://wiki.ubuntuusers.de/SquashFS
https://www.kernel.org/doc/html/latest/filesystems/squashfs.html

Kotlin installieren mit Snap (Linux Mint)

Dienstag, Mai 23rd, 2023


# Install snap:(Linux Mint)
mv /etc/apt/preferences.d/nosnap.pref ~/nosnap.backup
apt update
apt install snapd

# Install Kotlin Compiler:
snap install –classic kotlin

Links:
https://snapcraft.io/docs/installing-snap-on-linux-mint
https://kotlinlang.org/docs/command-line.html
https://kotlinlang.org/docs/reference/coding-conventions.html

Sublime text Editor: Syntax highlighting hinzufügen

Mittwoch, Mai 17th, 2023

Beispiel Kotlin:

Gehe zu https://github.com/vkostyukov/kotlin-sublime-package,
lade und entpacke die Datei kotlin-sublime-package-master.zip

Im Sublime Text Editor:

  • Go to Preferences > Browse Packages.
  • Drag and drop the two files you downloaded, „kotlin.JSON-tmLanguage“ and „kotlin.tmLanguage“, into that folder and close the window.
  • Go to View > Syntax and select „CS“. Your code should now automatically be highlighted.