Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: SiZiOUS <sizious@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>, Pedro Alves <palves@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH][PR build/23568] Fix gdb-7.12.1 MinGW/MSYS build issue
Date: Wed, 29 Aug 2018 08:04:00 -0000	[thread overview]
Message-ID: <a2621e17-0b13-5959-3e62-d865efd08792@gmail.com> (raw)
In-Reply-To: <56153263-c5e6-45ce-8629-c5a77cf17f5b@gmail.com>

Hi there,

Just for your information, I tried to build gdb-8.1.1 under MinGW/MSYS 
and it doesn't work, due to a similar reason.
I opened a bug: https://sourceware.org/bugzilla/show_bug.cgi?id=23583

Have a nice day.
M. Laranjeira

Le 29/08/2018 à 00:19, SiZiOUS a écrit :
> Hello,
>
> Thank you very much for your interest to my patch.
>
> I'm using the MinGW/MSYS installer from the official SourceForge page: 
> https://sourceforge.net/projects/mingw/
>
> Please note, I'm using the original MinGW/MSYS environment, not the 
> newer MinGW-w64/MSYS2 environment which is a completely new project, 
> with no links from the original one.
> The problem for me with MinGW-w64/MSYS2 is they dropped Windows XP 
> support (and I understand that) but for my purpose I need XP support, 
> as I targetting an old exotic platform (Sega Dreamcast if you're 
> wondering), so I'm targetting GDB with sh-elf (fyi it's a Hitachi SH-4 
> CPU).
>
> I did a new try on a completely fresh MinGW/MSYS installation just to 
> be sure:
>
> 1- Download "mingw-get-setup.exe" from 
> https://sourceforge.net/projects/mingw/ - it shows 
> v0.6.2-beta-20131004-1 (It's just the MinGW Installation Manager Setup 
> Tool version).
> 2- Click Install.
> 3- Install packages : mingw32-base, mingw32-gcc-g++, msys-base. GCC is 
> 6.3.0-1.
> 4- Open MSYS Shell.
> 5- Unpack gdb-7.12.1 in the home directory or somewhere else.
> 6- Then execute the following command to launch the GDB build: 
> "configure --disable-werror --prefix=/opt/toolchains/dc/sh-elf 
> --target=sh-elf", followed by "make".
>
> If you not apply my patch, then you'll get the following error near 
> the build end:
>
> ser-mingw.c: In function 'int ser_windows_read_prim(serial*, size_t)':
> ser-mingw.c:346:30: error: 'ERROR_IO_PENDING' was not declared in this 
> scope
>        if (GetLastError () != ERROR_IO_PENDING
>                               ^~~~~~~~~~~~~~~~
> ser-mingw.c: In function 'int ser_windows_write_prim(serial*, const 
> void*, size_t)':
> ser-mingw.c:368:30: error: 'ERROR_IO_PENDING' was not declared in this 
> scope
>        if (GetLastError () != ERROR_IO_PENDING
>                               ^~~~~~~~~~~~~~~~
> make[2]: *** [ser-mingw.o] Error 1
>
> I tried the latest 8.0 build but it doesn't compile too.
> Anyway I'm sticking to the 7.x branch as the GDB 7.x is confirmed to 
> work with the Sega Dreamcast platform.
>
> And I know, the MinGW/MSYS original project is maintained but almost 
> deprecated in favour of MinGW-w64/MSYS2 project. But I really need XP 
> support for my needs.
> I proposed this patch because it's really simple and not intrusive, 
> but you're right, how many people uses that old MinGW/MSYS project?
>
> Thank you for reading me in all the cases!
>
> BR,
> SiZiOUS
>
> Le 28/08/2018 à 19:22, Eli Zaretskii a écrit :
>>> From: Pedro Alves <palves@redhat.com>
>>> Date: Tue, 28 Aug 2018 17:57:43 +0100
>>>
>>> On 08/28/2018 01:01 PM, SiZiOUS wrote:
>>>> This little patch was made to allow the compilation under the 
>>>> MinGW/MSYS legacy environment (I don't know for the newer 
>>>> MinGW-w64/MSYS2 environment!).
>>>> If this patch is not applied, then the compilation of gdb-7.12.1 
>>>> under MinGW/MSYS is impossible.
>>> GDB 7.12 is old by now and not actively maintained.
>>>
>>> Can you check whether this is necessary on the master branch?
>> AFAICS, we include winerror.h via serial.h, which includes winsock2.h,
>> which includes winerror.h.  Older MinGW included that via the chain
>> windows.h->windef.h->winnt.h.
>>
>> SiZiOUS, what version of the MinGW runtime are you using?
>


  reply	other threads:[~2018-08-29  8:04 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-28 12:01 SiZiOUS
2018-08-28 16:57 ` Pedro Alves
2018-08-28 17:22   ` Eli Zaretskii
2018-08-28 22:19     ` SiZiOUS
2018-08-29  8:04       ` SiZiOUS [this message]
2018-09-09 20:06         ` Eli Zaretskii
     [not found]           ` <ddb12e03-7fc3-bf4b-cd24-235b43c33d38@gmail.com>
2018-12-02 13:52             ` SiZiOUS
2018-08-29 15:50       ` Simon Marchi
2018-08-29 16:19         ` Eli Zaretskii
2018-08-29 16:25         ` Tom Tromey
2018-08-29 17:01           ` SiZiOUS
2018-08-29 17:46           ` Pedro Alves
2018-08-29 16:59         ` SiZiOUS
2018-08-29 18:27           ` Pedro Alves
2018-08-29 21:07             ` SiZiOUS
2018-08-29 17:54         ` Pedro Alves
2018-08-29 18:09           ` Eli Zaretskii

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=a2621e17-0b13-5959-3e62-d865efd08792@gmail.com \
    --to=sizious@gmail.com \
    --cc=eliz@gnu.org \
    --cc=gdb-patches@sourceware.org \
    --cc=palves@redhat.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