Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#17993 closed defect (worksforme)

ffmpeg +mmx fails

Reported by: steven@… Owned by: acho@…
Priority: Normal Milestone:
Component: ports Version: 1.7.0
Keywords: Cc: ddennedy (Dan Dennedy), dbevans (David B. Evans)
Port: ffmpeg

Description

Trying to install ffmpeg with mmx fails:

Fails: install ffmpeg +a52 +avfilter +darwin_i386 +extvorbis +faac +faad +gpl +lame +postproc +theora +x264 +xvid +mmx

OK: install ffmpeg +a52 +avfilter +darwin_i386 +extvorbis +faac +faad +gpl +lame +postproc +theora +x264 +xvid

The first fails in some mmx module.

Greetings, Steven

Change History (12)

comment:1 Changed 15 years ago by mf2k (Frank Schima)

Owner: changed from macports-tickets@… to acho@…
Port: ffmpeg added

comment:2 Changed 15 years ago by jmroot (Joshua Root)

You'll notice that port variants ffmpeg says (in part):

mmx: enable mmx support, experimental; does not build in gcc-4.2 or xcode 3.0 gcc-4.0

comment:3 Changed 15 years ago by dbevans (David B. Evans)

The mmx variant description is quite old and there have been a lot of changes in ffmpeg/ffmpeg-devel recently.

This requires some one with an Intel box to check and see if the current ffmpeg/ffmpeg-devel ports continue to have this problem or not and why. If there is a problem as described and it can be corrected, the results should be forwarded to the upstream developers as they are now bug fixing for a new release scheduled for about two weeks from now.

comment:4 Changed 15 years ago by ddennedy (Dan Dennedy)

Heh, for me it does not even build on 10.5 Intel even when using variant specification -mmx !

I synced today.

$ sudo port -c -d install ffmpeg-devel -mmx

...
DEBUG: Environment: CFLAGS='-O2 -DHAVE_LRINTF -I/opt/local/include' CPPFLAGS='-I/opt/local/include' CXXFLAGS='-O2' MACOSX_DEPLOYMENT_TARGET='10.5' CPP='/usr/bin/cpp-4.0' CXX='/usr/bin/g++-4.0' F90FLAGS='-O2' LDFLAGS='-L/opt/local/lib' FCFLAGS='-O2' OBJC='/usr/bin/gcc-4.0'
INSTALL='/usr/bin/install -c' OBJCFLAGS='-O2' FFLAGS='-O2' CC='/usr/bin/gcc-4.0'
DEBUG: Assembled command: 'cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_multimedia_ffmpeg-devel/work/trunk" && ./configure --prefix=/opt/local --disable-vhook --enable-gpl --enable-postproc --enable-swscale --enable-avfilter --enable-avfilter-lavf --enable-libmp3lame --enable-libvorbis --enable-libtheora --enable-libdirac --enable-libschroedinger --enable-libfaac --enable-libfaad --enable-libxvid --enable-libx264 --mandir=/opt/local/share/man --enable-shared --enable-pthreads --disable-mmx --cc=gcc-4.0'

...NOTE MMX is requested disabled...
gcc-4.0 -dynamiclib -Wl,-single_module -Wl,-install_name,/opt/local/lib/libswscale.dylib,-current_version,1.6.1,-compatibility_version,1 -Wl,-read_only_relocs,suppress -L"/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_multimedia_ffmpeg-devel/work/trunk"/libavutil -Wl,-dynamic,-search_paths_first -L/opt/local/lib -o libswscale/libswscale.1.dylib libswscale/rgb2rgb.o libswscale/swscale.o libswscale/swscale_avoption.o libswscale/yuv2rgb.o -lavutil -L"/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_multimedia_ffmpeg-devel/work/trunk"/libavutil -lavutil -lz -lbz2 -lm -ldirac_decoder -ldirac_encoder -lfaac -lfaad -lmp3lame -lm -L/opt/local/lib -lschroedinger-1.0 -lpthread -loil-0.3 -ltheora -logg -lvorbisenc -lvorbis -logg -lx264 -lm -lxvidcore
ld: absolute addressing (perhaps -mdynamic-no-pic) used in _rgb24tobgr24_MMX from libswscale/rgb2rgb.o not allowed in slidable image


This symbol appears in libswscale/rgb2rgb.c.

I have to use the no_gpl variant to install this today.

comment:5 Changed 15 years ago by ddennedy (Dan Dennedy)

Cc: dan@… added

Cc Me!

comment:6 Changed 15 years ago by dbevans (David B. Evans)

Looks like two issues here:

It appears that recent changes to libswscale/rgb2rgb.c upstream have reorganized the ifdef semantics in such a way that the various intel optimizations are compiled any time that a x86 platform is detected in configure without regard to the setting of the --disable-mmx switch. As you say, the code is disabled however if you select the +no_gpl variant since this code is licensed under gpl. This needs to be reported upstream.

Besides this, the error type noted above is one that is often seen as a result of a bug in the XCode 3.0 linker that was fixed in XCode 3.1. See the XCode release notes (see http://developer.apple.com/releasenotes/DeveloperTools/RN-Id/index.html) under Bugs fixed in XCode 3.1

No support for text relocs

Assembly code that uses instructions that require dyld to update the instructions at runtime are currently unsupported. The previous linker allow them with the option -read_only_relocs suppress

This should work on Tiger (XCode 2.5) and Leopard with XCode 3.1.

So are you using XCode 3.0 by any chance?

comment:7 Changed 15 years ago by dbevans (David B. Evans)

Cc: devans@… added

Cc Me!

comment:8 Changed 15 years ago by steven@…

I was using XCode 3.0 yes, but upgraded now to 3.1.2.

comment:9 Changed 15 years ago by dbevans (David B. Evans)

So did that solve the problem for you (except for the --disable-mmx not working)? If not, is the error any different now?

comment:10 Changed 15 years ago by ddennedy (Dan Dennedy)

Upgrading XCode to 3.2.1 fixed the build for me without having to specify a variant!

comment:11 Changed 15 years ago by dbevans (David B. Evans)

Resolution: worksforme
Status: newclosed

comment:12 Changed 15 years ago by (none)

Milestone: Port Bugs

Milestone Port Bugs deleted

Note: See TracTickets for help on using tickets.