libfuse2 791 B

123456789101112131415161718192021
  1. #!/bin/sh
  2. LIB=libfuse2
  3. ARCH=$(uname -m)
  4. # CREATE DIRECTORIES AND ADD REMOVER
  5. [ -n "$LIB" ] && mkdir -p "/opt/$LIB/tmp" && cd "/opt/$LIB/tmp" || exit 1
  6. printf "#!/bin/sh\nset -e\nsudo rm -f /usr/local/lib/libfuse*\nrm -R -f /opt/$LIB" > ../remove
  7. chmod a+x ../remove || exit 1
  8. # DOWNLOAD AND PREPARE THE LIBRARY
  9. LIBFUSE2_DEB=$(curl -Ls http://ftp.debian.org/debian/pool/main/f/fuse/ | grep -Po '(?<=href=")[^"]*' | sort | grep -v exp | grep arm64 | grep "libfuse2_" | tail -1)
  10. wget http://ftp.debian.org/debian/pool/main/f/fuse/"$LIBFUSE2_DEB" || exit 1
  11. ar x ./*.deb && tar fx ./data.tar.xz || exit 1
  12. cd .. || exit 1
  13. sudo mkdir -p /usr/local/lib || exit 1
  14. sudo mv ./tmp/lib/*/libfuse* /usr/local/lib/ && rm -R -f ./tmp || exit 1
  15. # CONFIGURE DYNAMIC LINKER RUN-TIME BINDINGS
  16. sudo ldconfig