0

In Ubuntu 14.04,I run ./configure --enable-gui --enable-xvid-lavc --enable-xv --enable-alsa to install mplayer,when it comes to Checking for FFmpeg .... then the error shows up. I cat config.log, the error details is below:

============ Checking for FFmpeg ============

 #include 'libavutil/x86/asm.h'

 int main(void) { return 0; }

cc -Wundef -Wall -Wno-switch -Wno-parentheses -Wpointer-arith -Wredundant-decls -Wstrict-prototypes -Wmissing-prototypes -Wdisabled-optimization -Wno-pointer-sign -Wdeclaration-after-statement -std=gnu99 -Werror-implicit-function-declaration -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -D_ISOC99_SOURCE -I. -Iffmpeg -O4 -march=native -mtune=native -pipe -ffast-math -fomit-frame-pointer -fno-tree-vectorize /tmp/mplayer-configure--1996/tmp.c -Ilibdvdread4  -fpie -DPIC -D_REENTRANT   -ffast-math -fpie -pie   -lrt -lasound -ldl -lpthread  -lXv  -o /tmp/mplayer-configure--1996/tmp  -lm

In file included from /tmp/mplayer-configure--1996/tmp.c:1:0:

ffmpeg/libavutil/x86/asm.h:30:5: warning: "ARCH_X86_64" is not defined [-Wundef]

 #if ARCH_X86_64

ffmpeg/libavutil/x86/asm.h:50:7: warning: "ARCH_X86_32" is not defined [-Wundef]

 #elif ARCH_X86_32

ffmpeg/libavutil/x86/asm.h:77:5: warning: "ARCH_X86_64" is not defined [-Wundef]

 #if ARCH_X86_64 && defined(PIC)

ffmpeg/libavutil/x86/asm.h:93:5: warning: "HAVE_XMM_CLOBBERS" is not defined [-Wundef]

 #if HAVE_XMM_CLOBBERS

ffmpeg/libavutil/x86/asm.h:105:5: warning: "ARCH_X86_64" is not defined [-Wundef]

 #if ARCH_X86_64 && defined(PIC)

ffmpeg/libavutil/x86/asm.h:111:5: warning: "HAVE_INLINE_ASM_DIRECT_SYMBOL_REFS" is not defined [-Wundef]

 #if HAVE_INLINE_ASM_DIRECT_SYMBOL_REFS

/usr/bin/ld: cannot find -lasound

collect2: error: ld returned 1 exit status

I don't know what's going on, please Help

3
  • Thank you muru for telling me the true problem. I used to thought it was something wrong with the 'asm.h' file(how stupid i am..). I fixed the dependency like you said and it worked!
    – sify
    Oct 13, 2014 at 18:18
  • Also I think Sylvain Pineau's method should work too though i didn't try it.
    – sify
    Oct 13, 2014 at 18:20
  • 1
    If you encounter more linker (ld) errors, Sylvain's method might be better.
    – muru
    Oct 13, 2014 at 19:16

3 Answers 3

1

If you want to build mplayer from source, I would install all its build dependencies:

sudo apt-get build-dep mplayer
0

The actual error is:

/usr/bin/ld: cannot find -lasound

I think you need to install libasound2-dev:

sudo apt-get install libasound2-dev
0

It would perhaps be easiest to follow this guide on the Ubuntu Forums:

Howto: Build the svn MPlayer under the latest release version of Ubuntu

http://ubuntuforums.org/showthread.php?t=2149564

and this would guarantee a working and fully featured copy of MPlayer as well as the most up to date SMPlayer...

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .