mirror of
https://github.com/mpv-player/mpv
synced 2024-12-18 12:55:16 +00:00
(on atmos's suggestions I found good :)
default is autodetection (if lame and divxencore libs found then compile it) use --enable-mencoder or --disable-mencoder to alter this behavior Makefile modified accordingly (uninstall and other ifeq...) removed XMM_* since XMMP no longer there git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@3080 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
9a21d44800
commit
590886a8f4
30
Makefile
30
Makefile
@ -64,6 +64,9 @@ LOADER_DEP = $(W32_DEP) $(DS_DEP)
|
||||
LIB_LOADER = $(W32_LIB) $(DS_LIB)
|
||||
|
||||
ALL_PRG = $(PRG)
|
||||
ifeq ($(MENCODER),yes)
|
||||
ALL_PRG += $(PRG_MENCODER)
|
||||
endif
|
||||
ifeq ($(CSS_USE),yes)
|
||||
ALL_PRG += $(PRG_FIBMAP)
|
||||
endif
|
||||
@ -144,16 +147,18 @@ MENCODER_DEP += Gui/libgui.a
|
||||
endif
|
||||
|
||||
$(PRG): $(MPLAYER_DEP)
|
||||
$(CC) $(CFLAGS) -o $(PRG) $(OBJS_MPLAYER) -Llibmpdemux -lmpdemux $(XMM_LIBS) $(LIRC_LIBS) $(LIB_LOADER) $(AV_LIB) -Llibmpeg2 -lmpeg2 -Llibao2 -lao2 $(A_LIBS) $(VO_LIBS) $(CSS_LIB) $(GUI_LIBS) $(ARCH_LIBS) $(OSDEP_LIBS) $(PP_LIBS) $(XA_LIBS) $(DECORE_LIBS) $(TERMCAP_LIB) -lm $(STATIC)
|
||||
$(CC) $(CFLAGS) -o $(PRG) $(OBJS_MPLAYER) -Llibmpdemux -lmpdemux $(LIRC_LIBS) $(LIB_LOADER) $(AV_LIB) -Llibmpeg2 -lmpeg2 -Llibao2 -lao2 $(A_LIBS) $(VO_LIBS) $(CSS_LIB) $(GUI_LIBS) $(ARCH_LIBS) $(OSDEP_LIBS) $(PP_LIBS) $(XA_LIBS) $(DECORE_LIBS) $(TERMCAP_LIB) -lm $(STATIC)
|
||||
|
||||
$(PRG_FIBMAP): fibmap_mplayer.o
|
||||
$(CC) -o $(PRG_FIBMAP) fibmap_mplayer.o
|
||||
|
||||
ifeq ($(MENCODER),yes)
|
||||
$(PRG_MENCODER): $(MENCODER_DEP)
|
||||
$(CC) $(CFLAGS) -o $(PRG_MENCODER) $(OBJS_MENCODER) -Llibmpeg2 -lmpeg2 -Llibmpdemux -lmpdemux $(X_LIBS) $(XMM_LIBS) $(LIB_LOADER) $(AV_LIB) -lmp3lame $(A_LIBS) $(CSS_LIB) $(GUI_LIBS) $(ARCH_LIBS) $(OSDEP_LIBS) $(PP_LIBS) $(XA_LIBS) $(DECORE_LIBS) $(ENCORE_LIBS) $(TERMCAP_LIB) -lm
|
||||
$(CC) $(CFLAGS) -o $(PRG_MENCODER) $(OBJS_MENCODER) -Llibmpeg2 -lmpeg2 -Llibmpdemux -lmpdemux $(X_LIBS) $(LIB_LOADER) $(AV_LIB) -lmp3lame $(A_LIBS) $(CSS_LIB) $(GUI_LIBS) $(ARCH_LIBS) $(OSDEP_LIBS) $(PP_LIBS) $(XA_LIBS) $(DECORE_LIBS) $(ENCORE_LIBS) $(TERMCAP_LIB) -lm
|
||||
endif
|
||||
|
||||
# $(PRG_HQ): depfile mplayerHQ.o $(OBJS) loader/libloader.a libmpeg2/libmpeg2.a opendivx/libdecore.a $(COMMONLIBS) encore/libencore.a
|
||||
# $(CC) $(CFLAGS) -o $(PRG_HQ) mplayerHQ.o $(OBJS) $(XMM_LIBS) $(LIRC_LIBS) $(A_LIBS) -lm $(TERMCAP_LIB) -Lloader -lloader -ldl -Llibmpeg2 -lmpeg2 -Lopendivx -ldecore $(VO_LIBS) -Lencore -lencore -lpthread
|
||||
# $(CC) $(CFLAGS) -o $(PRG_HQ) mplayerHQ.o $(OBJS) $(LIRC_LIBS) $(A_LIBS) -lm $(TERMCAP_LIB) -Lloader -lloader -ldl -Llibmpeg2 -lmpeg2 -Lopendivx -ldecore $(VO_LIBS) -Lencore -lencore -lpthread
|
||||
|
||||
# $(PRG_AVIP): depfile aviparse.o $(OBJS) loader/libloader.a $(COMMONLIBS)
|
||||
# $(CC) $(CFLAGS) -o $(PRG_AVIP) aviparse.o $(OBJS) $(A_LIBS) -lm $(TERMCAP_LIB) -Lloader -lloader -ldl $(VO_LIBS) -lpthread
|
||||
@ -175,13 +180,16 @@ $(PRG_CFG): version.h codec-cfg.c codec-cfg.h
|
||||
install: $(ALL_PRG)
|
||||
if test ! -d $(BINDIR) ; then mkdir -p $(BINDIR) ; fi
|
||||
$(INSTALL) -m 755 -s $(PRG) $(BINDIR)/$(PRG)
|
||||
if test -x $(PRG_MENCODER) ; then $(INSTALL) -m 755 -s $(PRG_MENCODER) $(BINDIR)/$(PRG_MENCODER) ; fi
|
||||
ifeq ($(GUI),yes)
|
||||
-ln -sf $(BINDIR)/$(PRG) $(BINDIR)/gmplayer
|
||||
endif
|
||||
if test ! -d $(prefix)/man/man1 ; then mkdir -p $(prefix)/man/man1; fi
|
||||
$(INSTALL) -c -m 644 DOCS/mplayer.1 $(prefix)/man/man1/mplayer.1
|
||||
if test -x $(PRG_MENCODER) ; then $(INSTALL) -c -m 644 DOCS/mencoder.1 $(prefix)/man/man1/mencoder.1 ; fi
|
||||
ifeq ($(MENCODER),yes)
|
||||
$(INSTALL) -m 755 -s $(PRG_MENCODER) $(BINDIR)/$(PRG_MENCODER)
|
||||
$(INSTALL) -c -m 644 DOCS/mencoder.1 $(prefix)/man/man1/mencoder.1
|
||||
endif
|
||||
|
||||
ifeq ($(CSS_USE),yes)
|
||||
@echo "Following task requires root privs. If it fails don't panic"
|
||||
@echo "however it means you can't use fibmap_mplayer."
|
||||
@ -191,17 +199,17 @@ ifeq ($(CSS_USE),yes)
|
||||
endif
|
||||
|
||||
uninstall:
|
||||
rm -f $(BINDIR)/$(PRG)
|
||||
rm -f $(BINDIR)/gmplayer
|
||||
rm -f $(prefix)/man/man1/mplayer.1
|
||||
rm -f $(BINDIR)/$(PRG_FIBMAP)
|
||||
-rm -f $(BINDIR)/$(PRG) $(BINDIR)/gmplayer $(prefix)/man/man1/mplayer.1
|
||||
-rm -f $(BINDIR)/$(PRG_FIBMAP)
|
||||
-rm -f $(BINDIR)/$(PRG_MENCODER) $(prefix)/man/man1/mencoder.1
|
||||
@echo "Uninstall completed"
|
||||
|
||||
clean:
|
||||
rm -f *.o *~ $(OBJS)
|
||||
-rm -f *.o *~ $(OBJS)
|
||||
|
||||
distclean:
|
||||
rm -f *~ $(PRG) $(PRG_FIBMAP) $(PRG_HQ) $(PRG_AVIP) $(PRG_TV) $(OBJS) $(PRG_MENCODER) *.o *.a .depend
|
||||
-rm -f *~ $(PRG) $(PRG_FIBMAP) $(PRG_HQ) $(PRG_AVIP) $(PRG_TV) $(OBJS) $(PRG_MENCODER)
|
||||
-rm -f *.o *.a .depend configure.log
|
||||
@for a in $(PARTS); do $(MAKE) -C $$a distclean; done
|
||||
|
||||
dep: depend
|
||||
|
43
configure
vendored
43
configure
vendored
@ -108,6 +108,7 @@ Installation directories:
|
||||
data [/usr/local/share/mplayer]
|
||||
|
||||
Optional features:
|
||||
--disable-mencoder disable mencoder [autodetect]
|
||||
--enable-largefiles enable support for files >2^32 bytes long [disable]
|
||||
--enable-termcap use termcap database for key codes [autodetect]
|
||||
--enable-lirc enable LIRC (remote control) support [autodetect]
|
||||
@ -629,6 +630,7 @@ _prefix="/usr/local"
|
||||
_libavcodec=auto
|
||||
_libavcodecso=auto
|
||||
|
||||
_mencoder=auto
|
||||
_x11=auto
|
||||
_dga=auto
|
||||
_dga2=auto
|
||||
@ -691,6 +693,8 @@ for ac_option do
|
||||
|
||||
|
||||
# Real 2nd pass
|
||||
--enable-mencoder) _mencoder=yes ;;
|
||||
--disable-mencoder) _mencoder=no ;;
|
||||
--enable-x11) _x11=yes ;;
|
||||
--disable-x11) _x11=no ;;
|
||||
--enable-dga) _dga=yes ;;
|
||||
@ -2148,26 +2152,38 @@ EOF
|
||||
fi
|
||||
echores "$_divx4linux_decore"
|
||||
test "$_divx4linux_decore" = yes && _divx4linux=yes
|
||||
echocheck "Divx4linux encore (for mencoder)"
|
||||
cat > $TMPC <<EOF
|
||||
#include <encore2.h>
|
||||
int main(void) { (void) encore(0, 0, 0, 0); return 0; }
|
||||
EOF
|
||||
_divx4linux_encore=no
|
||||
cc_check -ldivxencore -lm && _divx4linux_encore=yes
|
||||
echores "$_divx4linux_encore"
|
||||
fi
|
||||
_def_decore='#undef NEW_DECORE'
|
||||
_ld_decore='-Lopendivx -ldecore'
|
||||
_def_encore='#undef NEW_ENCORE'
|
||||
if test "$_divx4linux_decore" = yes ; then
|
||||
_def_decore='#define NEW_DECORE 1'
|
||||
_ld_decore='-ldivxdecore opendivx/postprocess.o'
|
||||
if test "$_divx4linux_encore" = yes ; then
|
||||
_def_encore='#define NEW_ENCORE 1'
|
||||
_ld_encore='-ldivxencore'
|
||||
fi
|
||||
|
||||
|
||||
echocheck "lame and encore (for mencoder)"
|
||||
#mencoder requires those libs
|
||||
if test "$_mencoder" != no ; then
|
||||
cat > $TMPC <<EOF
|
||||
#include <encore2.h>
|
||||
#include <lame/lame.h>
|
||||
int main(void) { (void) lame_init(); (void) encore(0, 0, 0, 0); return 0; }
|
||||
EOF
|
||||
_mencoder=no
|
||||
if cc_check -lmp3lame -ldivxencore -lm ; then
|
||||
_mencoder=yes
|
||||
_ld_encore='-lmp3lame -ldivxencore -lm'
|
||||
elif cc_check -lmp3lame $_ld_vorbis -ldivxencore -lm ; then
|
||||
_mencoder=yes
|
||||
_ld_encore="-lmp3lame -ldivxencore -lm $_ld_vorbis"
|
||||
fi
|
||||
fi
|
||||
if test "$_mencoder" = yes ; then
|
||||
_def_encore='#define NEW_ENCORE 1'
|
||||
else
|
||||
_def_encore='#undef NEW_ENCORE'
|
||||
fi
|
||||
echores "$_mencoder"
|
||||
|
||||
|
||||
echocheck "lirc"
|
||||
@ -2411,7 +2427,8 @@ SGI_AUDIO_LIB = $_ld_sgiaudio
|
||||
ARCH_LIBS = $_ld_static $_ld_arch $_ld_iconv
|
||||
DIVX4LINUX = $_ld_static $_divx4linux
|
||||
DECORE_LIBS = $_ld_static $_ld_decore
|
||||
ENCORE_LIBS = $_ld_static $_ld_encore
|
||||
MENCODER = $_mencoder
|
||||
ENCORE_LIBS = $_ld_static $_ld_encore
|
||||
HAVE_MLIB = $_mlib
|
||||
MLIB_INC = $_inc_mlib
|
||||
MLIB_LIB = $_ld_static $_ld_mlib
|
||||
|
Loading…
Reference in New Issue
Block a user