Re: 3.0.5 msvc path construction problem

"Joseph C. Brill" <[email protected]>
Newsgroups gmane.comp.programming.tools.scons.user
Message-ID <009a01d4e4b1$55d62970$01827c50$@com>
On 3/27/19 10:45 AM, Mats Wichmann wrote:
> tools modules add the path in which the underlying tool was found, if
> one was found (thus the JDK, for instance).  but it seems unlikely all
> of those should have been added unless your system has all of 32/64 bit
> msys, 32/64bit cygwin, and stuff installed through Chocolatey.
> 
> So  it  seems like something is letting additional paths sneak in to
> ENV['PATH']

Something is definitely letting additional paths sneak into ENV[PATH].

The cygwin path and the jdk path exist.  The rest do not.

As for the added paths:
	C:\\ProgramData\\chocolatey\\bin; <= does not exist
	C:\\msys64; <= does not exist
	C:\\msys; <= does not exist
	C:\\cygwin64\\bin; <= does not exist
	C:\\cygwin\\bin; <= exists
	C:/Program Files\\Java\\jdk1.8.0_172\\bin; <= exists

With the exception of the jdk, the remaining paths are "newly added" in 3.0.5 when compared directly to 3.0.4.

In the github issue, there is a fuller description of the local environment and ENV['PATH']:
	https://github.com/SCons/scons/issues/3336

I still don't understand (yet) why the JDK is added to the ENV[PATH] when running scons.  An msvc compile after running vcvarsall.bat from a command line console does not add the JDK to the system path.

I am manually adding the mingw-w64 binary to the path using AppendENVPath() to produce a mingw-w64 compatible import library from a msvc compiled DLL.  The location of my mingw-w64 installation is not one of the paths SCons is silently adding.  By silently adding the cygwin folder, generating a 64-bit import library from a 64-bit DLL compiled on a 32-bit platform fails (i.e., evidently the cygwin dlltool.exe does not support this or is not configured correctly when run in this context).

My expectation is that the ENV[PATH] would contain only what's necessary for the MSVC compiler tools.  Perhaps, my expectation is misguided.

Regards,
Joe






_______________________________________________
Scons-users mailing list
[email protected]
https://pairlist4.pair.net/mailman/listinfo/scons-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.