]> git.sesse.net Git - vlc/commitdiff
* extras/contrib/src/Makefile, extras/contrib/src/Patches/libogg-wince.patch,tremor...
authorGildas Bazin <gbazin@videolan.org>
Tue, 22 Nov 2005 22:29:00 +0000 (22:29 +0000)
committerGildas Bazin <gbazin@videolan.org>
Tue, 22 Nov 2005 22:29:00 +0000 (22:29 +0000)
extras/contrib/src/Makefile
extras/contrib/src/Patches/libogg-wince.patch [new file with mode: 0644]
extras/contrib/src/Patches/tremor.patch [new file with mode: 0644]

index 3fe111609aa1abb0c920c4432ee5563a2c17d2ec..d55acafca93b8cbc1b4c908a5a0b299fe700db33 100644 (file)
@@ -141,7 +141,7 @@ else
 
    ifdef HAVE_WINCE
 
-   all: .dvbpsi .zlib .ffmpeg
+   all: .dvbpsi .zlib .ffmpeg .ogg .tremor
    else
 
 # Standard Linux or other UNIX-like systems
@@ -543,12 +543,12 @@ libogg-$(OGG_VERSION).tar.gz:
 libogg: libogg-$(OGG_VERSION).tar.gz
        $(EXTRACT_GZ)
        patch -p 0 < Patches/ogg.patch
-#ifdef HAVE_WIN32
-#      (cd libogg;patch -p 0 <../Patches/libogg-1.1-win32.patch)
-#endiF
+ifdef HAVE_WINCE
+       patch -p 0 < Patches/libogg-wince.patch
+endif
 
 .ogg: libogg
-       (cd $<; $(HOSTCC) ./configure $(HOSTCONF) --prefix=$(PREFIX) && make && make install)
+       (cd $<; $(HOSTCC) ./configure $(HOSTCONF) --prefix=$(PREFIX) && make install)
        $(INSTALL_NAME)
        touch $@
 
@@ -588,6 +588,32 @@ CLEAN_FILE += .vorbis .vorbisenc
 CLEAN_PKG += libvorbis
 DISTCLEAN_PKG += libvorbis-$(VORBIS_VERSION).tar.gz
 
+# ***************************************************************************
+# tremor
+# ***************************************************************************
+
+ifdef SVN
+tremor: 
+       $(SVN) co http://svn.xiph.org/trunk/Tremor tremor
+       (cd $@ && patch -p0 < ../Patches/tremor.patch)
+       (cd $@; rm -f ogg.h && echo "#include <ogg/ogg.h>" > ogg.h && rm -f os_types.h && echo "#include <ogg/os_types.h>" > os_types.h && ./autogen.sh)
+else
+tremor-$(TREMOR_VERSION).tar.bz2:
+       $(WGET) $(TREMOR_URL)
+
+tremor: tremor-$(TREMOR_VERSION).tar.bz2
+       $(EXTRACT_BZ2)
+endif
+
+.tremor: tremor .ogg
+       (cd $<; $(HOSTCC) ./configure $(HOSTCONF) --prefix=$(PREFIX) --disable-shared && make && make install)
+       $(INSTALL_NAME)
+       touch $@
+
+CLEAN_FILE += .tremor
+CLEAN_PKG += tremor
+DISTCLEAN_PKG += tremor-$(TREMOR_VERSION).tar.gz
+
 # ***************************************************************************
 # theora
 # ***************************************************************************
