mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-08 22:45:43 +00:00
extra/mplayer to 38542-2
This commit is contained in:
parent
e5d72ef0d3
commit
5f1138a318
3 changed files with 112 additions and 10 deletions
|
@ -1,7 +1,7 @@
|
|||
pkgbase = mplayer
|
||||
pkgdesc = Media player for Linux
|
||||
pkgver = 38448
|
||||
pkgrel = 1
|
||||
pkgver = 38542
|
||||
pkgrel = 2
|
||||
url = http://www.mplayerhq.hu/
|
||||
arch = x86_64
|
||||
license = GPL
|
||||
|
@ -72,12 +72,14 @@ pkgbase = mplayer
|
|||
makedepends = nasm
|
||||
options = !emptydirs
|
||||
options = !lto
|
||||
source = mplayer-38448::svn://svn.mplayerhq.hu/mplayer/trunk#revision=38448
|
||||
source = mplayer-38542::svn://svn.mplayerhq.hu/mplayer/trunk#revision=38542
|
||||
source = mplayer.desktop
|
||||
source = include-samba-4.0.patch
|
||||
source = ffmpeg-7.patch
|
||||
sha512sums = SKIP
|
||||
sha512sums = d3c5cbf0035279c6f307e4e225473d7b77f9b56566537a26aa694e68446b9e3240333296da627ad5af83b04cc8f476d1a3f8c05e4cf81cd6e77153feb4ed74bc
|
||||
sha512sums = 9debb8c58b996f6c716c22c86c720bf9dc49b4ee9b76c57519f791667ae1de2cc6f5add878fbf4ac02c6b6fd1865e1bcfa6105e75de4bf7ec596c338ed0cae99
|
||||
sha512sums = 93185451be01fd872c5304f2b4ac2832a91b89397f7d920759ef4681dd43977d50c0207851721d7e8ec00ff3fbef93133aa54e8f6cf3d83190f8ab331e106a16
|
||||
|
||||
pkgname = mplayer
|
||||
pkgdesc = Media player for Linux
|
||||
|
|
|
@ -8,8 +8,8 @@
|
|||
|
||||
pkgbase=mplayer
|
||||
pkgname=('mplayer' 'mencoder')
|
||||
pkgver=38448
|
||||
pkgrel=1
|
||||
pkgver=38542
|
||||
pkgrel=2
|
||||
pkgdesc='Media player for Linux'
|
||||
url='http://www.mplayerhq.hu/'
|
||||
arch=('x86_64')
|
||||
|
@ -30,21 +30,27 @@ makedepends=('xorgproto' 'libxxf86vm' 'libmad' 'libxinerama' 'libmng' 'libxss'
|
|||
options=('!emptydirs' '!lto')
|
||||
source=(${pkgbase}-${pkgver}::"svn://svn.mplayerhq.hu/mplayer/trunk#revision=${pkgver}"
|
||||
mplayer.desktop
|
||||
include-samba-4.0.patch)
|
||||
include-samba-4.0.patch
|
||||
ffmpeg-7.patch)
|
||||
sha512sums=('SKIP'
|
||||
'd3c5cbf0035279c6f307e4e225473d7b77f9b56566537a26aa694e68446b9e3240333296da627ad5af83b04cc8f476d1a3f8c05e4cf81cd6e77153feb4ed74bc'
|
||||
'9debb8c58b996f6c716c22c86c720bf9dc49b4ee9b76c57519f791667ae1de2cc6f5add878fbf4ac02c6b6fd1865e1bcfa6105e75de4bf7ec596c338ed0cae99')
|
||||
'9debb8c58b996f6c716c22c86c720bf9dc49b4ee9b76c57519f791667ae1de2cc6f5add878fbf4ac02c6b6fd1865e1bcfa6105e75de4bf7ec596c338ed0cae99'
|
||||
'93185451be01fd872c5304f2b4ac2832a91b89397f7d920759ef4681dd43977d50c0207851721d7e8ec00ff3fbef93133aa54e8f6cf3d83190f8ab331e106a16')
|
||||
|
||||
prepare() {
|
||||
cd ${pkgbase}-${pkgver}
|
||||
patch -p1 < "../include-samba-4.0.patch"
|
||||
./version.sh
|
||||
|
||||
# Fix build with ffmpeg 7, https://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/2024-April/074138.html
|
||||
patch -p0 -i ../ffmpeg-7.patch
|
||||
}
|
||||
|
||||
build() {
|
||||
cd ${pkgbase}-${pkgver}
|
||||
export LDFLAGS="${LDFLAGS/,O1/}"
|
||||
export LDFLAGS="${LDFLAGS/,--sort-common/}"
|
||||
export CFLAGS="$CFLAGS -Wno-incompatible-pointer-types -Wno-implicit-function-declaration -Wno-int-conversion"
|
||||
export LDFLAGS="${LDFLAGS/-Wl,-O1/}"
|
||||
export LDFLAGS="${LDFLAGS/-Wl,--sort-common/}"
|
||||
./configure --prefix=/usr \
|
||||
--disable-gui \
|
||||
--disable-arts \
|
||||
|
@ -56,7 +62,6 @@ build() {
|
|||
--disable-ass-internal \
|
||||
--disable-cdparanoia \
|
||||
--disable-ffmpeg_a \
|
||||
--enable-xvmc \
|
||||
--enable-radio \
|
||||
--enable-radio-capture \
|
||||
--enable-smb \
|
||||
|
|
95
extra/mplayer/ffmpeg-7.patch
Normal file
95
extra/mplayer/ffmpeg-7.patch
Normal file
|
@ -0,0 +1,95 @@
|
|||
Index: libao2/ao_jack.c
|
||||
===================================================================
|
||||
--- libao2/ao_jack.c (revisión: 38542)
|
||||
+++ libao2/ao_jack.c (copia de trabajo)
|
||||
@@ -71,7 +71,7 @@
|
||||
#define BUFFSIZE (NUM_CHUNKS * CHUNK_SIZE)
|
||||
|
||||
//! buffer for audio data
|
||||
-static AVFifoBuffer *buffer;
|
||||
+static AVFifo *buffer;
|
||||
|
||||
/**
|
||||
* \brief insert len bytes into buffer
|
||||
@@ -82,9 +82,10 @@
|
||||
* If there is not enough room, the buffer is filled up
|
||||
*/
|
||||
static int write_buffer(unsigned char* data, int len) {
|
||||
- int free = av_fifo_space(buffer);
|
||||
+ int free = av_fifo_can_write(buffer);
|
||||
if (len > free) len = free;
|
||||
- return av_fifo_generic_write(buffer, data, len, NULL);
|
||||
+ av_fifo_write(buffer, data, len);
|
||||
+ return len;
|
||||
}
|
||||
|
||||
static void silence(float **bufs, int cnt, int num_bufs);
|
||||
@@ -125,12 +126,12 @@
|
||||
*/
|
||||
static int read_buffer(float **bufs, int cnt, int num_bufs) {
|
||||
struct deinterleave di = {bufs, num_bufs, 0, 0};
|
||||
- int buffered = av_fifo_size(buffer);
|
||||
+ int buffered = av_fifo_can_read(buffer);
|
||||
if (cnt * sizeof(float) * num_bufs > buffered) {
|
||||
silence(bufs, cnt, num_bufs);
|
||||
cnt = buffered / sizeof(float) / num_bufs;
|
||||
}
|
||||
- av_fifo_generic_read(buffer, &di, cnt * num_bufs * sizeof(float), deinterleave);
|
||||
+ av_fifo_read(buffer, &di, cnt * num_bufs * sizeof(float));
|
||||
return cnt;
|
||||
}
|
||||
|
||||
@@ -242,7 +243,7 @@
|
||||
mp_msg(MSGT_AO, MSGL_FATAL, "[JACK] cannot open server\n");
|
||||
goto err_out;
|
||||
}
|
||||
- buffer = av_fifo_alloc(BUFFSIZE);
|
||||
+ buffer = av_fifo_alloc2(BUFFSIZE, 1, 0);
|
||||
jack_set_process_callback(client, outputaudio, 0);
|
||||
|
||||
// list matching ports if connections should be made
|
||||
@@ -302,7 +303,7 @@
|
||||
free(client_name);
|
||||
if (client)
|
||||
jack_client_close(client);
|
||||
- av_fifo_free(buffer);
|
||||
+ av_fifo_freep2(&buffer);
|
||||
buffer = NULL;
|
||||
return 0;
|
||||
}
|
||||
@@ -315,7 +316,7 @@
|
||||
reset();
|
||||
usec_sleep(100 * 1000);
|
||||
jack_client_close(client);
|
||||
- av_fifo_free(buffer);
|
||||
+ av_fifo_freep2(&buffer);
|
||||
buffer = NULL;
|
||||
}
|
||||
|
||||
@@ -324,7 +325,7 @@
|
||||
*/
|
||||
static void reset(void) {
|
||||
paused = 1;
|
||||
- av_fifo_reset(buffer);
|
||||
+ av_fifo_reset2(buffer);
|
||||
paused = 0;
|
||||
}
|
||||
|
||||
@@ -343,7 +344,7 @@
|
||||
}
|
||||
|
||||
static int get_space(void) {
|
||||
- return av_fifo_space(buffer);
|
||||
+ return av_fifo_can_write(buffer);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -357,7 +358,7 @@
|
||||
}
|
||||
|
||||
static float get_delay(void) {
|
||||
- int buffered = av_fifo_size(buffer); // could be less
|
||||
+ int buffered = av_fifo_can_read(buffer); // could be less
|
||||
float in_jack = jack_latency;
|
||||
if (estimate && callback_interval > 0) {
|
||||
float elapsed = (float)GetTimer() / 1000000.0 - callback_time;
|
Loading…
Reference in a new issue