Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 88582 - avifile-0.7.43-20050224-r1 qtvidcap code fails to build PIC
Summary: avifile-0.7.43-20050224-r1 qtvidcap code fails to build PIC
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High normal
Assignee: Gentoo Media-video project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-04-10 05:42 UTC by Kevin F. Quinn (RETIRED)
Modified: 2005-07-13 04:59 UTC (History)
1 user (show)

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


Attachments
Fix non-PIC code in deinterlace-rgb.cpp and qtrenderer.cpp (avifile-0.7.43.20050224-pic.patch,1.38 KB, patch)
2005-04-10 05:49 UTC, Kevin F. Quinn (RETIRED)
Details | Diff
Patch against 0.7.43.20050224-r1 ebuild v1.1 (avifile-0.7.43.20050224-r1.ebuild-PIC.patch,973 bytes, patch)
2005-04-14 05:53 UTC, Kevin F. Quinn (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kevin F. Quinn (RETIRED) gentoo-dev 2005-04-10 05:42:40 UTC
Errors during build are:

deinterlace-rgb.cpp: In function `void copy_deinterlace_24(void*, const void*, int, int)':
deinterlace-rgb.cpp:44: error: can't find a register in class `GENERAL_REGS' while reloading `asm'

in both deinterlace-rgb.cpp and qtrenderer.cpp


Patch to follow.

# emerge info
Portage 2.0.51.19 (default-linux/x86/2005.0, gcc-3.4.3-20050110, glibc-2.3.4.20050125-r1, 2.6.11-hardened-r1 i686)
=================================================================
System uname: 2.6.11-hardened-r1 i686 Mobile Intel(R) Pentium(R) III CPU - M  1200MHz
Gentoo Base System version 1.4.16
Python:              dev-lang/python-2.3.4-r1 [2.3.4 (#1, Feb 19 2005, 20:56:14)]
ccache version 2.3 [enabled]
dev-lang/python:     2.3.4-r1
sys-devel/autoconf:  2.59-r6, 2.13
sys-devel/automake:  1.7.9-r1, 1.8.5-r3, 1.5, 1.4_p6, 1.6.3, 1.9.4
sys-devel/binutils:  2.15.92.0.2-r8
sys-devel/libtool:   1.5.10-r4
virtual/os-headers:  2.6.11
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-g -O2 -march=pentium3 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.3/env /usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-g -O2 -march=pentium3 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache distlocks nostrip sandbox sfperms strict userpriv"
GENTOO_MIRRORS="http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/ http://ftp.linux.ee/pub/gentoo/distfiles/ http://ftp.easynet.nl/mirror/gentoo/ http://ftp.heanet.ie/pub/gentoo/"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/portage"
SYNC="rsync://192.168.31.11/gentoo-portage"
USE="x86 X aalib acl acpi alsa apache2 apm arts avi berkdb bitmap-fonts cdr crypt cups curl dlloader dvd dvdr emboss encode esd faad fam flac foomaticdb fortran gcj gdbm ggi gif gpm gtk gtk2 hardened imagemagick imlib ipv6 java jce jikes jpeg junit kde kdeenablefinal kerberos ldap libg++ libwww mad makecheck mbox mikmod mmx motif mozilla mp3 mpeg multitarget nas ncurses nls odbc oggvorbis opengl oss pam pcmcia pdflib perl pic pie png pnp postgres python qt quicktime readline samba sdl slang speex spell sse ssl svga tcltk tcpd tiff truetype truetype-fonts trusted type1-fonts unicode usb xinerama xml2 xmms xprint xv zlib video_cards_ati linguas_en_gb linguas_it linguas_de linguas_es linguas_fr"
Unset:  ASFLAGS, CBUILD, CTARGET, LANG, LC_ALL, LDFLAGS
Comment 1 Kevin F. Quinn (RETIRED) gentoo-dev 2005-04-10 05:49:17 UTC
Created attachment 55861 [details, diff]
Fix non-PIC code in deinterlace-rgb.cpp and qtrenderer.cpp

The two mentioned files fail to build with hardened gcc; this patch should fix.

Applied with "use pic && epatch ${FILESDIR}/avifile-0.7.43.20050224-pic.patch"
- in which case 'pic' needs to be added to IUSE, obviously.

BTW also "libmad" is missing from IUSE - required for "$(use_enable libmad)"
Comment 2 Kevin F. Quinn (RETIRED) gentoo-dev 2005-04-14 05:53:56 UTC
Created attachment 56251 [details, diff]
Patch against 0.7.43.20050224-r1 ebuild v1.1

Ebuild patch to incorporate code patch as described above.
Comment 3 Diego Elio Pettenò (RETIRED) gentoo-dev 2005-04-22 11:45:28 UTC
Is still an issue? I can't reproduce on amd64 enabling x86opts and with pic obviously enabled.
Comment 4 Kevin F. Quinn (RETIRED) gentoo-dev 2005-04-24 03:28:48 UTC
amd64 has many more registers than x86, so I'm not surprised there's no problem on amd64 - it's not something I'd considered.  The problem on x86 is that the list of general registers is very small, and the clobber list on the affected functions is long enough to use up all of them, indeed too many when building PIC which has one fewer general register.

The patch should be conditional on 'use x86' as well, i.e.

use x86 && use pic && epatch...
Comment 5 Diego Elio Pettenò (RETIRED) gentoo-dev 2005-07-13 04:07:03 UTC
*** Bug 92487 has been marked as a duplicate of this bug. ***
Comment 6 Diego Elio Pettenò (RETIRED) gentoo-dev 2005-07-13 04:59:37 UTC
Patch applied. Maybe you should send that upstream, too.