diff --git a/extras/contrib/src/Patches/libogg-wince.patch b/extras/contrib/src/Patches/libogg-wince.patch
new file mode 100644 (file)
index 0000000..7e280bc
--- /dev/null
@@ -0,0 +1,13 @@
+--- libogg/include/ogg/os_types.h      2005-11-22 23:01:12.000000000 +0000
++++ libogg/include/ogg/os_types.h      2005-11-22 23:05:11.000000000 +0000
+@@ -55,6 +55,10 @@
+      typedef unsigned __int16 ogg_uint16_t;
+ #  endif
++#  if defined(UNDER_CE)
++#     define exit(a)
++#  endif
++
+ #elif defined(__MACOS__)
+ #  include <sys/types.h>
diff --git a/extras/contrib/src/Patches/tremor.patch b/extras/contrib/src/Patches/tremor.patch
new file mode 100644 (file)
index 0000000..83c0967
--- /dev/null
@@ -0,0 +1,94 @@
+Index: os.h
+===================================================================
+--- os.h       (revision 10420)
++++ os.h       (working copy)
+@@ -20,6 +20,14 @@
+ #include <math.h>
+ #include "os_types.h"
++#ifdef _LOW_ACCURACY_
++#  define X(n) (((((n)>>22)+1)>>1) - ((((n)>>22)+1)>>9))
++#  define LOOKUP_T const unsigned char
++#else
++#  define X(n) (n)
++#  define LOOKUP_T const ogg_int32_t
++#endif
++
+ #ifndef _V_IFDEFJAIL_H_
+ #  define _V_IFDEFJAIL_H_
+Index: synthesis.c
+===================================================================
+--- synthesis.c        (revision 10420)
++++ synthesis.c        (working copy)
+@@ -33,7 +33,7 @@
+  
+   /* first things first.  Make sure decode is ready */
+   _vorbis_block_ripcord(vb);
+-  oggpack_readinit(opb,op->packet);
++  oggpack_readinit(opb,op->packet,op->bytes);
+   /* Check the packet type */
+   if(oggpack_read(opb,1)!=0){
+@@ -86,7 +86,7 @@
+   oggpack_buffer       opb;
+   int                  mode;
+  
+-  oggpack_readinit(&opb,op->packet);
++  oggpack_readinit(&opb,op->packet,op->bytes);
+   /* Check the packet type */
+   if(oggpack_read(&opb,1)!=0){
+Index: info.c
+===================================================================
+--- info.c     (revision 10420)
++++ info.c     (working copy)
+@@ -299,7 +299,7 @@
+   oggpack_buffer opb;
+   
+   if(op){
+-    oggpack_readinit(&opb,op->packet);
++    oggpack_readinit(&opb,op->packet,op->bytes);
+     /* Which of the three types of header is this? */
+     /* Also verify header-ness, vorbis */
+Index: ivorbiscodec.h
+===================================================================
+--- ivorbiscodec.h     (revision 10420)
++++ ivorbiscodec.h     (working copy)
+@@ -23,7 +23,7 @@
+ {
+ #endif /* __cplusplus */
+-#include "ogg.h"
++#include <ogg/ogg.h>
+ typedef struct vorbis_info{
+   int version;
+Index: Makefile.am
+===================================================================
+--- Makefile.am        (revision 10420)
++++ Makefile.am        (working copy)
+@@ -8,11 +8,11 @@
+                         synthesis.c info.c \
+                         floor1.c floor0.c vorbisfile.c \
+                         res012.c mapping0.c registry.c codebook.c \
+-                      sharedbook.c framing.c bitwise.c \
++                      sharedbook.c \
+                         codebook.h misc.h mdct_lookup.h\
+                         os.h mdct.h ivorbisfile.h lsp_lookup.h\
+                         registry.h window.h window_lookup.h\
+-                        codec_internal.h backends.h ogg.h \
++                        codec_internal.h backends.h \
+                       asm_arm.h ivorbiscodec.h
+ libvorbisidec_la_LDFLAGS = -version-info @V_LIB_CURRENT@:@V_LIB_REVISION@:@V_LIB_AGE@
+@@ -25,7 +25,7 @@
+ includedir = $(prefix)/include/tremor
+-include_HEADERS = ivorbiscodec.h ivorbisfile.h ogg.h os_types.h config_types.h
++include_HEADERS = ivorbiscodec.h ivorbisfile.h os_types.h config_types.h
+ example:
+       -ln -fs . vorbis