! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
Compilation error due to conflicting types in /usr/include/sys and /usr/inclu...
Status:
RESOLVED: FIXED
Product:
Xfce4-battery-plugin
Component:
General

Comments

Description Facundo Oliva 2008-03-10 20:56:15 CET
User-Agent:       Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9b3) Gecko/2008030818 Firefox/3.0b3
Build Identifier: 

I can't remember when I started to have this problem. I believe it was when upgrading kernel sources to 2.6.24. I've had this error message when I tried to compile the sources:

In file included from ./libapm.h:21,
                 from battery.c:39:
/usr/include/sys/types.h:46: error: conflicting types for 'loff_t'
/usr/include/linux/types.h:57: error: previous declaration of 'loff_t' was here
/usr/include/sys/types.h:62: error: conflicting types for 'dev_t'
/usr/include/linux/types.h:19: error: previous declaration of 'dev_t' was here
In file included from /usr/include/sys/types.h:133,
                 from ./libapm.h:21,
                 from battery.c:39:
/usr/include/time.h:105: error: conflicting types for 'timer_t'
/usr/include/linux/types.h:28: error: previous declaration of 'timer_t' was here
In file included from ./libapm.h:21,
                 from battery.c:39:
/usr/include/sys/types.h:198: error: conflicting types for 'int64_t'
/usr/include/linux/types.h:125: error: previous declaration of 'int64_t' was here
/usr/include/sys/types.h:204: error: conflicting types for 'u_int64_t'
/usr/include/linux/types.h:124: error: previous declaration of 'u_int64_t' was here
In file included from /usr/include/sys/types.h:220,
                 from ./libapm.h:21,
                 from battery.c:39:
/usr/include/sys/select.h:78: error: conflicting types for 'fd_set'
/usr/include/linux/types.h:18: error: previous declaration of 'fd_set' was here
In file included from ./libapm.h:21,
                 from battery.c:39:
/usr/include/sys/types.h:235: error: conflicting types for 'blkcnt_t'
/usr/include/linux/types.h:151: error: previous declaration of 'blkcnt_t' was here
make[2]: *** [xfce4_battery_plugin-battery.o] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

This is the only thing that I can't compile. I use SVN. I have 2.6.24.3 kernel and GCC 4.2.3.

Reproducible: Always

Steps to Reproduce:
1. Download SVN tree.
2. Try to compile the sources.
Comment 1 Facundo Oliva 2008-03-17 23:23:09 CET
My glibc version is 2.7.
Comment 2 Samuli Suominen 2008-03-18 15:25:39 CET
Users have reported this also to us at http://bugs.gentoo.org/show_bug.cgi?id=210218
Comment 3 Christoph Wickert editbugs 2008-03-18 16:03:09 CET
Has also been reported for Fedora Development and 9 Beta, see
http://linux.dell.com/files/fedora/FixBuildRequires/mock-results-core/i386/xfce4-battery-plugin-0.5.0-2.fc7.src.rpm/result/build.log
Comment 4 Yves-Alexis Perez editbugs 2008-03-18 19:26:05 CET
Created attachment 1561 
Fix FTBFS using 2.6.24 headers

It seems that the attached patch fix this.
Comment 5 Facundo Oliva 2008-03-20 02:15:56 CET
It worked with the patch. Thanks!
Comment 6 Florian Rivoal editbugs 2010-12-24 16:57:39 CET
Patch applied. Thanks for your contribution. This will be available in the next release.
Comment 7 Florian Rivoal editbugs 2010-12-24 16:58:29 CET
*** Bug 5228 has been marked as a duplicate of this bug. ***
Comment 8 Florian Rivoal editbugs 2010-12-24 16:59:03 CET
*** Bug 4359 has been marked as a duplicate of this bug. ***

Bug #3938

Reported by:
Facundo Oliva
Reported on: 2008-03-10
Last modified on: 2010-12-24
Duplicates (2):
  • 4359 xfce4-battery-plugin-0.5.1 can't compile on x86_64 machine
  • 5228 xfce4-battery-plugin : compil failed on x86

People

Assignee:
Xfce-Goodies Maintainers
CC List:
6 users

Version

Version:
0.5.1 or older

Attachments

Fix FTBFS using 2.6.24 headers (422 bytes, patch)
2008-03-18 19:26 CET , Yves-Alexis Perez
no flags

Additional information