Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-20 Thread Yasumasa Suenaga
Thanks Ioi, David! I will push webrev.02 later. Yasumasa 2019年3月21日(木) 14:08 David Holmes : > On 21/03/2019 2:11 am, Ioi Lam wrote: > > That's the problem with ld and static libraries. If libbfd.a depends on > > libz.a, you must put libbfd.a before libz.a. > > > > Since this is a rarely touch

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-20 Thread David Holmes
On 21/03/2019 2:11 am, Ioi Lam wrote: That's the problem with ld and static libraries. If libbfd.a depends on libz.a, you must put libbfd.a before libz.a. Since this is a rarely touched Makefile, I think what you're doing in webrev.02 is fine. We can refactor it later if it becomes more unwiel

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-20 Thread Florian Weimer
* David Holmes: > I'm unclear whether MINGW is only an issue on Linux when building for > Windows or whether also of use on Windows itself? I suspect it depends on how binutils has been configured. If you have enabled the shared libbfd, you won't need to specify -lz because libbfd loads it auto

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-20 Thread Yasumasa Suenaga
Hi David, I tried to fix as you suggested, but it was failed. x86_64-w64-mingw32-gcc -o build/windows-amd64/hsdis-amd64.dll -Ibuild/windows-amd64/include -I/home/ysuenaga/rpmbuild/BUILD/binutils-2.31.1/include -I/home/ysuenaga/rpmbuild/BUILD/binutils-2.31.1/bfd -Ibuild/windows-amd64/bfd -DLIBARCH

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-19 Thread David Holmes
On 20/03/2019 4:03 pm, Yasumasa Suenaga wrote: Hi David, 2019年3月20日(水) 14:25 David Holmes : Hi Yasumasa, On 20/03/2019 3:01 pm, Yasumasa Suenaga wrote: Thanks David! I uploaded new webrev. This change affects Windows only, and I confirmed it works fine for Linux x64 and MinGW64. http://

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-19 Thread Yasumasa Suenaga
Hi David, 2019年3月20日(水) 14:25 David Holmes : > > Hi Yasumasa, > > On 20/03/2019 3:01 pm, Yasumasa Suenaga wrote: > > Thanks David! > > > > I uploaded new webrev. > > This change affects Windows only, and I confirmed it works fine for > > Linux x64 and MinGW64. > >http://cr.openjdk.java.net/~ys

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-19 Thread David Holmes
Hi Yasumasa, On 20/03/2019 3:01 pm, Yasumasa Suenaga wrote: Thanks David! I uploaded new webrev. This change affects Windows only, and I confirmed it works fine for Linux x64 and MinGW64. http://cr.openjdk.java.net/~ysuenaga/JDK-8220784/webrev.01/ I this is for MINGW only then shouldn't th

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-19 Thread Yasumasa Suenaga
Thanks David! I uploaded new webrev. This change affects Windows only, and I confirmed it works fine for Linux x64 and MinGW64. http://cr.openjdk.java.net/~ysuenaga/JDK-8220784/webrev.01/ Thanks, Yasumasa 2019年3月20日(水) 11:25 David Holmes : > > On 20/03/2019 11:54 am, Yasumasa Suenaga wrote:

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-19 Thread David Holmes
On 20/03/2019 11:54 am, Yasumasa Suenaga wrote: Hi David, 2019年3月20日(水) 10:38 David Holmes : Hi Yasumasa, I'm not familar with building hsdis, but if the only currnet problem is on Windows, why is the fix not restricted to only building on Windows? For Solaris and Linux, -lz is not added to

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-19 Thread Yasumasa Suenaga
Hi David, 2019年3月20日(水) 10:38 David Holmes : > > Hi Yasumasa, > > I'm not familar with building hsdis, but if the only currnet problem is > on Windows, why is the fix not restricted to only building on Windows? For Solaris and Linux, -lz is not added to LDFLAGS. I think it means initial committer

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-19 Thread David Holmes
Hi Yasumasa, I'm not familar with building hsdis, but if the only currnet problem is on Windows, why is the fix not restricted to only building on Windows? Otherwise we need people who build hsdis on other platforms to comment on the appropriateness of the fix. Thanks, David On 20/03/2019

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-19 Thread Yasumasa Suenaga
Hi Erik, David, I checked this change on Linux x64 and MinGW for Windows. According to hsdis README, we need to use MinGW cross compiler to build hsdis [1]. So I think Cygwin is not required. I do not have macOS and AIX. So I cannot check this change on them. BTW is hsdis included Java SE spec?

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-19 Thread David Holmes
CC'ing hotspot-dev. I agree this needs to be checked on every platform affected. I can't comment on the fix itself. David On 20/03/2019 2:36 am, Erik Joelsson wrote: I think this needs to be reviewed by at least someone in hotspot who regularly builds hsdis. I can't really comment on the valid

Re: RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-19 Thread Erik Joelsson
I think this needs to be reviewed by at least someone in hotspot who regularly builds hsdis. I can't really comment on the validity of the patch as I'm unfamiliar with both hsdis as well as this makefile. Have you at least verified the build on all the platforms which you affect with this chang

RFR: 8220784: hsdis cannot be built with MinGW64

2019-03-18 Thread Yasumasa Suenaga
Hi all, Please review this change: JBS: https://bugs.openjdk.java.net/browse/JDK-8220784 webrev: http://cr.openjdk.java.net/~ysuenaga/JDK-8220784/webrev.00/ I attempt to build hsdis for Windows on WSL Ubuntu 18.04 with gcc-mingw-w64-x86-64, but I saw error messages that some functions which