Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 87527 - vamps-0.97 doesnt compile
Summary: vamps-0.97 doesnt compile
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo Media-video project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-04-01 01:37 UTC by Florian Engelhardt
Modified: 2005-04-05 19:06 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Florian Engelhardt 2005-04-01 01:37:31 UTC
it is missing -lm in the linker call

Reproducible: Always
Steps to Reproduce:
1. emerge vamps
2.
3.

Actual Results:  
Calculating dependencies ...done!
>>> emerge (1 of 1) media-video/vamps-0.97 to /
>>> md5 src_uri ;-) vamps-0.97.tar.gz
>>> Unpacking source...
>>> Unpacking vamps-0.97.tar.gz to /var/tmp/portage/vamps-0.97/work
>>> Source unpacked.
i686-pc-linux-gnu-gcc -Os -march=athlon-xp -fomit-frame-pointer -pipe
-funroll-loops -m3dnow -msse -mmmx   -c -o vamps.o vamps.c
i686-pc-linux-gnu-gcc -Os -march=athlon-xp -fomit-frame-pointer -pipe
-funroll-loops -m3dnow -msse -mmmx   -c -o requant.o requant.c
i686-pc-linux-gnu-gcc -Os -march=athlon-xp -fomit-frame-pointer -pipe
-funroll-loops -m3dnow -msse -mmmx   -c -o play_cell.o play_cell.c
i686-pc-linux-gnu-gcc -o play_cell  play_cell.o -ldvdread
strip play_cell
i686-pc-linux-gnu-gcc -o vamps  vamps.o requant.o -lpthread
requant.o(.text+0x226): In function `getNewQuant':
: undefined reference to `floor'
requant.o(.text+0x27c): In function `getNewQuant':
: undefined reference to `floor'
collect2: ld returned 1 exit status
make: *** [vamps] Error 1


Expected Results:  
should compile

i fixed it with the following steps:
ebuild vamps-0.97.ebuild unpack
cd /var/tmp/portage/vamps-0.97/work/vamps-0.97/
vim Makefile
added -lm in line 25
save and close
ebuild vamps-0.97.ebuild compile

Maybe someone can make a patch or we should report this
problem tp upstream.
Comment 1 Jan Brinkmann (RETIRED) gentoo-dev 2005-04-01 09:26:41 UTC
please post the output of 'emerge info', thanks in advance.
Comment 2 Jan Brinkmann (RETIRED) gentoo-dev 2005-04-01 12:16:44 UTC
please try if compiling still fails if you use sane CFLAGS, edit the make.conf and replace the current setting with CFLAGS="-O2 -march=athlon-xp -pipe"
Comment 3 Florian Engelhardt 2005-04-02 04:14:20 UTC
discovery ~ # emerge info
Portage 2.0.51.19 (default-linux/x86/2004.0, gcc-3.4.3-20050110, glibc-2.3.4.20050125-r1, 2.6.11 i686)
=================================================================
System uname: 2.6.11 i686 AMD Athlon(tm) XP  2800+
Gentoo Base System version 1.6.10
Python:              dev-lang/python-2.2.3-r5,dev-lang/python-2.3.5 [2.3.5 (#1, Feb 18 2005, 09:45:18)]
distcc 2.18.3 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
dev-lang/python:     2.2.3-r5, 2.3.5
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.4_p6, 1.7.9-r1, 1.8.5-r3, 1.6.3, 1.5, 1.9.5
sys-devel/binutils:  2.15.92.0.2-r7
sys-devel/libtool:   1.5.14
virtual/os-headers:  2.6.8.1-r4
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-Os -march=athlon-xp -fomit-frame-pointer -pipe -funroll-loops -m3dnow -msse -mmmx"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /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="-Os -march=athlon-xp -fomit-frame-pointer -pipe -funroll-loops -m3dnow -msse -mmmx"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms"
GENTOO_MIRRORS="ftp://ftp.uni-erlangen.de/pub/mirrors/gentoo ftp://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ ftp://ftp.solnet.ch/mirror/Gentoo"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 3dnow 3dnowex X aalib alsa apm avi berkdb bitmap-fonts cdr crypt cups curl dga dvd emboss encode fam flac font-server foomaticdb fortran gdbm gif gpm gtk gtk2 guile imagemagick imlib ipv6 jpeg junit libg++ libwww mad mikmod mmx mmx2 motif mozilla moznoxft mp3 mpeg mysql ncurses nls nocardbus nptl nptlonly nvidia oggvorbis opengl pam pdflib perl png python quicktime readline slang speex spell sse ssl svga tcltk tcpd tga theora tiff truetype truetype-fonts type1-fonts unicode v4l v4l2 xml xml2 xmms xv xvid xvmc zlib"
Unset:  ASFLAGS, CBUILD, CTARGET, LANG, LC_ALL, LDFLAGS




emerging it with CFLAGS="-O2 -march=athlon-xp -pipe" fixed it

:)
Comment 4 Jan Brinkmann (RETIRED) gentoo-dev 2005-04-02 08:43:46 UTC
ah, i guess -Os was the problem. it's not recommended to use that flag. however, i'm going to mark this one as invalid
Comment 5 Paul Thompson 2005-04-05 19:06:10 UTC
Why is it not recommended to use the -Os CFLAG? Ive been using it for years
now, and this is the only 'problem' I have noticed, and then you go ahead
and special case amd64 *anyway* and apply the patch that would fix it...
If its that scary to manually specify linking against math, isnt there a
function that allows you to test the existance of '-Os' in the CFLAGS?
And how is manually specifying -lm going to harm anyone else?

Hmmm. Probably just another ebuild Ill have to maintain for myself. Or
even more ugly, just specify USE=adm64 for vamps, even though Im not.