xine-lib from pkgsrc

Jonathan Fosburgh jonathan at fosburgh.org
Wed Oct 19 06:27:37 PDT 2005


After several months I finally have DragonFly working again (my pc at work was 
upgraded to an HP system with an unsupported NIC).  Since it has been so long 
I wiped out all of my packages and started over with pkgsrc.  In general 
things are working OK, and in fact I have a useable KDE desktop now.  
However, I am running into a few problems, the first one I wish to tackle is 
xine.  

I am running 1.3.7.  (DragonFly jef-nt.mdacc.tmc.edu 1.3.7-DEVELOPMENT 
DragonFly 1.3.7-DEVELOPMENT #4: Tue Oct 18 12:20:42 CDT 2005     
root at xxxxxxxxxxxxxxxxxxxx:/usr/obj/usr/src/sys/vmbsd  i386
)   My pkgsrc is (as far as I know) current, not tracking any branches so I 
should have all of the latest fixes.  The first problem with xine-lib is that 
configure breaks due to the lack of a -lpthread.  I can fix this by editing 
the configure script to check for -pthread instead. This works well enough to 
get through configure. 

xine-lib proceeds to build, but stops 
in /usr/pkgsrc/multimedia/xine-lib/work/xine-lib-1.0.3/src/input/libdvdnav 
with the following error:

In file included from ifo_read.c:28:
bswap.h:92:2: #error "You need to add endian swap macros for you're system"
ifo_read.c: In function `ifoRead_VMG':
ifo_read.c:301: warning: implicit declaration of function `B2N_32'
ifo_read.c:301: warning: nested extern declaration of `B2N_32'
ifo_read.c:304: warning: implicit declaration of function `B2N_16'
ifo_read.c:304: warning: nested extern declaration of `B2N_16'
ifo_read.c:307: warning: implicit declaration of function `B2N_64'
ifo_read.c:307: warning: nested extern declaration of `B2N_64'
ifo_read.c: In function `ifoRead_VTS':
ifo_read.c:392: warning: nested extern declaration of `B2N_32'
ifo_read.c:406: warning: nested extern declaration of `B2N_16'
ifo_read.c: In function `ifoRead_PGC_COMMAND_TBL':
ifo_read.c:488: warning: nested extern declaration of `B2N_16'
ifo_read.c: In function `ifoRead_CELL_PLAYBACK_TBL':
ifo_read.c:588: warning: nested extern declaration of `B2N_32'
ifo_read.c: In function `ifoRead_CELL_POSITION_TBL':
ifo_read.c:617: warning: nested extern declaration of `B2N_16'
ifo_read.c: In function `ifoRead_PGC':
ifo_read.c:633: warning: nested extern declaration of `B2N_16'
ifo_read.c:644: warning: nested extern declaration of `B2N_32'
ifo_read.c: In function `ifoRead_TT_SRPT':
ifo_read.c:821: warning: nested extern declaration of `B2N_16'
ifo_read.c:822: warning: nested extern declaration of `B2N_32'
ifo_read.c: In function `ifoRead_VTS_PTT_SRPT':
ifo_read.c:923: warning: nested extern declaration of `B2N_16'
ifo_read.c:924: warning: nested extern declaration of `B2N_32'
ifo_read.c: In function `ifoRead_PTL_MAIT':
ifo_read.c:1062: warning: nested extern declaration of `B2N_16'
ifo_read.c:1064: warning: nested extern declaration of `B2N_32'
ifo_read.c: In function `ifoRead_VTS_TMAPT':
ifo_read.c:1214: warning: nested extern declaration of `B2N_16'
ifo_read.c:1215: warning: nested extern declaration of `B2N_32'
ifo_read.c: In function `ifoRead_C_ADT_internal':
ifo_read.c:1380: warning: nested extern declaration of `B2N_16'
ifo_read.c:1381: warning: nested extern declaration of `B2N_32'
ifo_read.c: In function `ifoRead_VOBU_ADMAP_internal':
ifo_read.c:1516: warning: nested extern declaration of `B2N_32'
ifo_read.c: In function `ifoRead_PGCIT_internal':
ifo_read.c:1601: warning: nested extern declaration of `B2N_16'
ifo_read.c:1602: warning: nested extern declaration of `B2N_32'
ifo_read.c: In function `ifoRead_PGCI_UT':
ifo_read.c:1724: warning: nested extern declaration of `B2N_16'
ifo_read.c:1725: warning: nested extern declaration of `B2N_32'
ifo_read.c: In function `ifoRead_VTS_ATTRIBUTES':
ifo_read.c:1840: warning: nested extern declaration of `B2N_32'
ifo_read.c:1842: warning: nested extern declaration of `B2N_16'
ifo_read.c: In function `ifoRead_VTS_ATRT':
ifo_read.c:1910: warning: nested extern declaration of `B2N_16'
ifo_read.c:1911: warning: nested extern declaration of `B2N_32'
gmake[4]: *** [ifo_read.lo] Error 1


I can make this section compile by adding the following to bswap.h (in the 
libdvdnav directory):


#elif defined(__DragonFly__)
#include <sys/endian.h>
#define B2N_16(x) x = be16toh(x)
#define B2N_32(x) x = be32toh(x)
#define B2N_64(x) x = be64toh(x)

This is added at line 62. It works to compile, but  I basically just copied it 
from the FreeBSD section above, so I don't know if it is right.  

Is there a better fix in place for the lpthread problem? It appears 
libthread_xu isn't quite ready yet.  Also, am I setting the above defines 
correctly? If that is right I would be happy to submit a patch to the 
appropriate people.
-- 
Jonathan Fosburgh
AIX and Storage Administrator
UT MD Anderson Cancer Center
Houston, TX





More information about the Users mailing list