This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

unable to cross compilation -- MPG123 for sitara AM335x

Hi,

we trying to cross compile mpg123 for sitara-AM335x - getting few error.

we are following : http://processors.wiki.ti.com/index.php/ARM_Open_Source_Codecs

 we modified the command:

./configure --enable-cross-compile --cc=arm_v5t_le-gcc --host-cc=gcc --target=arm-linux-gnu --prefix=/home/user/target/opt/MPlayer-1.0rc2/

to   -- 

./configure --enable-cross-compile CC=arm-linux-gnueabihf-gcc --host=arm-linux --target=arm-linux-gnueabihf- --prefix=/home/cyient/Audio/mpg123/

config log:

configure: WARNING: unrecognized options: --enable-cross-compile

make:

/bin/sh ../libtool --tag=CC --mode=link arm-linux-gnueabihf-gcc -O2 -fomit-frame-pointer -funroll-all-loops -finline-functions -ffast-math -g -O2 -o mpg123 audio.o buffer.o common.o compat.o control_generic.o equalizer.o getlopt.o httpget.o resolver.o genre.o mpg123.o metaprint.o local.o playlist.o streamdump.o term.o wav.o xfermem.o libmpg123/libmpg123.la legacy_module.o output/oss.o -lm
libtool: link: arm-linux-gnueabihf-gcc -O2 -fomit-frame-pointer -funroll-all-loops -finline-functions -ffast-math -g -O2 -o .libs/mpg123 audio.o buffer.o common.o compat.o control_generic.o equalizer.o getlopt.o httpget.o resolver.o genre.o mpg123.o metaprint.o local.o playlist.o streamdump.o term.o wav.o xfermem.o legacy_module.o output/oss.o libmpg123/.libs/libmpg123.so -lm -Wl,-rpath -Wl,/home/cyient/Audio/mpg123/lib
genre.o: file not recognized: File format not recognized
collect2: error: ld returned 1 exit status

please correct me if i am doing any thing wrong.

regards,

