Skip to content
Snippets Groups Projects
Commit fecd9e23 authored by Jan Alexander Steffens (heftig)'s avatar Jan Alexander Steffens (heftig)
Browse files

community2extra: Moving libquvi-scripts from community to extra

parents
No related branches found
Tags 0.4.8-2
No related merge requests found
From 5b1c00284e1bae3069b51d07d84d3a096ca6bfcf Mon Sep 17 00:00:00 2001
From: Martin Herkt <lachs0r@hong-mailing.de>
Date: Thu, 27 Sep 2012 13:45:27 +0200
Subject: [PATCH] Fix youtube.lua
YouTube has added a new "signature" parameter to their playback URLs.
Append this parameter to the URL if url_encoded_fmt_stream_map contains
"sig".
---
share/lua/website/youtube.lua | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/share/lua/website/youtube.lua b/share/lua/website/youtube.lua
index e7fc60c..39cc31d 100644
--- a/share/lua/website/youtube.lua
+++ b/share/lua/website/youtube.lua
@@ -125,7 +125,11 @@ function YouTube.iter_formats(config, U)
for f in fmt_stream_map:gmatch('([^,]*),') do
local d = U.decode(f)
if d['itag'] and d['url'] then
- urls[U.unescape(d['itag'])] = U.unescape(d['url'])
+ local uurl = U.unescape(d['url'])
+ if d['sig'] then
+ uurl = uurl .. "&signature=" .. U.unescape(d['sig'])
+ end
+ urls[U.unescape(d['itag'])] = uurl
end
end
--
1.7.12.1
PKGBUILD 0 → 100644
# Maintainer: Lukas Fleischer <archlinux at cryptocrack dot de>
pkgname=libquvi-scripts
pkgver=0.4.8
pkgrel=2
pkgdesc='Library for parsing video download links.'
arch=('any')
url='http://quvi.sourceforge.net/'
license=('LGPL')
depends=('curl' 'lua')
options=('!libtool')
source=("http://downloads.sourceforge.net/sourceforge/quvi/${pkgname}-${pkgver}.tar.gz"{,.sig}
0001-Fix-youtube.lua.patch)
md5sums=('9a11cfcb474266b377ec41a5a502ffe0'
'7126dbed0e493135089018775b1652a6'
'0cdcda0fed2128c78c0c3ac784b94243')
build() {
cd "${pkgname}-${pkgver}"
patch -Np1 -i ../0001-Fix-youtube.lua.patch
./configure --prefix=/usr
make
}
package() {
cd "${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment