Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 496346 - media-video/ffmpeg-1.2.4 fails to build on loongson mips
Summary: media-video/ffmpeg-1.2.4 fails to build on loongson mips
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: MIPS Linux
: Normal normal (vote)
Assignee: Gentoo Media-video project
URL:
Whiteboard:
Keywords:
: 496350 (view as bug list)
Depends on:
Blocks:
 
Reported: 2013-12-29 04:43 UTC by Tom Li
Modified: 2022-08-01 22:34 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,2.72 KB, text/plain)
2014-01-02 19:22 UTC, Tom Li
Details
config.log (config.log,292.11 KB, text/plain)
2014-01-02 19:23 UTC, Tom Li
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Li 2013-12-29 04:43:39 UTC
>>> Emerging (1 of 1) media-video/ffmpeg-1.2.4
 * ffmpeg-1.2.4.tar.bz2 SHA256 SHA512 WHIRLPOOL size ;-) ...                                                                    [ ok ]
>>> Unpacking source...
>>> Unpacking ffmpeg-1.2.4.tar.bz2 to /var/tmp/portage/media-video/ffmpeg-1.2.4/work
>>> Source unpacked in /var/tmp/portage/media-video/ffmpeg-1.2.4/work
>>> Preparing source in /var/tmp/portage/media-video/ffmpeg-1.2.4/work/ffmpeg-1.2.4 ...
 * Applying ffmpeg-1.2.4-freetype251.patch ...                                                                                  [ ok ]
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/media-video/ffmpeg-1.2.4/work/ffmpeg-1.2.4 ...
ERROR: fontconfig not found

If you think configure made a mistake, make sure you are using the latest
version from Git.  If the latest version fails, report the problem to the
ffmpeg-user@ffmpeg.org mailing list or IRC #ffmpeg on irc.freenode.net.
Include the log file "config.log" produced by configure as this will help
solving the problem.
 * ERROR: media-video/ffmpeg-1.2.4::gentoo failed (configure phase):
 *   (no error message)
 * 
 * Call stack:
 *     ebuild.sh, line  93:  Called src_configure
 *   environment, line 2690:  Called die
 * The specific snippet of code:
 *       "${S}/configure" --prefix="${EPREFIX}/usr" --libdir="${EPREFIX}/usr/$(get_libdir)" --shlibdir="${EPREFIX}/usr/$(get_libdir)" --mandir="${EPREFIX}/usr/share/man" --enable-shared --cc="$(tc-getCC)" --cxx="$(tc-getCXX)" --ar="$(tc-getAR)" --optflags="${CFLAGS}" --extra-cflags="${CFLAGS}" --extra-cxxflags="${CXXFLAGS}" $(use_enable static-libs static) ${myconf} || die
 * 
 * If you need support, post the output of `emerge --info '=media-video/ffmpeg-1.2.4::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=media-video/ffmpeg-1.2.4::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/media-video/ffmpeg-1.2.4/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/media-video/ffmpeg-1.2.4/temp/environment'.
 * Working directory: '/var/tmp/portage/media-video/ffmpeg-1.2.4/work/ffmpeg-1.2.4_build'
 * S: '/var/tmp/portage/media-video/ffmpeg-1.2.4/work/ffmpeg-1.2.4'


Reproducible: Always

Steps to Reproduce:
1. emerge ffmpeg



Portage 2.2.7 (default/linux/mips/13.0/mipsel/multilib/n32, gcc-4.8.2, glibc-2.17, 3.12.6-e-yeeloong-gaizi mips64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-3.12.6-e-yeeloong-gaizi-mips64-ICT_Loongson-2_V0.3_FPU_V0.1-with-gentoo-2.2
KiB Mem:     1031968 total,    206752 free
KiB Swap:     977232 total,    970496 free
Timestamp of tree: Fri, 27 Dec 2013 12:30:01 +0000
ld GNU ld (GNU Binutils) 2.23.2
distcc 3.1 mips64el-unknown-linux-gnu [enabled]
app-shells/bash:          4.2_p45
dev-lang/python:          2.7.6, 3.3.3
dev-util/cmake:           2.8.12.1-r2
dev-util/pkgconfig:       0.28
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.12.4
sys-apps/sandbox:         2.6-r1
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.12.6, 1.14.1
sys-devel/binutils:       2.23.2
sys-devel/gcc:            4.8.2
sys-devel/gcc-config:     1.8
sys-devel/libtool:        2.4.2
sys-devel/make:           4.0-r1
sys-kernel/linux-headers: 3.12 (virtual/os-headers)
sys-libs/glibc:           2.17
Repositories: gentoo gentoo-zh mate-overlay
ACCEPT_KEYWORDS="mips ~mips"
ACCEPT_LICENSE="* -@EULA"
CBUILD="mips64el-unknown-linux-gnu"
CFLAGS="-O2 -march=loongson2f -mplt -Wa,-mfix-loongson2f-nop -pipe -fomit-frame-pointer -mno-branch-likely"
CHOST="mips64el-unknown-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/sandbox.d /etc/terminfo"
CPPFLAGS="-O2 -march=loongson2f -mplt -Wa,-mfix-loongson2f-nop -pipe -fomit-frame-pointer -mno-branch-likely"
CXXFLAGS="-O2 -march=loongson2f -mplt -Wa,-mfix-loongson2f-nop -pipe -fomit-frame-pointer -mno-branch-likely"
DISTDIR="/var/lib/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distcc distcc-pump distlocks ebuild-locks fixlafiles merge-sync metadata-transfer news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://mirrors.sohu.com/gentoo/"
LANG="en_US.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j8"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/lib/layman/gentoo-zh /var/lib/layman/mate"
USE="X aac acl alac alsa berkdb bzip2 cairo cjk cli cracklib crypt cups cxx dbus flac fontconfig gdbm git gpm gudev iconv icu infinality ios ipod jpeg lame loongson2f mips modules mp3 mudflap multilib ncurses networkmanager nls nptl ogg opengl opus pam pch pcre png policykit python3 readline session sqlite ssl svg tcpd tiff twolame udisks unicode upnp vim-syntax vorbis webm xmp zlib zsh-completion" ABI_MIPS="n32" ALSA_CARDS="au1x00" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="zh_CN en_US zh cn" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_3" RUBY_TARGETS="ruby19 ruby18" USERLAND="GNU" VIDEO_CARDS="fbdev" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
USE_PYTHON="2.7 3.3"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, SYNC

=================================================================
                        Package Settings
=================================================================

media-libs/fontconfig-2.11.0 was built with the following:
USE="-doc -static-libs" ABI_MIPS="n32 -n64 -o32"
Comment 1 Rafał Mużyło 2013-12-29 05:43:54 UTC
...well ? Attach that config.log.
Comment 2 Tom Li 2013-12-29 06:48:49 UTC
Now I'm busy. I'll back to test it later on.
Comment 3 Tom Li 2013-12-29 06:50:31 UTC
I have very much doubt on distcc. Because of ffmpeg use the compiler to configure the source.

But I need to confirm it.  Will report back soon.
Comment 4 Jeroen Roovers (RETIRED) gentoo-dev 2013-12-30 00:55:33 UTC
1) Please attach the entire build log to this bug report.
2) Please attach the file config.log from the top build directory to this bug report.
Comment 5 Tom Li 2014-01-02 14:50:59 UTC
*** Bug 496350 has been marked as a duplicate of this bug. ***
Comment 6 Tom Li 2014-01-02 19:22:50 UTC
Created attachment 366786 [details]
build.log
Comment 7 Tom Li 2014-01-02 19:23:11 UTC
Created attachment 366788 [details]
config.log
Comment 8 Tom Li 2014-01-02 19:25:36 UTC
build.log and config.log attached.

It seems

>  error: '-mips32r2' conflicts with the other architecture options, which specify a mips3 processor

during configure cause the issue.
Comment 9 Tom Li 2014-01-02 19:46:00 UTC
media-video/ffmpeg-1.2.3 also has the issue.
Comment 10 Tom Li 2014-01-02 19:49:17 UTC
media-video/ffmpeg-1.0.8 also has the issue.
Comment 11 Tom Li 2014-01-02 19:52:31 UTC
As well as media-video/ffmpeg-1.0.7.
Comment 12 Tom Li 2014-01-02 20:03:08 UTC
media-video/ffmpeg-0.10.10 works, too ancient version...
Comment 13 Rafał Mużyło 2014-01-02 20:37:14 UTC
Just about every single error looks the same:
mips64el-unknown-linux-gnu-gcc -O2 -march=loongson2f -mplt -Wa,-mfix-loongson2f-nop -pipe -fomit-frame-pointer -mno-branch-likely -D_ISOC99_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -DPIC -O2 -march=loongson2f -mplt -Wa,-mfix-loongson2f-nop -pipe -fomit-frame-pointer -mno-branch-likely -O2 -march=loongson2f -mplt -Wa,-mfix-loongson2f-nop -pipe -fomit-frame-pointer -mno-branch-likely -march=loongson2f -std=c99 -fomit-frame-pointer -fPIC -mips32r2 -mdsp -mdspr2 -mhard-float -c -o /var/tmp/portage/media-video/ffmpeg-1.2.4/temp/ffconf.pJZpt6hJ.o /var/tmp/portage/media-video/ffmpeg-1.2.4/temp/ffconf.a2ykCyPc.c
Assembler messages:
Error: -mips32r2 conflicts with the other architecture options, which imply -mips3
Warning: mips3 ISA does not support DSP ASE
Warning: mips3 ISA does not support DSP R2 ASE

Either ffmpeg configure script doesn't like your C{XX,PP}FLAGS (which look a bit fishy, btw.) or it doesn't support your hardware (by bug or choice).
Comment 14 Tom Li 2014-01-02 22:17:06 UTC
Now my temporary solution is using libav instead of ffmpeg. The latest version just build without any problem. 

I think if I remove -mips32r2 from ffmpeg's flags, it will build without problem, hum...
Comment 15 Alexis Ballier gentoo-dev 2014-01-03 11:57:40 UTC
does it work with 
$ EXTRA_FFMPEG_CONF="--disable-mips32r2" emerge -1 ffmpeg

?

I think we should add the relevant useflags for these new mips optimisations then
Comment 16 Tom Li 2014-01-22 21:50:46 UTC
(In reply to Alexis Ballier from comment #15)
> does it work with 
> $ EXTRA_FFMPEG_CONF="--disable-mips32r2" emerge -1 ffmpeg
> 
> ?
> 
> I think we should add the relevant useflags for these new mips optimisations
> then

Yes, it works. It just finished the configuration without any problem. :)
Comment 17 Markos Chandras (RETIRED) gentoo-dev 2014-01-23 18:06:36 UTC
(In reply to Alexis Ballier from comment #15)
> does it work with 
> $ EXTRA_FFMPEG_CONF="--disable-mips32r2" emerge -1 ffmpeg
> 
> ?
> 
> I think we should add the relevant useflags for these new mips optimisations
> then

Is this related to #498082?
The mips profiles are ISA agnostic. They only cover ABI, 32/64bits and endianness options. So these flags should be masked on per user basis.
Comment 18 Alexis Ballier gentoo-dev 2014-01-23 19:38:00 UTC
(In reply to Markos Chandras from comment #17)
> (In reply to Alexis Ballier from comment #15)
> > does it work with 
> > $ EXTRA_FFMPEG_CONF="--disable-mips32r2" emerge -1 ffmpeg
> > 
> > ?
> > 
> > I think we should add the relevant useflags for these new mips optimisations
> > then
> 
> Is this related to #498082?
> The mips profiles are ISA agnostic. They only cover ABI, 32/64bits and
> endianness options. So these flags should be masked on per user basis.

yes it is, but so far it was automagically enabled and impossible to disable without the above command

now that use.masks/unmasks are in place I'll backport them to the ~arch ebuilds