summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorWillem Mulder2020-02-22 14:37:55 +0100
committerWillem Mulder2020-02-22 14:37:55 +0100
commit30d857df90e6939f9ad27cd46edced3f890da624 (patch)
treed4ea3f216c4f403fefc90f5eafde8516e62ace2b
parent5b1022381f4939212bacd08fc1a071cb8b773497 (diff)
downloadaur-30d857df90e6939f9ad27cd46edced3f890da624.tar.gz
Update to ffmpegfs 1.10, backport PR #47
-rw-r--r--.SRCINFO10
-rw-r--r--PKGBUILD13
-rw-r--r--move-cache-to-xdg-cache-home.patch (renamed from revert-move-to-var-cache.patch)88
3 files changed, 48 insertions, 63 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 871163bee0f..6a8640c3668 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,6 +1,6 @@
pkgbase = ffmpegfs
pkgdesc = FUSE-based transcoding filesystem from many formats to MP3 or MP4 including video transcoding
- pkgver = 1.9
+ pkgver = 1.10
pkgrel = 1
url = https://nschlia.github.io/ffmpegfs/
arch = x86_64
@@ -18,10 +18,10 @@ pkgbase = ffmpegfs
depends = ffmpeg
depends = sqlite
depends = libbluray
- source = https://github.com/nschlia/ffmpegfs/releases/download/v1.9/ffmpegfs-1.9.tar.gz
- source = revert-move-to-var-cache.patch
- sha384sums = 188fb452d59359f94c689eb65de5b226c1affebeffeef37692595f187dcc306209f0b1658635741a6a372d19f9cd05ae
- sha384sums = 359b739b93d314d9d5a132a359c04c121c15225f5383cbe9570b4f7b44aaa6685fa24fb281281258e0937fff7b9ee776
+ source = https://github.com/nschlia/ffmpegfs/releases/download/v1.10/ffmpegfs-1.10.tar.gz
+ source = move-cache-to-xdg-cache-home.patch
+ sha384sums = 7d09182ae0bed45d86567a51a52038dffe1c2b69c9b5a8bb842b5bcce1cc429b92f9ed9cd694abdcce385286ae1895fc
+ sha384sums = ec9c63cf5d2d7de81a766f95aa4f1a83889b639fcc258caafbe2812091a1885b587cffc869f90d5088f532ee5a69441b
pkgname = ffmpegfs
diff --git a/PKGBUILD b/PKGBUILD
index 96c823aeb3a..1d29f7e0b16 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,6 +1,6 @@
# Maintainer: Willem Mulder <14mRh4X0r@gmail.com>
pkgname=ffmpegfs
-pkgver=1.9
+pkgver=1.10
pkgrel=1
pkgdesc="FUSE-based transcoding filesystem from many formats to MP3 or MP4 including video transcoding"
arch=('x86_64' 'i686' 'arm' 'armv6h' 'armv7h' 'aarch64') # Not arch-specific, should work on all
@@ -9,13 +9,11 @@ license=('GPL3' 'FDL1.3')
makedepends=('asciidoc' 'w3m' 'xxd')
depends=('fuse' 'ffmpeg' 'sqlite' 'libbluray')
source=("https://github.com/nschlia/ffmpegfs/releases/download/v$pkgver/ffmpegfs-$pkgver.tar.gz"
- "revert-move-to-var-cache.patch")
-sha384sums=('188fb452d59359f94c689eb65de5b226c1affebeffeef37692595f187dcc306209f0b1658635741a6a372d19f9cd05ae'
- '359b739b93d314d9d5a132a359c04c121c15225f5383cbe9570b4f7b44aaa6685fa24fb281281258e0937fff7b9ee776')
+ "move-cache-to-xdg-cache-home.patch")
prepare() {
cd "$pkgname-$pkgver"
- patch -p1 -i ../revert-move-to-var-cache.patch
+ patch -p1 -i ../move-cache-to-xdg-cache-home.patch
}
build() {
@@ -30,3 +28,8 @@ package() {
install -Dm644 README.md "$pkgdir/usr/share/doc/ffmpegfs/README.md"
}
+
+sha384sums=('7d09182ae0bed45d86567a51a52038dffe1c2b69c9b5a8bb842b5bcce1cc429b92f9ed9cd694abdcce385286ae1895fc'
+ 'a55b6baadb81bc02c332c08ba7d6410aca3f86c032348bcfc44f2f11afc91b1e9588a21217353214ff634f25ad46c0ee')
+sha384sums=('7d09182ae0bed45d86567a51a52038dffe1c2b69c9b5a8bb842b5bcce1cc429b92f9ed9cd694abdcce385286ae1895fc'
+ 'ec9c63cf5d2d7de81a766f95aa4f1a83889b639fcc258caafbe2812091a1885b587cffc869f90d5088f532ee5a69441b')
diff --git a/revert-move-to-var-cache.patch b/move-cache-to-xdg-cache-home.patch
index d27d366c208..a5aebeacf73 100644
--- a/revert-move-to-var-cache.patch
+++ b/move-cache-to-xdg-cache-home.patch
@@ -1,19 +1,8 @@
-Index: ffmpegfs-1.9/Makefile.am
-===================================================================
---- ffmpegfs-1.9.orig/Makefile.am
-+++ ffmpegfs-1.9/Makefile.am
-@@ -4,10 +4,6 @@ export WARNINGS = -Wall -Wextra -Wconver
- export AM_CFLAGS = -std=c11 $(INCLUDES) $(WARNINGS) $(OPTIMISATION) -D_GNU_SOURCE
- export AM_CXXFLAGS = -std=c++11 $(INCLUDES) $(WARNINGS) $(OPTIMISATION) -D_GNU_SOURCE
-
--export USERNAME=ffmpegfs
--export USERGROUP=ffmpegfs
--export CACHEDIR=/var/cache/ffmpegfs
--
- SUBDIRS = src test
-
- dist_man_MANS = ffmpegfs.1
-@@ -104,43 +100,4 @@ clean-local: doxy-clean
+diff --git a/Makefile.am b/Makefile.am
+index 535cbee..5d415f3 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -104,42 +104,3 @@ clean-local: doxy-clean
# Really clean up everything
wipe-all: doxy-clean distclean
rm -Rf autom4te.cache configure config aclocal.m4 Makefile.in test/Makefile.in src/Makefile.in
@@ -24,8 +13,7 @@ Index: ffmpegfs-1.9/Makefile.am
- echo "User $(USERNAME) already exists."; \
- else \
- echo "Creating user $(USERNAME)."; \
-- ls -l /etc/; \
-- useradd --system $(USERNAME); \
+- useradd -M $(USERNAME); \
- usermod -L $(USERNAME); \
- fi
-
@@ -57,68 +45,62 @@ Index: ffmpegfs-1.9/Makefile.am
- echo "Removing user $(USERNAME)."; \
- userdel $(USERNAME); \
- fi
-+
-Index: ffmpegfs-1.9/NEWS
-===================================================================
---- ffmpegfs-1.9.orig/NEWS
-+++ ffmpegfs-1.9/NEWS
-@@ -11,7 +11,6 @@ Important changes in 1.9 (2019-11-18)
- * Feature: Added optional graphviz to configure, only required for Doxygen.
- * Feature: Updated INSTALL.md with missing prerequisites. Rearranged paragraphs, mentioning building
- from git first was confusing.
--* Feature: Moved cache directory from rather unusual /tmp/ffmpegfs location to /var/cache/ffmpegfs.
- * Bugfix: Fixed several warnings if compiled for 32 bit.
- * Bugfix: Removed unused xmlint prerequisite from configure.
- * Bugfix: Video and audio was out of sync on android devices.
-Index: ffmpegfs-1.9/ffmpegfs.1.txt
-===================================================================
---- ffmpegfs-1.9.orig/ffmpegfs.1.txt
-+++ ffmpegfs-1.9/ffmpegfs.1.txt
+diff --git a/ffmpegfs.1.txt b/ffmpegfs.1.txt
+index 5989f2d..b3ac806 100644
+--- a/ffmpegfs.1.txt
++++ b/ffmpegfs.1.txt
@@ -228,7 +228,7 @@ Default: 0 (no minimum space)
*--cachepath*=DIR, *-o cachepath*=DIR::
Sets the disk cache directory to 'DIR'. Will be created if not existing. The user running ffmpegfs must have write access to the location.
+
-Default: /var/cache/ffmpegfs
-+Default: temp directory, e.g. /tmp
++Default: ${XDG_CACHE_DIR:-~/.cache}/ffmpegfs (as specified in the XDG Base Directory Specification)
*--disable_cache*, -o *disable_cache*::
Disable the cache functionality.
-Index: ffmpegfs-1.9/src/ffmpegfs.cc
-===================================================================
---- ffmpegfs-1.9.orig/src/ffmpegfs.cc
-+++ ffmpegfs-1.9/src/ffmpegfs.cc
+diff --git a/src/ffmpegfs.cc b/src/ffmpegfs.cc
+index 9746755..94a78fb 100644
+--- a/src/ffmpegfs.cc
++++ b/src/ffmpegfs.cc
@@ -113,7 +113,7 @@ FFMPEGFS_PARAMS::FFMPEGFS_PARAMS()
, m_prebuffer_size(100 /* KB */ * 1024) // default: 100 KB
, m_max_cache_size(0) // default: no limit
, m_min_diskspace(0) // default: no minimum
- , m_cachepath("") // default: /var/cache/ffmpegfs
-+ , m_cachepath("") // default: /tmp
++ , m_cachepath("") // default: $XDG_CACHE_HOME/ffmpegfs
, m_disable_cache(0) // default: enabled
, m_cache_maintenance((60*60)) // default: prune every 60 minutes
, m_prune_cache(0) // default: Do not prune cache immediately
-Index: ffmpegfs-1.9/src/ffmpegfs.h
-===================================================================
---- ffmpegfs-1.9.orig/src/ffmpegfs.h
-+++ ffmpegfs-1.9/src/ffmpegfs.h
-@@ -159,7 +159,7 @@ extern struct FFMPEGFS_PARAMS
+diff --git a/src/ffmpegfs.h b/src/ffmpegfs.h
+index 85599a1..2a6a76e 100644
+--- a/src/ffmpegfs.h
++++ b/src/ffmpegfs.h
+@@ -158,7 +158,7 @@ extern struct FFMPEGFS_PARAMS
size_t m_prebuffer_size; /**< @brief Number of bytes that will be decoded before it can be accessed */
size_t m_max_cache_size; /**< @brief Max. cache size in MB. When exceeded, oldest entries will be pruned */
size_t m_min_diskspace; /**< @brief Min. diskspace required for cache */
- std::string m_cachepath; /**< @brief Disk cache path, defaults to /var/cache */
-+ std::string m_cachepath; /**< @brief Disk cache path, defaults to /tmp */
++ std::string m_cachepath; /**< @brief Disk cache path, defaults to $XDG_CACHE_HOME */
int m_disable_cache; /**< @brief Disable cache */
time_t m_cache_maintenance; /**< @brief Prune timer interval */
int m_prune_cache; /**< @brief Prune cache immediately */
-Index: ffmpegfs-1.9/src/transcode.cc
-===================================================================
---- ffmpegfs-1.9.orig/src/transcode.cc
-+++ ffmpegfs-1.9/src/transcode.cc
-@@ -173,7 +173,7 @@ void transcoder_cache_path(std::string &
+diff --git a/src/transcode.cc b/src/transcode.cc
+index 809cb0b..b503f01 100644
+--- a/src/transcode.cc
++++ b/src/transcode.cc
+@@ -173,7 +173,14 @@ void transcoder_cache_path(std::string & path)
}
else
{
- path = "/var/cache";
-+ tempdir(path);
++ if (const char* cache_home = std::getenv("XDG_CACHE_HOME"))
++ {
++ path = cache_home;
++ }
++ else
++ {
++ expand_path(&path, "~/.cache");
++ }
}
append_sep(&path);