[Scons-users] Scons 2.3.2 regression for 64 bit MSVC compilers

William Deegan bill at baddogconsulting.com
Tue Jul 22 17:37:02 EDT 2014


Kay,

Greetings and welcome!

Can you do the following:
1. Create a very simple hello world example with your TARGET_ARCH settings and make sure you still have this issue?
2. If you do, in your shell “set SCONS_MSCOMMON_DEBUG=%TEMP%/scons_msdebug.log  run your simple example and then post the output to the mailing list or paste bin it somewhere?

That’ll make it much much easier to figure out what the issue is.

Thanks,
-Bill

On July 22, 2014 at 1:16:58 AM, Kay Hayen (kay.hayen at gmail.com) wrote:

Hello there,


In my Python compiler Nuitka, I specify the target architecture, as detected by  
another Python running potentially under Python3, potentially on another  
architecture. That is why I do TARGET_ARCH assignment when created the  
environment.

For Python2 though, it's running Scons with sys.executable, as that will be good  
enough for Scons for sure. But it could well be imagined, and happens, that a Python3  
compilation calls Scons with a Python2 of another architecture, as scanned from the registry.

However, I noticed that with Scons 2.3.2, only the 32 bit compiler is found, but  
when TARGET_ARCH is "x86_64", on the same system, that 2.3.0 finds it, it is not  
found. I tried to hardcode, and other name variants, to no avail.

There is something in the release notes about TARGET_ARCH no longer defaulting  
to HOST_ARCH. Not sure, if that is related. I have tried setting HOST_ARCH as well, no help either.

So here is 2.3.2 output (ignore that I am using MinGW shell):

$ /c/Python27_32/python bin/nuitka --run --show-scons tests/basics/Asserts.py
Scons command: c:\Python27_32\python.exe .\nuitka\build\inline_copy\bin\scons.py
 -f .\nuitka\build\SingleExe.scons --jobs 6 --warn=no-deprecated --no-site-dir -
-debug=explain show_scons=true python_version=2.7 unstriped_mode=false full_comp
at=true debug_mode=false target_arch=x86 optimize_mode=true source_dir=Asserts.b
uild cache_mode=true name=Asserts python_debug=false python_prefix=c:\Python27_3
2 module_count=1 result_name=Asserts nuitka_src=.\nuitka\build module_mode=false
 experimental=false
scons: Reading SConscript files ...
AssertionError: C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\BIN\cl.exe
:
  File "C:\Users\hayen\repos\Py2C\nuitka\build\SingleExe.scons", line 205:
    assert False, getExecutablePath(env["CXX"], initial = False)

$ /c/Python27_64/python bin/nuitka --run --show-scons tests/basics/Asserts.py
Scons command: c:\Python27_64\python.exe .\nuitka\build\inline_copy\bin\scons.py
 -f .\nuitka\build\SingleExe.scons --jobs 6 --warn=no-deprecated --no-site-dir -
-debug=explain show_scons=true python_version=2.7 unstriped_mode=false full_comp
at=true debug_mode=false target_arch=x86_64 optimize_mode=true source_dir=Assert
s.build cache_mode=true name=Asserts python_debug=false python_prefix=c:\Python2
7_64 module_count=1 result_name=Asserts nuitka_src=.\nuitka\build module_mode=fa
lse experimental=false
scons: Reading SConscript files ...
AssertionError: None:
  File "C:\Users\hayen\repos\Py2C\nuitka\build\SingleExe.scons", line 205:
    assert False, getExecutablePath(env["CXX"], initial = False)

I am merely dumping what env["CXX"] resolves to. No MSVC is in PATH of course.

For 2.3.0, this looks like this:


$ /c/Python27_32/python bin/nuitka --run --show-scons tests/basics/Asserts.py
Scons command: c:\Python27_32\python.exe .\nuitka\build\inline_copy\bin\scons.py
 -f .\nuitka\build\SingleExe.scons --jobs 6 --warn=no-deprecated --no-site-dir -
-debug=explain show_scons=true python_version=2.7 unstriped_mode=false full_comp
at=true debug_mode=false target_arch=x86 optimize_mode=true source_dir=Asserts.b
uild cache_mode=true name=Asserts python_debug=false python_prefix=c:\Python27_3
2 module_count=1 result_name=Asserts nuitka_src=.\nuitka\build module_mode=false
 experimental=false
scons: Reading SConscript files ...
AssertionError: C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\BIN\cl.exe
:
  File "C:\Users\hayen\repos\Py2C\nuitka\build\SingleExe.scons", line 205:
    assert False, getExecutablePath(env["CXX"], initial = False)

$ /c/Python27_64/python bin/nuitka --run --show-scons tests/basics/Asserts.py
Scons command: c:\Python27_64\python.exe .\nuitka\build\inline_copy\bin\scons.py
 -f .\nuitka\build\SingleExe.scons --jobs 6 --warn=no-deprecated --no-site-dir -
-debug=explain show_scons=true python_version=2.7 unstriped_mode=false full_comp
at=true debug_mode=false target_arch=x86_64 optimize_mode=true source_dir=Assert
s.build cache_mode=true name=Asserts python_debug=false python_prefix=c:\Python2
7_64 module_count=1 result_name=Asserts nuitka_src=.\nuitka\build module_mode=fa
lse experimental=false
scons: Reading SConscript files ...
AssertionError: C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\BIN\amd64\
cl.exe:
  File "C:\Users\hayen\repos\Py2C\nuitka\build\SingleExe.scons", line 205:
    assert False, getExecutablePath(env["CXX"], initial = False)

Any idea what is going on there?

I really would like to update the inline copy of Scons, mainly for VS 2013 support but that is kind of tough regression, that I have no clue on.

In an unrelated note, "default" is not working with Python2.6, due to the "D" compiler tool. That is quite unwelcome of course, and made me realize, that I am including too many tools, that can only slow down scons startup I suppose. I never managed to replace "default" with something else that works for MSVC. Is there a way to discover the set of used tools?

For Nuitka, the set of used tools, e.g. doesn't include "D", nor some other common tools, as it's only compiling C++, translating Windows Resource files, linking, and practically no more.

Yours,
Kay

_______________________________________________  
Scons-users mailing list  
Scons-users at scons.org  
http://four.pairlist.net/mailman/listinfo/scons-users  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://four.pairlist.net/pipermail/scons-users/attachments/20140722/d9318eb0/attachment-0001.html>


More information about the Scons-users mailing list