Discussion:
How to run gcc test suite in pure mingw32 environment?
徐持恒
2009-11-09 02:26:49 UTC
Permalink
Hi,

These days, I’m trying to build gcc-4.4.2 + binutils-2.20 + gmp + mpfr in
Msys+MinGW and Cygwin environment.

The builds on both environments are OK, but I cannot run "make check", or
"make check-gcc".

Finally, I found, that, to run test, you must first install guile, autogen,
tck/tk, expect, dejagnu.
In Msys+MinGW and Cygwin environments, these tools are missing or outdated.
I spend a lot of time to have the latest versions of these packages to be
build and installed in Cygwin, with some patchs applied of course.
Sometimes, I even edit configure.ac file, and run "autoreconf" with the
newest version of autoconf, automake, libtool installed. For expect-5.43.0,
it is even necessary for Cygwin to masquerade as a linux host by specifing
"--host=i686-pc-linux", thus the configure script can run without a
complain.

Having all these tools installed, I found, most of the test results of "make
check" is "fail" in Cygwin environment.

I'm very disappointed with this.

I also spend a lot of time, trying to get these packages installed int
Msys+MinGW environment. But this is too difficult for me.

So, I want to ask, how to run gcc test suite in pure Msys+MinGW environment?

Can the Msys+MinGW use the installed tools in Cygwin to let "make check"
possible ?

Althouth the "gcc + binutils + gmp + mpfr" are ported to pure MinGW
environment, many of the dependent tools are very difficult to port to pure
MinGW environment, because they expect a linux environmemt. But I found,
newlib seems to meet their desire very well. Is't it necessary to port
newlib to pure MinGW environment ? This is much like what cygwin does, but
in a much simpler way. Just to make the necessary gnu tools to be build and
installed.

I think the test environment is very significant.

If we have test environment on Windows platform, we can greatly improve the
development process in this platform ,and ensure the quality of gcc and
companion tools on Windows. I noticed that there are also a MinGW-w64
project, if we have that test environment, we can impove it, even accelerate
it.










Chiheng Xu

Embedded OS Group,
Optical Network Product Division,
Fiberhome Telecommunication Technology Co.,Ltd.,
No.5 Dongxin Road of Guanshan Er Road,Hongshan Dist.,Wuhan,Hubei,P.R.China
Tel: +86 27 59100296
zipcode: 430073
Email: ***@fiberhome.com.cn
Dave Korn
2009-11-09 06:53:36 UTC
Permalink
Post by 徐持恒
Finally, I found, that, to run test, you must first install guile, autogen,
tck/tk, expect, dejagnu.
In Msys+MinGW and Cygwin environments, these tools are missing or outdated.
The ones in the cygwin distro may be outdated, but they work just fine for
running "make check". The only problem is you can't use "-j" with "make
check", but everything else works OK. (Also you can get by without autogen
and guile.)
Post by 徐持恒
I spend a lot of time to have the latest versions of these packages to be
build and installed in Cygwin, with some patchs applied of course.
Sometimes, I even edit configure.ac file, and run "autoreconf" with the
newest version of autoconf, automake, libtool installed. For expect-5.43.0,
it is even necessary for Cygwin to masquerade as a linux host by specifing
"--host=i686-pc-linux", thus the configure script can run without a
complain.
No, it is not only not "necessary", it is completely incorrect. Tricking
configure about what system it is running on will simply make it do the wrong
things and cause it to build an executable that does the wrong things and
doesn't work.
Post by 徐持恒
Having all these tools installed, I found, most of the test results of "make
check" is "fail" in Cygwin environment.
See?
Post by 徐持恒
I'm very disappointed with this.
Shouldn't have given false information to configure then, sorry. Use the
standard packages, they ought to work for you too.

As for MinGW testing, I think the people who work on it do indeed use the
Cygwin tools from within MSYS shell to run the tests, but I don't know how
exactly they set it up. You might get a quicker answer if you asked on the
mingw list.

