Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
xorg-server 1.11.4 compile time error
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
fnoord
n00b
n00b


Joined: 06 Nov 2011
Posts: 5

PostPosted: Thu Feb 02, 2012 5:13 pm    Post subject: xorg-server 1.11.4 compile time error Reply with quote

Updating xorg-server from 1.11.3 to 1.11.4 fails for me with some strange compiler-error stating that there is an out-of-bound array access in some part of the xorg server code.

Previous versions of xorg-server are still building without any problems; the active use flags are:
ipv6
nptl
udev
xorg

Build log contains a shitload of warnings (>13k lines) trailed by a compile time error:

In file included from /var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86Crtc.h:30:0,
from /var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:44:
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86Modes.h:102:1: warning: redundant redeclaration of ‘xf86ValidateModesFlags’
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86Modes.h:72:1: note: previous declaration of ‘xf86ValidateModesFlags’ was here
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:240:5: warning: initialization discards qualifiers from pointer target type
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:244:5: warning: initialization discards qualifiers from pointer target type
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:248:5: warning: initialization discards qualifiers from pointer target type
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:252:5: warning: initialization discards qualifiers from pointer target type
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:256:5: warning: initialization discards qualifiers from pointer target type
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:260:5: warning: initialization discards qualifiers from pointer target type
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:264:5: warning: initialization discards qualifiers from pointer target type
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:268:5: warning: initialization discards qualifiers from pointer target type
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:272:5: warning: initialization discards qualifiers from pointer target type
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:276:5: warning: initialization discards qualifiers from pointer target type
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c: In function ‘DDCModesFromCEAExtension’:
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:988:52: warning: declaration of ‘MonPtr’ shadows a global declaration
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/common/xf86str.h:229:12: warning: shadowed declaration is here
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c: In function ‘handle_detailed_modes’:
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:750:19: error: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:749:19: error: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:748:19: error: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:747:33: error: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:750:19: error: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:749:19: error: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:748:19: error: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:747:33: error: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:750:19: error: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:749:19: error: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:748:19: error: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:747:33: error: array subscript is above array bounds
make[4]: *** [xf86EdidModes.lo] Error 1
make[4]: Leaving directory `/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4_build/hw/xfree86/modes'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4_build/hw/xfree86'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4_build/hw/xfree86'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4_build/hw'
make: *** [all-recursive] Error 1

Emerge also states that:
* Running elibtoolize in: xorg-server-1.11.4/
* We've already been run in this tree; you should
* avoid this if possible (perhaps by filing a bug)

Are there any obvious reasons or known bugs with that, might that just be a configuration issue and/or should I file a bug about this?
Back to top
View user's profile Send private message
chithanh
Developer
Developer


Joined: 05 Aug 2006
Posts: 1390
Location: Berlin, Germany

PostPosted: Fri Feb 03, 2012 1:36 am    Post subject: Reply with quote

Do you have anything installed to /usr/local that could interfere?
Back to top
View user's profile Send private message
Khrisbie
n00b
n00b


Joined: 26 Jun 2006
Posts: 7
Location: paris, France

PostPosted: Fri Feb 03, 2012 7:57 am    Post subject: Reply with quote

Same thing here.

I looked into the source code :

/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:750:19: erreur: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:749:19: erreur: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:748:19: erreur: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:747:33: erreur: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:750:19: erreur: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:749:19: erreur: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:748:19: erreur: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:747:33: erreur: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:750:19: erreur: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:749:19: erreur: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:748:19: erreur: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:747:33: erreur: array subscript is above array bounds

Looks like there is a patch for that (named "stay in array bounds in DDCModesFromEstIII()")...

http://patchwork.freedesktop.org/patch/7970/
Back to top
View user's profile Send private message
OPelerin
Guru
Guru


Joined: 17 Jul 2004
Posts: 318
Location: Belgium

PostPosted: Mon Feb 06, 2012 7:51 am    Post subject: Reply with quote

I'm having the same pb too.

Is there a bug already open for that?
_________________
Olivier PELERIN
Back to top
View user's profile Send private message
fnoord
n00b
n00b


Joined: 06 Nov 2011
Posts: 5

PostPosted: Mon Feb 06, 2012 5:54 pm    Post subject: Reply with quote

@chithanh: I can not imagine anything in my /usr/local could interfere with xorg. Only things in my /usr/local are vim-supertab, crossdev for mingw and avr and truecrypt...
Back to top
View user's profile Send private message
mrpdaemon
Tux's lil' helper
Tux's lil' helper


Joined: 23 Aug 2004
Posts: 124

PostPosted: Thu Feb 09, 2012 6:25 am    Post subject: Reply with quote

OPelerin wrote:
I'm having the same pb too.

Is there a bug already open for that?


https://bugs.gentoo.org/show_bug.cgi?id=402285
Back to top
View user's profile Send private message
Goeland86
Apprentice
Apprentice


Joined: 12 Mar 2004
Posts: 177
Location: Neuchatel, Switzerland

PostPosted: Sun Feb 26, 2012 6:16 pm    Post subject: Reply with quote

So I'm having this same issue, but I tried masking 11.4, then 11.3 when that one failed with the SAME problem, and now that I'm back down to 10.6 I *STILL* have the exact same problem.

I'm no expert, but I'd say this is not the xorg-server code itself, but a dependent lib that's fubarding the whole thing!
Back to top
View user's profile Send private message
OPelerin
Guru
Guru


Joined: 17 Jul 2004
Posts: 318
Location: Belgium

PostPosted: Fri Mar 23, 2012 11:52 am    Post subject: Reply with quote

11-4-r1 is out and It went without any pb
_________________
Olivier PELERIN
Back to top
View user's profile Send private message
Zarhan
l33t
l33t


Joined: 27 Feb 2004
Posts: 920

PostPosted: Mon Jun 04, 2012 8:32 pm    Post subject: Reply with quote

This happens to me, even with the -r1. What's wrong? Haven't tried with -O2 yet, though.
Back to top
View user's profile Send private message
miket
Tux's lil' helper
Tux's lil' helper


Joined: 28 Apr 2007
Posts: 97
Location: Gainesville, FL, USA

PostPosted: Mon Jun 04, 2012 9:45 pm    Post subject: Reply with quote

Something really screwy has gone on. I already have a working installation of xorg-server-1.11.2-r2 on a different machine, and it installed with no problem (months ago). I've been trying to get the same package to compile on a new machine, and no matter what I try, from using simpler USE flags and rebuilding system and world, the ebuild keeps failing. This is on a new install.

I decided to take it one step further. On this same new machine, I made a new-installation chroot, emerged gentoo-sources so that the xorg packages could find kernel sources, and tried one more time for xorg-server in this very vanilla environment. Still no dice.

I get the idea that something happened in a eclass or one of the packages on which xorg-server depends.

I guess I could try unkeywording ~1.11.4-r1 and seeing if that would work.

Ah, what a fun day this has been. :(
Back to top
View user's profile Send private message
gentoorockerfr
n00b
n00b


Joined: 25 May 2012
Posts: 54

PostPosted: Tue Jun 05, 2012 4:43 pm    Post subject: Reply with quote

problem here
Code:

In function ‘handle_detailed_modes’:
/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:750:19: σφάλμα: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:749:19: σφάλμα: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:748:19: σφάλμα: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:747:33: σφάλμα: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:750:19: σφάλμα: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:749:19: σφάλμα: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:748:19: σφάλμα: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:747:33: σφάλμα: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:750:19: σφάλμα: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:749:19: σφάλμα: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:748:19: σφάλμα: array subscript is above array bounds
/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4/hw/xfree86/modes/xf86EdidModes.c:747:33: σφάλμα: array subscript is above array bounds
make[4]: *** [xf86EdidModes.lo] Error 1
make[4]: *** Waiting for unfinished jobs....
make[4]: Leaving directory `/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4_build/hw/xfree86/modes'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4_build/hw/xfree86'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4_build/hw/xfree86'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4_build/hw'
make: *** [all-recursive] Error 1
 * ERROR: x11-base/xorg-server-1.11.4-r1 failed (compile phase):
 *   emake failed
 *
 * If you need support, post the output of 'emerge --info =x11-base/xorg-server-1.11.4-r1',
 * the complete build log and the output of 'emerge -pqv =x11-base/xorg-server-1.11.4-r1'.
 * The complete build log is located at '/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/temp/environment'.
 * S: '/var/tmp/portage/x11-base/xorg-server-1.11.4-r1/work/xorg-server-1.11.4'

