# These ones are currently shipped with VLC
CONFIG_FLAGS += --enable-ffmpeg --with-ffmpeg-tree=extras/ffmpeg
CONFIG_FLAGS += --enable-faad --with-faad-tree=extras/faad
+CONFIG_FLAGS += --enable-libmpeg2 --with-libmpeg2-tree=extras/mpeg2dec
# Glide is only for x86
ifeq ($(DEB_BUILD_ARCH),i386)
cd extras/ffmpeg \
&& ./configure \
&& cd libavcodec \
- && make; \
+ && $(MAKE); \
fi
# Check that we have an faad tree in here (can be a symlink)
&& touch `find . -name Makefile.in` \
&& ./configure --disable-shared \
&& cd libfaad \
- && make; \
+ && $(MAKE); \
fi
- # Configure VLC and build it
+ # Check that we have an mpeg2dec tree in here (can be a symlink)
+ test -d extras/mpeg2dec
+ if test ! -d CVS; then \
+ cd extras/mpeg2dec \
+ && touch configure.in \
+ && touch aclocal.m4 \
+ && touch acinclude.m4 \
+ && touch configure \
+ && touch `find . -name config.h.in` \
+ && touch `find . -name Makefile.in` \
+ && ./configure --disable-shared \
+ && cd libmpeg2 \
+ && $(MAKE); \
+ fi
+
+ # Configure VLC
./configure --mandir=$${prefix}/share/man \
--infodir=$${prefix}/share/info $(CONFIG_FLAGS)
+
+ # Build only VLC, with the non-PIC libs
+ $(MAKE) vlc
+
+ifneq ($(DEB_BUILD_ARCH),i386)
+ # Hackety hackety hack
+ if test ! -d CVS; then \
+ cd extras/ffmpeg/libavcodec \
+ && $(MAKE) clean \
+ && rm -f Makefile.pic \
+ && sed 's/^CFLAGS *=/&-fPIC -DPIC /' <Makefile >Makefile.pic \
+ && $(MAKE) -f Makefile.pic \
+ && rm -f Makefile.pic; \
+ fi
+
+ # HACKETY HACKETY HACK
+ if test ! -d CVS; then \
+ cd extras/faad/libfaad \
+ && $(MAKE) clean \
+ && $(MAKE) AM_CFLAGS=-fPIC; \
+ fi
+
+ # HACK ME PLENTY MORE!!!
+ if test ! -d CVS; then \
+ cd extras/mpeg2dec/libmpeg2 \
+ && $(MAKE) clean \
+ && $(MAKE) LIBMPEG2_CFLAGS=-fPIC; \
+ fi
+endif
+
+ # Build all the rest, with the PIC libs
$(MAKE)
touch build-stamp
# Check that we have an ffmpeg tree in here (can be a symlink)
test -d extras/ffmpeg
- -if test ! -d CVS; then cd extras/ffmpeg && make distclean; fi
+ -if test ! -d CVS; then cd extras/ffmpeg && $(MAKE) distclean; fi
# Check that we have an faad tree in here (can be a symlink)
test -d extras/faad
- -if test ! -d CVS; then cd extras/faad && make distclean; fi
+ -if test ! -d CVS; then cd extras/faad && $(MAKE) distclean; fi
+ # Check that we have an mpeg2dec tree in here (can be a symlink)
+ test -d extras/mpeg2dec
+ -if test ! -d CVS; then cd extras/mpeg2dec && $(MAKE) distclean; fi
+
+ # Remove spurious autotools stuff
+ rm -f config.log confdefs.h
-$(MAKE) distclean