cheers,
DaveK
Kai Tietz
2009-11-09 06:43:15 UTC
Permalink
Post by Dave Korn
Post by 徐持恒
Finally, I found, that, to run test, you must first install guile, autogen,
tck/tk, expect, dejagnu.
In Msys+MinGW and Cygwin environments, these tools are missing or outdated.
The ones in the cygwin distro may be outdated, but they work just fine for
running "make check". The only problem is you can't use "-j" with "make
check", but everything else works OK. (Also you can get by without autogen
and guile.)
Post by 徐持恒
I spend a lot of time to have the latest versions of these packages to be
build and installed in Cygwin, with some patchs applied of course.
Sometimes, I even edit configure.ac file, and run "autoreconf" with the
newest version of autoconf, automake, libtool installed. For expect-5.43.0,
it is even necessary for Cygwin to masquerade as a linux host by specifing
"--host=i686-pc-linux", thus the configure script can run without a
complain.
No, it is not only not "necessary", it is completely incorrect. Tricking
configure about what system it is running on will simply make it do the wrong
things and cause it to build an executable that does the wrong things and
doesn't work.
Post by 徐持恒
Having all these tools installed, I found, most of the test results of "make
check" is "fail" in Cygwin environment.
See?
Post by 徐持恒
I'm very disappointed with this.
Shouldn't have given false information to configure then, sorry. Use the
standard packages, they ought to work for you too.
As for MinGW testing, I think the people who work on it do indeed use the
Cygwin tools from within MSYS shell to run the tests, but I don't know how
exactly they set it up. You might get a quicker answer if you asked on the
mingw list.
cheers,
DaveK
Hello,

I use testsuite quite regularly and I use cygwin shell with default
packages for dejagnu installed.
The setup of it is just default. I don't modify anything special. Just
install and use.

Cheers,
Kai
--
| (\_/) This is Bunny. Copy and paste
| (='.'=) Bunny into your signature to help
| (")_(") him gain world domination
徐持恒
2009-11-09 07:13:01 UTC
Permalink
Thank you, I'll give it a try.

But can you tell me why there are no testresult of MinGW or Cygwin on
gcc-testresults mailinglist ?
Post by Dave Korn
As for MinGW testing, I think the people who work on it do indeed use the
Cygwin tools from within MSYS shell to run the tests, but I don't know how
exactly they set it up. You might get a quicker answer if you asked on the
mingw list.
cheers,
DaveK
I use testsuite quite regularly and I use cygwin shell with default
packages for dejagnu installed.
The setup of it is just default. I don't modify anything special. Just
install and use.

Cheers,
Kai
--
| (\_/) This is Bunny. Copy and paste
| (='.'=) Bunny into your signature to help
| (")_(") him gain world domination
Kai Tietz
2009-11-09 07:49:54 UTC
Permalink
Post by 徐持恒
Thank you, I'll give it a try.
But can you tell me why there are no testresult of MinGW or Cygwin on
gcc-testresults mailinglist ?
There are, but as a full testsuite run for cygwin/mingw needs round
about 25-35 hours, they are sent not regular. But if there would be
somebody volunteering to do them regular, it would be for sure most
welcome.

Kai
--
| (\_/) This is Bunny. Copy and paste
| (='.'=) Bunny into your signature to help
| (")_(") him gain world domination
Dave Korn
2009-11-09 14:43:31 UTC
Permalink
Post by 徐持恒
Thank you, I'll give it a try.
But can you tell me why there are no testresult of MinGW or Cygwin on
gcc-testresults mailinglist ?
That's not correct. I haven't done it for a few weeks because I've been
busy on other stuff, but Christian J. is still posting them regularly for Cygwin:

http://gcc.gnu.org/ml/gcc-testresults/2009-11/msg00451.html
http://gcc.gnu.org/ml/gcc-testresults/2009-11/msg00337.html
http://gcc.gnu.org/ml/gcc-testresults/2009-11/msg00137.html
http://gcc.gnu.org/ml/gcc-testresults/2009-10/msg02827.html

The last one I sent is at:
http://gcc.gnu.org/ml/gcc-testresults/2009-10/msg02682.html

cheers,
DaveK
Kai Ruottu
2009-11-09 10:53:45 UTC
Permalink
Post by 徐持恒
These days, I’m trying to build gcc-4.4.2 + binutils-2.20 + gmp + mpfr in
Msys+MinGW and Cygwin environment.
The builds on both environments are OK, but I cannot run "make check", or
"make check-gcc".
Finally, I found, that, to run test, you must first install guile, autogen,
tck/tk, expect, dejagnu.
This "self-hosted" idea is quite the same as trying to produce cars in
garages or even on roads because they
will be used there...

