Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 259282

Summary: gcc-3.3.6 fails to compile with "call to ‘__open_missing_mode’ declared with attribute error"
Product: Gentoo Linux Reporter: Markus Wernig <public>
Component: New packagesAssignee: Gentoo Linux bug wranglers <bug-wranglers>
Status: RESOLVED DUPLICATE    
Severity: normal    
Priority: High    
Version: 2008.0   
Hardware: x86   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on: 258519    
Bug Blocks:    
Attachments: emerge --info

Description Markus Wernig 2009-02-16 21:33:30 UTC
This is a fresh ~x86 install of 2008.0

When trying to install mozilla-thunderbird-bin, gcc-3.3.6 gets pulled in as a dependency of virtual/libstdc++-3.3. It then fails to compile with the following errors:

[...]
gcc -c    -O -DIN_GCC   -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wtraditional -pedantic -Wno-long-long   -DHAVE_CONFIG_H    -I. -I. -I/var/tmp/portage/sys-devel/gcc-3.3.6-r1/work/gcc-3.3.6/gcc -I/var/tmp/portage/sys-devel/gcc-3.3.6-r1/work/gcc-3.3.6/gcc/. -I/var/tmp/portage/sys-devel/gcc-3.3.6-r1/work/gcc-3.3.6/gcc/config -I/var/tmp/portage/sys-devel/gcc-3.3.6-r1/work/gcc-3.3.6/gcc/../include /var/tmp/portage/sys-devel/gcc-3.3.6-r1/work/gcc-3.3.6/gcc/tlink.c -o tlink.o                               
/var/tmp/portage/sys-devel/gcc-3.3.6-r1/work/gcc-3.3.6/gcc/config/i386/i386.c: In function ‘x86_function_profiler’:                                                                                                 
/var/tmp/portage/sys-devel/gcc-3.3.6-r1/work/gcc-3.3.6/gcc/config/i386/i386.c:14753: warning: unused parameter ‘labelno’                                                                                            
/var/tmp/portage/sys-devel/gcc-3.3.6-r1/work/gcc-3.3.6/gcc/tlink.c: In function ‘scan_linker_output’:     
/var/tmp/portage/sys-devel/gcc-3.3.6-r1/work/gcc-3.3.6/gcc/tlink.c:598: warning: comparison of unsigned expression < 0 is always false                                                                              
/var/tmp/portage/sys-devel/gcc-3.3.6-r1/work/gcc-3.3.6/gcc/tlink.c:614: warning: comparison of unsigned expression < 0 is always false                                                                              
/var/tmp/portage/sys-devel/gcc-3.3.6-r1/work/gcc-3.3.6/gcc/tlink.c:658: warning: comparison of unsigned expression < 0 is always false                                                                              
In function ‘open’,                                                                                       
    inlined from ‘collect_execute’ at /var/tmp/portage/sys-devel/gcc-3.3.6-r1/work/gcc-3.3.6/gcc/collect2.c:1581:                                                                                                   
/usr/include/bits/fcntl2.h:51: error: call to ‘__open_missing_mode’ declared with attribute error: open with O_CREAT in second argument needs 3 arguments  
[...]

BTW: The same error occurs when trying to compile pilot-link, which I worked around by disabling the pda USE flag, so it wouldn't get installed.

It seems that there has been an API change in fcntl2.h, which belongs to glibc (sys-libs/glibc-2.9_p20081201-r1 on my system), that older code is not aware of.
Comment 1 Markus Wernig 2009-02-16 21:35:29 UTC
Created attachment 182276 [details]
emerge --info
Comment 2 Peter Alfredsen (RETIRED) gentoo-dev 2009-02-16 21:39:57 UTC

*** This bug has been marked as a duplicate of bug 256638 ***
Comment 3 Markus Wernig 2009-02-17 00:56:29 UTC
Yet another duplicate that could have been prevented ...