Browse Source

Add sub.dirs of lib, ?-linux-gnu

Joachim M. Giæver 3 years ago
parent
commit
d6b9dd6329
1 changed files with 9 additions and 0 deletions
  1. 9 0
      src/config/plug-bin

+ 9 - 0
src/config/plug-bin

@@ -12,4 +12,13 @@ if [ $? -eq 0 ]; then
     fi
 fi
 
+# Add sub directories of lib-path; (e.g pulseaudio)
+readarray -d '' PATHS < <(find "$SNAP/usr/lib/$(uname -m)-linux-gnu" -maxdepth 1 -type d -print0)
+
+if [ "${#PATHS[@]}" -ne 0 ]; then
+    for TPATH in "${PATHS[@]}"; do
+        PATH="${PATH}:${TPATH}"
+    done
+fi
+
 eval $@