public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: Steven Penny <svnpenn@gmail.com>
To: cygwin@cygwin.com
Subject: Re: [ANNOUNCEMENT] [Updated] mingw64-{i686,x86_64} binutils, gcc (Test)
Date: Thu, 21 Sep 2017 00:10:00 -0000	[thread overview]
Message-ID: <59c3037d.4cfdca0a.795e7.29d7@mx.google.com> (raw)
In-Reply-To: <59c1a4d8.072d9d0a.f9f88.5663@mx.google.com>

On Tue, 19 Sep 2017 16:14:32, Steven Penny wrote:
> Looks like a Cmake error rather than GCC - thought you might like to know.
> Cmake is inserting "-isystem" instead of "-I":

Looks like I spoke too soon - I think it is a GCC error. Using this file:

$ cat alfa.cpp
#include <cstdio>
#include <functional>
int main() {
  puts("hello world");
}

5.4.0 compiles without issue:

$ x86_64-w64-mingw32-g++ --version
x86_64-w64-mingw32-g++ (GCC) 5.4.0

$ x86_64-w64-mingw32-g++ \
> -I /usr/x86_64-w64-mingw32/sys-root/mingw/include alfa.cpp

$ x86_64-w64-mingw32-g++ \
> -isystem /usr/x86_64-w64-mingw32/sys-root/mingw/include alfa.cpp

However 6.3.0 only works in certain cases:

$ x86_64-w64-mingw32-g++ \
> -I /usr/x86_64-w64-mingw32/sys-root/mingw/include alfa.cpp

$ x86_64-w64-mingw32-g++ \
> -isystem /usr/x86_64-w64-mingw32/sys-root/mingw/include alfa.cpp
In file included from
/usr/lib/gcc/x86_64-w64-mingw32/6.3.0/include/c++/ext/string_conversions.h:41:0,
from /usr/lib/gcc/x86_64-w64-mingw32/6.3.0/include/c++/bits/basic_string.h:5402,
from /usr/lib/gcc/x86_64-w64-mingw32/6.3.0/include/c++/string:52,
from /usr/lib/gcc/x86_64-w64-mingw32/6.3.0/include/c++/stdexcept:39,
from /usr/lib/gcc/x86_64-w64-mingw32/6.3.0/include/c++/array:39,
from /usr/lib/gcc/x86_64-w64-mingw32/6.3.0/include/c++/tuple:39,
from /usr/lib/gcc/x86_64-w64-mingw32/6.3.0/include/c++/functional:55,
from alfa.cpp:2:
/usr/lib/gcc/x86_64-w64-mingw32/6.3.0/include/c++/cstdlib:75:25: fatal error:
  stdlib.h: No such file or directory
#include_next <stdlib.h>

Now really "-I" and "-isystem" are not really needed for this example, because
that directory gets pulled in already - but it should work even with them
included. Also it is somewhat important that it do work even with the redundant
options included, because Cmake often dumps those options in with GCC commands.


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

  reply	other threads:[~2017-09-21  0:10 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-20 16:19 JonY
2017-08-21  1:57 ` Steven Penny
2017-08-21  2:45   ` Steven Penny
2017-08-22  2:22     ` Steven Penny
2017-08-22 12:47       ` JonY
2017-09-19 23:14         ` Steven Penny
2017-09-21  0:10           ` Steven Penny [this message]
2017-09-24  0:49             ` JonY
2017-09-24  3:07               ` Steven Penny
2017-09-25  1:53               ` Steven Penny
2017-09-25 14:18                 ` JonY
2017-09-25 18:33                   ` Steven Penny
2017-09-27 23:43                     ` JonY
2017-09-28  4:13                       ` Steven Penny
2017-09-25 16:43                 ` Hans-Bernhard Bröker
2017-09-25 18:44                   ` Steven Penny
2017-09-25 20:04                     ` Hans-Bernhard Bröker
2017-09-27  4:35                       ` Andrey Repin
2017-10-17 11:47 ` Steven Penny
2017-10-18  7:30   ` JonY

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=59c3037d.4cfdca0a.795e7.29d7@mx.google.com \
    --to=svnpenn@gmail.com \
    --cc=cygwin@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).