public inbox for gdb-testers@sourceware.org
help / color / mirror / Atom feed
From: sergiodj+buildbot@sergiodj.net
To: gdb-testers@sourceware.org
Subject: [binutils-gdb] Conditionally include "<windows.h>" on common/pathstuff.c (and unbreak build on mingw*)
Date: Fri, 02 Mar 2018 12:46:00 -0000	[thread overview]
Message-ID: <ab818ade016bcd794980438775e15c7a74f054f9@gdb-build> (raw)

*** TEST RESULTS FOR COMMIT ab818ade016bcd794980438775e15c7a74f054f9 ***

Author: Sergio Durigan Junior <sergiodj@redhat.com>
Branch: master
Commit: ab818ade016bcd794980438775e15c7a74f054f9

Conditionally include "<windows.h>" on common/pathstuff.c (and unbreak build on mingw*)

commit b4987c956dfa44ca9fd8552f63e15f5fa094b2a4
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Fri Feb 9 18:44:59 2018 -0500

    Create new common/pathstuff.[ch]

Introduced a regression when compiling for mingw*:

  /gdb/common/pathstuff.c: In function 'gdb::unique_xmalloc_ptr<char>
  gdb_realpath(const char*)':
  /gdb/common/pathstuff.c:56:14: error: 'MAX_PATH' was not declared in this scope
       char buf[MAX_PATH];
		^
  /gdb/common/pathstuff.c:57:5: error: 'DWORD' was not declared in this scope
       DWORD len = GetFullPathName (filename, MAX_PATH, buf, NULL);
       ^
  /gdb/common/pathstuff.c:57:11: error: expected ';' before 'len'
       DWORD len = GetFullPathName (filename, MAX_PATH, buf, NULL);
	     ^
  /gdb/common/pathstuff.c:63:9: error: 'len' was not declared in this scope
       if (len > 0 && len < MAX_PATH)
	   ^
  /gdb/common/pathstuff.c:64:54: error: 'buf' was not declared in this scope
	 return gdb::unique_xmalloc_ptr<char> (xstrdup (buf));
							^
  make[2]: *** [pathstuff.o] Error 1

The proper fix is to conditionally include "<windows.h>".  This commit
does that, without introducing any regressions as per tests made by
our BuildBot.

gdb/ChangeLog:
2018-03-01  Sergio Durigan Junior  <sergiodj@redhat.com>

	PR gdb/22907
	* common/pathstuff.c: Conditionally include "<windows.h>".


             reply	other threads:[~2018-03-02 12:46 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-02 12:46 sergiodj+buildbot [this message]
2018-03-02 12:46 ` Failures on RHEL-s390x-m64, branch master sergiodj+buildbot
2018-03-02 12:53 ` Failures on Debian-s390x-m64, " sergiodj+buildbot
2018-03-02 12:57 ` Failures on Fedora-x86_64-native-gdbserver-m32, " sergiodj+buildbot
2018-03-02 13:08 ` Failures on Debian-s390x-native-extended-gdbserver-m64, " sergiodj+buildbot
2018-03-02 13:32 ` Failures on Fedora-x86_64-native-extended-gdbserver-m32, " sergiodj+buildbot
2018-03-02 13:32 ` Failures on Fedora-x86_64-cc-with-index, " sergiodj+buildbot
2018-03-02 13:38 ` Failures on Fedora-x86_64-m64, " sergiodj+buildbot
2018-03-02 13:39 ` *** COMPILATION FAILED *** Failures on Fedora-x86_64-w64-mingw32, branch master *** BREAKAGE *** sergiodj+buildbot
2018-03-02 13:51 ` Failures on Fedora-s390x-m64, branch master sergiodj+buildbot
2018-03-02 13:52 ` Failures on Ubuntu-AArch32-native-extended-gdbserver-m32, " sergiodj+buildbot
2018-03-02 13:54 ` Failures on Fedora-x86_64-native-gdbserver-m64, " sergiodj+buildbot
2018-03-06 23:10 ` Failures on Ubuntu-AArch64-m64, " sergiodj+buildbot

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=ab818ade016bcd794980438775e15c7a74f054f9@gdb-build \
    --to=sergiodj+buildbot@sergiodj.net \
    --cc=gdb-testers@sourceware.org \
    /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).