>>> Failed to emerge x11-base/xorg-server-1.11.4-r1,


σφάλμα=error in hellenic language
Back to top
View user's profile Send private message
miket
Tux's lil' helper
Tux's lil' helper


Joined: 28 Apr 2007
Posts: 97
Location: Gainesville, FL, USA

PostPosted: Wed Jun 06, 2012 2:54 am    Post subject: Reply with quote

Well, I bit the bullet and followed the workaround in the bug report: compile with the -O2 switch, not the -O3 that I normally use. The bug reports that someone has a patch to make xorg-server build with the -O3 switch, but that's not in any of the versions I tried.

https://bugs.gentoo.org/show_bug.cgi?id=402285

If I were really ambitious, I would have made my own private ebuild for xorg-server 1.11.2-r2. As it was, I compiled that package--and that package only--with -O2. Heh. Give it a little oxygen. I did, and now I can breathe again.
Back to top
View user's profile Send private message
czernitko
n00b
n00b


Joined: 06 Jun 2012
Posts: 2

PostPosted: Wed Jun 06, 2012 5:19 pm    Post subject: Reply with quote

If anyone doesn't know about this portage feature, it might help someone.
If you are optimising with -O3 by default (in make.conf) and want to always optimise xorg-server with -O2, try this:

Code:

$cat /etc/portage/env/x11-base/xorg-server
CFLAGS="${CFLAGS} -O2"
CXXFLAGS="${CFLAGS}"
FFLAGS="${CFLAGS}"

$


This way you can set environment variables explicitly for any ebuild.
HTH
Back to top
View user's profile Send private message
miket
Tux's lil' helper
Tux's lil' helper


Joined: 28 Apr 2007
Posts: 97
Location: Gainesville, FL, USA

PostPosted: Fri Jun 08, 2012 4:08 am    Post subject: Reply with quote

czernitko wrote:
If anyone doesn't know about this portage feature, it might help someone.
If you are optimising with -O3 by default (in make.conf) and want to always optimise xorg-server with -O2, try this:

Code:

$cat /etc/portage/env/x11-base/xorg-server
CFLAGS="${CFLAGS} -O2"
CXXFLAGS="${CFLAGS}"
FFLAGS="${CFLAGS}"

$


This way you can set environment variables explicitly for any ebuild.
HTH


Wow, I need to do a better job at reading the Portage documentation.

Here's what else I found about that feature. While the man page for portage documents the setup you describe, it describes a second way that I find to be a better fit for my workflow. This makes things easier to maintain: you can put common environment settings in one place for use by several packages and you can see all the packages at one glance.

In /etc/portage/env/, I can set up a file like O2.conf with the same contents as what you have for /etc/portage/env/x11-base/xorg-server:
Code:
CFLAGS="${CFLAGS} -O2"
CXXFLAGS="${CFLAGS}"
FFLAGS="${CFLAGS}"


Now the file /etc/portage/package.env contains package atoms like the other package* files do but this time refers to the common configuration file:
Code:
x11-base/xorg-server O2.conf


So now if I want more packages to be compiled with -O2, I can add lines for them in /etc/portage/package.env without having to duplicate files or make links or without having to keep up with directory trees. I added another common file:
Code:
$ cat /etc/portage/package.env
app-doc/doxygen O2.conf
x11-base/xorg-server O2.conf
znurt/larry-cow no-unroll.conf


Of course, since is Gentoo, you don't have to choose between one form or the other: evidently you could use both forms at once. I'm not taking bets, though, on what happens if you use the two different forms for the same package.

Thanks for the hint! I wouldn't have looked for the man page if you hadn't pointed out the feature.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum