Commit 25ef68ba authored by Pavlov Konstantin's avatar Pavlov Konstantin

Contrib: update bulk patch for libdvdnav.

parent ca235087
...@@ -1173,7 +1173,7 @@ CLEAN_FILE += .dvdread ...@@ -1173,7 +1173,7 @@ CLEAN_FILE += .dvdread
ifdef SVN ifdef SVN
libdvdnav: libdvdnav:
$(SVN) co $(LIBDVDNAV_SVN) libdvdnav $(SVN) co $(LIBDVDNAV_SVN) libdvdnav
patch -p0 < Patches/libdvdnav.patch patch -d libdvdnav -p1 < Patches/libdvdnav.patch
ifdef HAVE_WIN32 ifdef HAVE_WIN32
patch -p0 < Patches/libdvdnav-win32.patch patch -p0 < Patches/libdvdnav-win32.patch
endif endif
......
diff -r -u libdvdnav-4.1.1/configure.ac libdvdnav/configure.ac diff --git a/configure.ac b/configure.ac
--- libdvdnav-4.1.1/configure.ac 2007-05-01 11:11:52.000000000 +0100 index e5ee5c4..b381093 100644
+++ libdvdnav/configure.ac 2007-11-12 11:40:20.406250000 +0000 --- a/configure.ac
@@ -130,6 +130,11 @@ +++ b/configure.ac
AC_C_BIGENDIAN @@ -161,25 +166,61 @@ AC_SUBST(THREAD_LIBS)
dnl ---------------------------------------------
+dnl Check for basic *nix fonction that we may emulate on other OS
+dnl ---------------------------------------------
+AC_CHECK_FUNCS(gettimeofday)
+
+dnl ---------------------------------------------
dnl threads
dnl ---------------------------------------------
case $host in
@@ -150,25 +155,61 @@
AC_SUBST(THREAD_CFLAGS) AC_SUBST(THREAD_CFLAGS)
dnl --------------------------------------------- dnl ---------------------------------------------
...@@ -93,29 +82,23 @@ diff -r -u libdvdnav-4.1.1/configure.ac libdvdnav/configure.ac ...@@ -93,29 +82,23 @@ diff -r -u libdvdnav-4.1.1/configure.ac libdvdnav/configure.ac
dnl --------------------------------------------- dnl ---------------------------------------------
dnl cflags dnl cflags
diff -r -u libdvdnav-4.1.1/src/dvdnav_internal.h libdvdnav/src/dvdnav_internal.h diff --git a/examples/Makefile.am b/examples/Makefile.am
--- libdvdnav-4.1.1/src/dvdnav_internal.h 2007-04-21 12:56:41.000000000 +0100 index 3cfda2f..3015dd5 100644
+++ libdvdnav/src/dvdnav_internal.h 2007-11-12 11:42:26.046875000 +0000 --- a/examples/Makefile.am
@@ -39,6 +39,7 @@ +++ b/examples/Makefile.am
#define pthread_mutex_unlock(a) LeaveCriticalSection(a) @@ -8,7 +8,7 @@ noinst_PROGRAMS = menus
#define pthread_mutex_destroy(a)
+#ifndef HAVE_GETTIMEOFDAY menus_SOURCES = menus.c
/* replacement gettimeofday implementation */ menus_LDFLAGS = -L$(top_srcdir)/src/
#include <sys/timeb.h> -menus_LDADD = $(DVDNAV_LIB)
static inline int _private_gettimeofday( struct timeval *tv, void *tz ) +menus_LDADD = $(DVDNAV_LIB) $(CSS_LIBS)
@@ -50,6 +51,8 @@
return 0;
}
#define gettimeofday(TV, TZ) _private_gettimeofday((TV), (TZ))
+#endif
+
#include <io.h> /* read() */
#define lseek64 _lseeki64
diff -r -u libdvdnav-4.1.1/src/libdvdread/dvd_input.c libdvdnav/src/libdvdread/dvd_input.c $(DVDNAV_LIB):
--- libdvdnav-4.1.1/src/libdvdread/dvd_input.c 2007-04-19 16:45:30.000000000 +0100 @cd $(top_builddir)/src/ && $(MAKE) libdvdnav.la
+++ libdvdnav/src/libdvdread/dvd_input.c 2007-11-12 11:19:57.984375000 +0000 diff --git a/src/libdvdread/dvd_input.c b/src/libdvdread/dvd_input.c
index d55aac7..63b416f 100644
--- a/src/libdvdread/dvd_input.c
+++ b/src/libdvdread/dvd_input.c
@@ -27,6 +27,11 @@ @@ -27,6 +27,11 @@
#include "dvd_reader.h" #include "dvd_reader.h"
#include "dvd_input.h" #include "dvd_input.h"
...@@ -128,10 +111,11 @@ diff -r -u libdvdnav-4.1.1/src/libdvdread/dvd_input.c libdvdnav/src/libdvdread/d ...@@ -128,10 +111,11 @@ diff -r -u libdvdnav-4.1.1/src/libdvdread/dvd_input.c libdvdnav/src/libdvdread/d
/* The function pointers that is the exported interface of this file. */ /* The function pointers that is the exported interface of this file. */
dvd_input_t (*dvdinput_open) (const char *); dvd_input_t (*dvdinput_open) (const char *);
diff -r -u libdvdnav-4.1.1/src/vm/vm.c libdvdnav/src/vm/vm.c diff --git a/src/vm/vm.c b/src/vm/vm.c
--- libdvdnav-4.1.1/src/vm/vm.c 2007-04-25 00:06:22.000000000 +0100 index 53bef88..db855c7 100644
+++ libdvdnav/src/vm/vm.c 2007-11-12 11:35:55.859375000 +0000 --- a/src/vm/vm.c
@@ -135,24 +135,25 @@ +++ b/src/vm/vm.c
@@ -134,24 +134,25 @@ static void vm_print_current_domain_state(vm_t *vm) {
} }
#endif #endif
...@@ -165,23 +149,23 @@ diff -r -u libdvdnav-4.1.1/src/vm/vm.c libdvdnav/src/vm/vm.c ...@@ -165,23 +149,23 @@ diff -r -u libdvdnav-4.1.1/src/vm/vm.c libdvdnav/src/vm/vm.c
if((data[i] == 0)) break; if((data[i] == 0)) break;
if((data[i] > 32) && (data[i] < 127)) { if((data[i] > 32) && (data[i] < 127)) {
fprintf(MSG_OUT, "%c", data[i]); fprintf(MSG_OUT, "%c", data[i]);
@@ -160,10 +161,12 @@ @@ -159,10 +160,12 @@ static void dvd_read_name(char *name, const char *device) {
fprintf(MSG_OUT, " "); fprintf(MSG_OUT, " ");
} }
} }
- strncpy(name, &data[25], 48); - strncpy(name, (char*) &data[25], 48);
- name[48] = 0; - name[48] = 0;
+ strncpy(name, &data[40], 32); + strncpy(name, (char*) &data[40], 32);
+ i=31; + i=31;
+ while( (i >= 0) && (name[i] <= ' ')) --i; + while( (i >= 0) && (name[i] <= ' ')) --i;
+ name[i+1] = '\0'; + name[i+1] = '\0';
fprintf(MSG_OUT, "\nlibdvdnav: DVD Serial Number: "); fprintf(MSG_OUT, "\nlibdvdnav: DVD Serial Number: ");
- for(i=73; i < 89; i++ ) { - for(i=73; i < 89; i++ ) {
+ for(i=813; i < 829; i++ ) { + for(i=813; i < 829; i++ ) {
if((data[i] == 0)) break; if((data[i] == 0)) break;
if((data[i] > 32) && (data[i] < 127)) { if((data[i] > 32) && (data[i] < 127)) {
fprintf(MSG_OUT, "%c", data[i]); fprintf(MSG_OUT, "%c", data[i]);
@@ -187,7 +190,7 @@ @@ -186,7 +189,7 @@ static void dvd_read_name(char *name, const char *device) {
} else { } else {
fprintf(MSG_OUT, "libdvdnav: Can't seek to block %u\n", 32 ); fprintf(MSG_OUT, "libdvdnav: Can't seek to block %u\n", 32 );
} }
...@@ -190,14 +174,3 @@ diff -r -u libdvdnav-4.1.1/src/vm/vm.c libdvdnav/src/vm/vm.c ...@@ -190,14 +174,3 @@ diff -r -u libdvdnav-4.1.1/src/vm/vm.c libdvdnav/src/vm/vm.c
} else { } else {
fprintf(MSG_OUT, "NAME OPEN FAILED\n"); fprintf(MSG_OUT, "NAME OPEN FAILED\n");
} }
--- libdvdnav-4.1.1/examples/Makefile.am 2004-01-11 21:43:13.000000000 +0000
+++ libdvdnav/examples/Makefile.am 2007-11-12 12:44:09.328125000 +0000
@@ -8,7 +8,7 @@
menus_SOURCES = menus.c
menus_LDFLAGS = -L$(top_srcdir)/src/
-menus_LDADD = $(DVDNAV_LIB)
+menus_LDADD = $(DVDNAV_LIB) $(CSS_LIBS)
$(DVDNAV_LIB):
@cd $(top_builddir)/src/ && $(MAKE) libdvdnav.la
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment