mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-23 12:10:06 +02:00
libdvdnav: added a recipe for version 5.0.1
This commit is contained in:
77
media-libs/libdvdnav/libdvdnav-5.0.1.recipe
Normal file
77
media-libs/libdvdnav/libdvdnav-5.0.1.recipe
Normal file
@@ -0,0 +1,77 @@
|
||||
SUMMARY="Easy use of sophisticated DVD navigation features"
|
||||
DESCRIPTION="
|
||||
libdvdnav allows easy use of sophisticated DVD navigation features such as \
|
||||
DVD menus, multiangle playback and even interactive DVD games.
|
||||
"
|
||||
HOMEPAGE="http://dvdnav.mplayerhq.hu/"
|
||||
LICENSE="GNU GPL v2"
|
||||
COPYRIGHT="2000 Rich Wareham
|
||||
2001-2004 the dvdnav project"
|
||||
SRC_URI="http://downloads.videolan.org/pub/videolan/libdvdnav/$portVersion/libdvdnav-$portVersion.tar.bz2"
|
||||
CHECKSUM_SHA256="72b1cb8266f163d4a1481b92c7b6c53e6dc9274d2a6befb08ffc351fe7a4a2a9"
|
||||
REVISION="1"
|
||||
|
||||
ARCHITECTURES="x86_gcc2 x86 x86_64"
|
||||
SECONDARY_ARCHITECTURES="x86_gcc2 x86"
|
||||
|
||||
PATCHES="libdvdnav-$portVersion.patchset"
|
||||
|
||||
PROVIDES="
|
||||
libdvdnav$secondaryArchSuffix = $portVersion
|
||||
lib:libdvdnav$secondaryArchSuffix = 4.1.2 compat >= 4
|
||||
"
|
||||
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix >= $haikuVersion
|
||||
libdvdread$secondaryArchSuffix
|
||||
# required by libdvdread
|
||||
libdvdcss$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
libdvdread${secondaryArchSuffix}_devel
|
||||
# required by libdvdread
|
||||
libdvdcss${secondaryArchSuffix}_devel
|
||||
"
|
||||
|
||||
BUILD_PREREQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel >= $haikuVersion
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:libtoolize
|
||||
cmd:aclocal
|
||||
cmd:autoconf
|
||||
cmd:autoreconf
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
autoreconf -fi
|
||||
runConfigure ./configure --enable-shared --enable-static \
|
||||
--disable-maintainer-mode
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install
|
||||
|
||||
# prepare develop/lib
|
||||
prepareInstalledDevelLibs libdvdnav
|
||||
fixPkgconfig
|
||||
|
||||
packageEntries devel \
|
||||
$developDir
|
||||
}
|
||||
|
||||
# ----- devel package -------------------------------------------------------
|
||||
|
||||
PROVIDES_devel="
|
||||
libdvdnav${secondaryArchSuffix}_devel = $portVersion
|
||||
devel:libdvdnav$secondaryArchSuffix = $portVersion
|
||||
"
|
||||
REQUIRES_devel="
|
||||
libdvdnav$secondaryArchSuffix == $portVersion base
|
||||
"
|
||||
95
media-libs/libdvdnav/patches/libdvdnav-5.0.1.patchset
Normal file
95
media-libs/libdvdnav/patches/libdvdnav-5.0.1.patchset
Normal file
@@ -0,0 +1,95 @@
|
||||
From 1312fe411468d2bf4f64afe8e318d43a195e34a6 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Wed, 3 Sep 2014 15:37:19 +0000
|
||||
Subject: haiku patch
|
||||
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 3eff01a..6b14c25 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -84,10 +84,12 @@ case $host in
|
||||
THREAD_CFLAGS="-I/usr/local/include -D_THREAD_SAFE"
|
||||
CFLAGS="$THREAD_CFLAGS $CFLAGS"
|
||||
;;
|
||||
- *mingw32* | *cygwin*)
|
||||
+ *mingw32* | *cygwin* | *haiku*)
|
||||
;;
|
||||
*android*)
|
||||
;;
|
||||
+ *haiku*)
|
||||
+ ;;
|
||||
*)
|
||||
AC_CHECK_LIB(pthread, pthread_create,
|
||||
[THREAD_LIBS="-lpthread"],
|
||||
--
|
||||
1.8.3.4
|
||||
|
||||
|
||||
From 89577dcab8e80a283ab361c137565c20009b9da1 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Wed, 3 Sep 2014 19:54:24 +0000
|
||||
Subject: gcc2 fix
|
||||
|
||||
|
||||
diff --git a/src/searching.c b/src/searching.c
|
||||
index f6e497e..993b9d0 100644
|
||||
--- a/src/searching.c
|
||||
+++ b/src/searching.c
|
||||
@@ -1147,6 +1147,8 @@ static int32_t dvdnav_find_vobu_by_tmap(dvdnav_t *this, dvd_state_t *state,
|
||||
uint64_t seek_offset = 0;
|
||||
uint32_t seek_idx = 0;
|
||||
int32_t result = 0;
|
||||
+ uint32_t seek_remainder;
|
||||
+ uint32_t seek_pct;
|
||||
dvdnav_pos_data_t *cell_bgn_lo = NULL;
|
||||
dvdnav_pos_data_t *cell_bgn_hi = NULL;
|
||||
dvdnav_pos_data_t *jump_lo = NULL;
|
||||
@@ -1172,8 +1174,8 @@ static int32_t dvdnav_find_vobu_by_tmap(dvdnav_t *this, dvd_state_t *state,
|
||||
/* calc time of jump_time relative to cell_bgn_lo */
|
||||
seek_offset = jump->time - cell_bgn_lo->time;
|
||||
seek_idx = (uint32_t)(seek_offset / args->tmap_interval);
|
||||
- uint32_t seek_remainder = seek_offset - (seek_idx * args->tmap_interval);
|
||||
- uint32_t seek_pct = (seek_remainder * 1000) / args->tmap_interval;
|
||||
+ seek_remainder = seek_offset - (seek_idx * args->tmap_interval);
|
||||
+ seek_pct = (seek_remainder * 1000) / args->tmap_interval;
|
||||
|
||||
/* get tmap entries on either side of jump_time */
|
||||
jump_lo = &(dvdnav_pos_data_t){0};
|
||||
@@ -1250,7 +1252,6 @@ static int32_t dvdnav_find_vobu_by_cell_boundaries(
|
||||
/* -1: Before. Always jump to a time that is < time_in_pts_ticks */
|
||||
dvdnav_status_t dvdnav_jump_to_sector_by_time(dvdnav_t *this,
|
||||
uint64_t time_in_pts_ticks, int32_t mode) {
|
||||
- if (mode != JUMP_MODE_TIME_DEFAULT) return DVDNAV_STATUS_ERR;
|
||||
int32_t result = DVDNAV_STATUS_ERR;
|
||||
dvd_state_t *state = NULL;
|
||||
uint32_t sector_off = 0;
|
||||
@@ -1258,6 +1259,8 @@ dvdnav_status_t dvdnav_jump_to_sector_by_time(dvdnav_t *this,
|
||||
dvdnav_cell_data_t *cell_data = NULL;
|
||||
dvdnav_jump_args_t *args = NULL;
|
||||
|
||||
+ if (mode != JUMP_MODE_TIME_DEFAULT) return DVDNAV_STATUS_ERR;
|
||||
+
|
||||
jump = &(dvdnav_pos_data_t){0};
|
||||
/* convert time to milliseconds */
|
||||
jump->time = time_in_pts_ticks / 90;
|
||||
diff --git a/src/vm/vm.c b/src/vm/vm.c
|
||||
index 7e4d594..e4e8995 100644
|
||||
--- a/src/vm/vm.c
|
||||
+++ b/src/vm/vm.c
|
||||
@@ -816,10 +816,12 @@ static int process_command(vm_t *vm, link_t link_values) {
|
||||
/* These should never be set in SystemSpace and/or MenuSpace */
|
||||
/* vm->state.TTN_REG = rsm_tt; ?? */
|
||||
/* vm->state.TT_PGCN_REG = vm->state.rsm_pgcN; ?? */
|
||||
+ {
|
||||
int i;
|
||||
for(i = 0; i < 5; i++) {
|
||||
vm->state.registers.SPRM[4 + i] = vm->state.rsm_regs[i];
|
||||
}
|
||||
+ }
|
||||
|
||||
if(link_values.data1 != 0)
|
||||
vm->state.HL_BTNN_REG = link_values.data1 << 10;
|
||||
--
|
||||
1.8.3.4
|
||||
|
||||
Reference in New Issue
Block a user