[MPlayer-dev-eng] [PATH] libmpdvdkit and tvi_bsdbt848 on NetBSD

Bernd Ernesti mplayer at lists.veego.de
Sun Apr 28 13:05:11 CEST 2002


Hi,

I noticed that netbsd has the same problem as openbsd has with libmpdvdkit.

It doesn't build, thats because mplayer doesn't uses the latest libdvdcss
from ogle, which cause this failures:

gcc -I. -O4 -march=i686 -mcpu=i686 -pipe -ffast-math -fomit-frame-pointer -D_THREAD_SAFE -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DHAVE_MPLAYER -D_LARGEFILE64_SOURCE -DSYS_LINUX -D_FILE_OFFSET_BITS=64 -D__USE_UNIX98 -D_REENTRANT -D_GNU_SOURCE -ffast-math -funroll-loops -fomit-frame-pointer  -c -o ioctl.o ioctl.c
ioctl.c: In function `ioctl_ReadCopyright':
ioctl.c:118: storage size of `dvd' isn't known
ioctl.c:123: `DVDIOCREADSTRUCTURE' undeclared (first use in this function)
ioctl.c:123: (Each undeclared identifier is reported only once
ioctl.c:123: for each function it appears in.)
ioctl.c: In function `ioctl_ReadKey':
ioctl.c:245: storage size of `dvd' isn't known
ioctl.c:251: `DVDIOCREADSTRUCTURE' undeclared (first use in this function)
ioctl.c: In function `ioctl_ReportAgid':
ioctl.c:363: storage size of `auth_info' isn't known
ioctl.c:365: `DVD_REPORT_AGID' undeclared (first use in this function)
ioctl.c:368: `DVDIOCREPORTKEY' undeclared (first use in this function)

This is a quick diff to make it work:

--- libmpdvdkit/ioctl.c.orig	Wed Apr 24 21:28:03 2002
+++ libmpdvdkit/ioctl.c	Sun Apr 28 12:43:48 2002
@@ -73,6 +73,12 @@
 #   include "MacOSX_dvdioctl/DVDioctl.h"
 #endif
 
+/* This should be done in configure but for now kludge it. */
+#if defined(__NetBSD__)
+#undef HAVE_BSD_DVD_STRUCT
+#define HAVE_LINUX_DVD_STRUCT 1
+#endif
+
 #include "ioctl.h"
 
 /*****************************************************************************

But the latest libdvdcss from ogle has some addtitional support so you
should better use that or just disable libmpdvdkit if you find libdvdread.

Hmmm, I would like to see the later way, because compiling libdvdcss in mplayer
would mean that we have to disable libmpdvdkit in the NetBSD package.
libdvdcss is a little complicated due to the $#$#$# US DMCA, libdvdread use a
dlopen to load libdvdcss, so a normal user can install libdvdcss whenever he wants.


And here is another patch to fix the build of tvi_bsdbt848:

--- libmpdemux/tvi_bsdbt848.c.orig	Sun Apr 28 00:42:25 2002
+++ libmpdemux/tvi_bsdbt848.c	Sun Apr 28 12:20:15 2002
@@ -49,7 +49,9 @@
 #ifdef HAVE_SYS_SOUNDCARD_H
 #include <sys/soundcard.h>
 #else
-#include <machine/soundcard.h>
+#ifdef HAVE_SOUNDCARD_H
+#include <soundcard.h> /* NetBSD/OpenBSD have this instead of <sys/soundcard> */
+#endif
 #endif
 
 #include "../libvo/img_format.h"

Bernd

P.S Both patches are also uuencoded attached to this mail.

-------------- next part --------------
begin 644 ioctl.c.patch
M+2TM(&QI8FUP9'9D:VET+VEO8W1L+F,N;W)I9PE7960 at 07!R(#(T(#(Q.C(X
M.C`S(#(P,#(**RLK(&QI8FUP9'9D:VET+VEO8W1L+F,)4W5N($%P<B`R."`Q
M,CHT,SHT."`R,#`R"D!`("TW,RPV("LW,RPQ,B!`0`H@(R`@(&EN8VQU9&4@
M(DUA8T]36%]D=F1I;V-T;"]$5D1I;V-T;"YH(@H@(V5N9&EF"B`**R\J(%1H
M:7,@<VAO=6QD(&)E(&1O;F4@:6X at 8V]N9FEG=7)E(&)U="!F;W(@;F]W(&ML
M=61G92!I="X@*B\**R-I9B!D969I;F5D*%]?3F5T0E-$7U\I"BLC=6YD968@
M2$%615]"4T1?1%9$7U-44E5#5`HK(V1E9FEN92!(059%7TQ)3E587T161%]3
M5%)50U0@,0HK(V5N9&EF"BL*("-I;F-L=61E(")I;V-T;"YH(@H@"B`O*BHJ
M*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ
>*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BHJ*BH*
`
end
-------------- next part --------------
begin 644 tvi_bsdbt848.c.patch
M+2TM(&QI8FUP9&5M=7 at O='9I7V)S9&)T.#0X+F,N;W)I9PE3=6X at 07!R(#(X
M(#`P.C0R.C(U(#(P,#(**RLK(&QI8FUP9&5M=7 at O='9I7V)S9&)T.#0X+F,)
M4W5N($%P<B`R."`Q,CHR,#HQ-2`R,#`R"D!`("TT.2PW("LT.2PY($!`"B`C
M:69D968 at 2$%615]365-?4T]53D1#05)$7T@*("-I;F-L=61E(#QS>7,O<V]U
M;F1C87)D+F@^"B`C96QS90HM(VEN8VQU9&4@/&UA8VAI;F4O<V]U;F1C87)D
M+F@^"BLC:69D968 at 2$%615]33U5.1$-!4D1?2`HK(VEN8VQU9&4@/'-O=6YD
M8V%R9"YH/B`O*B!.971"4T0O3W!E;D)31"!H879E('1H:7,@:6YS=&5A9"!O
M9B`\<WES+W-O=6YD8V%R9#X@*B\**R-E;F1I9 at H@(V5N9&EF"B`*("-I;F-L
<=61E("(N+B]L:6)V;R]I;6=?9F]R;6%T+F at B"@H@
`
end


More information about the MPlayer-dev-eng mailing list