Skip to content
Tcl Source Code View Ticket
Login

View Ticket

2012-06-19
17:43 • Closed ticket [967195ffff]: Test failures on mingw build plus 6 other change... artifact: 7f923d15c8 user: nijtmans
2012-06-12
20:09 • Pending ticket [967195ffff]. artifact: e94193525c user: nijtmans
2011-12-01
15:56 • Ticket [967195ffff]: 4 changes artifact: c3a6144238 user: nijtmans
04:16 • Ticket [967195ffff]: 4 changes artifact: 393c6f4b81 user: dgp
04:12 • Ticket [967195ffff]: 4 changes artifact: 881de83109 user: dgp
04:10 • Ticket [967195ffff]: 4 changes artifact: 0d173d4453 user: nijtmans
04:06 • Ticket [967195ffff]: 4 changes artifact: b1891d441f user: dgp
2011-11-30
20:10 • Open ticket [967195ffff]. artifact: a1cc661aaf user: nijtmans
2004-06-12
09:08 • Closed ticket [967195ffff]. artifact: d1b7364f55 user: kennykb
2004-06-05
17:37 • New ticket [967195ffff]. artifact: 670ced15f7 user: kennykb

Test failures on mingw build

Closed / Fixed967195ffffffffffffffffffffffffffffffffffCreated 22 years agoUpdated 14 years ago
Descriptionplain2004-06-05 17:37:36
Platform: Win2k
Compiler: mingw gcc
Configuration options: --enable-symbols --enable-threads

With the above configuration, the following error occurs
when running make TESTFLAGS='-singleproc 1' test.
Without the '-singleproc 1' option, every test file
fails with a verbose error message because of this
bug.

The test works correctly under 8.4 (tip of branch)
or under VC++ - the problem is specific to mingw
and 8.5.

==== winpipe-8.19 ensure parse_cmdline isn't doing
wildcard replacement FAILED
==== Contents of test case:

    exec [interpreter] $path(echoArgs.tcl) foo *
makefile.?c bar

---- Result was:
{C:/Documents and Settings/kennykb/My
Documents/SourceForge/tcl/NSK1KENNKEVI01-m
ingw/echoArgs.tcl} {foo big cat32.exe cat32.o
config.log config.status config.st
atus.lineno echoArgs.tcl libtcl85g.a libtcldde13g.a
libtclreg11g.a libtclstub85g
.a little Makefile nothing regcomp.o regerror.o
regexec.o regfree.o stderr stdou
t strftime.o strtoll.o strtoull.o stub16.o tcl.hpj
tcl.res.o tcl85g.dll tclAlloc
.o tclAppInit.o tclAsync.o tclBasic.o tclBinary.o
tclCkalloc.o tclClock.o tclCmd
AH.o tclCmdIL.o tclCmdMZ.o tclCompCmds.o tclCompExpr.o
tclCompile.o tclConfig.o
tclConfig.sh tclDate.o tcldde13g.dll tclDictObj.o
tclEncoding.o tclEnv.o tclEven
t.o tclExecute.o tclFCmd.o tclFileName.o tclGet.o
tclHash.o tclHistory.o tclInde
xObj.o tclInterp.o tclIO.o tclIOCmd.o tclIOGT.o
tclIOSock.o tclIOUtil.o tclLink.
o tclListObj.o tclLiteral.o tclLoad.o tclMain.o
tclNamesp.o tclNotify.o tclObj.o
 tclPanic.o tclParse.o tclParseExpr.o tclPathObj.o
tclpip85g.dll tclPipe.o tclPk
g.o tclPkgConfig.o tclPosixStr.o tclPreserve.o
tclProc.o tclreg11g.dll tclRegexp
.o tclResolve.o tclResult.o tclScan.o tclsh.res.o
tclsh85g.exe tclStringObj.o tc
lStubInit.o tclStubLib.o tcltest.exe tclTest.o
tclTestObj.o tclTestProcBodyObj.o
 tclThread.o tclThreadAlloc.o tclThreadJoin.o
tclThreadTest.o tclTimer.o tclTrac
e.o tclUtf.o tclUtil.o tclVar.o tclWin32Dll.o
tclWinChan.o tclWinConsole.o tclWi
nDde.o tclWinError.o tclWinFCmd.o tclWinFile.o
tclWinInit.o tclWinLoad.o tclWinN
otify.o tclWinPipe.o tclWinReg.o tclWinSerial.o
tclWinSock.o tclWinTest.o tclWin
Thrd.o tclWinTime.o testMain.o makefile.?c bar}
---- Result should have been (exact matching):
{C:/Documents and Settings/kennykb/My
Documents/SourceForge/tcl/NSK1KENNKEVI01-m
ingw/echoArgs.tcl} {foo * makefile.?c bar}
==== winpipe-8.19 FAILED
kennykbplain2004-06-12 09:08:34
Logged In: YES 
user_id=99768

mingw runtime still needs the old 'setargv' function that
was removed back in February.  I put it back, conditioned on
#if defined( __GNUC__ )
nijtmansplain2011-11-30 20:10:42
Since a few years, mingw-w64 is available, which does the
command line parsing correctly, So I would like to
finally get rid of the setargv function: This should not
be Tcl's responsibility. Working on that.
dgpplain2011-12-01 04:06:47
Why does this bug involve changes to
the tcltest package?
nijtmansplain2011-12-01 04:10:27
Modified tcltest.tcl in all branches such that it no
longer transfers default configuration arguments
to its sub-processes. This is the simplest fix, to make
at least tcltest work in all situations, no matter
how tclsh/tcltest expands its arguments.

It's an improvement which doesn't hurt: It only
modifies the command line arguments used
between the main tcltest process and its
sub-processes, it's not visible outside.
dgpplain2011-12-01 04:12:23
As the tcltest maintainer, I'd like to review patches.
dgpplain2011-12-01 04:16:23
I see this reduces the number of arguments
passed to child processes in the -singleproc 0
mode.  That seems fine.  Is the length of the
command line an issue here?
nijtmansplain2011-12-01 15:56:27
The issue was not the length of the command line, but the
fact that the command line contains '*' as one of the
arguments. In an (incorrectly) built tclsh, this expands
to multiple arguments, which screws up all Tcl tests,
not only the ones testing command line arguments.

My further ideas have nothing to do with tcltest, but
at least this change allows me to concentrate
on the real problem here.

Further idea: backport handling of
TCL_BROKEN_MAINARGS from Tcl 8.6
to 8.5 and 8.4, so the setargv() function
is only used when necessary (i.e with
cygwin and mingw32, but not mingw-w64).

Final step: I would like to discuss on Tcl-Core
removing support for mingw32 in Tcl 8.6:
There is an alternative now (mingw-w64)
which does a much better job, not only
in command line handling but in much
more areas. This means that the function
setargv() finally can be removed completely.
People ignoring this, still using mingw32,
will have a few failing tests, like winpipe-8.19,
but those rightfully point to bugs in mingw32.

Regards,
       Jan Nijtmans
nijtmansplain2012-06-12 20:09:06
I think this one can be closed now.
nijtmansplain2012-06-19 17:43:08
allow_comments - 1
Log in (anonymous is fine) to add a comment.