I myself would be more interested to get these tests for MinGW-hosted
tools to work on Linux because that is
the "preferred build platform for MinGW-hosted tools" for me. Some years
ago I produced more than 100
binutils+GCC+GDB/Insight toolchains for all kind of targets to be run on
the MinGW runtime host. Just for a
fun... The tests regarding to "does it work" happening on Windoze/MinGW
via compiling apps there and then
possibly running them on the built-in simulator in GDB or using the
standalone "$target-run" simulator on the
console.

When all the $target systems for the MinGW-hosted binutils, GCCs and
GDB/Insights are non-Windoze
targets, the question is about how well these tools would work on
Windoze and are the results from them
identical with their equivalents on the primary Linux host. What maybe
could be usable, would be some
kind of "gdbserver" to run on Windoze and run the MinGW-hosted toolchain
tests "natively" there.

What has been the "problem" is that those very limited tests on the
Windoze/MinGW host have this far
showed the toolchains to work quite identically with their earlier
equivalents on the Linux host, for instance
a toolchain for "arm-elf" on MinGW-host working nicely on Windoze too.
So really no need to wonder how
to get "make check" to work with the Canadian-cross built toolchains...
Post by 徐持恒
Is't it necessary to port newlib to pure MinGW environment ?
I tried to understand what this clause means but didn't "grok" it...
Could you elaborate what the point is?
"Pure MinGW" means "running apps using the native Windoze DLLs"
meanwhile Cygwin (and MSYS?)
try to provide a "Unix layer" for the apps like binutils, GCC and GDB.
For instance the tcl/tk/itcl DLLs are
for Win32 API in the MinGW-hosted Insights...
Post by 徐持恒
If we have test environment on Windows platform, we can greatly improve the
development process in this platform ,and ensure the quality of gcc and
companion tools on Windows. I noticed that there are also a MinGW-w64
project, if we have that test environment, we can impove it, even accelerate
it.
When producing those 100+ toolchains for MinGW, my conclusion was : "In
the same time when one
developer builds 100 toolchains for MinGW host on a productive build
platform, there must be 100
developers to get just one toolchain (for MinGW target) being built on
the native Windoze build platform :(

Just name your $target(s) and I will report how many minutes it takes to
build gcc-4.4.2 + binutils-2.20 (and
the gmp + mpfr for MinGW host) for it and for MinGW $host on Linux
$build host.... Producing Insight
6.8 for MinGW host and for a couple of targets like 'mips-elf' seemed to
work nicely on July 2009 but some
targets might still be problems with the MinGW $host. For instance
making a remote debugger for
'sparc-solaris2.11' or some embedded Linux target to run on MinGW host....
Kai Tietz
2009-11-09 11:03:59 UTC
Permalink
Post by Kai Ruottu
I myself would be more interested to get these tests for MinGW-hosted
tools to work on Linux because that is
the "preferred build platform for MinGW-hosted tools" for me. Some years
ago I produced more than 100
binutils+GCC+GDB/Insight toolchains for all kind of targets to be run on
the MinGW runtime host. Just for a
fun... The tests regarding to "does it work" happening on Windoze/MinGW
via compiling apps there and then
possibly running them on the built-in simulator in GDB or using the
standalone "$target-run" simulator on the
console.
The testruns we do for 32-bit and 64-bit of mingw-w64 are done on a
linux host by cross-compilation and are executed on a remote Windows
host. ssh and rexec can be used here. NightStrike can give here more
details.
Post by Kai Ruottu
What has been the "problem" is that those very limited tests on the
Windoze/MinGW host have this far
showed the toolchains to work quite identically with their earlier
equivalents on the Linux host, for instance
a toolchain for "arm-elf" on MinGW-host working nicely on Windoze too.
So really no need to wonder how
to get "make check" to work with the Canadian-cross built toolchains...
Indeed, to make a cross-compiler (especially on cygwin and linux)
makes absolutely sense. In fact it is at the moment (as the expect
tool isn't ported for native Windows hosts) the only way to do
regression tests.
Post by Kai Ruottu
Post by 徐持恒
Is't it necessary to port newlib to pure MinGW environment ?
This makes no sense. Possibly your initial idea here isn't
understandable, so could you give us more details about this?

Regards,
Kai
--
| (\_/) This is Bunny. Copy and paste
| (='.'=) Bunny into your signature to help
| (")_(") him gain world domination
徐持恒
2009-11-10 02:37:11 UTC
Permalink
I know very well the spirit of MinGW, it want to provide a native Win32
development evrionment.

The issue is : many of the host tools have not been ported or very hard to
be ported to pure MinGW/Win32 environment, for example, bash. This is why
Msys exist. Msys essensially a fork of Cygwin 1.3. In MinGW's download
page, there are two kinds of packages to download, MinGW pacakges and Msys
packages. The MinGW packages are packages ported to pure MinGW/Win32
environment, not linked to non standard DLLs, like, cygwin1.dll or
msys-1.0.dll. The Msys packages are packages developed in a outdated
developent toolchain(gcc-2.9), and linked to msys-1.0.dll. The Msys packages
are not native MinGW/Win32 packages, just like Cygwin packages.

The existence of Msys proves that : in MinGW, you must provide a
additional/optional newlib style library, the headers,libs, to make a bundle
of tools to be build easily : bash, make, coreutils, bzip2,diffutils, file,
findutils, gawk, grep, gzip, less, m4, patch, sed, tar, texinfo, perl, etc.

The testruns for 32-bit and 64-bit of mingw-w64 are done on a linux host by
cross-compilation and are executed on a remote Windows host, again confirm
this points : MinGW lack the the native ported MinGW/Win32 tools.

I know that a lot of basic tools like, make,dmake, perl, tck/tk have been
ported to pure MinGW/Win32 evnrironment. Autoconf, automake, libtool, depend
on perl, but I don't know whether not pure MinGW/Win32 perl works.

I also notice that there a GnuWin32 project, but no prove exists that we
can use that as gcc development environment.

It seems that all GNU development tools have been ported to Cygwin, with the
latest version. But in Msys, many tools are missing or outdated. In some
meaning , Cygwin seems more successful than MinGW+Msys.

It would be very nice when Cygwin can masquerade as MinGW. I have tried to
relpace the uname.exe in Cygwin's bin directory(c:/cygwin/bin), with the one
in MinGW is bin directory(c:/msys/1.0/bin). Then in Cygwin bash when run
"config.guess", it print "i686-pc-mingw32". For lack of time, I have not
done further test.




cheers.
Chiheng Xu
Wuhan,China







-----邮件原件-----
发件人: Kai Tietz [mailto:***@googlemail.com]
发送时间: 2009年11月9日 19:04
收件人: Kai Ruottu
抄送: 徐持恒; ***@gcc.gnu.org
主题: Re: How to run gcc test suite in pure mingw32 environment?
Post by Kai Ruottu
I myself would be more interested to get these tests for MinGW-hosted
tools to work on Linux because that is
the "preferred build platform for MinGW-hosted tools" for me. Some years
ago I produced more than 100
binutils+GCC+GDB/Insight toolchains for all kind of targets to be run on
the MinGW runtime host. Just for a
fun... The tests regarding to "does it work" happening on Windoze/MinGW
via compiling apps there and then
possibly running them on the built-in simulator in GDB or using the
standalone "$target-run" simulator on the
console.
The testruns we do for 32-bit and 64-bit of mingw-w64 are done on a
linux host by cross-compilation and are executed on a remote Windows
host. ssh and rexec can be used here. NightStrike can give here more
details.
Post by Kai Ruottu
What has been the "problem" is that those very limited tests on the
Windoze/MinGW host have this far
showed the toolchains to work quite identically with their earlier
equivalents on the Linux host, for instance
a toolchain for "arm-elf" on MinGW-host working nicely on Windoze too.
So really no need to wonder how
to get "make check" to work with the Canadian-cross built toolchains...
Indeed, to make a cross-compiler (especially on cygwin and linux)
makes absolutely sense. In fact it is at the moment (as the expect
tool isn't ported for native Windows hosts) the only way to do
regression tests.
Post by Kai Ruottu
Post by 徐持恒
Is't it necessary to port newlib to pure MinGW environment ?
This makes no sense. Possibly your initial idea here isn't
understandable, so could you give us more details about this?

Regards,
Kai
--
| (\_/) This is Bunny. Copy and paste
| (='.'=) Bunny into your signature to help
| (")_(") him gain world domination
Continue reading on narkive:
Loading...