summaryrefslogtreecommitdiff
path: root/src/input/libdvdnav/dvd_input.c
diff options
context:
space:
mode:
authorMichael Roitzsch <mroi@users.sourceforge.net>2004-03-16 11:43:38 +0000
committerMichael Roitzsch <mroi@users.sourceforge.net>2004-03-16 11:43:38 +0000
commit50a26e7dabcb36c002f8527c8364c67439adbb11 (patch)
treed79ee798b6681d0fc8e8a3c93c845d34cfdb92e4 /src/input/libdvdnav/dvd_input.c
parentb323267b7a8f5592c66158376a1ce25e2bdfefd5 (diff)
downloadxine-lib-50a26e7dabcb36c002f8527c8364c67439adbb11.tar.gz
xine-lib-50a26e7dabcb36c002f8527c8364c67439adbb11.tar.bz2
sync to latest libdvdnav
* fixes a menu problem (German RC2 of "Anatomie", chapter menu) * addresses some compilation problems on Windows (Could someone try cygwin, mingw builds, please? It should work with the standalone libdvdnav, but who knows if the integration breaks anything...) * turns some abort()s into assert(0)s, where we really can try to continue CVS patchset: 6269 CVS date: 2004/03/16 11:43:38
Diffstat (limited to 'src/input/libdvdnav/dvd_input.c')
-rw-r--r--src/input/libdvdnav/dvd_input.c19
1 files changed, 8 insertions, 11 deletions
diff --git a/src/input/libdvdnav/dvd_input.c b/src/input/libdvdnav/dvd_input.c
index ae332257e..47084016c 100644
--- a/src/input/libdvdnav/dvd_input.c
+++ b/src/input/libdvdnav/dvd_input.c
@@ -24,18 +24,10 @@
#include <fcntl.h>
#include <unistd.h>
-#include <dlfcn.h>
-
#include "dvd_reader.h"
#include "dvd_input.h"
-#ifndef _MSC_VER
-#define LIBDVDCSS_NAME = "libdvdcss.so.2"
-#else
-#define LIBDVDCSS_NAME = "libdvdcss.dll"
-#endif
-
/* The function pointers that is the exported interface of this file. */
dvd_input_t (*dvdinput_open) (const char *);
int (*dvdinput_close) (dvd_input_t);
@@ -56,7 +48,12 @@ char * (*dvdinput_error) (dvd_input_t);
#else
/* dlopening libdvdcss */
+#ifdef HAVE_DLFCN_H
#include <dlfcn.h>
+#else
+/* Only needed on MINGW at the moment */
+#include "../../msvc/contrib/dlfcn.c"
+#endif
typedef struct dvdcss_s *dvdcss_handle;
static dvdcss_handle (*DVDcss_open) (const char *);
@@ -172,8 +169,8 @@ static dvd_input_t file_open(const char *target)
}
/* Open the device */
-#ifndef _MSC_VER
- dev->fd = open(target, O_RDONLY|O_EXCL);
+#ifndef WIN32
+ dev->fd = open(target, O_RDONLY | O_EXCL);
#else
dev->fd = open(target, O_RDONLY | O_BINARY);
#endif
@@ -290,7 +287,7 @@ int dvdinput_setup(void)
#else
/* dlopening libdvdcss */
-#ifndef _MSC_VER
+#ifndef WIN32
dvdcss_library = dlopen("libdvdcss.so.2", RTLD_LAZY);
#else
dvdcss_library = dlopen("libdvdcss.dll", RTLD_LAZY);