http://bugs.winehq.org/show_bug.cgi?id=28920
Bug #: 28920 Summary: vsvars32 PATH setting doesn't propagate to caller Product: Wine Version: 1.3.31 Platform: x86 OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: cmd AssignedTo: wine-bugs@winehq.org ReportedBy: dank@kegel.com Classification: Unclassified
Installed visual c++ 2005 express, tried to use it with windows eclipse.
After patching wine to work around bug 28915, next problem was getting PATH set before running eclipse.
Creating a batch file foo.bat that does call c:\Program Files\Microsoft Visual Studio 8\Common7\Tools\vsvars32.bat PATH shows that the PATH set by vsvars32.bat doesn't affect the parent.
Small examples do, though. Not sure what's wrong with the bigger batch file. I think this used to work.
http://bugs.winehq.org/show_bug.cgi?id=28920
Dan Kegel dank@kegel.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |DUPLICATE
--- Comment #1 from Dan Kegel dank@kegel.com 2011-10-28 13:36:10 CDT --- Frederic points out it's a dup.
*** This bug has been marked as a duplicate of bug 26749 ***
http://bugs.winehq.org/show_bug.cgi?id=28920
Dan Kegel dank@kegel.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |REOPENED Resolution|DUPLICATE |
--- Comment #2 from Dan Kegel dank@kegel.com 2011-10-28 14:00:27 CDT --- Wait, it's not really a dup. Oddly, the problem goes away if you quote the path to the batch file. Looking on the web, everybody does this, and trying it on Windows 7, the call won't even work without quotes.
So the problem seems to be that wine's cmd is too forgiving about running programs from unquoted paths, and when it does that, it runs the batch file as a new subprocess rather than as just another script, thus the settings from the batch file are lost.
http://bugs.winehq.org/show_bug.cgi?id=28920
Dan Kegel dank@kegel.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|vsvars32 PATH setting |Calling batch files with |doesn't propagate to caller |spaces in the name | |half-works, but shouldn't
http://bugs.winehq.org/show_bug.cgi?id=28920
Frédéric Delanoy frederic.delanoy@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |frederic.delanoy@gmail.com
--- Comment #3 from Frédéric Delanoy frederic.delanoy@gmail.com 2012-11-09 18:52:41 CST --- Could you please retest in current wine (1.5.17 or later), now that Jason's command-line fixes are in?
https://bugs.winehq.org/show_bug.cgi?id=28920
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|REOPENED |RESOLVED Resolution|--- |FIXED
--- Comment #4 from Austin English austinenglish@gmail.com --- With wine-1.7.26-28-ge98eee8, this fails: [austin@localhost drive_c]$ cat foo.bat call c:\Program Files\Microsoft Visual Studio 8\Common7\Tools\vsvars32.bat PATH [austin@localhost drive_c]$ wine cmd /c foo.bat
C:>call c:\Program Files\Microsoft Visual Studio 8\Common7\Tools\vsvars32.bat
C:>c:\Program Files\Microsoft Visual Studio 8\Common7\Tools\vsvars32.bat Can't recognize 'c:\Program Files\Microsoft Visual Studio 8\Common7\Tools\vsvars32.bat' as an internal or external command, or batch script.
C:>PATH PATH=C:\windows\system32;C:\windows;C:\windows\system32\wbem
It works with the path quoted: [austin@localhost drive_c]$ cat foo.bat call "c:\Program Files\Microsoft Visual Studio 8\Common7\Tools\vsvars32.bat" PATH [austin@localhost drive_c]$ wine cmd /c foo.bat
C:>call "c:\Program Files\Microsoft Visual Studio 8\Common7\Tools\vsvars32.bat" Setting environment for using Microsoft Visual Studio 2005 x86 tools.
C:>PATH PATH=C:\Program Files\Microsoft Visual Studio 8\Common7\IDE;C:\Program Files\Microsoft Visual Studio 8\VC\BIN;C:\Program Files\Microsoft Visual Studio 8\Common7\Tools;C:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\bin;C:\windows\Microsoft.NET\Framework\v2.0.50727;C:\Program Files\Microsoft Visual Studio 8\VC\VCPackages;C:\windows\system32;C:\windows;C:\windows\system32\wbem
https://bugs.winehq.org/show_bug.cgi?id=28920
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #5 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 1.7.29.