Viswanath K

  • This is not a Sitara-related question so I will move this to the Linux forum.
  • TRUE.
    Thank u.
    can do one more favour. i posted for madplay also. can you move that too linux-fourm .

    regards,

    Viswanath K
  • Hi,
    Do you want to rebuild mplayer ?

    Please refer to the following TI E2E post.
    e2e.ti.com/.../347724
  • Hi ,
    Thank you for the reply. i tried the same command for all player builds -- mpg123,madplay and MPlayer-1.0rc2.
    But i got error while doing make.

    Mplayer-1.0rc2:

    arm-linux-gnueabihf-gcc -I../libswscale -I../libavcodec -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_ISOC9X_SOURCE -I.. -I.. -I../libavutil -Wdisabled-optimization -Wno-pointer-sign -Wdeclaration-after-statement -I. -I.. -I../libavutil -Wall -Wno-switch -Wpointer-arith -Wredundant-decls -O4 -pipe -ffast-math -fomit-frame-pointer -D_REENTRANT -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -DHAVE_CONFIG_H -c -o armv4l/mpegvideo_armv5te.o armv4l/mpegvideo_armv5te.c
    {standard input}: Assembler messages:
    {standard input}:58: Error: thumb conditional instruction should be in IT block -- `addgt r10,r3,#0'
    {standard input}:59: Error: thumb conditional instruction should be in IT block -- `rsblt r10,r3,#0'
    {standard input}:60: Error: thumb conditional instruction should be in IT block -- `smlatbne r10,r4,lr,r10'
    {standard input}:62: Error: thumb conditional instruction should be in IT block -- `addgt fp,r3,#0'
    {standard input}:63: Error: thumb conditional instruction should be in IT block -- `rsblt fp,r3,#0'
    {standard input}:64: Error: thumb conditional instruction should be in IT block -- `smlatbne fp,r5,lr,fp'
    {standard input}:66: Error: thumb conditional instruction should be in IT block -- `addgt r9,r3,#0'
    {standard input}:67: Error: thumb conditional instruction should be in IT block -- `rsblt r9,r3,#0'
    {standard input}:68: Error: thumb conditional instruction should be in IT block -- `smlabbne r4,r4,lr,r9'
    {standard input}:70: Error: thumb conditional instruction should be in IT block -- `addgt r9,r3,#0'
    {standard input}:71: Error: thumb conditional instruction should be in IT block -- `rsblt r9,r3,#0'
    {standard input}:72: Error: thumb conditional instruction should be in IT block -- `smlabbne r5,r5,lr,r9'
    {standard input}:78: Error: thumb conditional instruction should be in IT block -- `addgt r10,r3,#0'
    {standard input}:79: Error: thumb conditional instruction should be in IT block -- `rsblt r10,r3,#0'
    {standard input}:80: Error: thumb conditional instruction should be in IT block -- `smlatbne r10,r6,lr,r10'
    {standard input}:82: Error: thumb conditional instruction should be in IT block -- `addgt fp,r3,#0'
    {standard input}:83: Error: thumb conditional instruction should be in IT block -- `rsblt fp,r3,#0'
    {standard input}:84: Error: thumb conditional instruction should be in IT block -- `smlatbne fp,r7,lr,fp'
    {standard input}:86: Error: thumb conditional instruction should be in IT block -- `addgt r9,r3,#0'
    {standard input}:87: Error: thumb conditional instruction should be in IT block -- `rsblt r9,r3,#0'
    {standard input}:88: Error: thumb conditional instruction should be in IT block -- `smlabbne r6,r6,lr,r9'
    {standard input}:90: Error: thumb conditional instruction should be in IT block -- `addgt r9,r3,#0'
    {standard input}:91: Error: thumb conditional instruction should be in IT block -- `rsblt r9,r3,#0'
    {standard input}:92: Error: thumb conditional instruction should be in IT block -- `smlabbne r7,r7,lr,r9'
    {standard input}:98: Warning: conditional infixes are deprecated in unified syntax
    {standard input}:98: Error: thumb conditional instruction should be in IT block -- `ldrgtd r4,[r2,#0]'
    {standard input}:107: Error: thumb conditional instruction should be in IT block -- `rsblt r9,r3,#0'
    {standard input}:108: Error: thumb conditional instruction should be in IT block -- `smlabbne r10,r10,lr,r9'
    {standard input}:111: Error: thumb conditional instruction should be in IT block -- `rsblt r9,r3,#0'
    {standard input}:112: Error: thumb conditional instruction should be in IT block -- `smlabbne fp,fp,lr,r9'
    {standard input}:156: Error: thumb conditional instruction should be in IT block -- `addgt r8,lr,#0'
    {standard input}:157: Error: thumb conditional instruction should be in IT block -- `rsblt r8,lr,#0'
    {standard input}:158: Error: thumb conditional instruction should be in IT block -- `smlatbne r8,r4,r3,r8'
    {standard input}:160: Error: thumb conditional instruction should be in IT block -- `addgt r9,lr,#0'
    {standard input}:161: Error: thumb conditional instruction should be in IT block -- `rsblt r9,lr,#0'
    {standard input}:162: Error: thumb conditional instruction should be in IT block -- `smlatbne r9,r5,r3,r9'
    {standard input}:164: Error: thumb conditional instruction should be in IT block -- `addgt r0,lr,#0'
    {standard input}:165: Error: thumb conditional instruction should be in IT block -- `rsblt r0,lr,#0'
    {standard input}:166: Error: thumb conditional instruction should be in IT block -- `smlabbne r4,r4,r3,r0'
    {standard input}:168: Error: thumb conditional instruction should be in IT block -- `addgt r0,lr,#0'
    {standard input}:169: Error: thumb conditional instruction should be in IT block -- `rsblt r0,lr,#0'
    {standard input}:170: Error: thumb conditional instruction should be in IT block -- `smlabbne r5,r5,r3,r0'
    {standard input}:176: Error: thumb conditional instruction should be in IT block -- `addgt r8,lr,#0'
    {standard input}:177: Error: thumb conditional instruction should be in IT block -- `rsblt r8,lr,#0'
    {standard input}:178: Error: thumb conditional instruction should be in IT block -- `smlatbne r8,r6,r3,r8'
    {standard input}:180: Error: thumb conditional instruction should be in IT block -- `addgt r9,lr,#0'
    {standard input}:181: Error: thumb conditional instruction should be in IT block -- `rsblt r9,lr,#0'
    {standard input}:182: Error: thumb conditional instruction should be in IT block -- `smlatbne r9,r7,r3,r9'
    {standard input}:184: Error: thumb conditional instruction should be in IT block -- `addgt r0,lr,#0'
    {standard input}:185: Error: thumb conditional instruction should be in IT block -- `rsblt r0,lr,#0'
    {standard input}:186: Error: thumb conditional instruction should be in IT block -- `smlabbne r6,r6,r3,r0'
    {standard input}:188: Error: thumb conditional instruction should be in IT block -- `addgt r0,lr,#0'
    {standard input}:189: Error: thumb conditional instruction should be in IT block -- `rsblt r0,lr,#0'
    {standard input}:190: Error: thumb conditional instruction should be in IT block -- `smlabbne r7,r7,r3,r0'
    {standard input}:196: Warning: conditional infixes are deprecated in unified syntax
    {standard input}:196: Error: thumb conditional instruction should be in IT block -- `ldrgtd r4,[r1,#0]'
    {standard input}:205: Error: thumb conditional instruction should be in IT block -- `rsblt r0,lr,#0'
    {standard input}:206: Error: thumb conditional instruction should be in IT block -- `smlabbne r8,r8,r3,r0'
    {standard input}:209: Error: thumb conditional instruction should be in IT block -- `rsblt r0,lr,#0'
    {standard input}:210: Error: thumb conditional instruction should be in IT block -- `smlabbne r9,r9,r3,r0'
    make[1]: *** [armv4l/mpegvideo_armv5te.o] Error 1
    make[1]: Leaving directory `/home/cyient/Audio/MPlayer-1.0rc2/libavcodec'
    make: *** [libavcodec/libavcodec.a] Error 2
    cyient@cyient-Latitude-E5420:~/Audio/MPlayer-1.0rc2$



    MPG123:

    /bin/sh ../libtool --tag=CC --mode=link arm-linux-gnueabihf-gcc -O2 -fomit-frame-pointer -funroll-all-loops -finline-functions -ffast-math -g -O2 -o mpg123 audio.o buffer.o common.o compat.o control_generic.o equalizer.o getlopt.o httpget.o resolver.o genre.o mpg123.o metaprint.o local.o playlist.o streamdump.o term.o wav.o xfermem.o libmpg123/libmpg123.la legacy_module.o output/oss.o -lm
    libtool: link: arm-linux-gnueabihf-gcc -O2 -fomit-frame-pointer -funroll-all-loops -finline-functions -ffast-math -g -O2 -o .libs/mpg123 audio.o buffer.o common.o compat.o control_generic.o equalizer.o getlopt.o httpget.o resolver.o genre.o mpg123.o metaprint.o local.o playlist.o streamdump.o term.o wav.o xfermem.o legacy_module.o output/oss.o libmpg123/.libs/libmpg123.so -lm
    genre.o: file not recognized: File format not recognized
    collect2: error: ld returned 1 exit status
    make[3]: *** [mpg123] Error 1
    make[3]: Leaving directory `/home/cyient/Audio/mpg123/mpg123-1.22.2/src'
    make[2]: *** [all-recursive] Error 1
    make[2]: Leaving directory `/home/cyient/Audio/mpg123/mpg123-1.22.2/src'
    make[1]: *** [all] Error 2
    make[1]: Leaving directory `/home/cyient/Audio/mpg123/mpg123-1.22.2/src'
    make: *** [all-recursive] Error 1
    cyient@cyient-Latitude-E5420:~/Audio/mpg123/mpg123-1.22.2$

    MADPLAY:
    for libmad i tried with same command options while doing make :

    /bin/sh ../libtool --tag=CC --mode=link arm-linux-gnueabihf-gcc -O2 -fomit-frame-pointer -funroll-all-loops -finline-functions -ffast-math -g -O2 -o mpg123 audio.o buffer.o common.o compat.o control_generic.o equalizer.o getlopt.o httpget.o resolver.o genre.o mpg123.o metaprint.o local.o playlist.o streamdump.o term.o wav.o xfermem.o libmpg123/libmpg123.la legacy_module.o output/oss.o -lm
    libtool: link: arm-linux-gnueabihf-gcc -O2 -fomit-frame-pointer -funroll-all-loops -finline-functions -ffast-math -g -O2 -o .libs/mpg123 audio.o buffer.o common.o compat.o control_generic.o equalizer.o getlopt.o httpget.o resolver.o genre.o mpg123.o metaprint.o local.o playlist.o streamdump.o term.o wav.o xfermem.o legacy_module.o output/oss.o libmpg123/.libs/libmpg123.so -lm
    genre.o: file not recognized: File format not recognized
    collect2: error: ld returned 1 exit status
    make[3]: *** [mpg123] Error 1
    make[3]: Leaving directory `/home/cyient/Audio/mpg123/mpg123-1.22.2/src'
    make[2]: *** [all-recursive] Error 1
    make[2]: Leaving directory `/home/cyient/Audio/mpg123/mpg123-1.22.2/src'
    make[1]: *** [all] Error 2
    make[1]: Leaving directory `/home/cyient/Audio/mpg123/mpg123-1.22.2/src'
    make: *** [all-recursive] Error 1
    cyient@cyient-Latitude-E5420:~/Audio/mpg123/mpg123-1.22.2$
  • i taken new sub version from mplayer: this error is came
    Checking for FFmpeg ...
    Error: libavutil/x86/asm.h header is required for shared FFmpeg

    Check "config.log" if you do not understand why it failed.
    cyient@cyient-Latitude-E5420:~/mplayer$




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

    #include <libavutil/x86/asm.h>
    int main(void) { return 0; }

    arm-linux-gnueabihf-gcc -Wundef -Wall -Wno-switch -Wno-parentheses -Wpointer-arith -Wredundant-decls -Werror=format-security -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 -pipe -ffast-math -fomit-frame-pointer -fno-tree-vectorize /tmp/mplayer-configure-9885-15845/tmp.c -marm -D_REENTRANT -ffast-math -lrt -lasound -ldl -lpthread -o /tmp/mplayer-configure-9885-15845/tmp -lm
    In file included from /tmp/mplayer-configure-9885-15845/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/lib/gcc-cross/arm-linux-gnueabihf/4.8/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lasound
    collect2: error: ld returned 1 exit status
  • Hi,
    What is your SDK version and linaro toolchain ?
  • MPLAYER-1.1.1: while doing make. this error was came.

    /synthesis.o tremor/window.o stream/stream_tv.o stream/tv.o stream/frequencies.o stream/tvi_dummy.o sub/unrar_exec.o stream/stream_vcd.o libmpcodecs/ad_libvorbis.o libmpdemux/demux_ogg.o libmpcodecs/vd_xanim.o osdep/shmem.o ffmpeg/libpostproc/libpostproc.a ffmpeg/libavfilter/libavfilter.a ffmpeg/libavformat/libavformat.a ffmpeg/libavcodec/libavcodec.a ffmpeg/libswscale/libswscale.a ffmpeg/libswresample/libswresample.a ffmpeg/libavutil/libavutil.a -lm -ffast-math -lasound -ldl -lpthread -lpthread -ldl -rdynamic
    /usr/lib/gcc-cross/arm-linux-gnueabihf/4.8/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lasound
    collect2: error: ld returned 1 exit status
    make: *** [mplayer] Error 1
    cyient@cyient-Latitude-E5420:~/Audio/MPlayer-1.1.1$
  • We are using SDK-08 -- but we are not using this SDK -- we too sitara-linux-3.14 and toolchain is : gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux

    regards,
    Viswanath K
  • Hi,

    I'm able to build mplayer.

    I've attached the log.

    I have used the following configuration and mplayer version is "MPlayer-1.1.1"

    ./configure --prefix=/home/titus/fs --enable-cross-compile --cc=arm-linux-gnueabihf-gcc --host-cc=gcc --as=arm-linux-gnueabihf-as --ar=arm-linux-gnueabihf-ar --ranlib=arm-linux-gnueabihf-ranlib --target=arm-linux --disable-ivtv

     

    Share your email-ID and I send to you since here I can't attach the huge file size.

    8780.log_mplayer.txt

  • viswa.kondapalli@gmail.com -- really Titus -- what ever u r helping -- its like god only helping us. it is mean it. we were trying last 1 week -- day and night. plz -- sir. we are desperately - in seeking help.
  • we are using Ubuntu - 14.04- host
    target: AM335x-- processor, gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux -- toolchain. -- might you also using the same -- as per ur log.

    This error occurred for me : i given same the same:

    ./configure --prefix=/home/cyient/mplayer-lib --enable-cross-compile --cc=arm-linux-gnueabihf-gcc --host-cc=gcc --as=arm-linux-gnueabihf-as --ar=arm-linux-gnueabihf-ar --ranlib=arm-linux-gnueabihf-ranlib --target=arm-linux --disable-ivtv


    here some doubt while :configure -- summary : disable options ..?? is it alsa is in disable state..??

    Disabled optional drivers:
    Input: vstream radio tv-v4l1 tv-dshow librtmp live555 nemesi cddb cdda bluray smb
    Codecs: libvpx libschroedinger libdirac x264 xvid crystalhd libdv libopencore_amrwb libopencore_amrnb qtx win32 faad2 faac musepack libdca liba52 mpg123 libtheora libgsm speex toolame twolame libmad liblzo gif OpenJPEG
    Audio output: sun alsa openal jack pulse nas esd arts ivtv dxr2 sdl
    Video output: zr zr2 ivtv dxr3 dxr2 matrixview opengl sdl vesa gif89a jpeg mng svga caca aa ggi xvidix winvidix cvidix 3dfx xmga dga vdpau xvmc xv x11 directfb dfbmga bl xvr100 tdfx_vid wii s3fb tdfxfb mga


    once done -then- make .


    CC libavcodec/cook.o
    CC libavcodec/cook_parser.o
    CC libavcodec/cscd.o
    CC libavcodec/cyuv.o
    CC libavcodec/dca.o
    In file included from libavcodec/dca.c:48:0:
    libavcodec/dca.c: In function 'dca_subsubframe':
    libavcodec/arm/dca.h:36:5: error: can't find a register in class 'CORE_REGS' while reloading 'asm'
    libavcodec/arm/dca.h:36:5: error: 'asm' operand has impossible constraints
    libavcodec/dca.c:1275: confused by earlier errors, bailing out
    make[1]: *** [libavcodec/dca.o] Error 1
    make[1]: Leaving directory `/home/cyient/Audio/MPlayer-1.1.1/ffmpeg'
    make: *** [ffmpeg/libavcodec/libavcodec.a] Error 2
    cyient@cyient-Latitude-E5420:~/Audio/MPlayer-1.1.1$
  • we fixed the mp3 decoder issue with mp3 decoder - mpg123 -- the issue with tool chain -- audio lib files are missing, so how we figured it -- then fixed this issue.
  • Hi,
    Sounds good.
    Sorry for the delayed response.
    I just sent mplayer binary to your email-ID.

    You can also test "mplayer" on your board.