]> sigrok.org Git - sigrok-build.git/commitdiff
sigrok-appimage-create-appimage.sh: Fix hardcoded python version
authorSoeren Apel <redacted>
Sun, 25 Aug 2024 12:08:40 +0000 (14:08 +0200)
committerSoeren Apel <redacted>
Sun, 25 Aug 2024 12:08:40 +0000 (14:08 +0200)
ci/appimage/sigrok-appimage-create-appimage.sh

index 6e1fca6a6250c8e9697523990bc1433e410f8ecb..649130142f4e2a2c2cb296afd9ee06d341317ab7 100755 (executable)
@@ -41,7 +41,9 @@ cp -r "$INSTALL_DIR"/share/sigrok-firmware "$APP_DIR"/usr/share
 
 # Copy extra Python files
 mkdir -p "$APP_DIR"/usr/share/pyshared
-cp -r /usr/lib/python3.6/* "$APP_DIR"/usr/share/pyshared
+# Find local python path of the latest version, e.g. /usr/lib/python3.12
+export LOCAL_PYTHON_PATH=`find /usr/lib -maxdepth 1 -iname "python3*" | sort -V | tail -n 1`
+cp -r $LOCAL_PYTHON_PATH/* "$APP_DIR"/usr/share/pyshared
 
 # AppImage build dir
 mkdir -p appimage-build