Thread overview
[Bug 64] Build warnings in gcc.
Jun 27, 2013
Johannes Pfau
Jun 27, 2013
Iain Buclaw
Jun 27, 2013
Iain Buclaw
Jun 27, 2013
Johannes Pfau
Jul 01, 2013
Iain Buclaw
Jul 04, 2013
Johannes Pfau
Jul 05, 2013
Iain Buclaw
Jul 05, 2013
Johannes Pfau
Jul 10, 2013
Iain Buclaw
June 27, 2013
http://bugzilla.gdcproject.org/show_bug.cgi?id=64

Johannes Pfau <johannespfau@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |johannespfau@gmail.com

--- Comment #1 from Johannes Pfau <johannespfau@gmail.com> 2013-06-27 13:44:35 UTC ---
I'll see if those can be reproduced on x86, but what headers are included in what order can be different on every platform.

I hope we don't need to mirror TARGET_OS_CPP_BUILTINS. What headers are included in what order is defined in the gcc/config.gcc file. As you can see there it's "... linux.h glibc-stdint.h ia64/sysv4.h ia64/linux.h" for ia64/linux.

It seems that for some architectures */sysv4.h is included before the real final os header, e.g */linux.h.

So we could #undef & redefine TARGET_OS_D_BUILTINS in ia64/sysv4.h, then undef & redefine it to TARGET_GENERIC_LINUX_OS_D_BUILTINS in ia64/linux.h.

-- 
Configure bugmail: http://bugzilla.gdcproject.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
June 27, 2013
http://bugzilla.gdcproject.org/show_bug.cgi?id=64

--- Comment #2 from Iain Buclaw <ibuclaw@gdcproject.org> 2013-06-27 14:25:32 UTC ---
OK, so I've have a look, the order of file inclusion is such (see config.gcc):

dbxelf.h
elfos.h
gnu-user.h
linux.h              // Sets as: linux, Posix, GNU libc
glibc-stdint.h
ia64/sysv4.h         // Overrides with SysV4, Posix
ia64/linux.h         // %% Should override again here.


I don't see it being much harm removing this from config/linux.h:

#define TARGET_OS_D_BUILTINS() TARGET_GENERIC_LINUX_OS_D_BUILTINS()


And moving it into config/ia64/linux.h  -  ditto for other architectures where necessary.  But I'll leave that to you if you want to take ownership. :)

-- 
Configure bugmail: http://bugzilla.gdcproject.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
June 27, 2013
http://bugzilla.gdcproject.org/show_bug.cgi?id=64

--- Comment #3 from Iain Buclaw <ibuclaw@gdcproject.org> 2013-06-27 14:26:50 UTC ---
(In reply to comment #1)
> I'll see if those can be reproduced on x86, but what headers are included in what order can be different on every platform.
> 
> I hope we don't need to mirror TARGET_OS_CPP_BUILTINS. What headers are included in what order is defined in the gcc/config.gcc file. As you can see there it's "... linux.h glibc-stdint.h ia64/sysv4.h ia64/linux.h" for ia64/linux.
> 
> It seems that for some architectures */sysv4.h is included before the real final os header, e.g */linux.h.
> 
> So we could #undef & redefine TARGET_OS_D_BUILTINS in ia64/sysv4.h, then undef & redefine it to TARGET_GENERIC_LINUX_OS_D_BUILTINS in ia64/linux.h.

I should have actually read the entirety of your post before responding... :o)

-- 
Configure bugmail: http://bugzilla.gdcproject.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
June 27, 2013
http://bugzilla.gdcproject.org/show_bug.cgi?id=64

Johannes Pfau <johannespfau@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
         AssignedTo|ibuclaw@gdcproject.org      |johannespfau@gmail.com

-- 
Configure bugmail: http://bugzilla.gdcproject.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
July 01, 2013
http://bugzilla.gdcproject.org/show_bug.cgi?id=64

--- Comment #4 from Iain Buclaw <ibuclaw@gdcproject.org> 2013-07-01 12:18:20 UTC ---
OK, see this link:

https://buildd.debian.org/status/package.php?p=gcc-4.8

The only other target where this warning occurs is sparc-linux-gnu.

---
Order of headers in config.gcc: "sparc/sysv4.h gnu-user.h linux.h"

-- 
Configure bugmail: http://bugzilla.gdcproject.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
July 04, 2013
http://bugzilla.gdcproject.org/show_bug.cgi?id=64

--- Comment #5 from Johannes Pfau <johannespfau@gmail.com> 2013-07-04 18:44:21 UTC ---
It seems that the '*-*-sysv*' targets are not supported by gcc anymore and gcc refuses to build those anyway. So maybe we don't need to use the sysv4.h headers at all.

Another issue is that alpha and powerpc don't use the generic linux.h file so versions are not set correctly right now. I'll have to duplicate that code into alpha/linux.h and rs6000/linux[64].h.

BTW: What diff command did you use to avoid the "diff -..." lines in the patch?

-- 
Configure bugmail: http://bugzilla.gdcproject.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
July 05, 2013
http://bugzilla.gdcproject.org/show_bug.cgi?id=64

--- Comment #6 from Iain Buclaw <ibuclaw@gdcproject.org> 2013-07-05 07:51:09 UTC ---
Hmm.... I think I just used sed to remove them.

sed -i -s '/^diff/d'

-- 
Configure bugmail: http://bugzilla.gdcproject.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
July 05, 2013
http://bugzilla.gdcproject.org/show_bug.cgi?id=64

Johannes Pfau <johannespfau@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED

--- Comment #7 from Johannes Pfau <johannespfau@gmail.com> 2013-07-05 20:39:59 UTC ---
https://github.com/D-Programming-GDC/GDC/commit/e02b8eb28adc340138238c0c8a4bd523b29da764

-- 
Configure bugmail: http://bugzilla.gdcproject.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
July 10, 2013
http://bugzilla.gdcproject.org/show_bug.cgi?id=64

--- Comment #8 from Iain Buclaw <ibuclaw@gdcproject.org> 2013-07-10 18:45:53 UTC ---
Thanks Johannes, though I seem to have been given the credit in the debian changelog. :-P

http://ftp-master.metadata.debian.org/changelogs/main/g/gcc-4.8/unstable_changelog

-- 
Configure bugmail: http://bugzilla.gdcproject.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.