Bug 15503 - FooBillard won't compile under new xfree opengl
Bug#: 15503 Product:  Gentoo Linux Version: unspecified Platform: x86
OS/Version: Linux Status: RESOLVED Severity: normal Priority: P2
Resolution: FIXED Assigned To: games@gentoo.org Reported By: nevernow@gmx.net
Component: Games
URL: 
Summary: FooBillard won't compile under new xfree opengl
Keywords:  
Status Whiteboard: 
Opened: 2003-02-11 12:18 0000
Description:   Opened: 2003-02-11 12:18 0000
I have an ATI Radeon 8500, DRI enabled and xfree openGL acceleration. I tried
to emerge FooBillard 2.2 and it didn't compile, complaining about a missing
reference to a gl library. On the FooBillard FAQ page at
http://foobillard.sunsite.dk/, I found a solution which consists in adding a
line to the config info. The line is: "...$ configure --enable-bumpref=no". I
added it to the games eclass and it worked. 

Reproducible: Always
Steps to Reproduce:

1.Use an ATI Radeon with DRI enabled and xfree openGL support.
2.Emerge foobillard.
3.

Actual Results:  
It didn't compile, exiting with the following error: 

gcc -Wall -O3 `freetype-config --cflags` `sdl-config --cflags` -DUSE_SDL 
`freetype- config --libs` `sdl-config --libs` -o foobillard billard3d.o
billmove.o billard.o vmath.o ball.o png_loader.o table.o queue.o aiplayer.o
options.o evaluate_move.o helpscreen.o textobj.o font.o sys_stuff.o
net_socket.o sound_stuff.o menu.o bumpref.o -lSM -lICE -L/usr/ X11R6/lib -lGL
-lGLU -lXaw -lm -lXi -lpng -lz 
bumpref.o(.text+0xc06): In function `bumpref_setup_vp_ts_rc': 
: undefined reference to `glGenProgramsNV' 
bumpref.o(.text+0xc1b): In function `bumpref_setup_vp_ts_rc': 
: undefined reference to `glBindProgramNV' 
bumpref.o(.text+0xc46): In function `bumpref_setup_vp_ts_rc': 
: undefined reference to `glLoadProgramNV' 
bumpref.o(.text+0xc7f): In function `bumpref_setup_vp_ts_rc': 
: undefined reference to `glTrackMatrixNV' 
bumpref.o(.text+0xca3): In function `bumpref_setup_vp_ts_rc': 
: undefined reference to `glTrackMatrixNV' 
bumpref.o(.text+0xcee): In function `bumpref_setup_vp_ts_rc': 
: undefined reference to `glProgramParameter4fNV' 
bumpref.o(.text+0xd03): In function `bumpref_setup_vp_ts_rc': 
: undefined reference to `glBindProgramNV' 
collect2: ld returned 1 exit status 
make[1]: *** [foobillard] Error 1 
make[1]: Leaving directory
`/var/tmp/portage/foobillard-2.2/work/foobillard-2.2/src' 
make: *** [all-recursive] Error 1 

!!! ERROR: app-games/foobillard-2.2 failed. 
!!! Function src_compile, Line 26, Exitcode 2 
!!! (no error message)

Expected Results:  
Well, it should have compiled! :) I guess the ebuild should somehow
discriminate whether you have an Nvidia card or not.

Athlon XP 1700, ATI Radeon 8500, DRI, xfree openGL.

------- Comment #1 From SpanKY 2003-02-11 13:00:46 0000 -------
odd that it doesnt support latest xfree ... i *think* it supported the older
one ...

------- Comment #2 From xenon 2003-02-11 14:04:09 0000 -------
#vapier: I tagged it as critical in relation with the package, since it doesn't
even install. Of course a game will never be critical by itself in a system.
Anyway, it's probably better now. :)

------- Comment #3 From SpanKY 2003-02-11 15:26:59 0000 -------
yeah, i just confirmed ... the old xfree-4.2.1 will let this guy compile just
fine, its the new 
xfree that breaks it 

have at it seemant ;) 

------- Comment #4 From Seemant Kulleen (RETIRED) 2003-02-11 18:09:52 0000 -------
do you have xfree-drm emerged?

------- Comment #5 From SpanKY 2003-02-11 18:35:49 0000 -------
it doesnt have to do with xfree-drm ... i emerged xfree-4.2.99.x and it failed,
i emerged xfree-4.2.1 and it worked, re-emerged xfree-4.2.99.x and it failed

basically the opengl header files claim that the libraries provide functions
that they dont (i'm assuming)

------- Comment #6 From SpanKY 2003-02-12 01:36:48 0000 -------
quick fix is to pass --disable-bumpref, but we're still left with this issue of
functions not being defined

------- Comment #7 From Seemant Kulleen (RETIRED) 2003-02-12 09:57:43 0000 -------
yep, definitely an x-4.2.99.x issue, coz it works with the nvidia opengl stuffs
(3xxx driver anyway)

------- Comment #8 From Seemant Kulleen (RETIRED) 2003-02-26 04:38:32 0000 -------
can you check with X-4.2.99.902 please?

------- Comment #9 From Faye Pearson 2003-02-26 15:28:51 0000 -------
This is a foobillard issue.  Stupid configuration defaults to some NVIDIA
specific GL 
commands. 

I changed the following two lines and *DIDN'T* USE nv. 

IUSE="sdl nv" 
egamesconf `use_enable sdl SDL` `use_enable nv bumpref` 

compiles fine then :) 

------- Comment #10 From xenon 2003-02-26 16:28:21 0000 -------
I told ya it was foobillard's fault! :) It expexts all users to have an Nvidia
card.

------- Comment #11 From Faye Pearson 2003-02-26 17:30:22 0000 -------
more than that I'd say it was specific to the NVidia Binary Driver. 
Is that the difference for the user who said it works in 4.2.1 and doesn't in 4.2.99? 

------- Comment #12 From SpanKY 2003-02-26 17:49:55 0000 -------
no, foobillard compiles under 4.2.1 while using the X opengl libraries 

------- Comment #13 From SpanKY 2003-03-05 10:00:15 0000 -------
ok, i added a small test program to enable/disable bumpmap depending on whether
your system supports it ... enjoy ;)

http://cvs.gentoo.org/cgi-bin/viewcvs.cgi/gentoo-x86/app-games/foobillard/foobillard-2.4.ebuild.diff?r1=1.1&r2=1.2
http://cvs.gentoo.org/cgi-bin/viewcvs.cgi/gentoo-x86/app-games/foobillard/files/bumpmaptest.c?rev=1.1&content-type=text/vnd.viewcvs-markup